summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSam Spilsbury <smspillaz@gmail.com>2010-08-16 16:13:02 +0800
committerSam Spilsbury <smspillaz@gmail.com>2010-08-16 16:13:02 +0800
commit7464bfb9ed59cdd90148d59df0a61ca66e37b688 (patch)
tree2aaa37f770368725db30194ae80e4e26b6b745c1
parentf640fa90f99fd8fbcce9cafef59b2e4b0cc5b341 (diff)
downloadkdecompat-7464bfb9ed59cdd90148d59df0a61ca66e37b688.tar.gz
kdecompat-7464bfb9ed59cdd90148d59df0a61ca66e37b688.tar.bz2
Fix windows not redrawing after animating in
-rw-r--r--src/kdecompat.cpp28
1 files changed, 14 insertions, 14 deletions
diff --git a/src/kdecompat.cpp b/src/kdecompat.cpp
index 6032a32..724eda8 100644
--- a/src/kdecompat.cpp
+++ b/src/kdecompat.cpp
@@ -189,10 +189,19 @@ KDECompatWindow::glPaint (const GLWindowPaintAttrib &attrib,
const CompRegion &region,
unsigned int mask)
{
- bool status;
+ bool status = false;
KDECOMPAT_SCREEN (screen);
+ if ((!(ks->optionGetPlasmaThumbnails () || mPreviews.empty ()) &&
+ !(mSlideData || mSlideData->remaining)) ||
+ !window->mapNum () ||
+ (mask & PAINT_WINDOW_OCCLUSION_DETECTION_MASK))
+ {
+ status = gWindow->glPaint (attrib, transform, region, mask);
+ return status;
+ }
+
if (mSlideData && mSlideData->remaining)
{
GLFragment::Attrib fragment (gWindow->paintAttrib ());
@@ -246,25 +255,13 @@ KDECompatWindow::glPaint (const GLWindowPaintAttrib &attrib,
glScissor (clipBox.x1 (), screen->height () - clipBox.y2 (),
clipBox.width (), clipBox.height ());
- gWindow->glDraw (wTransform, fragment, region,
+ status = gWindow->glDraw (wTransform, fragment, region,
mask | PAINT_WINDOW_TRANSFORMED_MASK);
glDisable (GL_SCISSOR_TEST);
glPopAttrib ();
glPopMatrix ();
}
- else
- {
- status = gWindow->glPaint (attrib, transform, region, mask);
- }
-
- if (!ks->optionGetPlasmaThumbnails () ||
- mPreviews.empty () ||
- !window->mapNum () ||
- (mask & PAINT_WINDOW_OCCLUSION_DETECTION_MASK))
- {
- return status;
- }
foreach (const Thumb& thumb, mPreviews)
{
@@ -366,6 +363,9 @@ KDECompatWindow::glPaint (const GLWindowPaintAttrib &attrib,
glPopMatrix ();
}
}
+
+ if (!status)
+ status = gWindow->glPaint (attrib, transform, region, mask);
return status;
}