diff options
author | Bastien Montagne <bastien@blender.org> | 2021-03-05 11:21:12 +0300 |
---|---|---|
committer | Bastien Montagne <bastien@blender.org> | 2021-03-11 16:26:19 +0300 |
commit | 93f8c9b8238b4f69c34b605b7e08dfe113f4023d (patch) | |
tree | ad3032c6201438283869fc1fa61f6baf37a13b71 /source/blender | |
parent | a023c1a34c43b86a661ce3cc73e8fba72b1bfba4 (diff) |
LibOverride: auto-run resync process on file reading.
Part of T83811 & D10649.
Diffstat (limited to 'source/blender')
-rw-r--r-- | source/blender/blenkernel/intern/blendfile.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/source/blender/blenkernel/intern/blendfile.c b/source/blender/blenkernel/intern/blendfile.c index 101f4b7caf6..a7af0eccb49 100644 --- a/source/blender/blenkernel/intern/blendfile.c +++ b/source/blender/blenkernel/intern/blendfile.c @@ -51,6 +51,7 @@ #include "BKE_keyconfig.h" #include "BKE_layer.h" #include "BKE_lib_id.h" +#include "BKE_lib_override.h" #include "BKE_main.h" #include "BKE_preferences.h" #include "BKE_report.h" @@ -401,6 +402,13 @@ static void setup_app_data(bContext *C, * to recompute refcount for all local IDs too. */ BKE_main_id_refcount_recompute(bmain, false); } + + if (mode != LOAD_UNDO) { + BKE_lib_override_library_main_resync( + bmain, + curscene, + bfd->cur_view_layer ? bfd->cur_view_layer : BKE_view_layer_default_view(curscene)); + } } static void setup_app_blend_file_data(bContext *C, |