diff options
author | Campbell Barton <ideasman42@gmail.com> | 2018-04-11 10:20:29 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2018-04-11 10:21:01 +0300 |
commit | c963488b5e25b906ff72cbaabdcc76cbfbc77172 (patch) | |
tree | a2f64156a2f2554d99b2b3ffc18cc17e42699a39 /source/blender/editors/space_outliner/outliner_select.c | |
parent | 32339a56f11ac1392c4b8d8651ff452a2a5511cc (diff) |
Pose Mode: pass object to mode enter/exit
Also add lower level mode exit function
Diffstat (limited to 'source/blender/editors/space_outliner/outliner_select.c')
-rw-r--r-- | source/blender/editors/space_outliner/outliner_select.c | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/source/blender/editors/space_outliner/outliner_select.c b/source/blender/editors/space_outliner/outliner_select.c index ec234f0c08b..27c96bd0232 100644 --- a/source/blender/editors/space_outliner/outliner_select.c +++ b/source/blender/editors/space_outliner/outliner_select.c @@ -714,13 +714,16 @@ static eOLDrawState tree_element_active_pose( } if (set != OL_SETSEL_NONE) { - if (scene->obedit) + if (scene->obedit) { ED_object_editmode_exit(C, EM_FREEDATA | EM_WAITCURSOR | EM_DO_UNDO); + } - if (ob->mode & OB_MODE_POSE) - ED_object_posemode_exit(C, base); - else - ED_object_posemode_enter(C, base); + if (ob->mode & OB_MODE_POSE) { + ED_object_posemode_exit(C, ob); + } + else { + ED_object_posemode_enter(C, ob); + } } else { if (ob->mode & OB_MODE_POSE) { |