aboutsummaryrefslogtreecommitdiffstats
path: root/src/qml/qml/qqmlproperty.cpp
diff options
context:
space:
mode:
authorJędrzej Nowacki <jedrzej.nowacki@nokia.com>2012-05-18 17:30:03 +0200
committerQt by Nokia <qt-info@nokia.com>2012-05-21 15:54:56 +0200
commitfdc55ec837c79f1b42896b56f5be2c4abb5183ed (patch)
tree3223e96473b5fe05354674dee1262a6d4803e3a6 /src/qml/qml/qqmlproperty.cpp
parentda0c8b6cd5c824e063c96ba54724ccf13ca2d808 (diff)
Simplify QVariant::convert and QVariant::canConvert calls.
QVariant::Type casts are not necessary in Qt5. Change-Id: Ia2e7d8fa367a59c23bd06993db36d96a0a46a229 Reviewed-by: Roberto Raggi <roberto.raggi@nokia.com>
Diffstat (limited to 'src/qml/qml/qqmlproperty.cpp')
-rw-r--r--src/qml/qml/qqmlproperty.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/qml/qml/qqmlproperty.cpp b/src/qml/qml/qqmlproperty.cpp
index d68d8a9517..761b75acf4 100644
--- a/src/qml/qml/qqmlproperty.cpp
+++ b/src/qml/qml/qqmlproperty.cpp
@@ -1371,7 +1371,7 @@ bool QQmlPropertyPrivate::write(QObject *object,
v = QQmlStringConverters::variantFromString(value.toString(), propertyType, &ok);
if (!ok) {
v = value;
- if (v.convert((QVariant::Type)propertyType)) {
+ if (v.convert(propertyType)) {
ok = true;
} else if ((uint)propertyType >= QVariant::UserType && variantType == QVariant::String) {
QQmlMetaType::StringConverter con = QQmlMetaType::customStringConverter(propertyType);