diff options
author | Campbell Barton <campbell@blender.org> | 2022-04-12 04:59:25 +0300 |
---|---|---|
committer | Campbell Barton <campbell@blender.org> | 2022-04-12 04:59:25 +0300 |
commit | 2451d7d57ed354aa3721153af417f06b2cebeec0 (patch) | |
tree | dc6ff0850383ffbb5b7663ef5ca0aeb4fa14a1e4 /source/blender/windowmanager | |
parent | 6f1ad5f5e77ca5b5c257db97798e9a2087c9defd (diff) |
Cleanup: use _NUM suffix for space/region type ranges
- Replace SPACE_TYPE_LAST with SPACE_TYPE_NUM (adding 1).
- Rename RGN_TYPE_LEN to RGN_TYPE_NUM
This makes it possible to tag space-type/region-type combinations
with `bool tag[SPACE_TYPE_NUM][RGN_TYPE_NUM]` which reads more clearly
than `bool tag[SPACE_TYPE_LAST + 1][RGN_TYPE_LEN]`.
Diffstat (limited to 'source/blender/windowmanager')
-rw-r--r-- | source/blender/windowmanager/intern/wm_toolsystem.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/source/blender/windowmanager/intern/wm_toolsystem.c b/source/blender/windowmanager/intern/wm_toolsystem.c index a8d4ca0f02b..388abe21578 100644 --- a/source/blender/windowmanager/intern/wm_toolsystem.c +++ b/source/blender/windowmanager/intern/wm_toolsystem.c @@ -551,7 +551,7 @@ void WM_toolsystem_refresh_screen_area(WorkSpace *workspace, ViewLayer *view_lay void WM_toolsystem_refresh_screen_window(wmWindow *win) { WorkSpace *workspace = WM_window_get_active_workspace(win); - bool space_type_has_tools[SPACE_TYPE_LAST + 1] = {0}; + bool space_type_has_tools[SPACE_TYPE_NUM] = {0}; LISTBASE_FOREACH (bToolRef *, tref, &workspace->tools) { space_type_has_tools[tref->space_type] = true; } |