From 31945c6e01153339540ac8d87e9f89d65f9a5c3e Mon Sep 17 00:00:00 2001 From: Bill Currie Date: Thu, 29 Sep 2022 15:48:23 +0900 Subject: [PATCH] [ui] Rearrange fields in view_t slightly Moving the flags bitfields up with the gravity field makes for better packing in 64-bit builds. --- include/QF/ui/view.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/include/QF/ui/view.h b/include/QF/ui/view.h index 2ae69e3d7..a2486ccdd 100644 --- a/include/QF/ui/view.h +++ b/include/QF/ui/view.h @@ -93,6 +93,9 @@ struct view_s { int xrel, yrel; //@} grav_t gravity; ///< The gravity of the view. + unsigned visible:1; ///< If false, view_draw() skips this view. + unsigned resize_x:1; ///< If true, view's width follows parent's. + unsigned resize_y:1; ///< If true, view's height follows parent's. view_t *parent; ///< The parent view. view_t **children; ///< The child views. int num_children; ///< Number of child views in view. @@ -119,9 +122,6 @@ struct view_s { touch this at all except view_new(), which just sets it to 0. */ void *data; - unsigned visible:1; ///< If false, view_draw() skips this view. - unsigned resize_x:1; ///< If true, view's width follows parent's. - unsigned resize_y:1; ///< If true, view's height follows parent's. }; /** Create a new view. view_t::draw is set to view_draw() and the view is made