From d07bd1b22f6da2fcf961618b59f10f59d0a95d16 Mon Sep 17 00:00:00 2001 From: Richard Moe Gustavsen Date: Tue, 11 Dec 2012 12:07:05 +0100 Subject: iOS: remove the view from the view hierarchy upon destruction MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit We need to remove the view that backs QWindow when the window is destroyed. Otherwise the view will still be visible on screen, but now with a dangling QWindow pointer. This fixes a crash that happens when closing dialogs. Change-Id: I9053c83c6db80a39f4f71a63993cc7ae73fc4196 Reviewed-by: Tor Arne Vestbø --- src/plugins/platforms/ios/qioswindow.mm | 1 + 1 file changed, 1 insertion(+) (limited to 'src') diff --git a/src/plugins/platforms/ios/qioswindow.mm b/src/plugins/platforms/ios/qioswindow.mm index 90734e58e8..871a046c71 100644 --- a/src/plugins/platforms/ios/qioswindow.mm +++ b/src/plugins/platforms/ios/qioswindow.mm @@ -221,6 +221,7 @@ QIOSWindow::~QIOSWindow() if (m_glData.depthRenderbuffer) glDeleteRenderbuffers(1, &m_glData.depthRenderbuffer); + [m_view removeFromSuperview]; [m_view release]; } -- cgit v1.2.3