[mutter/f17] Backport fixes for GNOME #677657 and #670396

Debarshi Ray rishi at fedoraproject.org
Wed Nov 28 19:15:22 UTC 2012


commit 4a69de65ea531449b2b923bbeaf99791a61856d1
Author: Debarshi Ray <debarshir at gnome.org>
Date:   Wed Nov 28 20:15:13 2012 +0100

    Backport fixes for GNOME #677657 and #670396

 ...guard-window-when-the-X-screen-is-resized.patch |   43 ++++++++++++++++++++
 ...dow-actor-Don-t-unredirect-shaped-windows.patch |   33 +++++++++++++++
 mutter.spec                                        |   13 +++++-
 3 files changed, 88 insertions(+), 1 deletions(-)
---
diff --git a/0001-Resize-the-guard-window-when-the-X-screen-is-resized.patch b/0001-Resize-the-guard-window-when-the-X-screen-is-resized.patch
new file mode 100644
index 0000000..7b41b2f
--- /dev/null
+++ b/0001-Resize-the-guard-window-when-the-X-screen-is-resized.patch
@@ -0,0 +1,43 @@
+From 472662d0996b0b4db6355864c6e7944d31d3d62b Mon Sep 17 00:00:00 2001
+From: Benjamin Berg <benjamin at sipsolutions.net>
+Date: Sun, 14 Oct 2012 12:16:06 +0200
+Subject: [PATCH] Resize the guard window when the X screen is resized.
+
+Fixes bug #670396. Without this fix the guard window may not
+extend over the whole area of the screen after a XRandR
+reconfiguration. The effect being that mouse events are
+delivered to invisible windows.
+---
+ src/core/screen.c | 16 ++++++++++++++++
+ 1 file changed, 16 insertions(+)
+
+diff --git a/src/core/screen.c b/src/core/screen.c
+index db9b5ed..e49f7d0 100644
+--- a/src/core/screen.c
++++ b/src/core/screen.c
+@@ -2878,6 +2878,22 @@ meta_screen_resize (MetaScreen *screen,
+   reload_monitor_infos (screen);
+   set_desktop_geometry_hint (screen);
+ 
++  /* Resize the guard window to fill the screen again. */
++  if (screen->guard_window != None)
++    {
++      XWindowChanges changes;
++
++      changes.x = 0;
++      changes.y = 0;
++      changes.width = width;
++      changes.height = height;
++
++      XConfigureWindow(screen->display->xdisplay,
++                       screen->guard_window,
++                       CWX | CWY | CWWidth | CWHeight,
++                       &changes);
++    }
++
+   if (screen->display->compositor)
+     meta_compositor_sync_screen_size (screen->display->compositor,
+ 				      screen, width, height);
+-- 
+1.8.0
+
diff --git a/0001-meta-window-actor-Don-t-unredirect-shaped-windows.patch b/0001-meta-window-actor-Don-t-unredirect-shaped-windows.patch
new file mode 100644
index 0000000..3cbdcea
--- /dev/null
+++ b/0001-meta-window-actor-Don-t-unredirect-shaped-windows.patch
@@ -0,0 +1,33 @@
+From 66eac7824a7eb70fdd90109b763e59b70a13739b Mon Sep 17 00:00:00 2001
+From: "Jasper St. Pierre" <jstpierre at mecheye.net>
+Date: Thu, 7 Jun 2012 23:31:21 -0400
+Subject: [PATCH] meta-window-actor: Don't unredirect shaped windows
+
+If a window has its BoundingRegion shaped, we shouldn't unredirect it,
+as it expects the rest of the windows from being shown under it. This
+prevents applications like the Skype screen recorder or gtkRecordMyDesktop
+which want to show a "border" around the recorded area from being
+unredirected, giving the appearance of making the desktop freeze.
+
+https://bugzilla.gnome.org/show_bug.cgi?id=677657
+---
+ src/compositor/meta-window-actor.c | 3 +++
+ 1 file changed, 3 insertions(+)
+
+diff --git a/src/compositor/meta-window-actor.c b/src/compositor/meta-window-actor.c
+index 14010a0..2dfde8b 100644
+--- a/src/compositor/meta-window-actor.c
++++ b/src/compositor/meta-window-actor.c
+@@ -1202,6 +1202,9 @@ meta_window_actor_should_unredirect (MetaWindowActor *self)
+   if (priv->argb32)
+     return FALSE;
+ 
++  if (metaWindow->has_shape)
++    return FALSE;
++
+   meta_screen_get_size (screen, &screen_width, &screen_height);
+   meta_window_get_outer_rect (metaWindow, &window_rect);
+ 
+-- 
+1.8.0
+
diff --git a/mutter.spec b/mutter.spec
index 0005df3..8342b47 100644
--- a/mutter.spec
+++ b/mutter.spec
@@ -1,6 +1,6 @@
 Name:          mutter
 Version:       3.4.1
-Release:       3%{?dist}
+Release:       4%{?dist}
 Summary:       Window and compositing manager based on Clutter
 
 Group:         User Interface/Desktops
@@ -11,6 +11,12 @@ Source0:       http://download.gnome.org/sources/%{name}/3.4/%{name}-%{version}.
 Patch0: mutter-never-slice-shape-mask.patch
 Patch1: mutter-use-cogl-texrect-api.patch
 
+# https://bugzilla.gnome.org/show_bug.cgi?id=677657
+Patch2: 0001-meta-window-actor-Don-t-unredirect-shaped-windows.patch
+
+# https://bugzilla.gnome.org/show_bug.cgi?id=670396
+Patch3: 0001-Resize-the-guard-window-when-the-X-screen-is-resized.patch
+
 BuildRequires: clutter-devel >= 1.7.5
 BuildRequires: pango-devel
 BuildRequires: startup-notification-devel
@@ -68,6 +74,8 @@ utilities for testing Metacity/Mutter themes.
 %setup -q
 %patch0 -p1
 %patch1 -p1
+%patch2 -p1
+%patch3 -p1
 
 %build
 (if ! test -x configure; then NOCONFIGURE=1 ./autogen.sh; fi;
@@ -136,6 +144,9 @@ glib-compile-schemas %{_datadir}/glib-2.0/schemas &> /dev/null || :
 %doc %{_mandir}/man1/mutter-window-demo.1.gz
 
 %changelog
+* Wed Nov 28 2012 Debarshi Ray <rishi at fedoraproject.org> 3.4.1-4
+- Backport fixes for GNOME #677657 and #670396
+
 * Wed May 09 2012 Adam Jackson <ajax at redhat.com> 3.4.1-3
 - mutter-never-slice-shape-mask.patch, mutter-use-cogl-texrect-api.patch:
   Fix window texturing on hardware without ARB_texture_non_power_of_two


More information about the scm-commits mailing list