aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/qml/debugger/qqmlenginedebugservice.cpp2
-rw-r--r--src/qml/qml/qqmlexpression.cpp2
-rw-r--r--src/qml/qml/qqmlexpression_p.h2
-rw-r--r--src/qml/qml/qqmljavascriptexpression.cpp10
-rw-r--r--src/qml/qml/qqmljavascriptexpression_p.h6
5 files changed, 6 insertions, 16 deletions
diff --git a/src/qml/debugger/qqmlenginedebugservice.cpp b/src/qml/debugger/qqmlenginedebugservice.cpp
index 7db3d36361..fd7d1c2da4 100644
--- a/src/qml/debugger/qqmlenginedebugservice.cpp
+++ b/src/qml/debugger/qqmlenginedebugservice.cpp
@@ -752,7 +752,7 @@ bool QQmlEngineDebugService::setMethodBody(int objectId, const QString &method,
int lineNumber = vmeMetaObject->vmeMethodLineNumber(prop->coreIndex);
QV4::ExecutionEngine *v4 = QV8Engine::getV4(qmlEngine(object)->handle());
QV4::Scope scope(v4);
- QV4::ScopedValue v(scope, QQmlExpressionPrivate::evalFunction(contextData, object, jsfunction, contextData->urlString(), lineNumber));
+ QV4::ScopedValue v(scope, QQmlJavaScriptExpression::evalFunction(contextData, object, jsfunction, contextData->urlString(), lineNumber));
vmeMetaObject->setVmeMethod(prop->coreIndex, v);
return true;
}
diff --git a/src/qml/qml/qqmlexpression.cpp b/src/qml/qml/qqmlexpression.cpp
index 3813281044..e4a36f7580 100644
--- a/src/qml/qml/qqmlexpression.cpp
+++ b/src/qml/qml/qqmlexpression.cpp
@@ -246,7 +246,7 @@ QV4::ReturnedValue QQmlExpressionPrivate::v4value(bool *isUndefined)
QV4::ExecutionEngine *v4 = QQmlEnginePrivate::get(q->engine())->v4engine();
if (!expressionFunctionValid) {
- m_function.set(v4, qmlBinding(context(), scopeObject(), expression, url, line, &qmlscope));
+ m_function.set(v4, qmlBinding(context(), scopeObject(), expression, url, line));
expressionFunctionValid = true;
}
diff --git a/src/qml/qml/qqmlexpression_p.h b/src/qml/qml/qqmlexpression_p.h
index 0419c9c11c..2303539194 100644
--- a/src/qml/qml/qqmlexpression_p.h
+++ b/src/qml/qml/qqmlexpression_p.h
@@ -86,8 +86,6 @@ public:
QString expression;
- QV4::PersistentValue qmlscope;
-
QString url; // This is a QString for a reason. QUrls are slooooooow...
quint16 line;
quint16 column;
diff --git a/src/qml/qml/qqmljavascriptexpression.cpp b/src/qml/qml/qqmljavascriptexpression.cpp
index cc57d855c3..60378a26e7 100644
--- a/src/qml/qml/qqmljavascriptexpression.cpp
+++ b/src/qml/qml/qqmljavascriptexpression.cpp
@@ -313,8 +313,7 @@ QQmlDelayedError *QQmlJavaScriptExpression::delayedError()
QV4::ReturnedValue
QQmlJavaScriptExpression::evalFunction(QQmlContextData *ctxt, QObject *scopeObject,
- const QString &code, const QString &filename, quint16 line,
- QV4::PersistentValue *qmlscope)
+ const QString &code, const QString &filename, quint16 line)
{
QQmlEngine *engine = ctxt->engine;
QQmlEnginePrivate *ep = QQmlEnginePrivate::get(engine);
@@ -340,14 +339,11 @@ QQmlJavaScriptExpression::evalFunction(QQmlContextData *ctxt, QObject *scopeObje
ep->warning(error);
return QV4::Encode::undefined();
}
- if (qmlscope)
- qmlscope->set(v4, qmlScopeObject);
return result->asReturnedValue();
}
QV4::ReturnedValue QQmlJavaScriptExpression::qmlBinding(QQmlContextData *ctxt, QObject *qmlScope,
- const QString &code, const QString &filename, quint16 line,
- QV4::PersistentValue *qmlscope)
+ const QString &code, const QString &filename, quint16 line)
{
QQmlEngine *engine = ctxt->engine;
QQmlEnginePrivate *ep = QQmlEnginePrivate::get(engine);
@@ -373,8 +369,6 @@ QV4::ReturnedValue QQmlJavaScriptExpression::qmlBinding(QQmlContextData *ctxt, Q
ep->warning(error);
return QV4::Encode::undefined();
}
- if (qmlscope)
- qmlscope->set(v4, qmlScopeObject);
return result->asReturnedValue();
}
diff --git a/src/qml/qml/qqmljavascriptexpression_p.h b/src/qml/qml/qqmljavascriptexpression_p.h
index f846b6570f..c6028d86dc 100644
--- a/src/qml/qml/qqmljavascriptexpression_p.h
+++ b/src/qml/qml/qqmljavascriptexpression_p.h
@@ -137,13 +137,11 @@ public:
static QV4::ReturnedValue evalFunction(QQmlContextData *ctxt, QObject *scope,
const QString &code, const QString &filename,
- quint16 line,
- QV4::PersistentValue *qmlscope = 0);
+ quint16 line);
// doesn't require rewriting the expression
static QV4::ReturnedValue qmlBinding(QQmlContextData *ctxt, QObject *scope,
const QString &code,
- const QString &filename, quint16 line,
- QV4::PersistentValue *qmlscope = 0);
+ const QString &filename, quint16 line);
private:
friend class QQmlContextData;