summaryrefslogtreecommitdiffstats
path: root/src/declarative/qml/qdeclarativeexpression.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/declarative/qml/qdeclarativeexpression.cpp')
-rw-r--r--src/declarative/qml/qdeclarativeexpression.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/declarative/qml/qdeclarativeexpression.cpp b/src/declarative/qml/qdeclarativeexpression.cpp
index b1aecfa..8ae5f2f 100644
--- a/src/declarative/qml/qdeclarativeexpression.cpp
+++ b/src/declarative/qml/qdeclarativeexpression.cpp
@@ -145,7 +145,7 @@ void QDeclarativeExpressionPrivate::init(QDeclarativeContextData *ctxt, void *ex
if (!dd->cachedClosures.at(progIdx)) {
QScriptContext *scriptContext = QScriptDeclarativeClass::pushCleanContext(scriptEngine);
scriptContext->pushScope(ep->contextClass->newSharedContext());
- scriptContext->pushScope(ep->globalClass->globalObject());
+ scriptContext->pushScope(ep->globalClass->staticGlobalObject());
dd->cachedClosures[progIdx] = new QScriptValue(scriptEngine->evaluate(data->expression, data->url, data->line));
scriptEngine->popContext();
}
@@ -188,7 +188,7 @@ QScriptValue QDeclarativeExpressionPrivate::evalInObjectScope(QDeclarativeContex
} else {
scriptContext->pushScope(ep->contextClass->newContext(context, object));
}
- scriptContext->pushScope(ep->globalClass->globalObject());
+ scriptContext->pushScope(ep->globalClass->staticGlobalObject());
QScriptValue rv = ep->scriptEngine.evaluate(program, fileName, lineNumber);
ep->scriptEngine.popContext();
return rv;
@@ -206,7 +206,7 @@ QScriptValue QDeclarativeExpressionPrivate::evalInObjectScope(QDeclarativeContex
} else {
scriptContext->pushScope(ep->contextClass->newContext(context, object));
}
- scriptContext->pushScope(ep->globalClass->globalObject());
+ scriptContext->pushScope(ep->globalClass->staticGlobalObject());
QScriptValue rv = ep->scriptEngine.evaluate(program);
ep->scriptEngine.popContext();
return rv;
@@ -369,7 +369,7 @@ QScriptValue QDeclarativeExpressionPrivate::eval(QObject *secondaryScope, bool *
QScriptContext *scriptContext = QScriptDeclarativeClass::pushCleanContext(scriptEngine);
data->expressionContext = ep->contextClass->newContext(data->context(), data->me);
scriptContext->pushScope(data->expressionContext);
- scriptContext->pushScope(ep->globalClass->globalObject());
+ scriptContext->pushScope(ep->globalClass->staticGlobalObject());
if (data->expressionRewritten) {
data->expressionFunction = scriptEngine->evaluate(data->expression,