iOS: Fixed crashes when rotating the screen after destroying a window.
authorAlex Szpakowski <slime73@gmail.com>
Thu, 12 Nov 2015 20:58:11 -0400
changeset 9911 7423403b70da
parent 9910 3ef321f52ca5
child 9912 628225876708
iOS: Fixed crashes when rotating the screen after destroying a window.
src/video/uikit/SDL_uikitwindow.m
--- a/src/video/uikit/SDL_uikitwindow.m	Thu Nov 12 13:13:36 2015 -0800
+++ b/src/video/uikit/SDL_uikitwindow.m	Thu Nov 12 20:58:11 2015 -0400
@@ -316,6 +316,9 @@
             for (SDL_uikitview *view in views) {
                 [view setSDLWindow:NULL];
             }
+
+            data.uiwindow.rootViewController = nil;
+            data.uiwindow.hidden = YES;
         }
     }
     window->driverdata = NULL;