Avoid useless repeated processing of checking whether to unredirect.
svn path=/trunk/KDE/kdebase/workspace/; revision=863933
This commit is contained in:
parent
2cac0dd4e8
commit
e433f92374
2 changed files with 5 additions and 1 deletions
|
@ -839,6 +839,8 @@ bool Toplevel::updateUnredirectedState()
|
|||
|
||||
void Toplevel::suspendUnredirect( bool suspend )
|
||||
{
|
||||
if( unredirectSuspend == suspend )
|
||||
return;
|
||||
unredirectSuspend = suspend;
|
||||
workspace()->checkUnredirect();
|
||||
}
|
||||
|
|
|
@ -227,7 +227,6 @@ void Scene::paintSimpleScreen( int orig_mask, QRegion region )
|
|||
--i )
|
||||
{
|
||||
Window* w = stacking_order[ i ];
|
||||
w->suspendUnredirect( true );
|
||||
WindowPrePaintData data;
|
||||
data.mask = orig_mask | ( w->isOpaque() ? PAINT_WINDOW_OPAQUE : PAINT_WINDOW_TRANSLUCENT );
|
||||
w->resetPaintingEnabled();
|
||||
|
@ -244,7 +243,10 @@ void Scene::paintSimpleScreen( int orig_mask, QRegion region )
|
|||
kFatal( 1212 ) << "PAINT_WINDOW_TRANSFORMED without PAINT_SCREEN_WITH_TRANSFORMED_WINDOWS!";
|
||||
#endif
|
||||
if( !w->isPaintingEnabled())
|
||||
{
|
||||
w->suspendUnredirect( true );
|
||||
continue;
|
||||
}
|
||||
if( data.paint != region ) // prepaint added area to draw
|
||||
painted_region |= data.paint; // make sure it makes it to the screen
|
||||
// Schedule the window for painting
|
||||
|
|
Loading…
Reference in a new issue