Restore color settings after painting background. Fixes splashscreen
being fully black during KDE startup, not that I understand why. svn path=/trunk/KDE/kdebase/workspace/; revision=807447
This commit is contained in:
parent
5d1c5d355f
commit
e5b1dd90bc
1 changed files with 6 additions and 0 deletions
|
@ -728,10 +728,15 @@ void SceneOpenGL::paintBackground( QRegion region )
|
||||||
PaintClipper pc( region );
|
PaintClipper pc( region );
|
||||||
if( !PaintClipper::clip())
|
if( !PaintClipper::clip())
|
||||||
{
|
{
|
||||||
|
glPushAttrib( GL_COLOR_BUFFER_BIT );
|
||||||
glClearColor( 0, 0, 0, 1 ); // black
|
glClearColor( 0, 0, 0, 1 ); // black
|
||||||
glClear( GL_COLOR_BUFFER_BIT );
|
glClear( GL_COLOR_BUFFER_BIT );
|
||||||
|
glPopAttrib();
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
if( clip() && pc.paintArea().isEmpty())
|
||||||
|
return; // no background to paint
|
||||||
|
glPushAttrib( GL_CURRENT_BIT );
|
||||||
glColor4f( 0, 0, 0, 1 ); // black
|
glColor4f( 0, 0, 0, 1 ); // black
|
||||||
for( PaintClipper::Iterator iterator;
|
for( PaintClipper::Iterator iterator;
|
||||||
!iterator.isDone();
|
!iterator.isDone();
|
||||||
|
@ -745,6 +750,7 @@ void SceneOpenGL::paintBackground( QRegion region )
|
||||||
glVertex2i( r.x(), r.y() + r.height());
|
glVertex2i( r.x(), r.y() + r.height());
|
||||||
glEnd();
|
glEnd();
|
||||||
}
|
}
|
||||||
|
glPopAttrib();
|
||||||
}
|
}
|
||||||
|
|
||||||
void SceneOpenGL::windowAdded( Toplevel* c )
|
void SceneOpenGL::windowAdded( Toplevel* c )
|
||||||
|
|
Loading…
Reference in a new issue