diff options
author | Bastien Montagne <bastien@blender.org> | 2022-04-01 13:21:00 +0300 |
---|---|---|
committer | Bastien Montagne <bastien@blender.org> | 2022-04-01 13:35:25 +0300 |
commit | 1264142f78302dcecd229b3dd72544470e553964 (patch) | |
tree | 418b7bbf1f83c17b64eb524a7cef8ea6159de894 /source/blender/makesrna/intern/rna_collection.c | |
parent | d34c4089f18f4ec6c6f8f79b95146195d065ec1e (diff) |
LibOverride: RNA Apply: let apply function responsible for calling update or not on overridden properties.
While this is the desired behavior in almost cases, there are a few
hairy nightmares that may require not to do so.
NOTE: this change should should not modify any current behavior at all.
Diffstat (limited to 'source/blender/makesrna/intern/rna_collection.c')
-rw-r--r-- | source/blender/makesrna/intern/rna_collection.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/source/blender/makesrna/intern/rna_collection.c b/source/blender/makesrna/intern/rna_collection.c index eceabe65a67..599d36c0af7 100644 --- a/source/blender/makesrna/intern/rna_collection.c +++ b/source/blender/makesrna/intern/rna_collection.c @@ -138,7 +138,7 @@ static bool rna_Collection_objects_override_apply(Main *bmain, PointerRNA *ptr_dst, PointerRNA *UNUSED(ptr_src), PointerRNA *UNUSED(ptr_storage), - PropertyRNA *UNUSED(prop_dst), + PropertyRNA *prop_dst, PropertyRNA *UNUSED(prop_src), PropertyRNA *UNUSED(prop_storage), const int UNUSED(len_dst), @@ -185,6 +185,7 @@ static bool rna_Collection_objects_override_apply(Main *bmain, BKE_main_collection_sync(bmain); } + RNA_property_update_main(bmain, NULL, ptr_dst, prop_dst); return true; } @@ -245,7 +246,7 @@ static bool rna_Collection_children_override_apply(Main *bmain, PointerRNA *ptr_dst, PointerRNA *UNUSED(ptr_src), PointerRNA *UNUSED(ptr_storage), - PropertyRNA *UNUSED(prop_dst), + PropertyRNA *prop_dst, PropertyRNA *UNUSED(prop_src), PropertyRNA *UNUSED(prop_storage), const int UNUSED(len_dst), @@ -287,6 +288,7 @@ static bool rna_Collection_children_override_apply(Main *bmain, BKE_collection_object_cache_free(coll_dst); BKE_main_collection_sync(bmain); + RNA_property_update_main(bmain, NULL, ptr_dst, prop_dst); return true; } |