aboutsummaryrefslogtreecommitdiffstats
path: root/tests/auto/shared/visualtestutil.h
diff options
context:
space:
mode:
authorJ-P Nurmi <jpnurmi@qt.io>2017-06-10 10:18:21 +0200
committerJ-P Nurmi <jpnurmi@qt.io>2017-06-12 09:25:54 +0000
commite81332e461ae7662b11fc1da04bb052e354514a3 (patch)
treed9fb9f8520fa3ebcca2cecdf9253a666784dd122 /tests/auto/shared/visualtestutil.h
parent027c24e6965b3fe1316c379c6de650bafd94dc08 (diff)
Stabilize tst_menu
Add QQuickVisualTestUtil::moveMouseAway() (adapted from qtdeclarative) to help with testing menus that are now highlighting items on hover. It is important to move the mouse cursor away outside the window in such tests where hover highlight might conflict with the test. Change-Id: If3d642dd4f3ba2936a0d22c078d8fb0125d16c6c Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
Diffstat (limited to 'tests/auto/shared/visualtestutil.h')
-rw-r--r--tests/auto/shared/visualtestutil.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/tests/auto/shared/visualtestutil.h b/tests/auto/shared/visualtestutil.h
index 12f955ea..bcf45660 100644
--- a/tests/auto/shared/visualtestutil.h
+++ b/tests/auto/shared/visualtestutil.h
@@ -54,6 +54,8 @@ namespace QQuickVisualTestUtil
bool delegateVisible(QQuickItem *item);
+ void moveMouseAway(QQuickWindow *window);
+
/*
Find an item with the specified objectName. If index is supplied then the
item must also evaluate the {index} expression equal to index