From c9baf9190deceb1f83b2bde14bb94930b64a94b5 Mon Sep 17 00:00:00 2001 From: Andreas Demmer Date: Wed, 11 Aug 2010 09:25:25 +0000 Subject: [PATCH] tell other window effects to ignore dashboard window svn path=/trunk/KDE/kdebase/workspace/; revision=1162055 --- effects/dashboard/dashboard.cpp | 26 ++++++++++++++++++++++++++ effects/dashboard/dashboard.h | 2 ++ 2 files changed, 28 insertions(+) diff --git a/effects/dashboard/dashboard.cpp b/effects/dashboard/dashboard.cpp index 39a0ad794d..41fe890b32 100644 --- a/effects/dashboard/dashboard.cpp +++ b/effects/dashboard/dashboard.cpp @@ -133,4 +133,30 @@ void DashboardEffect::windowActivated( EffectWindow *w ) } } +void DashboardEffect::windowAdded( EffectWindow* w ) + { + propertyNotify( w, atom ); + + + if( isDashboard( w ) ) + { + // Tell other windowAdded() effects to ignore this window + w->setData( WindowAddedGrabRole, QVariant::fromValue( static_cast( this ))); + w->addRepaintFull(); + } + } + +void DashboardEffect::windowClosed( EffectWindow* w ) + { + propertyNotify( w, atom ); + + + if( isDashboard( w ) ) + { + // Tell other windowClosed() effects to ignore this window + w->setData( WindowClosedGrabRole, QVariant::fromValue( static_cast( this ))); + w->addRepaintFull(); + } + } + } // namespace diff --git a/effects/dashboard/dashboard.h b/effects/dashboard/dashboard.h index eec6fc2b30..b0eb8f9b9a 100644 --- a/effects/dashboard/dashboard.h +++ b/effects/dashboard/dashboard.h @@ -43,6 +43,8 @@ class DashboardEffect : public KWin::Effect virtual void reconfigure( ReconfigureFlags ); virtual void unpropagate(); virtual void windowActivated( EffectWindow *w ); + virtual void windowAdded( EffectWindow* c ); + virtual void windowClosed( EffectWindow* c ); private: bool blur; bool isDashboard( EffectWindow* w );