[gtk+] Some struct repacking



commit 5657b805d755f507f7b76b13cae60d75f5452e94
Author: Matthias Clasen <mclasen redhat com>
Date:   Sun Jan 12 09:39:23 2014 -0500

    Some struct repacking
    
    Save a few bytes here and there.

 gdk/gdkdisplayprivate.h |    2 +-
 gdk/gdkinternals.h      |   19 ++++++++++---------
 gdk/x11/gdkwindow-x11.h |    4 ++--
 3 files changed, 13 insertions(+), 12 deletions(-)
---
diff --git a/gdk/gdkdisplayprivate.h b/gdk/gdkdisplayprivate.h
index df79f59..2dbaafe 100644
--- a/gdk/gdkdisplayprivate.h
+++ b/gdk/gdkdisplayprivate.h
@@ -110,7 +110,6 @@ struct _GdkDisplay
    * is part of a double-click or triple-click
    */
   GHashTable *multiple_click_info;
-  guint double_click_time;  /* Maximum time between clicks in msecs */
   GdkDevice *core_pointer;  /* Core pointer device */
 
   guint event_pause_count;       /* How many times events are blocked */
@@ -125,6 +124,7 @@ struct _GdkDisplay
   GHashTable *pointers_info;  /* GdkPointerWindowInfo for each device */
   guint32 last_event_time;    /* Last reported event time from server */
 
+  guint double_click_time;  /* Maximum time between clicks in msecs */
   guint double_click_distance;   /* Maximum distance between clicks in pixels */
 };
 
diff --git a/gdk/gdkinternals.h b/gdk/gdkinternals.h
index bebdec0..954be90 100644
--- a/gdk/gdkinternals.h
+++ b/gdk/gdkinternals.h
@@ -192,6 +192,12 @@ struct _GdkWindow
   gint y;
 
   GdkEventMask event_mask;
+  guint8 window_type;
+
+  guint8 depth;
+  guint8 resize_count;
+
+  gint8 toplevel_window_type;
 
   GList *filters;
   GList *children;
@@ -204,14 +210,10 @@ struct _GdkWindow
   cairo_region_t *update_area;
   guint update_freeze_count;
 
-  guint8 window_type;
-  guint8 depth;
-  guint8 resize_count;
+  GdkWindowState state;
 
-  gint8 toplevel_window_type;
   guint8 alpha;
-
-  GdkWindowState state;
+  guint8 fullscreen_mode;
 
   guint guffaw_gravity : 1;
   guint input_only : 1;
@@ -234,7 +236,6 @@ struct _GdkWindow
   guint in_update : 1;
   guint geometry_dirty : 1;
   guint event_compression : 1;
-  GdkFullscreenMode fullscreen_mode;
 
   /* The GdkWindow that has the impl, ref:ed if another window.
    * This ref is required to keep the wrapper of the impl window alive
@@ -246,6 +247,8 @@ struct _GdkWindow
   gint abs_x, abs_y; /* Absolute offset in impl */
   gint width, height;
 
+  guint num_offscreen_children;
+
   /* The clip region is the part of the window, in window coordinates
      that is fully or partially (i.e. semi transparently) visible in
      the window hierarchy from the toplevel and down */
@@ -272,8 +275,6 @@ struct _GdkWindow
   gulong device_added_handler_id;
   gulong device_changed_handler_id;
 
-  guint num_offscreen_children;
-
   GdkFrameClock *frame_clock; /* NULL to use from parent or default */
   GdkWindowInvalidateHandlerFunc invalidate_handler;
 };
diff --git a/gdk/x11/gdkwindow-x11.h b/gdk/x11/gdkwindow-x11.h
index 92db3d8..d66e874 100644
--- a/gdk/x11/gdkwindow-x11.h
+++ b/gdk/x11/gdkwindow-x11.h
@@ -64,8 +64,6 @@ struct _GdkWindowImplX11
 
   Window xid;
 
-  gint window_scale;
-
   GdkToplevelX11 *toplevel;    /* Toplevel-specific information */
   GdkCursor *cursor;
   GHashTable *device_cursor;
@@ -76,6 +74,8 @@ struct _GdkWindowImplX11
   guint frame_clock_connected : 1;
   guint frame_sync_enabled : 1;
 
+  gint window_scale;
+
   cairo_surface_t *cairo_surface;
 
 #if defined (HAVE_XCOMPOSITE) && defined(HAVE_XDAMAGE) && defined (HAVE_XFIXES)


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