[gtk+/wip/simple-draw4] gdkwindow: Avoid some unnecessary typechecks

commit cb2ba0abc09dea01a9d8d95440f079158d56368f
Author: Alexander Larsson <alexl redhat com>
Date:   Fri May 3 10:44:44 2013 +0200

    gdkwindow: Avoid some unnecessary typechecks
    This removes the typechecks in GDK_WINDOW_TYPE and GDK_WINDOW_DESTROYED. These
    are only used internally in gdkwindow.c and gdkdisplay.c anyway,  and these
    functions check for typesafety of arguments on function entry.

 gdk/gdkinternals.h |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/gdk/gdkinternals.h b/gdk/gdkinternals.h
index 059f1b2..87d3fbc 100644
--- a/gdk/gdkinternals.h
+++ b/gdk/gdkinternals.h
@@ -269,8 +269,8 @@ struct _GdkWindow
   GdkWindowInvalidateHandlerFunc invalidate_handler;
-#define GDK_WINDOW_TYPE(d) (((GDK_WINDOW (d)))->window_type)
-#define GDK_WINDOW_DESTROYED(d) (GDK_WINDOW (d)->destroyed)
+#define GDK_WINDOW_TYPE(d) ((((GdkWindow *)(d)))->window_type)
+#define GDK_WINDOW_DESTROYED(d) (((GdkWindow *)(d))->destroyed)
 extern gchar     *_gdk_display_name;
 extern gint       _gdk_screen_number;

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