From 5610ccdc080497042a24592432ade575e2fab489 Mon Sep 17 00:00:00 2001 From: Bastien Montagne Date: Tue, 3 Nov 2020 11:39:36 +0100 Subject: Add a callback to `IDTypeInfo` to allow preservation of some data accross memfile undos This is essentially adding that new callback, and using it only for already existing Scene's 3DCursor. Note that the place where this is called has been moved again, after all have been lib-linked, such that those callbacks may also work on ID pointers. Maniphest Tasks: T71759 Differential Revision: https://developer.blender.org/D9237 --- source/blender/blenkernel/intern/world.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'source/blender/blenkernel/intern/world.c') diff --git a/source/blender/blenkernel/intern/world.c b/source/blender/blenkernel/intern/world.c index 094557502a3..8fe7653fc25 100644 --- a/source/blender/blenkernel/intern/world.c +++ b/source/blender/blenkernel/intern/world.c @@ -204,6 +204,8 @@ IDTypeInfo IDType_ID_WO = { .blend_read_data = world_blend_read_data, .blend_read_lib = world_blend_read_lib, .blend_read_expand = world_blend_read_expand, + + .blend_read_undo_preserve = NULL, }; World *BKE_world_add(Main *bmain, const char *name) -- cgit v1.2.3