aboutsummaryrefslogtreecommitdiffstats
path: root/src/qml/qml/qqmltypeloader.cpp
diff options
context:
space:
mode:
authorSimon Hausmann <simon.hausmann@digia.com>2013-10-24 10:38:29 +0200
committerThe Qt Project <gerrit-noreply@qt-project.org>2013-10-29 23:05:33 +0100
commit1fc951da6aa0bff05af37b20744aba810a2d2988 (patch)
treece83346780586278bc5ba91370146a034aeebeac /src/qml/qml/qqmltypeloader.cpp
parent4d33a38f4b11cea2123b818487ff55f0988767bc (diff)
Cleanup QML specific JS code generator
Move parameters global to the entire QML file to the constructor, pass component/context specific parameters to the generate function. Change-Id: I6c3ab41b3bab19b066bbe20f971c5cafaeb70b98 Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Diffstat (limited to 'src/qml/qml/qqmltypeloader.cpp')
-rw-r--r--src/qml/qml/qqmltypeloader.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/qml/qml/qqmltypeloader.cpp b/src/qml/qml/qqmltypeloader.cpp
index 733f057aee..6f718e5b5b 100644
--- a/src/qml/qml/qqmltypeloader.cpp
+++ b/src/qml/qml/qqmltypeloader.cpp
@@ -2357,8 +2357,8 @@ void QQmlTypeData::compile()
// Compile JS binding expressions and signal handlers
- JSCodeGen jsCodeGen;
- const QVector<int> runtimeFunctionIndices = jsCodeGen.generateJSCodeForFunctionsAndBindings(finalUrlString(), parsedQML.data());
+ JSCodeGen jsCodeGen(finalUrlString(), parsedQML->code, &parsedQML->jsModule, &parsedQML->jsParserEngine, parsedQML->program);
+ const QVector<int> runtimeFunctionIndices = jsCodeGen.generateJSCodeForFunctionsAndBindings(/*### context root*/0, parsedQML->functions);
QV4::ExecutionEngine *v4 = QV8Engine::getV4(m_typeLoader->engine());