macOS: Take QT_SCALE_FACTOR into account when applying NSWindow geometry
Amends 31ec108dd08d6381a15e49b6fbec9337705c3b2a. Fixes: QTBUG-131093 Pick-to: 6.5 Change-Id: I1fa947e9b4e15c18e4638f0374a9980b2ae2e571 Reviewed-by: Vladimir Belyavsky <belyavskyv@gmail.com> Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io> (cherry picked from commit 1e7581fafbaa20971b2ff649738f6b7a95084167) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
This commit is contained in:
parent
07807794f7
commit
6ade020b22
@ -13,6 +13,8 @@
|
||||
|
||||
#include <qpa/qwindowsysteminterface.h>
|
||||
|
||||
#include <QtGui/private/qhighdpiscaling_p.h>
|
||||
|
||||
Q_LOGGING_CATEGORY(lcQpaEvents, "qt.qpa.events");
|
||||
|
||||
static bool isMouseEvent(NSEvent *ev)
|
||||
@ -233,7 +235,8 @@ NSWindow<QNSWindowProtocol> *qnswindow_cast(NSWindow *window)
|
||||
// client geometry based on the QWindow's positionPolicy is a noop.
|
||||
// Now that we have a NSWindow to read the frame from we re-apply
|
||||
// the QWindow geometry, which will move the NSWindow if needed.
|
||||
m_platformWindow->setGeometry(window->geometry());
|
||||
m_platformWindow->setGeometry(QHighDpi::toNativeWindowGeometry(window->geometry(), window));
|
||||
|
||||
|
||||
m_platformWindow->setVisible(window->isVisible());
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user