Merge lp:~vanvugt/compiz-core/fix-924736 into lp:compiz-core

Proposed by Daniel van Vugt
Status: Merged
Merged at revision: 3005
Proposed branch: lp:~vanvugt/compiz-core/fix-924736
Merge into: lp:compiz-core
Diff against target: 30 lines (+3/-3)
1 file modified
gtk/window-decorator/metacity.c (+3/-3)
To merge this branch: bzr merge lp:~vanvugt/compiz-core/fix-924736
Reviewer Review Type Date Requested Status
Tim Penhey (community) Approve
Review via email: mp+93342@code.launchpad.net

Description of the change

Fix semi-maximized windows missing borders or shadows (LP: #924736).

To post a comment you must log in.
Revision history for this message
Sam Spilsbury (smspillaz) wrote :

Design has requested that semi maximized windows have maximized-like borders iirc.

Actually the bug that was causing them not to get shadows in the first place was that there was a typo where maximized windows were being given an invalid shadow context. That's fixed in my other branch

8 - &frame->max_border_shadow_inactive,
9 + &frame->max_border_shadow_active,

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

I don't think "design" fully understands the question and the implications of this particular bug.

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

This fix makes semi-maximized windows look exactly like they do in oneiric. Isn't that what we want?

Revision history for this message
Sam Spilsbury (smspillaz) wrote :

Not really, I remember asking John about this a while ago and he told me that semi maximized windows should effectively behave and look like maximized windows (but obviously need to have a shadow).

Like I said, I'll double check.

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

I just checked the source for unity-window-decorator and it already contains this fix (obviously never backported to gtk-window-decorator yet).

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

Removed the comment about the assertion. I can't reproduce the assertion any more. It's obviously not caused by this fix.

Revision history for this message
Tim Penhey (thumper) wrote :

Code seems sound.

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'gtk/window-decorator/metacity.c'
2--- gtk/window-decorator/metacity.c 2012-01-12 06:48:58 +0000
3+++ gtk/window-decorator/metacity.c 2012-02-16 07:03:23 +0000
4@@ -521,7 +521,7 @@
5 if (d->active)
6 *flags |= (MetaFrameFlags ) META_FRAME_HAS_FOCUS;
7
8- if ((d->state & META_MAXIMIZED))
9+ if ((d->state & META_MAXIMIZED) == META_MAXIMIZED)
10 *flags |= (MetaFrameFlags ) META_FRAME_MAXIMIZED;
11
12 if (d->state & WNCK_WINDOW_STATE_STICKY)
13@@ -1142,7 +1142,7 @@
14 decor_context_t *context;
15 decor_shadow_t *shadow;
16
17- if ((d->state & META_MAXIMIZED))
18+ if ((d->state & META_MAXIMIZED) == META_MAXIMIZED)
19 {
20 if (!d->frame_window)
21 {
22@@ -1206,7 +1206,7 @@
23 }
24 else
25 {
26- if ((d->state & META_MAXIMIZED))
27+ if ((d->state & META_MAXIMIZED) == META_MAXIMIZED)
28 decor_get_default_layout (context, d->client_width,
29 d->client_height - d->frame->titlebar_height,
30 &layout);

Subscribers

People subscribed via source and target branches