[gtk+] Use the proper screen in _gdk_windowing_get_shape_for_mask()



commit 51a1af7aa4209bc602dafc058f87e3ed7a901764
Author: Claudio Saavedra <csaavedra igalia com>
Date:   Fri Apr 16 00:12:29 2010 +0300

    Use the proper screen in _gdk_windowing_get_shape_for_mask()
    
    Bug 615853 - BadMatch when pressing keyboard volume keys while pointer in
                 secondary X screen
    
    _gdk_windowing_get_shape_for_mask() is using the default screen, not taking
    into account that its GdkBitmap could have been created for a different one,
    causing BadMatch errors.

 gdk/x11/gdkwindow-x11.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/gdk/x11/gdkwindow-x11.c b/gdk/x11/gdkwindow-x11.c
index 1771873..e2dd131 100644
--- a/gdk/x11/gdkwindow-x11.c
+++ b/gdk/x11/gdkwindow-x11.c
@@ -4649,7 +4649,7 @@ _gdk_windowing_get_shape_for_mask (GdkBitmap *mask)
   display = gdk_drawable_get_display (GDK_DRAWABLE (mask));
 
   window = XCreateSimpleWindow (GDK_DISPLAY_XDISPLAY (display),
-                                GDK_SCREEN_XROOTWIN (gdk_display_get_default_screen (display)),
+                                GDK_SCREEN_XROOTWIN (gdk_drawable_get_screen (mask)),
                                 -1, -1, 1, 1, 0,
                                 0, 0);
   XShapeCombineMask (GDK_DISPLAY_XDISPLAY (display),



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