path: root/src
diff options
authorMorten Johan Sørvig <>2013-08-30 14:20:21 +0200
committerThe Qt Project <>2013-09-04 17:52:15 +0200
commita2bdda8e3ba324a51620d9e758e444d02c4fd061 (patch)
tree2f6830f8265880ff6fc7ab846be2e34d23eb194a /src
parent86f8bee96b658d1712733477e26e70a1fd723102 (diff)
Fix event delivery for apps with native widgets.
Native widgets, which have a NSView but not a NSWindow, must be created in the hidden state to prevent Cocoa from selecting them for event delivery. Change-Id: I741e52729047ad4e03959f2244abe5b14b5df46b Reviewed-by: Gabriel de Dietrich <> Reviewed-by: Morten Johan Sørvig <>
Diffstat (limited to 'src')
1 files changed, 1 insertions, 0 deletions
diff --git a/src/plugins/platforms/cocoa/ b/src/plugins/platforms/cocoa/
index 86f12e0e5f..a3797682a3 100644
--- a/src/plugins/platforms/cocoa/
+++ b/src/plugins/platforms/cocoa/
@@ -792,6 +792,7 @@ void QCocoaWindow::recreateWindow(const QPlatformWindow *parentWindow)
QRect rect = window()->geometry();
NSRect frame = NSMakeRect(rect.x(), rect.y(), rect.width(), rect.height());
[m_contentView setFrame:frame];
+ [m_contentView setHidden: YES];
const qreal opacity = qt_window_private(window())->opacity;