summaryrefslogtreecommitdiffstats
path: root/tests/auto/qcombobox
diff options
context:
space:
mode:
authorSimon Hausmann <simon.hausmann@nokia.com>2009-11-19 12:08:44 (GMT)
committerSimon Hausmann <simon.hausmann@nokia.com>2009-11-19 12:08:44 (GMT)
commitacb5cd795f4ea75794cfd31eaf768ec5a3e62844 (patch)
tree28064e139d82b1f51c43b67c078855524b52821c /tests/auto/qcombobox
parent65e00180516eb136c2a7119dfe9e63fc9c66065e (diff)
parent8e401cd4ae0133531613a3e097acc57979d78f50 (diff)
downloadQt-acb5cd795f4ea75794cfd31eaf768ec5a3e62844.zip
Qt-acb5cd795f4ea75794cfd31eaf768ec5a3e62844.tar.gz
Qt-acb5cd795f4ea75794cfd31eaf768ec5a3e62844.tar.bz2
Merge branch '4.6' of scm.dev.nokia.troll.no:qt/qt into 4.6
Diffstat (limited to 'tests/auto/qcombobox')
-rw-r--r--tests/auto/qcombobox/tst_qcombobox.cpp15
1 files changed, 3 insertions, 12 deletions
diff --git a/tests/auto/qcombobox/tst_qcombobox.cpp b/tests/auto/qcombobox/tst_qcombobox.cpp
index e903ab5..af71961 100644
--- a/tests/auto/qcombobox/tst_qcombobox.cpp
+++ b/tests/auto/qcombobox/tst_qcombobox.cpp
@@ -2290,11 +2290,8 @@ void tst_QComboBox::setItemDelegate()
QComboBox comboBox;
QStyledItemDelegate *itemDelegate = new QStyledItemDelegate;
comboBox.setItemDelegate(itemDelegate);
-#ifdef Q_CC_MWERKS
+ // the cast is a workaround for the XLC and Metrowerks compilers
QCOMPARE(static_cast<QStyledItemDelegate *>(comboBox.itemDelegate()), itemDelegate);
-#else
- QCOMPARE(comboBox.itemDelegate(), itemDelegate);
-#endif
}
void tst_QComboBox::task253944_itemDelegateIsReset()
@@ -2303,19 +2300,13 @@ void tst_QComboBox::task253944_itemDelegateIsReset()
QStyledItemDelegate *itemDelegate = new QStyledItemDelegate;
comboBox.setItemDelegate(itemDelegate);
+ // the casts are workarounds for the XLC and Metrowerks compilers
+
comboBox.setEditable(true);
-#ifdef Q_CC_MWERKS
QCOMPARE(static_cast<QStyledItemDelegate *>(comboBox.itemDelegate()), itemDelegate);
-#else
- QCOMPARE(comboBox.itemDelegate(), itemDelegate);
-#endif
comboBox.setStyleSheet("QComboBox { border: 1px solid gray; }");
-#ifdef Q_CC_MWERKS
QCOMPARE(static_cast<QStyledItemDelegate *>(comboBox.itemDelegate()), itemDelegate);
-#else
- QCOMPARE(comboBox.itemDelegate(), itemDelegate);
-#endif
}