[gtk+/rendering-cleanup: 9/41] x11: Change GDK_WINDOW_SCREEN macro



commit 55941207af64ddd20da07a5ca7ad0c2b6e3b9d5a
Author: Benjamin Otte <otte redhat com>
Date:   Wed Oct 6 01:54:00 2010 +0200

    x11: Change GDK_WINDOW_SCREEN macro
    
    on't look at GdkDrawableImplX11->screen, but call
    gdk_window_get_screen() instead.

 gdk/x11/gdkgeometry-x11.c |    2 +-
 gdk/x11/gdkprivate-x11.h  |    2 +-
 gdk/x11/gdkwindow-x11.c   |    2 +-
 3 files changed, 3 insertions(+), 3 deletions(-)
---
diff --git a/gdk/x11/gdkgeometry-x11.c b/gdk/x11/gdkgeometry-x11.c
index a4b7062..f7e967f 100644
--- a/gdk/x11/gdkgeometry-x11.c
+++ b/gdk/x11/gdkgeometry-x11.c
@@ -308,7 +308,7 @@ _gdk_x11_window_translate (GdkWindow      *window,
   item->u.translate.dy = dy;
   gdk_window_queue (window, item);
 
-  XCopyArea (GDK_WINDOW_XDISPLAY (impl),
+  XCopyArea (GDK_WINDOW_XDISPLAY ((GdkWindow *) impl),
              GDK_DRAWABLE_IMPL_X11 (private->impl)->xid,
              GDK_DRAWABLE_IMPL_X11 (impl->impl)->xid,
              xgc,
diff --git a/gdk/x11/gdkprivate-x11.h b/gdk/x11/gdkprivate-x11.h
index bfcf1e3..f413542 100644
--- a/gdk/x11/gdkprivate-x11.h
+++ b/gdk/x11/gdkprivate-x11.h
@@ -153,7 +153,7 @@ extern gboolean          _gdk_synchronize;
 #define GDK_DRAWABLE_XROOTWIN(win)    (GDK_WINDOW_XROOTWIN (win))
 #define GDK_SCREEN_DISPLAY(screen)    (GDK_SCREEN_X11 (screen)->display)
 #define GDK_SCREEN_XROOTWIN(screen)   (GDK_SCREEN_X11 (screen)->xroot_window)
-#define GDK_WINDOW_SCREEN(win)	      (GDK_DRAWABLE_IMPL_X11 (((GdkWindowObject *)win)->impl)->screen)
+#define GDK_WINDOW_SCREEN(win)	      (gdk_window_get_screen (win))
 #define GDK_WINDOW_DISPLAY(win)       (GDK_SCREEN_X11 (GDK_WINDOW_SCREEN (win))->display)
 #define GDK_WINDOW_XROOTWIN(win)      (GDK_SCREEN_X11 (GDK_WINDOW_SCREEN (win))->xroot_window)
 #define GDK_GC_DISPLAY(gc)            (GDK_SCREEN_DISPLAY (GDK_GC_X11(gc)->screen))
diff --git a/gdk/x11/gdkwindow-x11.c b/gdk/x11/gdkwindow-x11.c
index 0084d5a..e062a18 100644
--- a/gdk/x11/gdkwindow-x11.c
+++ b/gdk/x11/gdkwindow-x11.c
@@ -194,7 +194,7 @@ gdk_window_impl_x11_finalize (GObject *object)
 
   if (!GDK_WINDOW_DESTROYED (wrapper))
     {
-      GdkDisplay *display = GDK_WINDOW_DISPLAY (wrapper);
+      GdkDisplay *display = GDK_WINDOW_DISPLAY ((GdkWindow *) wrapper);
       
       _gdk_xid_table_remove (display, draw_impl->xid);
       if (window_impl->toplevel && window_impl->toplevel->focus_window)



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