mirror of
https://github.com/encounter/SDL.git
synced 2025-12-16 00:17:18 +00:00
Android: better fix for bug 3186. Run those commands from SDL thread.
This commit is contained in:
@@ -107,6 +107,12 @@ Android_PumpEvents(_THIS)
|
||||
android_egl_context_restore(Android_Window);
|
||||
SDL_UnlockMutex(Android_ActivityMutex);
|
||||
}
|
||||
|
||||
/* Make sure SW Keyboard is restored when an app becomes foreground */
|
||||
if (SDL_IsTextInputActive()) {
|
||||
SDL_VideoDevice *_this = SDL_GetVideoDevice();
|
||||
Android_StartTextInput(_this); /* Only showTextInput */
|
||||
}
|
||||
}
|
||||
} else {
|
||||
if (isPausing || SDL_SemTryWait(Android_PauseSem) == 0) {
|
||||
@@ -144,6 +150,12 @@ Android_PumpEvents(_THIS)
|
||||
android_egl_context_restore(Android_Window);
|
||||
SDL_UnlockMutex(Android_ActivityMutex);
|
||||
}
|
||||
|
||||
/* Make sure SW Keyboard is restored when an app becomes foreground */
|
||||
if (SDL_IsTextInputActive()) {
|
||||
SDL_VideoDevice *_this = SDL_GetVideoDevice();
|
||||
Android_StartTextInput(_this); /* Only showTextInput */
|
||||
}
|
||||
}
|
||||
} else {
|
||||
if (SDL_SemTryWait(Android_PauseSem) == 0) {
|
||||
|
||||
Reference in New Issue
Block a user