iOS: Handle key window as part of QWindow activation

The default UIWindow may not be the only UIWindow around in a multi
screen setup.

Change-Id: Ia7243190321a1416e577634bf5e010dd67d482e6
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@digia.com>
bb10
Tor Arne Vestbø 2013-11-11 16:33:21 +01:00 committed by The Qt Project
parent e6eadd6f61
commit 18182a6275
2 changed files with 3 additions and 1 deletions

View File

@ -64,7 +64,7 @@
self.window.backgroundColor = [UIColor cyanColor];
#endif
[self.window makeKeyAndVisible];
self.window.hidden = NO;
return YES;
}

View File

@ -456,6 +456,8 @@ void QIOSWindow::requestActivateWindow()
if (!window()->isTopLevel() || blockedByModal())
return;
[m_view.window makeKeyWindow];
raise();
QPlatformInputContext *context = QGuiApplicationPrivate::platformIntegration()->inputContext();
static_cast<QIOSInputContext *>(context)->focusViewChanged(m_view);