[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

rpms/gnome-screensaver/devel gnome-screensaver-2.18.0-handle-overlapping-heads.patch, 1.1, 1.2 gnome-screensaver.spec, 1.150, 1.151



Author: rstrode

Update of /cvs/pkgs/rpms/gnome-screensaver/devel
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv17208

Modified Files:
	gnome-screensaver-2.18.0-handle-overlapping-heads.patch 
	gnome-screensaver.spec 
Log Message:
- Yet another crack at bug 238961.


gnome-screensaver-2.18.0-handle-overlapping-heads.patch:

Index: gnome-screensaver-2.18.0-handle-overlapping-heads.patch
===================================================================
RCS file: /cvs/pkgs/rpms/gnome-screensaver/devel/gnome-screensaver-2.18.0-handle-overlapping-heads.patch,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- gnome-screensaver-2.18.0-handle-overlapping-heads.patch	16 May 2007 23:27:10 -0000	1.1
+++ gnome-screensaver-2.18.0-handle-overlapping-heads.patch	18 May 2007 16:26:05 -0000	1.2
@@ -1,44 +1,44 @@
---- gnome-screensaver-2.18.0/src/gs-manager.c.handle-overlapping-heads	2007-05-16 18:47:52.000000000 -0400
-+++ gnome-screensaver-2.18.0/src/gs-manager.c	2007-05-16 19:23:45.000000000 -0400
-@@ -1065,6 +1065,32 @@
-         g_signal_emit (manager, signals [AUTH_REQUEST_END], 0);
+--- gnome-screensaver-2.18.0/src/gs-window-x11.c.handle-overlapping-screens	2007-05-18 12:24:01.000000000 -0400
++++ gnome-screensaver-2.18.0/src/gs-window-x11.c	2007-05-18 12:24:01.000000000 -0400
+@@ -290,14 +290,41 @@
+         gdk_flush ();
  }
  
-+int
-+find_monitor_with_top_window_at_point (GdkScreen *screen,
-+		                       gint       x,
-+		                       gint       y)
++static GdkRegion *
++get_outside_region (GSWindow *window)
 +{
-+	gint num_monitors, i;
++        int i;
++        GdkRegion *region;
 +
-+	g_return_val_if_fail (GDK_IS_SCREEN (screen), -1);
++        region = gdk_region_new ();
++        for (i = 0; i < window->priv->monitor; i++) {
++                GdkRectangle geometry;
++
++                gdk_screen_get_monitor_geometry (GTK_WINDOW (window)->screen,
++                                                   i, &geometry);
++                gdk_region_union_with_rect (region, &geometry);
++        }
 +
-+	num_monitors = gdk_screen_get_n_monitors (screen);
-+
-+	for (i = num_monitors - 1; i <= 0; i--) {
-+		GdkRectangle monitor;
-+
-+		gdk_screen_get_monitor_geometry (screen, i, &monitor);
-+
-+		if (x >= monitor.x &&
-+				x < monitor.x + monitor.width &&
-+				y >= monitor.y &&
-+				y < (monitor.y + monitor.height))
-+			return i;
-+	}
-+
-+	return gdk_screen_get_monitor_at_point (screen, x, y);
++        return region;
 +}
 +
- static GSWindow *
- find_window_at_pointer (GSManager *manager)
+ static void
+ update_geometry (GSWindow *window)
  {
-@@ -1078,7 +1104,7 @@
+         GdkRectangle geometry;
++        GdkRegion *outside_region, *monitor_region;
++
++        outside_region = get_outside_region (window);
  
-         display = gdk_display_get_default ();
-         gdk_display_get_pointer (display, &screen, &x, &y, NULL);
--        monitor = gdk_screen_get_monitor_at_point (screen, x, y);
-+        monitor = find_monitor_with_top_window_at_point (screen, x, y);
-         screen_num = gdk_screen_get_number (screen);
+         gdk_screen_get_monitor_geometry (GTK_WINDOW (window)->screen,
+                                          window->priv->monitor,
+                                          &geometry);
++        monitor_region = gdk_region_rectangle (&geometry);
++        gdk_region_subtract (monitor_region, outside_region);
++        gdk_region_destroy (outside_region); 
++
++        gdk_region_get_clipbox (monitor_region, &geometry);
++        gdk_region_destroy (monitor_region); 
  
-         /* Find the gs-window that is on that screen */
+         window->priv->geometry.x = geometry.x;
+         window->priv->geometry.y = geometry.y;


Index: gnome-screensaver.spec
===================================================================
RCS file: /cvs/pkgs/rpms/gnome-screensaver/devel/gnome-screensaver.spec,v
retrieving revision 1.150
retrieving revision 1.151
diff -u -r1.150 -r1.151
--- gnome-screensaver.spec	17 May 2007 19:28:57 -0000	1.150
+++ gnome-screensaver.spec	18 May 2007 16:26:05 -0000	1.151
@@ -13,7 +13,7 @@
 Summary: GNOME Screensaver
 Name: gnome-screensaver
 Version: 2.18.0
-Release: 10%{?dist} 
+Release: 11%{?dist} 
 License: GPL
 Group: Amusements/Graphics
 Source0: http://ftp.gnome.org/pub/gnome/sources/gnome-screensaver/2.18/%{name}-%{version}.tar.bz2
@@ -133,6 +133,9 @@
 %{_sysconfdir}/pam.d/*
 
 %changelog
+* Fri May 18 2007 Ray Strode <rstrode redhat com> - 2.18.0-11
+- Yet another crack at bug 238961.
+
 * Wed May 16 2007 Ray Strode <rstrode redhat com> - 2.18.0-10
 - Another crack at bug 238961.
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]