slime wrote:I'm not sure - I think this is up to SDL, but looking at its code for creating the keyboard on iOS it has this line: "textField.returnKeyType = UIReturnKeyDefault;" which shouldn't make it go away when pressing the return key.
So do I need to put that line in the LÖVE or SDL code somewhere?
Ivo wrote:So do I need to put that line in the LÖVE or SDL code somewhere?
No, SDL's code already contains that line. I was confused because normally that should make the return button behave like you want, but I dug a little deeper into SDL's iOS code and found this:
Which is what's causing the text input dialog to always close when return is pressed. Since it's hardcoded into SDL's source, LÖVE can't override it in its own code (and there are situations where you'd want it to auto-close, too.)
Ivo wrote:So do I need to put that line in the LÖVE or SDL code somewhere?
No, SDL's code already contains that line. I was confused because normally that should make the return button behave like you want, but I dug a little deeper into SDL's iOS code and found this:
Which is what's causing the text input dialog to always close when return is pressed. Since it's hardcoded into SDL's source, LÖVE can't override it in its own code (and there are situations where you'd want it to auto-close, too.)
would it work like I want it to? Where can I find that line, do I need to download SDL for iOS and edit and compile it and put something in the love folder?
If you comment out the "SDL_StopTextInput();" line (line #303 in src/video/uikit/SDL_uikitview.m in SDL's current source) and recompile SDL for iOS it should work as you want, although I haven't tested it.
slime wrote:If you comment out the "SDL_StopTextInput();" line (line #303 in src/video/uikit/SDL_uikitview.m in SDL's current source) and recompile SDL for iOS it should work as you want, although I haven't tested it.
xpol wrote:I got a bit lag when running the no game in the iOS Simulator.
The sprites move not as smooth as the PC version.
That's probably because it's a simulator. The emulation of iOS hardware on a computer is (somewhat) computationally expensive so it would be strange if it didn't lag. And lag in an emulator does not necessarily mean it will lag on a real device.
The iOS Simulator uses software rendering for OpenGL ES instead of taking advantage of the computer's GPU.
Even though the no-game screen is really simple and no problem for a real GPU, a software renderer will almost always be orders of magnitude slower than hardware rendering, plus the no-game screen involves a lot of blending which is particularly slow for a software renderer.