diff options
-rw-r--r-- | src/gui/kernel/qguiapplication.cpp | 13 | ||||
-rw-r--r-- | src/gui/kernel/qwindowsysteminterface.cpp | 3 | ||||
-rw-r--r-- | tests/auto/corelib/kernel/qtimer/tst_qtimer.cpp | 6 |
3 files changed, 17 insertions, 5 deletions
diff --git a/src/gui/kernel/qguiapplication.cpp b/src/gui/kernel/qguiapplication.cpp index 1dd019cd55..c0b0acbda6 100644 --- a/src/gui/kernel/qguiapplication.cpp +++ b/src/gui/kernel/qguiapplication.cpp @@ -634,6 +634,18 @@ QGuiApplication::~QGuiApplication() QGuiApplicationPrivate::m_inputDeviceManager = 0; delete QGuiApplicationPrivate::desktopFileName; QGuiApplicationPrivate::desktopFileName = 0; + QGuiApplicationPrivate::mouse_buttons = Qt::NoButton; + QGuiApplicationPrivate::modifier_buttons = Qt::NoModifier; + QGuiApplicationPrivate::lastCursorPosition = {qInf(), qInf()}; + QGuiApplicationPrivate::currentMousePressWindow = QGuiApplicationPrivate::currentMouseWindow = nullptr; + QGuiApplicationPrivate::applicationState = Qt::ApplicationInactive; + QGuiApplicationPrivate::highDpiScalingUpdated = false; + QGuiApplicationPrivate::tabletDevicePoints.clear(); +#ifndef QT_NO_SESSIONMANAGER + QGuiApplicationPrivate::is_fallback_session_management_enabled = true; +#endif + QGuiApplicationPrivate::mousePressTime = 0; + QGuiApplicationPrivate::mousePressX = QGuiApplicationPrivate::mousePressY = 0; } QGuiApplicationPrivate::QGuiApplicationPrivate(int &argc, char **argv, int flags) @@ -1531,6 +1543,7 @@ QGuiApplicationPrivate::~QGuiApplicationPrivate() delete m_a32ColorProfile.load(); window_list.clear(); + screen_list.clear(); } #if 0 diff --git a/src/gui/kernel/qwindowsysteminterface.cpp b/src/gui/kernel/qwindowsysteminterface.cpp index 7f25ed76c3..3982b5568e 100644 --- a/src/gui/kernel/qwindowsysteminterface.cpp +++ b/src/gui/kernel/qwindowsysteminterface.cpp @@ -215,7 +215,8 @@ bool QWindowSystemEventHandler::sendEvent(QWindowSystemInterfacePrivate::WindowS QT_DEFINE_QPA_EVENT_HANDLER(void, handleEnterEvent, QWindow *window, const QPointF &local, const QPointF &global) { if (window) { - QWindowSystemInterfacePrivate::EnterEvent *e = new QWindowSystemInterfacePrivate::EnterEvent(window, local, global); + QWindowSystemInterfacePrivate::EnterEvent *e + = new QWindowSystemInterfacePrivate::EnterEvent(window, QHighDpi::fromNativeLocalPosition(local, window), QHighDpi::fromNativePixels(global, window)); QWindowSystemInterfacePrivate::handleWindowSystemEvent<Delivery>(e); } } diff --git a/tests/auto/corelib/kernel/qtimer/tst_qtimer.cpp b/tests/auto/corelib/kernel/qtimer/tst_qtimer.cpp index 3c2989831e..d2035a088e 100644 --- a/tests/auto/corelib/kernel/qtimer/tst_qtimer.cpp +++ b/tests/auto/corelib/kernel/qtimer/tst_qtimer.cpp @@ -144,12 +144,10 @@ void tst_QTimer::timeout() QCOMPARE(helper.count, 0); - QTest::qWait(TIMEOUT_TIMEOUT); - QVERIFY(helper.count > 0); + QTRY_VERIFY_WITH_TIMEOUT(helper.count > 0, TIMEOUT_TIMEOUT); int oldCount = helper.count; - QTest::qWait(TIMEOUT_TIMEOUT); - QVERIFY(helper.count > oldCount); + QTRY_VERIFY_WITH_TIMEOUT(helper.count > oldCount, TIMEOUT_TIMEOUT); } void tst_QTimer::remainingTime() |