diff options
authorTor Arne Vestbø <>2019-05-09 15:07:22 +0200
committerTor Arne Vestbø <>2019-05-10 17:15:29 +0000
commitc99678fb19e579466f2a9e4df626de3cdb51f272 (patch)
parent123053bba8dc2241041c31a262420edd3583b1c7 (diff)
macOS: Deliver geometry changes when content view changes frame
This was disabled in 9f22ac0aa0254f20f9b26aec7b124d74141fdfcd under the assumption that the windowDidResize callback was sufficient, but in the situation when macOS native tabs are enabled, AppKit will report the wrong geometry for the first windowDidResize callback when a new tab is created. We could potentially remove the geometry change in windowDidResize, as the viewDidChangeFrame callback should be enough for content views, but this is something that needs more investigation. Change-Id: I85045507da1a01b4a906e6f88301f3321c660943 Fixes: QTBUG-75482 Reviewed-by: Morten Johan Sørvig <> Reviewed-by: Tor Arne Vestbø <>
1 files changed, 5 insertions, 3 deletions
diff --git a/src/plugins/platforms/cocoa/ b/src/plugins/platforms/cocoa/
index f992248275..d0ad1791c3 100644
--- a/src/plugins/platforms/cocoa/
+++ b/src/plugins/platforms/cocoa/
@@ -1085,9 +1085,11 @@ void QCocoaWindow::setEmbeddedInForeignView()
void QCocoaWindow::viewDidChangeFrame()
- if (isContentView())
- return; // Handled below
+ // Note: When the view is the content view, it would seem redundant
+ // to deliver geometry changes both from windowDidResize and this
+ // callback, but in some cases such as when macOS native tabbed
+ // windows are enabled we may end up with the wrong geometry in
+ // the initial windowDidResize callback when a new tab is created.