diff options
author | Friedemann Kleint <Friedemann.Kleint@nokia.com> | 2012-07-20 12:49:12 +0200 |
---|---|---|
committer | Qt by Nokia <qt-info@nokia.com> | 2012-07-25 07:24:49 +0200 |
commit | 4677cf3d014d9b25c3516dd0e07a1a3fcd8af8e9 (patch) | |
tree | d2e8f109b850c13346c85b6e3dca0077530ac45b /tests/auto/gui/kernel/qwindow | |
parent | a4cd6ef25df6a2a99626a0e97bfc239f68e7771f (diff) |
Deprecate the qWaitForWindowShown(QWindow *) method.
While the qWaitForWindowShown(QWidget *) is inherited
from Qt 4.8, the qWaitForWindowShown(QWindow *) was introduced
in Qt 5. As it is identical to qWaitForWindowExposed()
and removed already, it can be deprecated in Qt 5.
Remove its usages in qtbase.
Change-Id: I28788d120ad687a49f02b2b44de6b38a2832fe5c
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
Reviewed-by: Jason McDonald <jason.mcdonald@nokia.com>
Diffstat (limited to 'tests/auto/gui/kernel/qwindow')
-rw-r--r-- | tests/auto/gui/kernel/qwindow/tst_qwindow.cpp | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/tests/auto/gui/kernel/qwindow/tst_qwindow.cpp b/tests/auto/gui/kernel/qwindow/tst_qwindow.cpp index 73f70fbe3c..f2393f905e 100644 --- a/tests/auto/gui/kernel/qwindow/tst_qwindow.cpp +++ b/tests/auto/gui/kernel/qwindow/tst_qwindow.cpp @@ -420,7 +420,7 @@ void tst_QWindow::testInputEvents() InputTestWindow window; window.setGeometry(80, 80, 40, 40); window.show(); - QTest::qWaitForWindowShown(&window); + QVERIFY(QTest::qWaitForWindowExposed(&window)); QWindowSystemInterface::handleKeyEvent(&window, QEvent::KeyPress, Qt::Key_A, Qt::NoModifier); QWindowSystemInterface::handleKeyEvent(&window, QEvent::KeyRelease, Qt::Key_A, Qt::NoModifier); @@ -478,7 +478,7 @@ void tst_QWindow::touchToMouseTranslation() window.ignoreTouch = true; window.setGeometry(80, 80, 40, 40); window.show(); - QTest::qWaitForWindowShown(&window); + QVERIFY(QTest::qWaitForWindowExposed(&window)); QList<QWindowSystemInterface::TouchPoint> points; QWindowSystemInterface::TouchPoint tp1, tp2; @@ -554,7 +554,7 @@ void tst_QWindow::mouseToTouchTranslation() window.ignoreMouse = true; window.setGeometry(80, 80, 40, 40); window.show(); - QTest::qWaitForWindowShown(&window); + QVERIFY(QTest::qWaitForWindowExposed(&window)); QWindowSystemInterface::handleMouseEvent(&window, QPoint(10, 10), window.mapToGlobal(QPoint(10, 10)), Qt::LeftButton); QWindowSystemInterface::handleMouseEvent(&window, QPoint(10, 10), window.mapToGlobal(QPoint(10, 10)), Qt::NoButton); @@ -603,7 +603,7 @@ void tst_QWindow::mouseToTouchLoop() window.ignoreTouch = true; window.setGeometry(80, 80, 40, 40); window.show(); - QTest::qWaitForWindowShown(&window); + QVERIFY(QTest::qWaitForWindowExposed(&window)); QWindowSystemInterface::handleMouseEvent(&window, QPoint(10, 10), window.mapToGlobal(QPoint(10, 10)), Qt::LeftButton); QWindowSystemInterface::handleMouseEvent(&window, QPoint(10, 10), window.mapToGlobal(QPoint(10, 10)), Qt::NoButton); @@ -618,7 +618,7 @@ void tst_QWindow::touchCancel() InputTestWindow window; window.setGeometry(80, 80, 40, 40); window.show(); - QTest::qWaitForWindowShown(&window); + QVERIFY(QTest::qWaitForWindowExposed(&window)); QList<QWindowSystemInterface::TouchPoint> points; QWindowSystemInterface::TouchPoint tp1; @@ -678,7 +678,7 @@ void tst_QWindow::touchCancelWithTouchToMouse() window.ignoreTouch = true; window.setGeometry(80, 80, 40, 40); window.show(); - QTest::qWaitForWindowShown(&window); + QVERIFY(QTest::qWaitForWindowExposed(&window)); QList<QWindowSystemInterface::TouchPoint> points; QWindowSystemInterface::TouchPoint tp1; @@ -757,9 +757,9 @@ void tst_QWindow::activateAndClose() for (int i = 0; i < 10; ++i) { QWindow window; window.show(); - QTest::qWaitForWindowShown(&window); window.requestActivateWindow(); - QTRY_COMPARE(qGuiApp->focusWindow(), &window); + QVERIFY(QTest::qWaitForWindowActive(&window)); + QCOMPARE(qGuiApp->focusWindow(), &window); } } @@ -770,7 +770,7 @@ void tst_QWindow::mouseEventSequence() InputTestWindow window; window.setGeometry(80, 80, 40, 40); window.show(); - QTest::qWaitForWindowShown(&window); + QVERIFY(QTest::qWaitForWindowExposed(&window)); ulong timestamp = 0; QPointF local(12, 34); @@ -892,7 +892,7 @@ void tst_QWindow::inputReentrancy() window.setGeometry(80, 80, 40, 40); window.show(); - QTest::qWaitForWindowShown(&window); + QVERIFY(QTest::qWaitForWindowExposed(&window)); // Queue three events. QPointF local(12, 34); |