Fix wrong logic.
svn path=/trunk/KDE/kdebase/workspace/; revision=864621
This commit is contained in:
parent
c2ef38b83c
commit
b9bf9831b0
2 changed files with 8 additions and 24 deletions
|
@ -1313,18 +1313,10 @@ void SceneOpenGL::Window::performPaint( int mask, QRegion region, WindowPaintDat
|
|||
// check if there is something to paint (e.g. don't paint if the window
|
||||
// is only opaque and only PAINT_WINDOW_TRANSLUCENT is requested)
|
||||
bool opaque = isOpaque() && data.opacity == 1.0;
|
||||
if( mask & ( PAINT_WINDOW_OPAQUE | PAINT_WINDOW_TRANSLUCENT ))
|
||||
{}
|
||||
else if( mask & PAINT_WINDOW_OPAQUE )
|
||||
{
|
||||
if( !opaque )
|
||||
return;
|
||||
}
|
||||
else if( mask & PAINT_WINDOW_TRANSLUCENT )
|
||||
{
|
||||
if( opaque )
|
||||
return;
|
||||
}
|
||||
if( opaque && ( mask & ( PAINT_WINDOW_OPAQUE | PAINT_WINDOW_TRANSLUCENT )) == PAINT_WINDOW_TRANSLUCENT )
|
||||
return;
|
||||
if( !opaque && ( mask & ( PAINT_WINDOW_OPAQUE | PAINT_WINDOW_TRANSLUCENT )) == PAINT_WINDOW_OPAQUE )
|
||||
return;
|
||||
// paint only requested areas
|
||||
if( region != infiniteRegion()) // avoid integer overflow
|
||||
region.translate( -x(), -y());
|
||||
|
|
|
@ -523,18 +523,10 @@ void SceneXrender::Window::performPaint( int mask, QRegion region, WindowPaintDa
|
|||
setTransformedShape( QRegion()); // maybe nothing will be painted
|
||||
// check if there is something to paint
|
||||
bool opaque = isOpaque() && data.opacity == 1.0;
|
||||
if( mask & ( PAINT_WINDOW_OPAQUE | PAINT_WINDOW_TRANSLUCENT ))
|
||||
{}
|
||||
else if( mask & PAINT_WINDOW_OPAQUE )
|
||||
{
|
||||
if( !opaque )
|
||||
return;
|
||||
}
|
||||
else if( mask & PAINT_WINDOW_TRANSLUCENT )
|
||||
{
|
||||
if( opaque )
|
||||
return;
|
||||
}
|
||||
if( opaque && ( mask & ( PAINT_WINDOW_OPAQUE | PAINT_WINDOW_TRANSLUCENT )) == PAINT_WINDOW_TRANSLUCENT )
|
||||
return;
|
||||
if( !opaque && ( mask & ( PAINT_WINDOW_OPAQUE | PAINT_WINDOW_TRANSLUCENT )) == PAINT_WINDOW_OPAQUE )
|
||||
return;
|
||||
Picture pic = picture(); // get XRender picture
|
||||
if( pic == None ) // The render format can be null for GL and/or Xv visuals
|
||||
return;
|
||||
|
|
Loading…
Reference in a new issue