diff options
author | Bea Lam <bea.lam@nokia.com> | 2011-02-10 01:30:47 (GMT) |
---|---|---|
committer | Bea Lam <bea.lam@nokia.com> | 2011-02-10 01:34:57 (GMT) |
commit | d7e42d7c5b0eb6513526d0c21025939a467e8d68 (patch) | |
tree | f959aaa30fee0db70bf7f5d9ae5a9b61eebd370d /src | |
parent | 8b653d4fa183f985d5c1bfb4b5c1d932305cacfa (diff) | |
download | Qt-d7e42d7c5b0eb6513526d0c21025939a467e8d68.zip Qt-d7e42d7c5b0eb6513526d0c21025939a467e8d68.tar.gz Qt-d7e42d7c5b0eb6513526d0c21025939a467e8d68.tar.bz2 |
Update modules-related tests and docs
Added tests for remote imports and fixed/improved examples and
text in the docs.
Change-Id: I8f411a0287c4d50ec3cebe5567d803689cd5b1c7
Diffstat (limited to 'src')
-rw-r--r-- | src/declarative/qml/qdeclarativeengine.cpp | 3 | ||||
-rw-r--r-- | src/declarative/qml/qdeclarativeimport.cpp | 23 |
2 files changed, 24 insertions, 2 deletions
diff --git a/src/declarative/qml/qdeclarativeengine.cpp b/src/declarative/qml/qdeclarativeengine.cpp index 37df226..2227146 100644 --- a/src/declarative/qml/qdeclarativeengine.cpp +++ b/src/declarative/qml/qdeclarativeengine.cpp @@ -2103,10 +2103,11 @@ QVariant QDeclarativeEnginePrivate::scriptValueToVariant(const QScriptValue &val /*! Adds \a path as a directory where the engine searches for installed modules in a URL-based directory structure. + The \a path may be a local filesystem directory or a URL. The newly added \a path will be first in the importPathList(). - \sa setImportPathList() + \sa setImportPathList(), \l {QML Modules} */ void QDeclarativeEngine::addImportPath(const QString& path) { diff --git a/src/declarative/qml/qdeclarativeimport.cpp b/src/declarative/qml/qdeclarativeimport.cpp index 22dcb44..87183c4 100644 --- a/src/declarative/qml/qdeclarativeimport.cpp +++ b/src/declarative/qml/qdeclarativeimport.cpp @@ -712,6 +712,7 @@ bool QDeclarativeImportedNamespace::find(const QByteArray& type, int *vmajor, in /*! \class QDeclarativeImportDatabase \brief The QDeclarativeImportDatabase class manages the QML imports for a QDeclarativeEngine. +\internal */ QDeclarativeImportDatabase::QDeclarativeImportDatabase(QDeclarativeEngine *e) : engine(e) @@ -926,16 +927,25 @@ QString QDeclarativeImportDatabase::resolvePlugin(const QDir &qmldirPath, const #endif } +/*! + \internal +*/ QStringList QDeclarativeImportDatabase::pluginPathList() const { return filePluginPath; } +/*! + \internal +*/ void QDeclarativeImportDatabase::setPluginPathList(const QStringList &paths) { filePluginPath = paths; } +/*! + \internal +*/ void QDeclarativeImportDatabase::addPluginPath(const QString& path) { if (qmlImportTrace()) @@ -950,6 +960,9 @@ void QDeclarativeImportDatabase::addPluginPath(const QString& path) } } +/*! + \internal +*/ void QDeclarativeImportDatabase::addImportPath(const QString& path) { if (qmlImportTrace()) @@ -974,17 +987,25 @@ void QDeclarativeImportDatabase::addImportPath(const QString& path) fileImportPath.prepend(cPath); } +/*! + \internal +*/ QStringList QDeclarativeImportDatabase::importPathList() const { return fileImportPath; } +/*! + \internal +*/ void QDeclarativeImportDatabase::setImportPathList(const QStringList &paths) { fileImportPath = paths; } - +/*! + \internal +*/ bool QDeclarativeImportDatabase::importPlugin(const QString &filePath, const QString &uri, QString *errorString) { if (qmlImportTrace()) |