diff options
-rw-r--r-- | src/qml/qml/qqmlproperty.cpp | 2 | ||||
-rw-r--r-- | src/qml/qml/v4/qv4bindings.cpp | 4 | ||||
-rw-r--r-- | src/qml/qml/v8/qv8engine.cpp | 4 | ||||
-rw-r--r-- | src/qml/qml/v8/qv8qobjectwrapper.cpp | 4 | ||||
-rw-r--r-- | src/quick/util/qquickanimation.cpp | 4 |
5 files changed, 9 insertions, 9 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); diff --git a/src/qml/qml/v4/qv4bindings.cpp b/src/qml/qml/v4/qv4bindings.cpp index f25bfccce4..d4665ac9be 100644 --- a/src/qml/qml/v4/qv4bindings.cpp +++ b/src/qml/qml/v4/qv4bindings.cpp @@ -455,8 +455,8 @@ static bool testCompareVariants(const QVariant &qtscriptRaw, const QVariant &v4) QVariant qtscript = qtscriptRaw; if (qtscript.userType() == v4.userType()) { - } else if (qtscript.canConvert((QVariant::Type)v4.userType())) { - qtscript.convert((QVariant::Type)v4.userType()); + } else if (qtscript.canConvert(v4.userType())) { + qtscript.convert(v4.userType()); } else if (qtscript.userType() == QVariant::Invalid && v4.userType() == QMetaType::QObjectStar) { qtscript = qVariantFromValue<QObject *>(0); } else { diff --git a/src/qml/qml/v8/qv8engine.cpp b/src/qml/qml/v8/qv8engine.cpp index 5fecd713ce..275b648ee4 100644 --- a/src/qml/qml/v8/qv8engine.cpp +++ b/src/qml/qml/v8/qv8engine.cpp @@ -1182,9 +1182,9 @@ bool QV8Engine::metaTypeFromJS(v8::Handle<v8::Value> value, int type, void *data QMetaType::constructInPlace(type, data, var.constData()); return true; } - if (var.canConvert(QVariant::Type(type))) { + if (var.canConvert(type)) { QVariant vv = var; - vv.convert(QVariant::Type(type)); + vv.convert(type); Q_ASSERT(vv.userType() == type); QMetaType::constructInPlace(type, data, vv.constData()); return true; diff --git a/src/qml/qml/v8/qv8qobjectwrapper.cpp b/src/qml/qml/v8/qv8qobjectwrapper.cpp index 95e2be7584..aab66e33a2 100644 --- a/src/qml/qml/v8/qv8qobjectwrapper.cpp +++ b/src/qml/qml/v8/qv8qobjectwrapper.cpp @@ -2137,9 +2137,9 @@ void CallArgument::fromValue(int callType, QV8Engine *engine, v8::Handle<v8::Val if (v.userType() == callType) { *qvariantPtr = v; - } else if (v.canConvert((QVariant::Type)callType)) { + } else if (v.canConvert(callType)) { *qvariantPtr = v; - qvariantPtr->convert((QVariant::Type)callType); + qvariantPtr->convert(callType); } else if (const QMetaObject *mo = ep ? ep->rawMetaObjectForType(callType) : 0) { QObject *obj = ep->toQObject(v); diff --git a/src/quick/util/qquickanimation.cpp b/src/quick/util/qquickanimation.cpp index 2fca7ba80c..77d4809ac6 100644 --- a/src/quick/util/qquickanimation.cpp +++ b/src/quick/util/qquickanimation.cpp @@ -1763,7 +1763,7 @@ QAbstractAnimationJob* QQuickParallelAnimation::transition(QQuickStateActions &a void QQuickPropertyAnimationPrivate::convertVariant(QVariant &variant, int type) { if (variant.userType() != QVariant::String) { - variant.convert((QVariant::Type)type); + variant.convert(type); return; } @@ -1783,7 +1783,7 @@ void QQuickPropertyAnimationPrivate::convertVariant(QVariant &variant, int type) break; default: if (QQmlValueTypeFactory::isValueType((uint)type)) { - variant.convert((QVariant::Type)type); + variant.convert(type); } else { QQmlMetaType::StringConverter converter = QQmlMetaType::customStringConverter(type); if (converter) |