Don't allow windows to cast shadows on screens they are not on.

BUG: 176018

svn path=/trunk/KDE/kdebase/workspace/; revision=888665
This commit is contained in:
Lucas Murray 2008-11-25 02:58:28 +00:00
parent 5f835b7c31
commit 2bb64077e7

View file

@ -653,6 +653,16 @@ void ShadowEffect::drawShadowQuadXRender( XRenderPicture *picture, QRect rect, f
void ShadowEffect::drawShadow( EffectWindow* window, int mask, QRegion region, const WindowPaintData& data )
{
// Don't allow windows to cast shadows on other displays
QRegion clipperGeom;
for( int screen = 0; screen < effects->numScreens(); screen++ )
{
QRect screenGeom = effects->clientArea( ScreenArea, screen, 0 );
if( !( window->geometry() & screenGeom ).isNull() )
clipperGeom |= screenGeom;
}
PaintClipper pc( clipperGeom );
#ifdef KWIN_HAVE_OPENGL_COMPOSITING
if( effects->compositingType() == OpenGLCompositing )
{