summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorAlan Alpert <alan.alpert@nokia.com>2010-02-15 15:20:06 (GMT)
committerAlan Alpert <alan.alpert@nokia.com>2010-02-15 15:20:06 (GMT)
commit8ac9280bad33e7f70bfb4381e20c6aae785ce744 (patch)
tree68c5f96e28f2ac2406685e2c3384cbd31f3654a3 /src
parent564d73b9a8ec5a5dd6f692b73625cd4c6a2f6b99 (diff)
downloadQt-8ac9280bad33e7f70bfb4381e20c6aae785ce744.zip
Qt-8ac9280bad33e7f70bfb4381e20c6aae785ce744.tar.gz
Qt-8ac9280bad33e7f70bfb4381e20c6aae785ce744.tar.bz2
Exposing some Validators requires Qt >= 4.7.0
This commit should make declarative compile against 4.6.2 again.
Diffstat (limited to 'src')
-rw-r--r--src/declarative/graphicsitems/qmlgraphicsitemsmodule.cpp6
-rw-r--r--src/declarative/graphicsitems/qmlgraphicstextinput_p.h2
2 files changed, 6 insertions, 2 deletions
diff --git a/src/declarative/graphicsitems/qmlgraphicsitemsmodule.cpp b/src/declarative/graphicsitems/qmlgraphicsitemsmodule.cpp
index 127aec8..66d62f0 100644
--- a/src/declarative/graphicsitems/qmlgraphicsitemsmodule.cpp
+++ b/src/declarative/graphicsitems/qmlgraphicsitemsmodule.cpp
@@ -127,9 +127,11 @@ void QmlGraphicsItemModule::defineModule()
QML_REGISTER_TYPE(Qt,4,6,PathQuad,QmlGraphicsPathQuad);
QML_REGISTER_TYPE(Qt,4,6,PathView,QmlGraphicsPathView);
QML_REGISTER_TYPE(Qt,4,6,Pen,QmlGraphicsPen);
- QML_REGISTER_TYPE(Qt,4,6,QDoubleValidator,QDoubleValidator);
QML_REGISTER_TYPE(Qt,4,6,QIntValidator,QIntValidator);
- QML_REGISTER_TYPE(Qt,4,6,QRegExpValidator,QRegExpValidator);
+#if (QT_VERSION >= QT_VERSION_CHECK(4,7,0))
+ QML_REGISTER_TYPE(Qt,4,7,QDoubleValidator,QDoubleValidator);
+ QML_REGISTER_TYPE(Qt,4,7,QRegExpValidator,QRegExpValidator);
+#endif
QML_REGISTER_TYPE(Qt,4,6,Rectangle,QmlGraphicsRectangle);
QML_REGISTER_TYPE(Qt,4,6,Repeater,QmlGraphicsRepeater);
QML_REGISTER_TYPE(Qt,4,6,Rotation,QGraphicsRotation);
diff --git a/src/declarative/graphicsitems/qmlgraphicstextinput_p.h b/src/declarative/graphicsitems/qmlgraphicstextinput_p.h
index 4708381..a91e71a 100644
--- a/src/declarative/graphicsitems/qmlgraphicstextinput_p.h
+++ b/src/declarative/graphicsitems/qmlgraphicstextinput_p.h
@@ -222,8 +222,10 @@ QT_END_NAMESPACE
QML_DECLARE_TYPE(QmlGraphicsTextInput)
QML_DECLARE_TYPE(QValidator)
QML_DECLARE_TYPE(QIntValidator)
+#if (QT_VERSION >= QT_VERSION_CHECK(4,7,0))
QML_DECLARE_TYPE(QDoubleValidator)
QML_DECLARE_TYPE(QRegExpValidator)
+#endif
QT_END_HEADER