From 6250a8725ed6a2d9d85f4d313e9931c2fe4a8de3 Mon Sep 17 00:00:00 2001 From: Hans Goudey Date: Thu, 29 Oct 2020 19:34:29 -0500 Subject: Cleanup: Use an enum to set instanced panel expansion This commit uses an enum to access expansion for specific panels for each modifier, constraint, etc. Even though these values are quite simple, this can help make the code more explicit when the ui_expand_flag is accessed directly. Also update comments about this bitfield to make them consistent. --- source/blender/blenkernel/intern/modifier.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'source/blender/blenkernel/intern/modifier.c') diff --git a/source/blender/blenkernel/intern/modifier.c b/source/blender/blenkernel/intern/modifier.c index 1ac63e653c0..0054d2f76d1 100644 --- a/source/blender/blenkernel/intern/modifier.c +++ b/source/blender/blenkernel/intern/modifier.c @@ -38,6 +38,7 @@ #include "DNA_mesh_types.h" #include "DNA_object_types.h" #include "DNA_scene_types.h" +#include "DNA_screen_types.h" #include "BLI_linklist.h" #include "BLI_listbase.h" @@ -132,7 +133,7 @@ void BKE_modifier_type_panel_id(ModifierType type, char *r_idname) void BKE_modifier_panel_expand(ModifierData *md) { - md->ui_expand_flag |= (1 << 0); + md->ui_expand_flag |= UI_PANEL_DATA_EXPAND_ROOT; } /***/ -- cgit v1.2.3