diff options
author | Hans Goudey <h.goudey@me.com> | 2020-11-13 21:56:55 +0300 |
---|---|---|
committer | Hans Goudey <h.goudey@me.com> | 2020-11-13 21:57:20 +0300 |
commit | 9d28353b525ecfbcca1501be72e4276dfb2bbc2a (patch) | |
tree | 533876e87d98d0800ad3e55eb3e637492fc66de5 /source/blender/makesrna/intern/rna_ui.c | |
parent | 4c193f731e31664eae335f7f093699b7a6dfac42 (diff) |
Cleanup: Make panel type flag names more clear
The overlap with the `Panel` flags that start with "PNL" was quite
confusing because wasn't clear which enum a flag was from. The
new names are a bit longer, but the clarity is worth it.
Diffstat (limited to 'source/blender/makesrna/intern/rna_ui.c')
-rw-r--r-- | source/blender/makesrna/intern/rna_ui.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/source/blender/makesrna/intern/rna_ui.c b/source/blender/makesrna/intern/rna_ui.c index 2994d0eafb5..51cc178ab15 100644 --- a/source/blender/makesrna/intern/rna_ui.c +++ b/source/blender/makesrna/intern/rna_ui.c @@ -376,7 +376,7 @@ static StructRNA *rna_Panel_register(Main *bmain, for (; pt_iter; pt_iter = pt_iter->prev) { /* No header has priority. */ - if ((pt->flag & PNL_NO_HEADER) && !(pt_iter->flag & PNL_NO_HEADER)) { + if ((pt->flag & PANEL_TYPE_NO_HEADER) && !(pt_iter->flag & PANEL_TYPE_NO_HEADER)) { continue; } if (pt_iter->order <= pt->order) { @@ -1300,29 +1300,29 @@ static void rna_def_panel(BlenderRNA *brna) FunctionRNA *func; static const EnumPropertyItem panel_flag_items[] = { - {PNL_DEFAULT_CLOSED, + {PANEL_TYPE_DEFAULT_CLOSED, "DEFAULT_CLOSED", 0, "Default Closed", "Defines if the panel has to be open or collapsed at the time of its creation"}, - {PNL_NO_HEADER, + {PANEL_TYPE_NO_HEADER, "HIDE_HEADER", 0, "Hide Header", "If set to False, the panel shows a header, which contains a clickable " "arrow to collapse the panel and the label (see bl_label)"}, - {PNL_INSTANCED, + {PANEL_TYPE_INSTANCED, "INSTANCED", 0, "Instanced Panel", "Multiple panels with this type can be used as part of a list depending on data external " "to the UI. Used to create panels for the modifiers and other stacks"}, - {PNL_LAYOUT_HEADER_EXPAND, + {PANEL_TYPE_HEADER_EXPAND, "HEADER_LAYOUT_EXPAND", 0, "Expand Header Layout", "Allow buttons in the header to stretch and shrink to fill the entire layout width"}, - {PNL_DRAW_BOX, "DRAW_BOX", 0, "Box Style", "Draw panel with the box widget theme"}, + {PANEL_TYPE_DRAW_BOX, "DRAW_BOX", 0, "Box Style", "Draw panel with the box widget theme"}, {0, NULL, 0, NULL, NULL}, }; |