diff options
Diffstat (limited to 'tests/auto/gui/kernel/qwindow/tst_qwindow.cpp')
-rw-r--r-- | tests/auto/gui/kernel/qwindow/tst_qwindow.cpp | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/tests/auto/gui/kernel/qwindow/tst_qwindow.cpp b/tests/auto/gui/kernel/qwindow/tst_qwindow.cpp index e0010fb8be..6ec0268d96 100644 --- a/tests/auto/gui/kernel/qwindow/tst_qwindow.cpp +++ b/tests/auto/gui/kernel/qwindow/tst_qwindow.cpp @@ -40,7 +40,7 @@ #if defined(Q_OS_QNX) #include <QOpenGLContext> -#elif defined(Q_OS_WIN) && !defined(Q_OS_WINCE) && !defined(Q_OS_WINRT) +#elif defined(Q_OS_WIN) && !defined(Q_OS_WINRT) # include <QtCore/qt_windows.h> #endif @@ -106,7 +106,7 @@ private slots: private: QPoint m_availableTopLeft; QSize m_testWindowSize; - QTouchDevice *touchDevice; + QTouchDevice *touchDevice = QTest::createTouchDevice(); }; void tst_QWindow::initTestCase() @@ -120,9 +120,6 @@ void tst_QWindow::initTestCase() if (screenWidth > 2000) width = 100 * ((screenWidth + 500) / 1000); m_testWindowSize = QSize(width, width); - touchDevice = new QTouchDevice; - touchDevice->setType(QTouchDevice::TouchScreen); - QWindowSystemInterface::registerTouchDevice(touchDevice); } void tst_QWindow::cleanup() @@ -2116,7 +2113,7 @@ void tst_QWindow::modalWindowEnterEventOnHide_QTBUG35109() static bool isNativeWindowVisible(const QWindow *window) { -#if defined(Q_OS_WIN) && !defined(Q_OS_WINCE) && !defined(Q_OS_WINRT) +#if defined(Q_OS_WIN) && !defined(Q_OS_WINRT) return IsWindowVisible(reinterpret_cast<HWND>(window->winId())); #else Q_UNIMPLEMENTED(); |