diff options
author | David Boddie <dboddie@trolltech.com> | 2010-05-20 13:24:30 (GMT) |
---|---|---|
committer | David Boddie <dboddie@trolltech.com> | 2010-05-20 13:24:30 (GMT) |
commit | ba2cc78943678173d21a4339839e63d16fe774a9 (patch) | |
tree | 691ac2916d5daf948cdac07bc4ef19d08f36cabd /src/declarative/qml/qdeclarativeengine.cpp | |
parent | 8f47373e3795d7ec50387d5f1a771a59567bdaea (diff) | |
parent | ef8cd7f2e68d6d34d70c3a12e82a67ed16b92b72 (diff) | |
download | Qt-ba2cc78943678173d21a4339839e63d16fe774a9.zip Qt-ba2cc78943678173d21a4339839e63d16fe774a9.tar.gz Qt-ba2cc78943678173d21a4339839e63d16fe774a9.tar.bz2 |
Merge branch '4.7' of scm.dev.nokia.troll.no:qt/oslo-staging-2 into 4.7
Diffstat (limited to 'src/declarative/qml/qdeclarativeengine.cpp')
-rw-r--r-- | src/declarative/qml/qdeclarativeengine.cpp | 30 |
1 files changed, 16 insertions, 14 deletions
diff --git a/src/declarative/qml/qdeclarativeengine.cpp b/src/declarative/qml/qdeclarativeengine.cpp index 79f8a17..0a75532 100644 --- a/src/declarative/qml/qdeclarativeengine.cpp +++ b/src/declarative/qml/qdeclarativeengine.cpp @@ -1024,14 +1024,14 @@ QScriptValue QDeclarativeEnginePrivate::createQmlObject(QScriptContext *ctxt, QS foreach (const QDeclarativeError &error, errors){ errstr += QLatin1String(" ") + error.toString() + QLatin1String("\n"); QScriptValue qmlErrObject = ctxt->engine()->newObject(); - qmlErrObject.setProperty("lineNumber", QScriptValue(error.line())); - qmlErrObject.setProperty("columnNumber", QScriptValue(error.column())); - qmlErrObject.setProperty("fileName", QScriptValue(error.url().toString())); - qmlErrObject.setProperty("message", QScriptValue(error.description())); + qmlErrObject.setProperty(QLatin1String("lineNumber"), QScriptValue(error.line())); + qmlErrObject.setProperty(QLatin1String("columnNumber"), QScriptValue(error.column())); + qmlErrObject.setProperty(QLatin1String("fileName"), QScriptValue(error.url().toString())); + qmlErrObject.setProperty(QLatin1String("message"), QScriptValue(error.description())); arr.setProperty(i++, qmlErrObject); } QScriptValue err = ctxt->throwError(errstr); - err.setProperty("qmlErrors",arr); + err.setProperty(QLatin1String("qmlErrors"),arr); return err; } @@ -1051,14 +1051,14 @@ QScriptValue QDeclarativeEnginePrivate::createQmlObject(QScriptContext *ctxt, QS foreach (const QDeclarativeError &error, errors){ errstr += QLatin1String(" ") + error.toString() + QLatin1String("\n"); QScriptValue qmlErrObject = ctxt->engine()->newObject(); - qmlErrObject.setProperty("lineNumber", QScriptValue(error.line())); - qmlErrObject.setProperty("columnNumber", QScriptValue(error.column())); - qmlErrObject.setProperty("fileName", QScriptValue(error.url().toString())); - qmlErrObject.setProperty("message", QScriptValue(error.description())); + qmlErrObject.setProperty(QLatin1String("lineNumber"), QScriptValue(error.line())); + qmlErrObject.setProperty(QLatin1String("columnNumber"), QScriptValue(error.column())); + qmlErrObject.setProperty(QLatin1String("fileName"), QScriptValue(error.url().toString())); + qmlErrObject.setProperty(QLatin1String("message"), QScriptValue(error.description())); arr.setProperty(i++, qmlErrObject); } QScriptValue err = ctxt->throwError(errstr); - err.setProperty("qmlErrors",arr); + err.setProperty(QLatin1String("qmlErrors"),arr); return err; } @@ -1550,8 +1550,9 @@ void QDeclarativeEngine::addImportPath(const QString& path) provided by that module. A \c qmldir file is required for defining the type version mapping and possibly declarative extensions plugins. - By default, the list contains the paths specified in the \c QML_IMPORT_PATH environment - variable, then the builtin \c ImportsPath from QLibraryInfo. + By default, the list contains the directory of the application executable, + paths specified in the \c QML_IMPORT_PATH environment variable, + and the builtin \c ImportsPath from QLibraryInfo. \sa addImportPath() setImportPathList() */ @@ -1565,8 +1566,9 @@ QStringList QDeclarativeEngine::importPathList() const Sets \a paths as the list of directories where the engine searches for installed modules in a URL-based directory structure. - By default, the list contains the paths specified in the \c QML_IMPORT_PATH environment - variable, then the builtin \c ImportsPath from QLibraryInfo. + By default, the list contains the directory of the application executable, + paths specified in the \c QML_IMPORT_PATH environment variable, + and the builtin \c ImportsPath from QLibraryInfo. \sa importPathList() addImportPath() */ |