QNX: Fix QTreeView autotest

The style is dpi dependent. I.e. on high dpi displays the pixel size of
sections and rows of a QTreeView will be larger.

Change-Id: I7477bfdd641d4db67973cafef5147f026f72c111
Reviewed-by: Bernd Weimer <bweimer@blackberry.com>
Reviewed-by: Sergio Ahumada <sahumada@blackberry.com>
This commit is contained in:
Fabian Bumberger 2014-04-10 12:07:02 +02:00 committed by The Qt Project
parent 7549ef883a
commit ff34070709

View File

@ -2488,7 +2488,7 @@ void tst_QTreeView::extendedSelection_data()
QTest::addColumn<int>("selectedCount");
QTest::newRow("select") << QPoint(10, 10) << 2;
QTest::newRow("unselect") << QPoint(10, 150) << 0;
QTest::newRow("unselect") << QPoint(10, 300) << 0;
}
void tst_QTreeView::extendedSelection()
@ -2499,7 +2499,7 @@ void tst_QTreeView::extendedSelection()
QStandardItemModel model(5, 2);
QWidget topLevel;
QTreeView view(&topLevel);
view.resize(qMax(mousePressPos.x() * 2, 200), qMax(mousePressPos.y() * 2, 200));
view.resize(qMax(mousePressPos.x() * 2, 300), qMax(mousePressPos.y() * 2, 350));
view.setModel(&model);
view.setSelectionMode(QAbstractItemView::ExtendedSelection);
topLevel.show();