From 4684375bd45f7c6bebcfd5006a8bc86e777f971e Mon Sep 17 00:00:00 2001 From: Joshua Leung Date: Wed, 1 Aug 2018 01:27:47 +1200 Subject: Fix: Motion Paths were still visible after clearing them After clearing motion paths from objects, those objects needed to be tagged for copy on write so that the copied data (i.e. viewport) recieve the changes (i.e. removed paths) Reported by Hjalti --- source/blender/editors/armature/pose_edit.c | 3 +++ source/blender/editors/object/object_edit.c | 3 +++ 2 files changed, 6 insertions(+) (limited to 'source') diff --git a/source/blender/editors/armature/pose_edit.c b/source/blender/editors/armature/pose_edit.c index 3ae578279ca..1dfb9ec984a 100644 --- a/source/blender/editors/armature/pose_edit.c +++ b/source/blender/editors/armature/pose_edit.c @@ -365,6 +365,9 @@ static void ED_pose_clear_paths(Object *ob, bool only_selected) /* if nothing was skipped, there should be no paths left! */ if (skipped == false) ob->pose->avs.path_bakeflag &= ~MOTIONPATH_BAKE_HAS_PATHS; + + /* tag armature object for copy on write - so removed paths don't still show */ + DEG_id_tag_update(&ob->id, DEG_TAG_COPY_ON_WRITE); } /* operator callback - wrapper for the backend function */ diff --git a/source/blender/editors/object/object_edit.c b/source/blender/editors/object/object_edit.c index 48048319cb7..a6dad906579 100644 --- a/source/blender/editors/object/object_edit.c +++ b/source/blender/editors/object/object_edit.c @@ -1378,6 +1378,9 @@ static void object_clear_mpath(Object *ob) animviz_free_motionpath(ob->mpath); ob->mpath = NULL; ob->avs.path_bakeflag &= ~MOTIONPATH_BAKE_HAS_PATHS; + + /* tag object for copy on write - so removed paths don't still show */ + DEG_id_tag_update(&ob->id, DEG_TAG_COPY_ON_WRITE); } } -- cgit v1.2.3