summaryrefslogtreecommitdiffstats
path: root/tests/auto/qheaderview
diff options
context:
space:
mode:
Diffstat (limited to 'tests/auto/qheaderview')
-rw-r--r--tests/auto/qheaderview/tst_qheaderview.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/tests/auto/qheaderview/tst_qheaderview.cpp b/tests/auto/qheaderview/tst_qheaderview.cpp
index 0be895b..920231d 100644
--- a/tests/auto/qheaderview/tst_qheaderview.cpp
+++ b/tests/auto/qheaderview/tst_qheaderview.cpp
@@ -1434,7 +1434,8 @@ void tst_QHeaderView::focusPolicy()
widget.show();
widget.setFocus(Qt::OtherFocusReason);
- QTest::qWait(100);
+ QApplication::setActiveWindow(&widget);
+ QTest::qWaitForWindowShown(&widget);
widget.activateWindow();
QTest::qWait(100);