diff options
author | Tor Arne Vestbø <tor.arne.vestbo@theqtcompany.com> | 2015-09-30 19:03:51 +0200 |
---|---|---|
committer | Tor Arne Vestbø <tor.arne.vestbo@theqtcompany.com> | 2015-10-13 10:45:05 +0000 |
commit | 86fdf2c914ec5e4867cc7fa281db190d9583f960 (patch) | |
tree | ae528f7b2603162756274cbb2cb3564182051aba | |
parent | dfa4361183a7a189b087b18e01c89d1c1adbc088 (diff) |
Remove special handling of popup windows on OS X
The handling should be taken care of at the QPA level, not in the
individual QWindow subclasses.
Change-Id: Iff564dac0c997eb97b426962d126e88c4703cdaa
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@theqtcompany.com>
-rw-r--r-- | src/quick/items/qquickwindow.cpp | 14 |
1 files changed, 0 insertions, 14 deletions
diff --git a/src/quick/items/qquickwindow.cpp b/src/quick/items/qquickwindow.cpp index 98d16709b7..c8256ed62a 100644 --- a/src/quick/items/qquickwindow.cpp +++ b/src/quick/items/qquickwindow.cpp @@ -1436,20 +1436,6 @@ void QQuickWindowPrivate::deliverKeyEvent(QKeyEvent *e) if (activeFocusItem) q->sendEvent(activeFocusItem, e); -#ifdef Q_OS_MAC - else { - // This is the case for popup windows on Mac, where popup windows get focus - // in Qt (after exposure) but they are not "key windows" in the Cocoa sense. - // Therefore, the will never receive key events from Cocoa. Instead, the - // toplevel non-popup window (the application current "key window") will - // receive them. (QWidgetWindow does something similar for widgets, by keeping - // a list of popup windows, and forwarding the key event to the top-most popup.) - QWindow *focusWindow = QGuiApplication::focusWindow(); - if (focusWindow && focusWindow != q - && (focusWindow->flags() & Qt::Popup) == Qt::Popup) - QGuiApplication::sendEvent(focusWindow, e); - } -#endif } QMouseEvent *QQuickWindowPrivate::cloneMouseEvent(QMouseEvent *event, QPointF *transformedLocalPos) |