diff options
Diffstat (limited to 'source')
-rw-r--r-- | source/blender/blenkernel/BKE_scene.h | 9 | ||||
-rw-r--r-- | source/blender/blenkernel/intern/scene.c | 4 | ||||
-rw-r--r-- | source/blender/editors/scene/scene_edit.c | 18 |
3 files changed, 15 insertions, 16 deletions
diff --git a/source/blender/blenkernel/BKE_scene.h b/source/blender/blenkernel/BKE_scene.h index a0525a4e9f7..4e4883222cc 100644 --- a/source/blender/blenkernel/BKE_scene.h +++ b/source/blender/blenkernel/BKE_scene.h @@ -42,11 +42,10 @@ struct ViewRender; struct WorkSpace; typedef enum eSceneCopyMethod { - SCE_COPY_NEW = 0, - SCE_COPY_EMPTY = 1, - SCE_COPY_LINK_OB = 2, - SCE_COPY_LINK_DATA = 3, - SCE_COPY_FULL = 4, + SCE_COPY_NEW = 0, + SCE_COPY_EMPTY = 1, + SCE_COPY_LINK_COLLECTION = 2, + SCE_COPY_FULL = 3, } eSceneCopyMethod; /* Use as the contents of a 'for' loop: for (SETLOOPER(...)) { ... */ diff --git a/source/blender/blenkernel/intern/scene.c b/source/blender/blenkernel/intern/scene.c index 50216d2e69a..f33939f0a3f 100644 --- a/source/blender/blenkernel/intern/scene.c +++ b/source/blender/blenkernel/intern/scene.c @@ -431,12 +431,12 @@ Scene *BKE_scene_copy(Main *bmain, Scene *sce, int type) BKE_sequencer_editing_free(sce_copy, true); } - /* NOTE: part of SCE_COPY_LINK_DATA and SCE_COPY_FULL operations + /* NOTE: part of SCE_COPY_FULL operations * are done outside of blenkernel with ED_object_single_users! */ /* camera */ /* XXX This is most certainly useless? Object have not yet been duplicated... */ - if (ELEM(type, SCE_COPY_LINK_DATA, SCE_COPY_FULL)) { + if (type == SCE_COPY_FULL) { ID_NEW_REMAP(sce_copy->camera); } diff --git a/source/blender/editors/scene/scene_edit.c b/source/blender/editors/scene/scene_edit.c index 3ad5ba5722a..ec0a851de97 100644 --- a/source/blender/editors/scene/scene_edit.c +++ b/source/blender/editors/scene/scene_edit.c @@ -70,10 +70,7 @@ Scene *ED_scene_add(Main *bmain, bContext *C, wmWindow *win, eSceneCopyMethod me scene_new = BKE_scene_copy(bmain, scene_old, method); /* these can't be handled in blenkernel currently, so do them here */ - if (method == SCE_COPY_LINK_DATA) { - ED_object_single_users(bmain, scene_new, false, true); - } - else if (method == SCE_COPY_FULL) { + if (method == SCE_COPY_FULL) { ED_editors_flush_edits(bmain, false); ED_object_single_users(bmain, scene_new, true, true); } @@ -205,11 +202,14 @@ static int scene_new_exec(bContext *C, wmOperator *op) static void SCENE_OT_new(wmOperatorType *ot) { static EnumPropertyItem type_items[] = { - {SCE_COPY_NEW, "NEW", 0, "New", "Add new scene"}, - {SCE_COPY_EMPTY, "EMPTY", 0, "Copy Settings", "Make a copy without any objects"}, - {SCE_COPY_LINK_OB, "LINK_OBJECTS", 0, "Link Objects", "Link to the objects from the current scene"}, - {SCE_COPY_LINK_DATA, "LINK_OBJECT_DATA", 0, "Link Object Data", "Copy objects linked to data from the current scene"}, - {SCE_COPY_FULL, "FULL_COPY", 0, "Full Copy", "Make a full copy of the current scene"}, + {SCE_COPY_NEW, "NEW", 0, "New", + "Add a new, empty scene with default settings"}, + {SCE_COPY_EMPTY, "EMPTY", 0, "Copy Settings", + "Add a new, empty scene, and copy settings from the current scene"}, + {SCE_COPY_LINK_COLLECTION, "LINK_COPY", 0, "Linked Copy", + "Link in the collections from the current scene (shallow copy)"}, + {SCE_COPY_FULL, "FULL_COPY", 0, "Full Copy", + "Make a full copy of the current scene"}, {0, NULL, 0, NULL, NULL}, }; |