Add EffectWindow::isDeleted() method.
Don't draw shadow for deleted windows. svn path=/branches/work/kwin_composite/; revision=648149
This commit is contained in:
parent
9027b501c8
commit
1f167d8d15
3 changed files with 9 additions and 1 deletions
|
@ -14,6 +14,7 @@ License. See the file "COPYING" for the exact licensing terms.
|
|||
#include "client.h"
|
||||
#include "scene.h"
|
||||
#include "options.h"
|
||||
#include "deleted.h"
|
||||
|
||||
#include "effects/boxswitch.h"
|
||||
#include "effects/demo_taskbarthumbnail.h"
|
||||
|
@ -621,4 +622,9 @@ bool EffectWindow::isOnDesktop( int d ) const
|
|||
return desktop() == d || isOnAllDesktops();
|
||||
}
|
||||
|
||||
bool EffectWindow::isDeleted() const
|
||||
{
|
||||
return (dynamic_cast<Deleted*>( toplevel ) != 0);
|
||||
}
|
||||
|
||||
} // namespace
|
||||
|
|
|
@ -201,6 +201,7 @@ class EffectWindow
|
|||
Toplevel* window();
|
||||
void enablePainting( int reason );
|
||||
void disablePainting( int reason );
|
||||
bool isDeleted() const;
|
||||
bool isOnDesktop( int d ) const;
|
||||
bool isOnCurrentDesktop() const;
|
||||
bool isOnAllDesktops() const;
|
||||
|
|
|
@ -32,7 +32,8 @@ void ShadowEffect::prePaintWindow( EffectWindow* w, int* mask, QRegion* paint, Q
|
|||
|
||||
void ShadowEffect::paintWindow( EffectWindow* w, int mask, QRegion region, WindowPaintData& data )
|
||||
{
|
||||
drawShadow( w, mask, region, data );
|
||||
if( !w->isDeleted() )
|
||||
drawShadow( w, mask, region, data );
|
||||
effects->paintWindow( w, mask, region, data );
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue