QCocoaWindow - resize embedded views
when QCocoaWindow::setCocoaGeometry is called on windows embedded into a native cocoa gui, QPlatformWindow::setGeometry does not apply the geometry. we therefore need to set the frame on the embedded view manually. related tasks: Task-number: QTBUG-47632 Task-number: QTBUG-45269 Change-Id: I976e4606d36bb4afc74b0834105bceab8a6f8cbd Reviewed-by: Morten Johan Sørvig <morten.sorvig@theqtcompany.com>
This commit is contained in:
parent
40804ad868
commit
0150cd3617
@ -503,7 +503,11 @@ void QCocoaWindow::setCocoaGeometry(const QRect &rect)
|
||||
QMacAutoReleasePool pool;
|
||||
|
||||
if (m_contentViewIsEmbedded) {
|
||||
QPlatformWindow::setGeometry(rect);
|
||||
if (m_qtView) {
|
||||
[m_qtView setFrame:NSMakeRect(0, 0, rect.width(), rect.height())];
|
||||
} else {
|
||||
QPlatformWindow::setGeometry(rect);
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user