UI: hide RNA properties that expand into themselves in the outliner

Mitigate the problem reported by #145877 where expanding the outliner
eventually runs out of stack memory.

The ViewLayer.despsgraph and node sockets would expand indefinitely.

I'm not sure if the issue is solved as expanding makes the outliner
unusably slow.
This commit is contained in:
Campbell Barton
2025-10-03 11:54:35 +00:00
parent a1967f1974
commit db770e903a
2 changed files with 3 additions and 0 deletions

View File

@@ -706,6 +706,7 @@ void RNA_def_view_layer(BlenderRNA *brna)
/* Dependency Graph */
prop = RNA_def_property(srna, "depsgraph", PROP_POINTER, PROP_NONE);
RNA_def_property_struct_type(prop, "Depsgraph");
RNA_def_property_flag_hide_from_ui_workaround(prop);
RNA_def_property_override_flag(prop, PROPOVERRIDE_NO_COMPARISON);
RNA_def_property_ui_text(prop, "Dependency Graph", "Dependencies in the scene data");
RNA_def_property_pointer_funcs(prop, "rna_ViewLayer_depsgraph_get", nullptr, nullptr, nullptr);

View File

@@ -8935,6 +8935,7 @@ static void rna_def_node(BlenderRNA *brna)
"rna_NodeInputs_lookup_string",
nullptr);
RNA_def_property_struct_type(prop, "NodeSocket");
RNA_def_property_flag_hide_from_ui_workaround(prop);
RNA_def_property_override_flag(prop, PROPOVERRIDE_OVERRIDABLE_LIBRARY);
RNA_def_property_ui_text(prop, "Inputs", "");
rna_def_node_sockets_api(brna, prop, SOCK_IN);
@@ -8951,6 +8952,7 @@ static void rna_def_node(BlenderRNA *brna)
"rna_NodeOutputs_lookup_string",
nullptr);
RNA_def_property_struct_type(prop, "NodeSocket");
RNA_def_property_flag_hide_from_ui_workaround(prop);
RNA_def_property_override_flag(prop, PROPOVERRIDE_OVERRIDABLE_LIBRARY);
RNA_def_property_ui_text(prop, "Outputs", "");
rna_def_node_sockets_api(brna, prop, SOCK_OUT);