diff options
Diffstat (limited to 'source/blender/makesrna/intern')
-rw-r--r-- | source/blender/makesrna/intern/rna_armature.c | 4 | ||||
-rw-r--r-- | source/blender/makesrna/intern/rna_fcurve.c | 2 | ||||
-rw-r--r-- | source/blender/makesrna/intern/rna_fcurve_api.c | 4 | ||||
-rw-r--r-- | source/blender/makesrna/intern/rna_group.c | 16 | ||||
-rw-r--r-- | source/blender/makesrna/intern/rna_scene.c | 4 |
5 files changed, 18 insertions, 12 deletions
diff --git a/source/blender/makesrna/intern/rna_armature.c b/source/blender/makesrna/intern/rna_armature.c index e79d8091917..f73ac517213 100644 --- a/source/blender/makesrna/intern/rna_armature.c +++ b/source/blender/makesrna/intern/rna_armature.c @@ -668,7 +668,7 @@ static void rna_def_armature(BlenderRNA *brna) RNA_def_property_ui_text(prop, "Bones", ""); { /* Collection active property */ - prop_act= RNA_def_property(srna, "bones_active", PROP_POINTER, PROP_NONE); + prop_act= RNA_def_property(srna, "bones__active", PROP_POINTER, PROP_NONE); RNA_def_property_struct_type(prop_act, "Bone"); RNA_def_property_pointer_sdna(prop_act, NULL, "act_bone"); RNA_def_property_flag(prop_act, PROP_EDITABLE); @@ -685,7 +685,7 @@ static void rna_def_armature(BlenderRNA *brna) RNA_def_property_ui_text(prop, "Edit Bones", ""); { /* Collection active property */ - prop_act= RNA_def_property(srna, "edit_bones_active", PROP_POINTER, PROP_NONE); + prop_act= RNA_def_property(srna, "edit_bones__active", PROP_POINTER, PROP_NONE); RNA_def_property_struct_type(prop_act, "EditBone"); RNA_def_property_pointer_sdna(prop_act, NULL, "act_edbone"); RNA_def_property_flag(prop_act, PROP_EDITABLE); diff --git a/source/blender/makesrna/intern/rna_fcurve.c b/source/blender/makesrna/intern/rna_fcurve.c index cdaebb2a3db..294f38cf3f7 100644 --- a/source/blender/makesrna/intern/rna_fcurve.c +++ b/source/blender/makesrna/intern/rna_fcurve.c @@ -611,7 +611,7 @@ static void rna_def_channeldriver(BlenderRNA *brna) /* Collections */ prop= RNA_def_property(srna, "targets", PROP_COLLECTION, PROP_NONE); RNA_def_property_collection_sdna(prop, NULL, "targets", NULL); - RNA_def_property_collection_funcs(prop, NULL, NULL, NULL, NULL, NULL, NULL, NULL, "add_target", "remove_target"); + RNA_def_property_collection_funcs(prop, NULL, NULL, NULL, NULL, NULL, NULL, NULL, "targets__add", "targets__remove"); RNA_def_property_struct_type(prop, "DriverTarget"); RNA_def_property_ui_text(prop, "Target Variables", "Properties acting as targets for this driver."); diff --git a/source/blender/makesrna/intern/rna_fcurve_api.c b/source/blender/makesrna/intern/rna_fcurve_api.c index 12ffb3e26fb..0abb5e8e499 100644 --- a/source/blender/makesrna/intern/rna_fcurve_api.c +++ b/source/blender/makesrna/intern/rna_fcurve_api.c @@ -71,7 +71,7 @@ void RNA_api_drivers(StructRNA *srna) PropertyRNA *parm; /* add target */ - func= RNA_def_function(srna, "add_target", "rna_Driver_add_target"); + func= RNA_def_function(srna, "targets__add", "rna_Driver_add_target"); RNA_def_function_ui_description(func, "Add a new target for the driver."); /* return type */ parm= RNA_def_pointer(func, "target", "DriverTarget", "", "Newly created Driver Target."); @@ -80,7 +80,7 @@ void RNA_api_drivers(StructRNA *srna) parm= RNA_def_string(func, "name", "", 64, "Name", "Name to use in scripted expressions/functions. (No spaces or dots are allowed. Also, must not start with a symbol or digit)"); /* remove target */ - func= RNA_def_function(srna, "remove_target", "rna_Driver_remove_target"); + func= RNA_def_function(srna, "targets__remove", "rna_Driver_remove_target"); RNA_def_function_ui_description(func, "Remove an existing target from the driver."); /* target to remove*/ parm= RNA_def_pointer(func, "target", "DriverTarget", "", "Target to remove from the driver."); diff --git a/source/blender/makesrna/intern/rna_group.c b/source/blender/makesrna/intern/rna_group.c index 8f6a5f1005c..8babb9593a0 100644 --- a/source/blender/makesrna/intern/rna_group.c +++ b/source/blender/makesrna/intern/rna_group.c @@ -38,6 +38,9 @@ #include "BKE_group.h" +#include "WM_api.h" +#include "WM_types.h" + static PointerRNA rna_Group_objects_get(CollectionPropertyIterator *iter) { ListBaseIterator *internal= iter->internal; @@ -48,11 +51,13 @@ static PointerRNA rna_Group_objects_get(CollectionPropertyIterator *iter) static int rna_Group_objects_add(Group *group, bContext *C, Object *object) { + WM_event_add_notifier(C, NC_OBJECT|ND_DRAW, &object->id); return add_to_group(group, object, CTX_data_scene(C), NULL); } static int rna_Group_objects_remove(Group *group, bContext *C, Object *object) { + WM_event_add_notifier(C, NC_OBJECT|ND_DRAW, &object->id); return rem_from_group(group, object, CTX_data_scene(C), NULL); } @@ -63,6 +68,9 @@ void RNA_def_group(BlenderRNA *brna) StructRNA *srna; PropertyRNA *prop; + FunctionRNA *func; + PropertyRNA *parm; + srna= RNA_def_struct(brna, "Group", "ID"); RNA_def_struct_ui_text(srna, "Group", "Group of Object datablocks."); RNA_def_struct_ui_icon(srna, ICON_GROUP); @@ -79,9 +87,7 @@ void RNA_def_group(BlenderRNA *brna) /* add object */ - FunctionRNA *func; - PropertyRNA *parm; - func= RNA_def_function(srna, "add_object", "rna_Group_objects_add"); + func= RNA_def_function(srna, "objects__add", "rna_Group_objects_add"); RNA_def_function_flag(func, FUNC_USE_CONTEXT); RNA_def_function_ui_description(func, "Add this object to a group"); /* return type */ @@ -92,7 +98,7 @@ void RNA_def_group(BlenderRNA *brna) RNA_def_property_flag(parm, PROP_REQUIRED); /* remove object */ - func= RNA_def_function(srna, "remove_object", "rna_Group_objects_remove"); + func= RNA_def_function(srna, "objects__remove", "rna_Group_objects_remove"); RNA_def_function_ui_description(func, "Remove this object to a group"); RNA_def_function_flag(func, FUNC_USE_CONTEXT); /* return type */ @@ -106,7 +112,7 @@ void RNA_def_group(BlenderRNA *brna) RNA_def_property_collection_sdna(prop, NULL, "gobject", NULL); RNA_def_property_struct_type(prop, "Object"); RNA_def_property_ui_text(prop, "Objects", "A collection of this groups objects."); - RNA_def_property_collection_funcs(prop, 0, 0, 0, "rna_Group_objects_get", 0, 0, 0, "add_object", "remove_object"); + RNA_def_property_collection_funcs(prop, 0, 0, 0, "rna_Group_objects_get", 0, 0, 0, "objects__add", "objects__remove"); } #endif diff --git a/source/blender/makesrna/intern/rna_scene.c b/source/blender/makesrna/intern/rna_scene.c index 6d198e10b38..943d559133f 100644 --- a/source/blender/makesrna/intern/rna_scene.c +++ b/source/blender/makesrna/intern/rna_scene.c @@ -2225,7 +2225,7 @@ void RNA_def_scene(BlenderRNA *brna) RNA_def_property_ui_text(prop, "Bases", ""); { /* Collection active property */ - prop_act= RNA_def_property(srna, "base_active", PROP_POINTER, PROP_NONE); + prop_act= RNA_def_property(srna, "bases__active", PROP_POINTER, PROP_NONE); RNA_def_property_struct_type(prop_act, "ObjectBase"); RNA_def_property_pointer_sdna(prop_act, NULL, "basact"); RNA_def_property_flag(prop_act, PROP_EDITABLE); @@ -2241,7 +2241,7 @@ void RNA_def_scene(BlenderRNA *brna) RNA_def_property_collection_funcs(prop, 0, 0, 0, "rna_Scene_objects_get", 0, 0, 0, 0, 0); { /* Collection active property */ - prop_act= RNA_def_property(srna, "objects_active", PROP_POINTER, PROP_NONE); + prop_act= RNA_def_property(srna, "objects__active", PROP_POINTER, PROP_NONE); RNA_def_property_struct_type(prop_act, "Object"); RNA_def_property_pointer_funcs(prop_act, "rna_Scene_active_object_get", "rna_Scene_active_object_set", NULL); RNA_def_property_flag(prop_act, PROP_EDITABLE); |