diff options
author | Kent Hansen <khansen@trolltech.com> | 2009-08-10 08:33:34 (GMT) |
---|---|---|
committer | Kent Hansen <khansen@trolltech.com> | 2009-08-10 08:33:34 (GMT) |
commit | e5913012f44843bd8f7a6cc28de5de87f134aa65 (patch) | |
tree | 9acb7897440aec8eec7e926cb160c59a8fed78d2 /tests/auto/qtreewidget | |
parent | 761b2fec23a17ea523cbd78beb2731526ea19891 (diff) | |
parent | 7aa2d76dfc4a107f38c5cb0aac00a0b31d0fbbb6 (diff) | |
download | Qt-e5913012f44843bd8f7a6cc28de5de87f134aa65.zip Qt-e5913012f44843bd8f7a6cc28de5de87f134aa65.tar.gz Qt-e5913012f44843bd8f7a6cc28de5de87f134aa65.tar.bz2 |
Merge branch 'master' of git@scm.dev.nokia.troll.no:qt/qt into qtscript-jsc-backend
Conflicts:
src/script/api/qscriptable.cpp
src/script/api/qscriptable_p.h
src/script/qscriptclassdata.cpp
Diffstat (limited to 'tests/auto/qtreewidget')
-rw-r--r-- | tests/auto/qtreewidget/tst_qtreewidget.cpp | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/tests/auto/qtreewidget/tst_qtreewidget.cpp b/tests/auto/qtreewidget/tst_qtreewidget.cpp index 7d79d56..fd0fdb1 100644 --- a/tests/auto/qtreewidget/tst_qtreewidget.cpp +++ b/tests/auto/qtreewidget/tst_qtreewidget.cpp @@ -238,6 +238,9 @@ void tst_QTreeWidget::initTestCase() testWidget = new CustomTreeWidget(); testWidget->show(); +#ifdef Q_WS_X11 + qt_x11_wait_for_window_manager(testWidget); +#endif } void tst_QTreeWidget::cleanupTestCase() @@ -2017,7 +2020,7 @@ void tst_QTreeWidget::setHeaderItem() headerItem->setText(0, "0"); headerItem->setText(1, "1"); testWidget->setHeaderItem(headerItem); - qApp->processEvents(); + QTest::qWait(100); QCOMPARE(testWidget->headerItem(), headerItem); QCOMPARE(headerItem->treeWidget(), static_cast<QTreeWidget *>(testWidget)); @@ -2762,16 +2765,18 @@ void tst_QTreeWidget::defaultRowSizes() for (int j=0; j<tw->columnCount() - 1; ++j) { it->setText(j, "This is a test"); } + QPixmap icon = tw->style()->standardPixmap((QStyle::StandardPixmap)(i + QStyle::SP_TitleBarMenuButton)); + if (icon.isNull()) + QSKIP("No pixmap found on current style, skipping this test.", SkipSingle); it->setIcon(tw->columnCount() - 1, - tw->style()->standardPixmap((QStyle::StandardPixmap)(i + QStyle::SP_TitleBarMenuButton)). - scaled(tw->iconSize())); + icon.scaled(tw->iconSize())); } tw->resize(100,100); tw->show(); QApplication::processEvents(); QRect visualRect = tw->visualItemRect(tw->topLevelItem(0)); - QVERIFY(visualRect.height() >=50); + QVERIFY(visualRect.height() >= 50); } void tst_QTreeWidget::task191552_rtl() |