Reset 'buffer' to None after freeing it.
That fixes the bug that XRender compositing can't be initialized correctly on KDE startup. svn path=/trunk/KDE/kdebase/workspace/; revision=821854
This commit is contained in:
parent
b703dc91a5
commit
69d45962cb
1 changed files with 1 additions and 2 deletions
|
@ -139,6 +139,7 @@ SceneXrender::~SceneXrender()
|
|||
}
|
||||
XRenderFreePicture( display(), front );
|
||||
XRenderFreePicture( display(), buffer );
|
||||
buffer = None;
|
||||
wspace->destroyOverlay();
|
||||
foreach( Window* w, windows )
|
||||
delete w;
|
||||
|
@ -153,8 +154,6 @@ bool SceneXrender::initFailed() const
|
|||
// so it is done manually using this buffer,
|
||||
void SceneXrender::createBuffer()
|
||||
{
|
||||
if( buffer != None )
|
||||
XRenderFreePicture( display(), buffer );
|
||||
Pixmap pixmap = XCreatePixmap( display(), rootWindow(), displayWidth(), displayHeight(), DefaultDepth( display(), DefaultScreen( display())));
|
||||
buffer = XRenderCreatePicture( display(), pixmap, format, 0, 0 );
|
||||
XFreePixmap( display(), pixmap ); // The picture owns the pixmap now
|
||||
|
|
Loading…
Reference in a new issue