summaryrefslogtreecommitdiff
path: root/src/mcompositescene.cpp
diff options
context:
space:
mode:
authorAbdiel Janulgue <abdiel.janulgue@nokia.com>2010-10-18 03:07:05 +0300
committerAbdiel Janulgue <abdiel.janulgue@nokia.com>2010-10-18 03:07:05 +0300
commit7a689dac20655a44dc14244bf88eaf92cc2d6429 (patch)
treec84fe9e4e0b824907dfb24ae1c2177dac6ab80ef /src/mcompositescene.cpp
parent975ccea8f404febb1f0c62c15b2b6f22fe858c12 (diff)
Changes: Fix ugly flicker caused by skipping desktop window painting when a window above it
is scaled or moved to an area that exposes the desktop window. RevBy: TrustMe
Diffstat (limited to 'src/mcompositescene.cpp')
-rw-r--r--src/mcompositescene.cpp8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/mcompositescene.cpp b/src/mcompositescene.cpp
index 617d6b0..239e991 100644
--- a/src/mcompositescene.cpp
+++ b/src/mcompositescene.cpp
@@ -121,9 +121,11 @@ void MCompositeScene::drawItems(QPainter *painter, int numItems, QGraphicsItem *
// nothing below is visible anymore
break;
- // FIXME: this region is always the same as the window's shape,
- // some transformations would be needed...
- QRegion r(cw->propertyCache()->shapeRegion());
+ // Ensure that intersects() still work, otherwise, painting a window
+ // is skipped when another window above it is scaled or moved to an
+ // area that exposed the lower window and causes an ugly flicker.
+ // r reflects the applied transformation and position of the window
+ QRegion r = cw->sceneTransform().map(cw->propertyCache()->shapeRegion());
// transitioning window can be smaller than shapeRegion(), so paint
// all transitioning windows