diff options
author | Joshua Leung <aligorith@gmail.com> | 2011-02-16 05:05:41 +0300 |
---|---|---|
committer | Joshua Leung <aligorith@gmail.com> | 2011-02-16 05:05:41 +0300 |
commit | 7756da34c9256c5948a79435301c88a4b850cb3d (patch) | |
tree | c001558bb18e58d753d78a376e59083c9a047d83 /source/blender/editors/armature/poselib.c | |
parent | 669cffdb1e4d2fb00d70e8bc77c5ea7bd92ff618 (diff) |
PoseLib UI and Bugfixes:
- Added operator button to show the current pose. This runs on top of
the interactive pose browse functionality, so the tooltip may be a bit
obtuse...
- Specifying a pose for the Pose browse functionality to set now works
correctly. Previously, some old depsgraph hacks were actually
interferring with correct updating (only the armature updated
correctly, but deforms didn't occur)
- Fixed a case of accessing freed memory, which I'm surprised no
static checkers have reportedly picked up on yet, or that nobody has
really had issues with (probably due to low memory "turnaround" so
far)
Diffstat (limited to 'source/blender/editors/armature/poselib.c')
-rw-r--r-- | source/blender/editors/armature/poselib.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/source/blender/editors/armature/poselib.c b/source/blender/editors/armature/poselib.c index 22aca8014cd..bab19bb02bf 100644 --- a/source/blender/editors/armature/poselib.c +++ b/source/blender/editors/armature/poselib.c @@ -1477,11 +1477,8 @@ static void poselib_preview_cleanup (bContext *C, wmOperator *op) if (IS_AUTOKEY_MODE(scene, NORMAL)) { //remake_action_ipos(ob->action); } - else { - /* need to trick depgraph, action is not allowed to execute on pose */ + else where_is_pose(scene, ob); - ob->recalc= 0; - } } /* free memory used for backups and searching */ @@ -1497,11 +1494,12 @@ static void poselib_preview_cleanup (bContext *C, wmOperator *op) static int poselib_preview_exit (bContext *C, wmOperator *op) { tPoseLib_PreviewData *pld= op->customdata; + int exit_state = pld->state; /* finish up */ poselib_preview_cleanup(C, op); - if (ELEM(pld->state, PL_PREVIEW_CANCEL, PL_PREVIEW_ERROR)) + if (ELEM(exit_state, PL_PREVIEW_CANCEL, PL_PREVIEW_ERROR)) return OPERATOR_CANCELLED; else return OPERATOR_FINISHED; |