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 <gabriel.dedietrich@digia.com> Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
This commit is contained in:
parent
86f8bee96b
commit
a2bdda8e3b
@ -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;
|
||||
|
Loading…
Reference in New Issue
Block a user