From 8b7a8efe66afecde87b45adf1c6e850f63670f86 Mon Sep 17 00:00:00 2001 From: Richard Moe Gustavsen Date: Thu, 22 Aug 2013 13:16:34 +0200 Subject: 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 --- src/corelib/plugin/qpluginloader.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'src/corelib/plugin/qpluginloader.h') 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 +#include #ifndef QT_NO_LIBRARY @@ -65,6 +66,7 @@ public: QJsonObject metaData() const; static QObjectList staticInstances(); + static QVector staticPlugins(); bool load(); bool unload(); -- cgit v1.2.3