diff options
author | Aaron Kennedy <aaron.kennedy@nokia.com> | 2009-11-30 06:25:37 (GMT) |
---|---|---|
committer | Aaron Kennedy <aaron.kennedy@nokia.com> | 2009-11-30 06:25:37 (GMT) |
commit | 1c8cf1b080c81c40bedc9d7c342555585fc394b0 (patch) | |
tree | 3aa4b9eec3c31773ee878ec8c4e23439428f3f08 /src/declarative/qml/qmlengine.cpp | |
parent | 34e5b058c81757e58f7356290d7866f37a52be53 (diff) | |
download | Qt-1c8cf1b080c81c40bedc9d7c342555585fc394b0.zip Qt-1c8cf1b080c81c40bedc9d7c342555585fc394b0.tar.gz Qt-1c8cf1b080c81c40bedc9d7c342555585fc394b0.tar.bz2 |
Basic WorkerScript functionality
Diffstat (limited to 'src/declarative/qml/qmlengine.cpp')
-rw-r--r-- | src/declarative/qml/qmlengine.cpp | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/src/declarative/qml/qmlengine.cpp b/src/declarative/qml/qmlengine.cpp index aa66c17..c0692eb 100644 --- a/src/declarative/qml/qmlengine.cpp +++ b/src/declarative/qml/qmlengine.cpp @@ -85,6 +85,7 @@ #include <qmlscriptstring.h> #include <private/qmlglobal_p.h> #include <QtCore/qcryptographichash.h> +#include <private/qmlworkerscript_p.h> #ifdef Q_OS_WIN // for %APPDATA% #include "qt_windows.h" @@ -111,8 +112,8 @@ QmlEnginePrivate::QmlEnginePrivate(QmlEngine *e) : rootContext(0), currentExpression(0), isDebugging(false), contextClass(0), objectClass(0), valueTypeClass(0), globalClass(0), nodeListClass(0), namedNodeMapClass(0), sqlQueryClass(0), cleanup(0), erroredBindings(0), - inProgressCreations(0), scriptEngine(this), componentAttacheds(0), rootComponent(0), - networkAccessManager(0), typeManager(e), uniqueId(1) + inProgressCreations(0), scriptEngine(this), workerScriptEngine(0), componentAttacheds(0), + rootComponent(0), networkAccessManager(0), typeManager(e), uniqueId(1) { // Note that all documentation for stuff put on the global object goes in // doc/src/declarative/globalobject.qdoc @@ -243,6 +244,14 @@ void QmlEnginePrivate::init() } } +QmlWorkerScriptEngine *QmlEnginePrivate::getWorkerScriptEngine() +{ + Q_Q(QmlEngine); + if (!workerScriptEngine) + workerScriptEngine = new QmlWorkerScriptEngine(q); + return workerScriptEngine; +} + /*! \class QmlEngine \brief The QmlEngine class provides an environment for instantiating QML components. |