Merge lp:~townsend/compiz/fix-decoration-grab-0.9.10 into lp:compiz/0.9.10

Proposed by Christopher Townsend
Status: Merged
Approved by: Brandon Schaefer
Approved revision: 3792
Merged at revision: 3794
Proposed branch: lp:~townsend/compiz/fix-decoration-grab-0.9.10
Merge into: lp:compiz/0.9.10
Diff against target: 22 lines (+3/-2)
1 file modified
gtk/window-decorator/metacity.c (+3/-2)
To merge this branch: bzr merge lp:~townsend/compiz/fix-decoration-grab-0.9.10
Reviewer Review Type Date Requested Status
PS Jenkins bot (community) continuous-integration Approve
Marco Trevisan (Treviño) Approve
Review via email: mp+188638@code.launchpad.net

Commit message

Fix issue where non-resizable windows and semi-maximized window would have an area near the top of the title bar that could not be grabbed.

Description of the change

= Issue =
On non-resizable windows or semi-maximized windows, approximately the top half to top third of the title bar decoration is not grabable for moving the window. This is due to a regression introduced in http://bazaar.launchpad.net/~compiz-team/compiz/0.9.10/revision/3735.

= Fix =
After much debugging, I discovered that these particular type of windows call the middle/middle event_window_position twice, so this was throwing off the y coordinate. Other window types just call this once. The y coordinate is not needed for these types of windows because there cannot be an invisible border to resize the window, so now just check if the window is able to be vertically resized, and if so, then add the y coordinate.

Note that this is the same fix that is proposed for trunk.

To post a comment you must log in.
Revision history for this message
Marco Trevisan (Treviño) (3v1n0) :
review: Approve
Revision history for this message
PS Jenkins bot (ps-jenkins) :
review: Approve (continuous-integration)

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'gtk/window-decorator/metacity.c'
--- gtk/window-decorator/metacity.c 2013-06-04 14:11:23 +0000
+++ gtk/window-decorator/metacity.c 2013-10-01 15:53:52 +0000
@@ -1108,7 +1108,7 @@
1108 *x += d->frame->win_extents.left + 4;1108 *x += d->frame->win_extents.left + 4;
1109 *y += d->frame->win_extents.top + 2;1109 *y += d->frame->win_extents.top + 2;
1110 }1110 }
1111 1111
1112 if (flags & META_FRAME_ALLOWS_HORIZONTAL_RESIZE)1112 if (flags & META_FRAME_ALLOWS_HORIZONTAL_RESIZE)
1113 {1113 {
1114 *x += mutter_draggable_border_width;1114 *x += mutter_draggable_border_width;
@@ -1389,7 +1389,8 @@
1389 if (!d->frame_window)1389 if (!d->frame_window)
1390 {1390 {
1391 *x += mutter_draggable_border_width;1391 *x += mutter_draggable_border_width;
1392 *y += mutter_draggable_border_width;1392 if (flags & META_FRAME_ALLOWS_VERTICAL_RESIZE)
1393 *y += mutter_draggable_border_width;
1393 }1394 }
13941395
1395 break;1396 break;

Subscribers

People subscribed via source and target branches