summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorQt Continuous Integration System <qt-info@nokia.com>2010-03-19 16:16:14 (GMT)
committerQt Continuous Integration System <qt-info@nokia.com>2010-03-19 16:16:14 (GMT)
commit54839932adbddf68c78fd79d1b824ff1ad3f83b8 (patch)
treeb3a97c95635bb53cec30b755ae56babbdb478579 /src
parent2969a34664430338875e9786935b865aec0252de (diff)
parent2c466e4a198f2a21d296eee77d321f548931a3b3 (diff)
downloadQt-54839932adbddf68c78fd79d1b824ff1ad3f83b8.zip
Qt-54839932adbddf68c78fd79d1b824ff1ad3f83b8.tar.gz
Qt-54839932adbddf68c78fd79d1b824ff1ad3f83b8.tar.bz2
Merge branch '4.6' of scm.dev.nokia.troll.no:qt/oslo-staging-1 into 4.6-integration
* '4.6' of scm.dev.nokia.troll.no:qt/oslo-staging-1: installTranslatorFunctions doesn't work for custom global object
Diffstat (limited to 'src')
-rw-r--r--src/script/api/qscriptengine.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/script/api/qscriptengine.cpp b/src/script/api/qscriptengine.cpp
index 1199263..d6d1367 100644
--- a/src/script/api/qscriptengine.cpp
+++ b/src/script/api/qscriptengine.cpp
@@ -2921,7 +2921,7 @@ void QScriptEngine::installTranslatorFunctions(const QScriptValue &object)
JSC::JSValue jscObject = d->scriptValueToJSCValue(object);
JSC::JSGlobalObject *glob = d->originalGlobalObject();
if (!jscObject || !jscObject.isObject())
- jscObject = glob;
+ jscObject = d->globalObject();
// unsigned attribs = JSC::DontEnum;
JSC::asObject(jscObject)->putDirectFunction(exec, new (exec)JSC::NativeFunctionWrapper(exec, glob->prototypeFunctionStructure(), 5, JSC::Identifier(exec, "qsTranslate"), QScript::functionQsTranslate));
JSC::asObject(jscObject)->putDirectFunction(exec, new (exec)JSC::NativeFunctionWrapper(exec, glob->prototypeFunctionStructure(), 2, JSC::Identifier(exec, "QT_TRANSLATE_NOOP"), QScript::functionQsTranslateNoOp));