mirror of
https://github.com/yawut/SDL.git
synced 2026-04-18 22:57:25 -05:00
Leave text input enabled unless text input shows some on-screen UI elements
This commit is contained in:
parent
8d286a8753
commit
8deae22cac
|
|
@ -125,10 +125,14 @@ SDL_StartEventLoop(void)
|
|||
|
||||
/* No filter to start with, process most event types */
|
||||
SDL_EventOK = NULL;
|
||||
SDL_EventState(SDL_TEXTINPUT, SDL_DISABLE);
|
||||
SDL_EventState(SDL_TEXTEDITING, SDL_DISABLE);
|
||||
SDL_EventState(SDL_SYSWMEVENT, SDL_DISABLE);
|
||||
|
||||
/* If text input shows UI onscreen we want to start with it disabled */
|
||||
if (SDL_HasScreenKeyboardSupport()) {
|
||||
SDL_EventState(SDL_TEXTINPUT, SDL_DISABLE);
|
||||
SDL_EventState(SDL_TEXTEDITING, SDL_DISABLE);
|
||||
}
|
||||
|
||||
/* Create the lock and set ourselves active */
|
||||
#if !SDL_THREADS_DISABLED
|
||||
if (!SDL_EventQ.lock) {
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user