Skip to content
This repository has been archived by the owner. It is now read-only.
Browse files
We can't check for the screen keyboard in the event code because the …
…video system isn't fully initialized yet.
  • Loading branch information
slouken committed Nov 9, 2012
1 parent c31aec7 commit 92b2d880f1bc3d01d614e45de906f19329181f2e

File 2 of 2 in 92b2d88

@@ -522,6 +522,17 @@ SDL_VideoInit(const char *driver_name)
_this->DestroyWindowFramebuffer = SDL_DestroyWindowTexture;

/* If we don't use a screen keyboard, turn on text input by default,
otherwise programs that expect to get text events without enabling
UNICODE input won't get any events.
Actually, come to think of it, you needed to call SDL_EnableUNICODE(1)
in SDL 1.2 before you got text input events. Hmm...
if (!SDL_HasScreenKeyboardSupport()) {

/* We're ready to go! */
return 0;
@@ -2831,7 +2842,12 @@ SDL_HasScreenKeyboardSupport(void)
if (_this && _this->SDL_HasScreenKeyboardSupport) {
return _this->SDL_HasScreenKeyboardSupport(_this);
/* FIXME: The event system queries this before we initialize our video driver */
#if __IPHONEOS__ || __ANDROID__
return SDL_TRUE;
return SDL_FALSE;


0 comments on commit 92b2d88

Please sign in to comment.