Fix loading of effect config plugins

X-KDE-ParentComponents is a list, so we have to check if this list
contains the plugin, not do a string comparison. It seems the
queryparser has become a bit stricter in this case. This query should be
fixed anyway, however, and it fixes a fairly important bug in the effect
system.

REVIEW:122821
remotes/origin/Plasma/5.2
Sebastian Kügler 11 years ago
parent 777dc69831
commit 25fc115a9c
  1. 2
      kcmkwin/kwincompositing/effectconfig.cpp
  2. 2
      kcmkwin/kwindesktop/main.cpp
  3. 2
      kcmkwin/kwintabbox/main.cpp

@ -65,7 +65,7 @@ void EffectConfig::openConfig(const QString &serviceName, bool scripted, const Q
}
} else {
kcm = KPluginTrader::createInstanceFromQuery<KCModule>(s_pluginDir, QString(),
QStringLiteral("[X-KDE-ParentComponents] == '%1'").arg(serviceName),
QStringLiteral("'%1' in [X-KDE-ParentComponents]").arg(serviceName),
&dialog);
}
if (!kcm) {

@ -619,7 +619,7 @@ void KWinDesktopConfig::slotConfigureEffectClicked()
QPointer<QDialog> configDialog = new QDialog(this);
KCModule *kcm = KPluginTrader::createInstanceFromQuery<KCModule>(QStringLiteral("kwin/effects/configs/"), QString(),
QStringLiteral("[X-KDE-ParentComponents] == '%1'").arg(effect),
QStringLiteral("'%1' in [X-KDE-ParentComponents]").arg(effect),
configDialog);
if (!kcm) {
delete configDialog;

@ -539,7 +539,7 @@ void KWinTabBoxConfig::configureEffectClicked()
const QString name = BuiltInEffects::nameForEffect(effect == CoverSwitch ? BuiltInEffect::CoverSwitch : BuiltInEffect::FlipSwitch);
KCModule *kcm = KPluginTrader::createInstanceFromQuery<KCModule>(QStringLiteral("kwin/effects/configs/"), QString(),
QStringLiteral("[X-KDE-ParentComponents] == '%1'").arg(name),
QStringLiteral("'%1' in [X-KDE-ParentComponents]").arg(name),
configDialog);
if (!kcm) {
delete configDialog;

Loading…
Cancel
Save