summaryrefslogtreecommitdiffstats
path: root/tests/auto/gui/kernel/qguimetatype/tst_qguimetatype.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'tests/auto/gui/kernel/qguimetatype/tst_qguimetatype.cpp')
-rw-r--r--tests/auto/gui/kernel/qguimetatype/tst_qguimetatype.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/tests/auto/gui/kernel/qguimetatype/tst_qguimetatype.cpp b/tests/auto/gui/kernel/qguimetatype/tst_qguimetatype.cpp
index f167bcb139..45f4791439 100644
--- a/tests/auto/gui/kernel/qguimetatype/tst_qguimetatype.cpp
+++ b/tests/auto/gui/kernel/qguimetatype/tst_qguimetatype.cpp
@@ -44,6 +44,8 @@
#include <QtGui>
#include <QtTest/QtTest>
+#include "../../../qtest-config.h"
+
Q_DECLARE_METATYPE(QMetaType::Type)
class tst_QGuiMetaType: public QObject
@@ -133,11 +135,13 @@ template<> struct TypeComparator<QMetaType::QBitmap>
{ return v1.size() == v2.size(); }
};
+#ifndef QTEST_NO_CURSOR
template<> struct TypeComparator<QMetaType::QCursor>
{
static bool equal(const QCursor &v1, const QCursor &v2)
{ return v1.shape() == v2.shape(); }
};
+#endif
template <int ID>
struct DefaultValueFactory
@@ -176,9 +180,11 @@ template<> struct TestValueFactory<QMetaType::QRegion> {
template<> struct TestValueFactory<QMetaType::QBitmap> {
static QBitmap *create() { return new QBitmap(16, 32); }
};
+#ifndef QTEST_NO_CURSOR
template<> struct TestValueFactory<QMetaType::QCursor> {
static QCursor *create() { return new QCursor(Qt::WaitCursor); }
};
+#endif
template<> struct TestValueFactory<QMetaType::QKeySequence> {
static QKeySequence *create() { return new QKeySequence(QKeySequence::Close); }
};