aboutsummaryrefslogtreecommitdiffstats
path: root/src/qml/jsapi
diff options
context:
space:
mode:
authorLars Knoll <lars.knoll@theqtcompany.com>2015-01-15 15:01:06 +0100
committerLars Knoll <lars.knoll@digia.com>2015-01-23 08:07:35 +0100
commit13cf87fa93b584091a51d775953074db9df1b453 (patch)
treedef0d8107e1a152faff71b31902eaade14531e12 /src/qml/jsapi
parent002a5d4303b3b182ae4abc4a752c49787c1c2821 (diff)
Remove all remaining usages of ValueRef
Change-Id: Icd76d3d03fac2e57530e55f8ec15b97109dcdcbc Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Diffstat (limited to 'src/qml/jsapi')
-rw-r--r--src/qml/jsapi/qjsvalue.cpp4
-rw-r--r--src/qml/jsapi/qjsvalue_p.h2
2 files changed, 3 insertions, 3 deletions
diff --git a/src/qml/jsapi/qjsvalue.cpp b/src/qml/jsapi/qjsvalue.cpp
index ac47e2b5c2..d57b8dcc16 100644
--- a/src/qml/jsapi/qjsvalue.cpp
+++ b/src/qml/jsapi/qjsvalue.cpp
@@ -205,7 +205,7 @@ QJSValue::QJSValue(const QJSValue& other)
{
QV4::Value *v = QJSValuePrivate::getValue(&other);
if (v) {
- QJSValuePrivate::setValue(this, QJSValuePrivate::engine(&other), v);
+ QJSValuePrivate::setValue(this, QJSValuePrivate::engine(&other), *v);
} else if (QVariant *v = QJSValuePrivate::getVariant(&other)) {
QJSValuePrivate::setVariant(this, *v);
}
@@ -854,7 +854,7 @@ QJSValue& QJSValue::operator=(const QJSValue& other)
QV4::Value *v = QJSValuePrivate::getValue(&other);
if (v) {
- QJSValuePrivate::setValue(this, QJSValuePrivate::engine(&other), v);
+ QJSValuePrivate::setValue(this, QJSValuePrivate::engine(&other), *v);
} else if (QVariant *v = QJSValuePrivate::getVariant(&other)) {
QJSValuePrivate::setVariant(this, *v);
}
diff --git a/src/qml/jsapi/qjsvalue_p.h b/src/qml/jsapi/qjsvalue_p.h
index 83dbe82f76..13ee107846 100644
--- a/src/qml/jsapi/qjsvalue_p.h
+++ b/src/qml/jsapi/qjsvalue_p.h
@@ -79,7 +79,7 @@ public:
jsval->d = reinterpret_cast<quintptr>(val) | 1;
}
- static inline void setValue(QJSValue *jsval, QV4::ExecutionEngine *engine, QV4::ValueRef v) {
+ static inline void setValue(QJSValue *jsval, QV4::ExecutionEngine *engine, const QV4::Value &v) {
QV4::Value *value = engine->memoryManager->m_persistentValues->allocate();
*value = v;
jsval->d = reinterpret_cast<quintptr>(value);