diff options
author | Richard Moe Gustavsen <richard.gustavsen@nokia.com> | 2010-02-04 11:21:24 (GMT) |
---|---|---|
committer | Richard Moe Gustavsen <richard.gustavsen@nokia.com> | 2010-02-04 11:25:37 (GMT) |
commit | 818ef4e93f40f2c3c6cf9d2a0a1fc42150f0d0cd (patch) | |
tree | a663338a14cb947ec0013348bda9e37936482aa6 /src/gui/kernel/qcocoawindowdelegate_mac.mm | |
parent | c111ccb7ff961c76e424bfab3a3bf6a1b43865dc (diff) | |
download | Qt-818ef4e93f40f2c3c6cf9d2a0a1fc42150f0d0cd.zip Qt-818ef4e93f40f2c3c6cf9d2a0a1fc42150f0d0cd.tar.gz Qt-818ef4e93f40f2c3c6cf9d2a0a1fc42150f0d0cd.tar.bz2 |
Cocoa: Tool Windows steal focus from the main window
The example that shows this off is tools/inputpanel. This example is
strangely written, and calls activateWindow on the main window in an
activate callback to another window. So a bit recursion will happend,
and this caused troubble for the cocoa port. In addition, in Qt several
windows can be active at the same time, expecially tool windows. This
means that we need to be careful when returning early from the
becomeKeyWindow methods for NSWindow. This patch fixes up on this stuff.
Task-number: QTBUG-6002
Reviewed-by: msorvig
Diffstat (limited to 'src/gui/kernel/qcocoawindowdelegate_mac.mm')
-rw-r--r-- | src/gui/kernel/qcocoawindowdelegate_mac.mm | 7 |
1 files changed, 0 insertions, 7 deletions
diff --git a/src/gui/kernel/qcocoawindowdelegate_mac.mm b/src/gui/kernel/qcocoawindowdelegate_mac.mm index db87491..24498f8 100644 --- a/src/gui/kernel/qcocoawindowdelegate_mac.mm +++ b/src/gui/kernel/qcocoawindowdelegate_mac.mm @@ -269,9 +269,6 @@ static void cleanupCocoaWindowDelegate() { QWidget *qwidget = m_windowHash->value([notification object]); Q_ASSERT(qwidget); - if (qwidget->isActiveWindow()) - return; // Widget is already active, no need to go through re-activation. - onApplicationWindowChangedActivation(qwidget, true); } @@ -288,10 +285,6 @@ static void cleanupCocoaWindowDelegate() { QWidget *qwidget = m_windowHash->value([notification object]); Q_ASSERT(qwidget); - if (qwidget->isActiveWindow()) - return; // Widget is already active, no need to go through re-activation - - onApplicationWindowChangedActivation(qwidget, true); } |