From c2bb80a26daf59b795ed96d008e76602d1a3194d Mon Sep 17 00:00:00 2001 From: Sebastian Keller Date: Wed, 29 Sep 2021 20:02:04 +0200 Subject: [PATCH] util: Export and annotate meta_get_clutter_debug_flags This will be useful for getting the initial state when adding switches for these flags to looking glass. Related: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3968 Part-of: --- src/core/util-private.h | 4 ---- src/core/util.c | 6 ++++++ src/meta/util.h | 5 +++++ 3 files changed, 11 insertions(+), 4 deletions(-) diff --git a/src/core/util-private.h b/src/core/util-private.h index 01b663966..ff9d7ce42 100644 --- a/src/core/util-private.h +++ b/src/core/util-private.h @@ -54,8 +54,4 @@ void meta_init_debug_utils (void); (ycoord) >= (rect).y && \ (ycoord) < ((rect).y + (rect).height)) -void meta_get_clutter_debug_flags (ClutterDebugFlag *debug_flags, - ClutterDrawDebugFlag *draw_flags, - ClutterPickDebugFlag *pick_flags); - #endif diff --git a/src/core/util.c b/src/core/util.c index 5e32db549..3133a072c 100644 --- a/src/core/util.c +++ b/src/core/util.c @@ -772,6 +772,12 @@ meta_remove_clutter_debug_flags (ClutterDebugFlag debug_flags, clutter_remove_debug_flags (debug_flags, draw_flags, pick_flags); } +/** + * meta_get_clutter_debug_flags: + * @debug_flags: (out) (optional): return location for debug flags + * @draw_flags: (out) (optional): return location for draw debug flags + * @pick_flags: (out) (optional): return location for pick debug flags + */ void meta_get_clutter_debug_flags (ClutterDebugFlag *debug_flags, ClutterDrawDebugFlag *draw_flags, diff --git a/src/meta/util.h b/src/meta/util.h index 9e67ed19d..d08bba4aa 100644 --- a/src/meta/util.h +++ b/src/meta/util.h @@ -226,6 +226,11 @@ void meta_remove_clutter_debug_flags (ClutterDebugFlag debug_flags, ClutterDrawDebugFlag draw_flags, ClutterPickDebugFlag pick_flags); +META_EXPORT +void meta_get_clutter_debug_flags (ClutterDebugFlag *debug_flags, + ClutterDrawDebugFlag *draw_flags, + ClutterPickDebugFlag *pick_flags); + META_EXPORT void meta_add_debug_paint_flag (MetaDebugPaintFlag flag);