diff --git a/effects/shadow_config.cpp b/effects/shadow_config.cpp
index 645f31517b..61a82a2b5d 100644
--- a/effects/shadow_config.cpp
+++ b/effects/shadow_config.cpp
@@ -25,6 +25,7 @@ along with this program. If not, see .
#include
+#include
#include
#include
#ifndef KDE_USE_FINAL
@@ -116,6 +117,10 @@ void ShadowEffectConfig::save()
emit changed(false);
EffectsHandler::sendReloadMessage( "shadow" );
+
+ // We also need to reload decorations
+ QDBusMessage message = QDBusMessage::createMethodCall( "org.kde.kwin", "/KWin", "org.kde.KWin", "reconfigure" );
+ QDBusConnection::sessionBus().send( message );
}
void ShadowEffectConfig::defaults()
diff --git a/kcmkwin/kwincompositing/main.cpp b/kcmkwin/kwincompositing/main.cpp
index 8ebaeb8922..b0de661936 100644
--- a/kcmkwin/kwincompositing/main.cpp
+++ b/kcmkwin/kwincompositing/main.cpp
@@ -791,6 +791,19 @@ bool KWinCompositingConfig::sendKWinReloadSignal()
QDBusMessage message = QDBusMessage::createSignal( "/KWin", "org.kde.KWin", "reloadCompositingConfig" );
QDBusConnection::sessionBus().send(message);
+ // If we added or removed shadows we need to reload decorations as well
+ // We have to do this separately so the settings are in sync
+ // HACK: This should really just reload decorations, not do a full reconfigure
+ KConfigGroup effectConfig( mBackupConfig, "Plugins" );
+ bool shadowBefore = effectEnabled( "shadow", effectConfig );
+ effectConfig = KConfigGroup( mNewConfig, "Plugins" );
+ bool shadowAfter = effectEnabled( "shadow", effectConfig );
+ if( shadowBefore != shadowAfter )
+ {
+ message = QDBusMessage::createMethodCall( "org.kde.kwin", "/KWin", "org.kde.KWin", "reconfigure" );
+ QDBusConnection::sessionBus().send( message );
+ }
+
// If compositing is enabled, check if it could be started.
KConfigGroup newGroup( mNewConfig, "Compositing" );
bool enabled = newGroup.readEntry( "Enabled", mDefaultPrefs.enableCompositing() );