aboutsummaryrefslogtreecommitdiffstats
path: root/tests/auto/declarative/qquickgridview
diff options
context:
space:
mode:
authorBea Lam <bea.lam@nokia.com>2011-11-22 15:13:28 +1000
committerQt by Nokia <qt-info@nokia.com>2011-11-22 06:14:52 +0100
commit18e89379f8db9b656885739daef5d24aa24fb92c (patch)
tree992bdb16d4f7091d0a6921156e43bec00ec2cdc6 /tests/auto/declarative/qquickgridview
parent8d8015f8d5912300d8c6a1f8bac298163cb566b1 (diff)
Try again to fix currentIndex() test
Seems that if the threaded renderer is disabled, updatePolish() isn't called on the view until after setCurrentIndex(), so then the view starts at the wrong position and never moves upwards when setCurrentIndex(0) is executed. Change-Id: I74da9de8ac432d27189416287e7ea5937c1d6299 Reviewed-by: Andrew den Exter <andrew.den-exter@nokia.com>
Diffstat (limited to 'tests/auto/declarative/qquickgridview')
-rw-r--r--tests/auto/declarative/qquickgridview/tst_qquickgridview.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/tests/auto/declarative/qquickgridview/tst_qquickgridview.cpp b/tests/auto/declarative/qquickgridview/tst_qquickgridview.cpp
index 322587876b..bdcb27f72e 100644
--- a/tests/auto/declarative/qquickgridview/tst_qquickgridview.cpp
+++ b/tests/auto/declarative/qquickgridview/tst_qquickgridview.cpp
@@ -1346,6 +1346,7 @@ void tst_QQuickGridView::currentIndex()
QQuickGridView *gridview = findItem<QQuickGridView>(canvas->rootObject(), "grid");
QVERIFY(gridview != 0);
+ QTRY_VERIFY(!QQuickItemPrivate::get(gridview)->polishScheduled);
QQuickItem *contentItem = gridview->contentItem();
QVERIFY(contentItem != 0);