1.1 --- a/src/core/android/SDL_android.c Wed Jan 16 10:31:51 2019 +0100
1.2 +++ b/src/core/android/SDL_android.c Wed Jan 16 10:48:28 2019 +0100
1.3 @@ -700,11 +700,15 @@
1.4 JNIEnv *env, jclass jcls,
1.5 jint orientation)
1.6 {
1.7 - SDL_VideoDevice *_this = SDL_GetVideoDevice();
1.8 - if (_this) {
1.9 + SDL_LockMutex(Android_ActivityMutex);
1.10 +
1.11 + if (Android_Window)
1.12 + {
1.13 SDL_VideoDisplay *display = SDL_GetDisplay(0);
1.14 SDL_SendDisplayEvent(display, SDL_DISPLAYEVENT_ORIENTATION, orientation);
1.15 }
1.16 +
1.17 + SDL_UnlockMutex(Android_ActivityMutex);
1.18 }
1.19
1.20 JNIEXPORT void JNICALL SDL_JAVA_INTERFACE(nativeAddTouch)(