diff options
author | Shawn Rutledge <shawn.rutledge@qt.io> | 2020-07-13 13:40:04 +0200 |
---|---|---|
committer | Shawn Rutledge <shawn.rutledge@qt.io> | 2020-07-15 20:52:59 +0200 |
commit | c0e72e34863a5628c51e5c3bb42bcc455c310340 (patch) | |
tree | 71e661d2c54258a756087627227f4feb39521bae /tests/auto/quick/qquickflickable/tst_qquickflickable.cpp | |
parent | 151f58dc29f4b53fb46a96d773aee8641593e5c7 (diff) |
Replace QTouchEvent::TouchPoint with QEventPoint
It's a cosmetic change at this time, because we have declared
using TouchPoint = QEventPoint;
Also replace Qt::TouchPointState enum with QEventPoint::State.
Task-number: QTBUG-72173
Change-Id: Ife017aa98801c28abc6cccd106f47a95421549de
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
Diffstat (limited to 'tests/auto/quick/qquickflickable/tst_qquickflickable.cpp')
-rw-r--r-- | tests/auto/quick/qquickflickable/tst_qquickflickable.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/tests/auto/quick/qquickflickable/tst_qquickflickable.cpp b/tests/auto/quick/qquickflickable/tst_qquickflickable.cpp index a3340c0e3a..f6a6ab17b4 100644 --- a/tests/auto/quick/qquickflickable/tst_qquickflickable.cpp +++ b/tests/auto/quick/qquickflickable/tst_qquickflickable.cpp @@ -92,7 +92,7 @@ public: int touchUpdates; int touchReleases; int ungrabs; - QVector<Qt::TouchPointState> touchPointStates; + QVector<QEventPoint::State> touchPointStates; protected: void touchEvent(QTouchEvent *ev) override @@ -100,21 +100,21 @@ protected: QCOMPARE(ev->touchPoints().count(), 1); auto touchpoint = ev->touchPoints().first(); switch (touchpoint.state()) { - case Qt::TouchPointPressed: + case QEventPoint::State::Pressed: QVERIFY(!m_active); m_active = true; emit activeChanged(); grabTouchPoints(QList<int>() << touchpoint.id()); break; - case Qt::TouchPointMoved: + case QEventPoint::State::Updated: ++touchUpdates; break; - case Qt::TouchPointReleased: + case QEventPoint::State::Released: QVERIFY(m_active); m_active = false; ++touchReleases; emit activeChanged(); - case Qt::TouchPointStationary: + case QEventPoint::State::Stationary: break; } touchPointStates << touchpoint.state(); @@ -2068,7 +2068,7 @@ void tst_qquickflickable::nestedSliderUsingTouch() QCOMPARE(tda->active(), !ungrabs); QTest::touchEvent(window, touchDevice).release(0, p0, window); QQuickTouchUtils::flush(window); - QTRY_COMPARE(tda->touchPointStates.first(), Qt::TouchPointPressed); + QTRY_COMPARE(tda->touchPointStates.first(), QEventPoint::State::Pressed); QTRY_VERIFY(tda->touchUpdates >= minUpdates); QTRY_COMPARE(tda->touchReleases, releases); QTRY_COMPARE(tda->ungrabs, ungrabs); |