Merge lp:~smspillaz/compiz-core/compiz-core.fix_987639 into lp:compiz-core/0.9.8

Proposed by Sam Spilsbury
Status: Merged
Merged at revision: 3114
Proposed branch: lp:~smspillaz/compiz-core/compiz-core.fix_987639
Merge into: lp:compiz-core/0.9.8
Diff against target: 50 lines (+15/-18)
1 file modified
plugins/decor/src/decor.cpp (+15/-18)
To merge this branch: bzr merge lp:~smspillaz/compiz-core/compiz-core.fix_987639
Reviewer Review Type Date Requested Status
Daniel van Vugt Approve
Alan Griffiths Approve
Review via email: mp+103300@code.launchpad.net

Description of the change

== Problem ==

See LP#987639 - decorations would be clipped by paint region but this is incorrect

== Solution ==

Checked with older versions, they should indeed always use infiniteRegion in the case of transformed windows.

== test ==

Already covered.

To post a comment you must log in.
Revision history for this message
Alan Griffiths (alan-griffiths) wrote :

LGTM

review: Approve
Revision history for this message
Daniel van Vugt (vanvugt) wrote :

Looks OK, and confirmed the fix works.

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'plugins/decor/src/decor.cpp'
--- plugins/decor/src/decor.cpp 2012-04-23 05:36:16 +0000
+++ plugins/decor/src/decor.cpp 2012-04-24 14:37:25 +0000
@@ -223,31 +223,28 @@
223223
224 const CompRegion *preg = NULL;224 const CompRegion *preg = NULL;
225225
226 if (mClipGroup)226 if ((mask & (PAINT_WINDOW_ON_TRANSFORMED_SCREEN_MASK |
227 PAINT_WINDOW_WITH_OFFSET_MASK)))
228 preg = &region;
229 else if (mask & PAINT_WINDOW_TRANSFORMED_MASK)
230 preg = &infiniteRegion;
231 else if (mClipGroup)
227 {232 {
228 if ((mask & (PAINT_WINDOW_ON_TRANSFORMED_SCREEN_MASK |233 tmpRegion = mOutputRegion;
229 PAINT_WINDOW_WITH_OFFSET_MASK)))234 tmpRegion &= region;
235
236 if (tmpRegion.isEmpty ())
230 preg = &region;237 preg = &region;
231 else if (mask & PAINT_WINDOW_TRANSFORMED_MASK)
232 preg = &infiniteRegion;
233 else238 else
234 {239 preg = &shadowRegion;
235 tmpRegion = mOutputRegion;
236 tmpRegion &= region;
237
238 if (tmpRegion.isEmpty ())
239 preg = &region;
240 else
241 preg = &shadowRegion;
242 }
243
244 /* In case some plugin needs to paint us with an offset region */
245 if (preg->isEmpty ())
246 preg = &region;
247 }240 }
248 else241 else
249 preg = &region;242 preg = &region;
250243
244 /* In case some plugin needs to paint us with an offset region */
245 if (preg->isEmpty ())
246 preg = &region;
247
251 const CompRegion &reg (*preg);248 const CompRegion &reg (*preg);
252249
253 gWindow->geometry ().reset ();250 gWindow->geometry ().reset ();

Subscribers

People subscribed via source and target branches