diff options
author | Richard Moe Gustavsen <richard.gustavsen@digia.com> | 2013-08-22 13:16:34 +0200 |
---|---|---|
committer | The Qt Project <gerrit-noreply@qt-project.org> | 2013-09-04 09:38:35 +0200 |
commit | 8b7a8efe66afecde87b45adf1c6e850f63670f86 (patch) | |
tree | e0396d4777bc53c912a29b84baa6d47ad75d1c01 /src/corelib/plugin/qpluginloader.h | |
parent | 500deb9a08242d177fdad9a8b5a57b560e754db1 (diff) |
QPluginLoader: add 'staticPlugins' function
Currently there is no API to extract the meta data
from static plugins. This is needed in e.g QtDeclarative
for loading static module plugins.
This patch moves the 'staticPlugins' function from
QLibraryPrivate into QPluginLoader, and makes it public.
As such, we now also export QStaticPlugin.
Since an application developer cannot do much with raw
metadata, we add a new function
QStaticPlugin::metaData() that returns the QJsonObject
for the plugin. The old metaData function is
renamed 'rawMetaData'.
Change-Id: Idb0bf9ad8ebb13340565512e1998b26e762a357e
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Diffstat (limited to 'src/corelib/plugin/qpluginloader.h')
-rw-r--r-- | src/corelib/plugin/qpluginloader.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/corelib/plugin/qpluginloader.h b/src/corelib/plugin/qpluginloader.h index 8f8833e839..88c8ba4fa0 100644 --- a/src/corelib/plugin/qpluginloader.h +++ b/src/corelib/plugin/qpluginloader.h @@ -43,6 +43,7 @@ #define QPLUGINLOADER_H #include <QtCore/qlibrary.h> +#include <QtCore/qplugin.h> #ifndef QT_NO_LIBRARY @@ -65,6 +66,7 @@ public: QJsonObject metaData() const; static QObjectList staticInstances(); + static QVector<QStaticPlugin> staticPlugins(); bool load(); bool unload(); |