diff options
author | Hans Goudey <h.goudey@me.com> | 2020-10-18 18:57:14 +0300 |
---|---|---|
committer | Hans Goudey <h.goudey@me.com> | 2020-10-18 18:57:14 +0300 |
commit | 78a5895c967e17b21e2a0a36309dad7f47bf928e (patch) | |
tree | 491cc57162619b8ea649c97796dabecf59060852 /source/blender/editors | |
parent | 806a561e23742a24b5b533f4f1410ea74178ca63 (diff) |
Fix T81800: Datablock pin not working for bones in pose mode
The "active_pose_bone" context variable isn't accessed from
`buttons_context`, it uses `screen_context` instead. This means
it can't account for pinning in the property editor.
Using "pose_bone" context variable first means the property
editor context will be used and the pinning will work.
Differential Revision: https://developer.blender.org/D9242
Diffstat (limited to 'source/blender/editors')
-rw-r--r-- | source/blender/editors/object/object_constraint.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/source/blender/editors/object/object_constraint.c b/source/blender/editors/object/object_constraint.c index 0f05608b82f..0073aa830de 100644 --- a/source/blender/editors/object/object_constraint.c +++ b/source/blender/editors/object/object_constraint.c @@ -111,9 +111,9 @@ ListBase *ED_object_constraint_active_list(Object *ob) */ ListBase *ED_object_pose_constraint_list(const bContext *C) { - bPoseChannel *pose_bone = CTX_data_pointer_get(C, "active_pose_bone").data; + bPoseChannel *pose_bone = CTX_data_pointer_get(C, "pose_bone").data; if (pose_bone == NULL) { - pose_bone = CTX_data_pointer_get(C, "pose_bone").data; + pose_bone = CTX_data_pointer_get(C, "active_pose_bone").data; if (pose_bone == NULL) { return NULL; } |