diff options
author | Olivier Goffart <ogoffart@trolltech.com> | 2009-05-07 15:35:58 (GMT) |
---|---|---|
committer | Olivier Goffart <ogoffart@trolltech.com> | 2009-05-07 16:02:36 (GMT) |
commit | 61bec93c12bdc2912b38264386af07f80c3c0272 (patch) | |
tree | 6a2059eef0804052794307de6e72e5f6981e1564 /tests/auto/qtreeview | |
parent | 36932e49769726a28a7ffbc3d5a11b4bffb9952f (diff) | |
download | Qt-61bec93c12bdc2912b38264386af07f80c3c0272.zip Qt-61bec93c12bdc2912b38264386af07f80c3c0272.tar.gz Qt-61bec93c12bdc2912b38264386af07f80c3c0272.tar.bz2 |
Fix treeview test with some style
the skulpture style (from KDE) always set ScrollByPixel
Diffstat (limited to 'tests/auto/qtreeview')
-rw-r--r-- | tests/auto/qtreeview/tst_qtreeview.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/tests/auto/qtreeview/tst_qtreeview.cpp b/tests/auto/qtreeview/tst_qtreeview.cpp index c0244e6..c4517d6 100644 --- a/tests/auto/qtreeview/tst_qtreeview.cpp +++ b/tests/auto/qtreeview/tst_qtreeview.cpp @@ -2028,6 +2028,8 @@ void tst_QTreeView::scrollTo() // view.show(); + view.setVerticalScrollMode(QAbstractItemView::ScrollPerItem); //some styles change that in Polish + view.resize(300, 200); //view.verticalScrollBar()->setValue(0); @@ -2040,6 +2042,7 @@ void tst_QTreeView::scrollTo() QCOMPARE(view.verticalScrollBar()->value(), 5); view.scrollTo(model.index(60, 60, QModelIndex())); + CHECK_VISIBLE(60,60); view.scrollTo(model.index(60, 30, QModelIndex())); CHECK_VISIBLE(60,30); @@ -2915,7 +2918,7 @@ void tst_QTreeView::styleOptionViewItem() delegate.count = 0; view.showMaximized(); QTest::qWait(30); - QVERIFY(delegate.count > 13); + QVERIFY(delegate.count >= 13); } class task174627_TreeView : public QTreeView |