[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [53601] trunk/blender/source/blender: Rename dilate/erode rna property "type" to "mode" to avoid naming conflicts

Sergey Sharybin sergey.vfx at gmail.com
Sun Jan 6 11:30:11 CET 2013


Revision: 53601
          http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=53601
Author:   nazgul
Date:     2013-01-06 10:30:05 +0000 (Sun, 06 Jan 2013)
Log Message:
-----------
Rename dilate/erode rna property "type" to "mode" to avoid naming conflicts

Modified Paths:
--------------
    trunk/blender/source/blender/editors/space_node/drawnode.c
    trunk/blender/source/blender/makesrna/intern/rna_nodetree.c

Modified: trunk/blender/source/blender/editors/space_node/drawnode.c
===================================================================
--- trunk/blender/source/blender/editors/space_node/drawnode.c	2013-01-06 10:17:38 UTC (rev 53600)
+++ trunk/blender/source/blender/editors/space_node/drawnode.c	2013-01-06 10:30:05 UTC (rev 53601)
@@ -1932,9 +1932,9 @@
 
 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;

Modified: trunk/blender/source/blender/makesrna/intern/rna_nodetree.c
===================================================================
--- trunk/blender/source/blender/makesrna/intern/rna_nodetree.c	2013-01-06 10:17:38 UTC (rev 53600)
+++ trunk/blender/source/blender/makesrna/intern/rna_nodetree.c	2013-01-06 10:30:05 UTC (rev 53601)
@@ -2480,7 +2480,7 @@
 {
 	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 @@
 	    {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);




More information about the Bf-blender-cvs mailing list