Rename dilate/erode rna property "type" to "mode" to avoid naming conflicts
This commit is contained in:
@@ -1932,9 +1932,9 @@ static void node_composit_buts_hue_sat(uiLayout *layout, bContext *UNUSED(C), Po
|
||||
|
||||
static void node_composit_buts_dilateerode(uiLayout *layout, bContext *UNUSED(C), PointerRNA *ptr)
|
||||
{
|
||||
uiItemR(layout, ptr, "type", 0, NULL, ICON_NONE);
|
||||
uiItemR(layout, ptr, "mode", 0, NULL, ICON_NONE);
|
||||
uiItemR(layout, ptr, "distance", 0, NULL, ICON_NONE);
|
||||
switch (RNA_enum_get(ptr, "type")) {
|
||||
switch (RNA_enum_get(ptr, "mode")) {
|
||||
case CMP_NODE_DILATEERODE_DISTANCE_THRESH:
|
||||
uiItemR(layout, ptr, "edge", 0, NULL, ICON_NONE);
|
||||
break;
|
||||
|
||||
@@ -2480,7 +2480,7 @@ static void def_cmp_dilate_erode(StructRNA *srna)
|
||||
{
|
||||
PropertyRNA *prop;
|
||||
|
||||
static EnumPropertyItem type_items[] = {
|
||||
static EnumPropertyItem mode_items[] = {
|
||||
{CMP_NODE_DILATEERODE_STEP, "STEP", 0, "Step", ""},
|
||||
{CMP_NODE_DILATEERODE_DISTANCE_THRESH, "THRESHOLD", 0, "Threshold", ""},
|
||||
{CMP_NODE_DILATEERODE_DISTANCE, "DISTANCE", 0, "Distance", ""},
|
||||
@@ -2488,10 +2488,10 @@ static void def_cmp_dilate_erode(StructRNA *srna)
|
||||
{0, NULL, 0, NULL, NULL}
|
||||
};
|
||||
|
||||
prop = RNA_def_property(srna, "type", PROP_ENUM, PROP_NONE);
|
||||
prop = RNA_def_property(srna, "mode", PROP_ENUM, PROP_NONE);
|
||||
RNA_def_property_enum_sdna(prop, NULL, "custom1");
|
||||
RNA_def_property_enum_items(prop, type_items);
|
||||
RNA_def_property_ui_text(prop, "Distance", "Distance to grow/shrink (number of iterations)");
|
||||
RNA_def_property_enum_items(prop, mode_items);
|
||||
RNA_def_property_ui_text(prop, "Mode", "Growing/shrinking mode");
|
||||
RNA_def_property_update(prop, NC_NODE | NA_EDITED, "rna_Node_update");
|
||||
|
||||
prop = RNA_def_property(srna, "distance", PROP_INT, PROP_NONE);
|
||||
|
||||
Reference in New Issue
Block a user