aboutsummaryrefslogtreecommitdiffstats
path: root/src/quicktemplates/qquickspinbox.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/quicktemplates/qquickspinbox.cpp')
-rw-r--r--src/quicktemplates/qquickspinbox.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/quicktemplates/qquickspinbox.cpp b/src/quicktemplates/qquickspinbox.cpp
index a76a06076c..5dce7809a5 100644
--- a/src/quicktemplates/qquickspinbox.cpp
+++ b/src/quicktemplates/qquickspinbox.cpp
@@ -437,7 +437,8 @@ QString QQuickSpinBoxPrivate::evaluateTextFromValue(int val) const
QJSValue loc;
#if QT_CONFIG(qml_locale)
QV4::ExecutionEngine *v4 = QQmlEnginePrivate::getV4Engine(engine);
- loc = QJSValuePrivate::fromReturnedValue(QQmlLocale::wrap(v4, locale));
+ loc = QJSValuePrivate::fromReturnedValue(
+ v4->fromData(QMetaType::fromType<QLocale>(), &locale));
#endif
text = textFromValue.call(QJSValueList() << val << loc).toString();
} else {
@@ -455,7 +456,8 @@ int QQuickSpinBoxPrivate::evaluateValueFromText(const QString &text) const
QJSValue loc;
#if QT_CONFIG(qml_locale)
QV4::ExecutionEngine *v4 = QQmlEnginePrivate::getV4Engine(engine);
- loc = QJSValuePrivate::fromReturnedValue(QQmlLocale::wrap(v4, locale));
+ loc = QJSValuePrivate::fromReturnedValue(
+ v4->fromData(QMetaType::fromType<QLocale>(), &locale));
#endif
value = valueFromText.call(QJSValueList() << text << loc).toInt();
} else {