diff options
author | Nathan Craddock <nzcraddock@gmail.com> | 2020-09-20 01:27:56 +0300 |
---|---|---|
committer | Nathan Craddock <nzcraddock@gmail.com> | 2020-09-20 01:33:45 +0300 |
commit | 94a63f75055024dbf0c9f9236b3cda5438fa2162 (patch) | |
tree | 3cca2bdf9c662dbc074d5a50595a8a00ff1e4e30 /source/blender/editors/object/object_modifier.c | |
parent | 4115229637c0acdcffbaceae282ccd854bfdb1c8 (diff) |
Fix T80945: Build modifier not updating after outliner copy
Build modifiers linked or copied to objects from the outliner would not
animate until the file was saved and reopened due to a missing depsgraph
relations tag.
Diffstat (limited to 'source/blender/editors/object/object_modifier.c')
-rw-r--r-- | source/blender/editors/object/object_modifier.c | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/source/blender/editors/object/object_modifier.c b/source/blender/editors/object/object_modifier.c index 370667391c5..8f5fa6b7834 100644 --- a/source/blender/editors/object/object_modifier.c +++ b/source/blender/editors/object/object_modifier.c @@ -521,13 +521,22 @@ void ED_object_modifier_link(bContext *C, Object *ob_dst, Object *ob_src) BKE_object_link_modifiers(ob_dst, ob_src); WM_event_add_notifier(C, NC_OBJECT | ND_MODIFIER, ob_dst); DEG_id_tag_update(&ob_dst->id, ID_RECALC_TRANSFORM | ID_RECALC_GEOMETRY | ID_RECALC_ANIMATION); + + Main *bmain = CTX_data_main(C); + DEG_relations_tag_update(bmain); } -void ED_object_modifier_copy_to_object(Object *ob_dst, Object *ob_src, ModifierData *md) +void ED_object_modifier_copy_to_object(bContext *C, + Object *ob_dst, + Object *ob_src, + ModifierData *md) { BKE_object_copy_modifier(ob_dst, ob_src, md); WM_main_add_notifier(NC_OBJECT | ND_MODIFIER, ob_dst); DEG_id_tag_update(&ob_dst->id, ID_RECALC_TRANSFORM | ID_RECALC_GEOMETRY | ID_RECALC_ANIMATION); + + Main *bmain = CTX_data_main(C); + DEG_relations_tag_update(bmain); } bool ED_object_modifier_convert(ReportList *UNUSED(reports), |