Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHans Goudey <h.goudey@me.com>2020-10-21 16:38:26 +0300
committerHans Goudey <h.goudey@me.com>2020-10-21 16:38:26 +0300
commitba718c1513607987fff8255906ab36aa88d3919c (patch)
treefb3f4c41a54d9c589fa3485c3648bedbc715224d
parent810f5b82ce1988cc0d295401486da809701e87d3 (diff)
Cleanup: Improve function and variable name
"pt" is unecessarily cryptic, and the funciton name wasn't very clear.
-rw-r--r--source/blender/makesrna/intern/rna_ui.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/source/blender/makesrna/intern/rna_ui.c b/source/blender/makesrna/intern/rna_ui.c
index 5179c4e538a..d87b3a6386e 100644
--- a/source/blender/makesrna/intern/rna_ui.c
+++ b/source/blender/makesrna/intern/rna_ui.c
@@ -180,14 +180,14 @@ static void panel_draw_header_preset(const bContext *C, Panel *panel)
RNA_parameter_list_free(&list);
}
-static void remove_panel_type_recursive(Panel *panel, const PanelType *pt)
+static void panel_type_clear_recursive(Panel *panel, const PanelType *type)
{
- if (panel->type == pt) {
+ if (panel->type == type) {
panel->type = NULL;
}
LISTBASE_FOREACH (Panel *, child_panel, &panel->children) {
- remove_panel_type_recursive(child_panel, pt);
+ panel_type_clear_recursive(child_panel, type);
}
}
@@ -231,7 +231,7 @@ static void rna_Panel_unregister(Main *bmain, StructRNA *type)
LISTBASE_FOREACH (ARegion *, region, regionbase) {
if (region->type == art) {
LISTBASE_FOREACH (Panel *, panel, &region->panels) {
- remove_panel_type_recursive(panel, pt);
+ panel_type_clear_recursive(panel, pt);
}
}
/* The unregistered panel might have had a template that added instanced panels,