Commit e00d8b84 authored by Marco Martin's avatar Marco Martin
Browse files

Only load one plugin per type

If we're installed in multiple prefixes (ie self built vs system packages)
only load the proper one which is from the prefix of the self built one
parent 6db12bbf
......@@ -119,6 +119,11 @@ void SettingsBase::initApplication()
const QVector<KPluginMetaData> plugins = KPluginLoader::findPlugins(QStringLiteral("systemsettingsview/"));
for (const KPluginMetaData &plugin : plugins) {
// Make sure we only load one plugin per type if we're installed on multiple prefixes
if (possibleViews.contains(plugin.pluginId())) {
KPluginLoader loader(plugin.fileName());
KPluginFactory *factory = loader.factory();
if (!factory) {
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment