summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authormae <qt-info@nokia.com>2010-04-14 14:55:36 (GMT)
committermae <qt-info@nokia.com>2010-04-14 14:56:52 (GMT)
commitbd062a4532cb9ffc3539093da0adf3be6fdc8fc9 (patch)
tree3562e8eac86f95484f62368adcf9cec56f1360ed /src
parent0cc27cec860f46b1e349c428973cf4ce3331b285 (diff)
downloadQt-bd062a4532cb9ffc3539093da0adf3be6fdc8fc9.zip
Qt-bd062a4532cb9ffc3539093da0adf3be6fdc8fc9.tar.gz
Qt-bd062a4532cb9ffc3539093da0adf3be6fdc8fc9.tar.bz2
Updates to the module documentation
Diffstat (limited to 'src')
-rw-r--r--src/declarative/qml/qdeclarativeengine.cpp2
-rw-r--r--src/declarative/qml/qdeclarativeextensionplugin.cpp12
2 files changed, 10 insertions, 4 deletions
diff --git a/src/declarative/qml/qdeclarativeengine.cpp b/src/declarative/qml/qdeclarativeengine.cpp
index f621af5..c5afe92 100644
--- a/src/declarative/qml/qdeclarativeengine.cpp
+++ b/src/declarative/qml/qdeclarativeengine.cpp
@@ -1949,6 +1949,8 @@ void QDeclarativeEngine::setPluginPathList(const QStringList &paths)
/*!
Imports the plugin named \a filePath with the \a uri provided.
Returns true if the plugin was successfully imported; otherwise returns false.
+
+ The plugin has to be a Qt plugin which implements the QDeclarativeExtensionPlugin interface.
*/
bool QDeclarativeEngine::importPlugin(const QString &filePath, const QString &uri, QString *errorString)
{
diff --git a/src/declarative/qml/qdeclarativeextensionplugin.cpp b/src/declarative/qml/qdeclarativeextensionplugin.cpp
index 5b7f1e8..762c642d 100644
--- a/src/declarative/qml/qdeclarativeextensionplugin.cpp
+++ b/src/declarative/qml/qdeclarativeextensionplugin.cpp
@@ -55,17 +55,21 @@ QT_BEGIN_NAMESPACE
applications using the QDeclarativeEngine class.
Writing a QML extension plugin is achieved by subclassing this
- base class, reimplementing the pure virtual initialize()
+ base class, reimplementing the pure virtual registerTypes()
function, and exporting the class using the Q_EXPORT_PLUGIN2()
- macro. See \l {How to Create Qt Plugins} for details.
+ macro.
- \sa QDeclarativeEngine::importExtension()
+ See \l {Extending QML in C++} for details how to write a QML extension plugin.
+ See \l {How to Create Qt Plugins} for general Qt plugin documentation.
+
+ \sa QDeclarativeEngine::importPlugin()
*/
/*!
\fn void QDeclarativeExtensionPlugin::registerTypes(const char *uri)
- Registers the QML types in the given \a uri.
+ Registers the QML types in the given \a uri. Here you call qmlRegisterType() for
+ all types which are provided by the extension plugin.
*/
/*!