Fix broken Node Tools after IDProps storage split.

Caused by 7276b2009a.

Turns out that for the same reasons as the Nodes modifier, Operator RNA
struct also needs to keep the 'old' IDProperties access for now, to
support Node Tools.

Can't wait for #132129 to be implemented...
This commit is contained in:
Bastien Montagne
2025-06-23 20:10:51 +02:00
parent 2cc5787885
commit 82534672d4
2 changed files with 5 additions and 1 deletions

View File

@@ -8081,7 +8081,8 @@ static void rna_def_modifier_nodes(BlenderRNA *brna)
srna = RNA_def_struct(brna, "NodesModifier", "Modifier");
RNA_def_struct_ui_text(srna, "Nodes Modifier", "");
RNA_def_struct_sdna(srna, "NodesModifierData");
/* NOTE: `RNA_def_struct_idprops_func` should be removed once #135807 is implemented. */
/* NOTE: `RNA_def_struct_idprops_func` should be removed once #132129 is implemented.
* Similar to the issue with Operator (for node tools), see #rna_def_operator. */
RNA_def_struct_idprops_func(srna, "rna_NodesModifier_properties");
RNA_def_struct_system_idprops_func(srna, "rna_NodesModifier_properties");
RNA_def_struct_ui_icon(srna, ICON_GEOMETRY_NODES);

View File

@@ -2256,6 +2256,9 @@ static void rna_def_operator(BlenderRNA *brna)
srna = RNA_def_struct(brna, "OperatorProperties", nullptr);
RNA_def_struct_ui_text(srna, "Operator Properties", "Input properties of an operator");
RNA_def_struct_refine_func(srna, "rna_OperatorProperties_refine");
/* NOTE: `RNA_def_struct_idprops_func` should be removed once #132129 is implemented.
* Similar to the issue with the nodes modifiers, see #rna_def_modifier_nodes. */
RNA_def_struct_idprops_func(srna, "rna_OperatorProperties_idprops");
RNA_def_struct_system_idprops_func(srna, "rna_OperatorProperties_idprops");
RNA_def_struct_property_tags(srna, rna_enum_operator_property_tag_items);
RNA_def_struct_flag(srna, STRUCT_NO_DATABLOCK_IDPROPERTIES | STRUCT_NO_CONTEXT_WITHOUT_OWNER_ID);