summaryrefslogtreecommitdiffstats
path: root/tests/auto/widgets/qwebengineview/tst_qwebengineview.cpp
diff options
context:
space:
mode:
authorAllan Sandfeld Jensen <allan.jensen@qt.io>2020-10-27 11:28:30 +0100
committerAllan Sandfeld Jensen <allan.jensen@qt.io>2020-11-02 12:42:10 +0100
commit13ac394567cb287c5caceef15f531544d73fde09 (patch)
tree38a497e108b6de6c98e9621e75def96dd8b6a55e /tests/auto/widgets/qwebengineview/tst_qwebengineview.cpp
parentf51f50c22e770e1ab20ecccc8a32906e4014caed (diff)
Update dependencies on 'dev' in qt/qtwebengine
Change-Id: I74c7293ebf5ace5bd07e3bf5455dd90bf4ed6380 Reviewed-by: Michal Klocek <michal.klocek@qt.io>
Diffstat (limited to 'tests/auto/widgets/qwebengineview/tst_qwebengineview.cpp')
-rw-r--r--tests/auto/widgets/qwebengineview/tst_qwebengineview.cpp16
1 files changed, 8 insertions, 8 deletions
diff --git a/tests/auto/widgets/qwebengineview/tst_qwebengineview.cpp b/tests/auto/widgets/qwebengineview/tst_qwebengineview.cpp
index f905234e3..81e3600b1 100644
--- a/tests/auto/widgets/qwebengineview/tst_qwebengineview.cpp
+++ b/tests/auto/widgets/qwebengineview/tst_qwebengineview.cpp
@@ -1543,9 +1543,9 @@ void tst_QWebEngineView::touchTap()
QVERIFY(evaluateJavaScriptSync(view.page(), "document.activeElement.id").toString().isEmpty());
auto singleTap = [](QWidget* target, const QPoint& tapCoords) -> void {
- QTest::touchEvent(target, s_touchDevice).press(1, tapCoords, target);
- QTest::touchEvent(target, s_touchDevice).stationary(1);
- QTest::touchEvent(target, s_touchDevice).release(1, tapCoords, target);
+ QTest::touchEvent(target->window(), s_touchDevice).press(0, tapCoords, target);
+ QTest::touchEvent(target->window(), s_touchDevice).stationary(0);
+ QTest::touchEvent(target->window(), s_touchDevice).release(0, tapCoords, target);
};
// Single tap on text doesn't trigger a selection
@@ -1604,10 +1604,10 @@ void tst_QWebEngineView::touchTapAndHold()
QVERIFY(evaluateJavaScriptSync(view.page(), "document.activeElement.id").toString().isEmpty());
auto tapAndHold = [](QWidget* target, const QPoint& tapCoords) -> void {
- QTest::touchEvent(target, s_touchDevice).press(1, tapCoords, target);
- QTest::touchEvent(target, s_touchDevice).stationary(1);
+ QTest::touchEvent(target, s_touchDevice).press(0, tapCoords, target);
+ QTest::touchEvent(target, s_touchDevice).stationary(0);
QTest::qWait(1000);
- QTest::touchEvent(target, s_touchDevice).release(1, tapCoords, target);
+ QTest::touchEvent(target, s_touchDevice).release(0, tapCoords, target);
};
// Tap-and-hold on text selects the word under it
@@ -1848,7 +1848,7 @@ void tst_QWebEngineView::inputFieldOverridesShortcuts()
};
// The input form is not focused. The action is triggered on pressing Shift+Delete.
- action->setShortcut(Qt::SHIFT + Qt::Key_Delete);
+ action->setShortcut(Qt::SHIFT | Qt::Key_Delete);
QTest::keyClick(view.windowHandle(), Qt::Key_Delete, Qt::ShiftModifier);
QTRY_VERIFY(actionTriggered);
QCOMPARE(inputFieldValue(), QString("x"));
@@ -1884,7 +1884,7 @@ void tst_QWebEngineView::inputFieldOverridesShortcuts()
// A Ctrl-1 action is no default Qt key binding and should be triggerable.
evaluateJavaScriptSync(view.page(), "document.getElementById('input1').focus();");
QTRY_COMPARE(evaluateJavaScriptSync(view.page(), "document.activeElement.id").toString(), QStringLiteral("input1"));
- action->setShortcut(Qt::CTRL + Qt::Key_1);
+ action->setShortcut(Qt::CTRL | Qt::Key_1);
QTest::keyClick(view.windowHandle(), Qt::Key_1, Qt::ControlModifier);
QTRY_VERIFY(actionTriggered);
QCOMPARE(inputFieldValue(), QString("yxx"));