Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoshua Leung <aligorith@gmail.com>2012-08-30 19:06:13 +0400
committerJoshua Leung <aligorith@gmail.com>2012-08-30 19:06:13 +0400
commitc4622c405e40a119ae213255022c5e1303af103f (patch)
treebd3b14f85701f3dc88314dc038ab0e81ec215076 /source/blender/makesrna
parentdfd54c61d1441d6c55dedaac0f2045bd388dc754 (diff)
Bugfix [#32249] Groups in Dopesheet and Action editor don't get updated after
bone renaming * Renaming F-Curves now checks if the corresponding F-Curve's group can also be renamed accordingly. * Changed the RNA updates for bone renaming so that they properly update the channel lists
Diffstat (limited to 'source/blender/makesrna')
-rw-r--r--source/blender/makesrna/intern/rna_armature.c14
1 files changed, 13 insertions, 1 deletions
diff --git a/source/blender/makesrna/intern/rna_armature.c b/source/blender/makesrna/intern/rna_armature.c
index 738e7ad2219..be70405d165 100644
--- a/source/blender/makesrna/intern/rna_armature.c
+++ b/source/blender/makesrna/intern/rna_armature.c
@@ -146,6 +146,18 @@ static void rna_Armature_redraw_data(Main *UNUSED(bmain), Scene *UNUSED(scene),
WM_main_add_notifier(NC_GEOM | ND_DATA, id);
}
+/* called whenever a bone is renamed */
+static void rna_Bone_update_renamed(Main *UNUSED(bmain), Scene *UNUSED(scene), PointerRNA *ptr)
+{
+ ID *id = ptr->id.data;
+
+ /* redraw view */
+ WM_main_add_notifier(NC_GEOM | ND_DATA, id);
+
+ /* update animation channels */
+ WM_main_add_notifier(NC_ANIMATION | ND_ANIMCHAN, id);
+}
+
static void rna_Bone_select_update(Main *UNUSED(bmain), Scene *UNUSED(scene), PointerRNA *ptr)
{
ID *id = ptr->id.data;
@@ -470,7 +482,7 @@ static void rna_def_bone_common(StructRNA *srna, int editbone)
RNA_def_struct_name_property(srna, prop);
if (editbone) RNA_def_property_string_funcs(prop, NULL, NULL, "rna_EditBone_name_set");
else RNA_def_property_string_funcs(prop, NULL, NULL, "rna_Bone_name_set");
- RNA_def_property_update(prop, 0, "rna_Armature_redraw_data");
+ RNA_def_property_update(prop, 0, "rna_Bone_update_renamed");
/* flags */
prop = RNA_def_property(srna, "layers", PROP_BOOLEAN, PROP_LAYER_MEMBER);