fix package listing

load a package of the proper type before listing
this makes the proper package structures to be loaded
This commit is contained in:
Marco Martin 2015-08-28 16:48:05 +02:00
parent 98583160cb
commit 60fe4f080c

View File

@ -436,6 +436,10 @@ QStringList PlasmaPkgPrivate::packages(const QStringList &types)
}
}
//Loading a package of the given type, caches the proper
//packagestructures in the packageloader, making the listing
//of packages succeed
Plasma::PluginLoader::self()->loadPackage(type);
const QList<KPluginMetaData> plugins = KPackage::PackageLoader::self()->listPackages(type);
for (auto plugin : plugins) {
const QString _plugin = plugin.pluginId();