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:
authorWayde Moss <GuiltyGhost>2020-03-29 15:04:32 +0300
committerCampbell Barton <ideasman42@gmail.com>2020-03-29 15:05:30 +0300
commit5b8b6b4c1eafbfcc08ce4f7f536f7c6f3af2be2a (patch)
tree691e70778663455aa37ea88fc5010b85c1ca0364 /source/blender/makesrna
parentd8e2cc9f4d10478861fa4a9e9c9eb49f4ebca09f (diff)
RNA: expose the pin flag for AnimData and ActionGroup
Diffstat (limited to 'source/blender/makesrna')
-rw-r--r--source/blender/makesrna/intern/rna_action.c6
-rw-r--r--source/blender/makesrna/intern/rna_animation.c6
2 files changed, 12 insertions, 0 deletions
diff --git a/source/blender/makesrna/intern/rna_action.c b/source/blender/makesrna/intern/rna_action.c
index 0685fb270f1..a3a89db66be 100644
--- a/source/blender/makesrna/intern/rna_action.c
+++ b/source/blender/makesrna/intern/rna_action.c
@@ -662,6 +662,12 @@ static void rna_def_action_group(BlenderRNA *brna)
prop, "Expanded in Graph Editor", "Action group is expanded in graph editor");
RNA_def_property_update(prop, NC_ANIMATION | ND_ANIMCHAN | NA_EDITED, NULL);
+ prop = RNA_def_property(srna, "use_pin", PROP_BOOLEAN, PROP_NONE);
+ RNA_def_property_flag(prop, PROP_NO_DEG_UPDATE);
+ RNA_def_property_boolean_sdna(prop, NULL, "flag", ADT_CURVES_ALWAYS_VISIBLE);
+ RNA_def_property_ui_text(prop, "Pin in Graph Editor", "");
+ RNA_def_property_update(prop, NC_ANIMATION | ND_ANIMCHAN | NA_EDITED, NULL);
+
/* color set */
rna_def_actionbone_group_common(srna, NC_ANIMATION | ND_ANIMCHAN | NA_EDITED, NULL);
}
diff --git a/source/blender/makesrna/intern/rna_animation.c b/source/blender/makesrna/intern/rna_animation.c
index 036bcfc6311..1ca1bf27156 100644
--- a/source/blender/makesrna/intern/rna_animation.c
+++ b/source/blender/makesrna/intern/rna_animation.c
@@ -1322,6 +1322,12 @@ static void rna_def_animdata(BlenderRNA *brna)
prop, "Use NLA Tweak Mode", "Whether to enable or disable tweak mode in NLA");
RNA_def_property_update(prop, NC_ANIMATION | ND_NLA, "rna_AnimData_update");
+ prop = RNA_def_property(srna, "use_pin", PROP_BOOLEAN, PROP_NONE);
+ RNA_def_property_flag(prop, PROP_NO_DEG_UPDATE);
+ RNA_def_property_boolean_sdna(prop, NULL, "flag", ADT_CURVES_ALWAYS_VISIBLE);
+ RNA_def_property_ui_text(prop, "Pin in Graph Editor", "");
+ RNA_def_property_update(prop, NC_ANIMATION | ND_ANIMCHAN | NA_EDITED, NULL);
+
/* Animation Data API */
RNA_api_animdata(srna);
}