Fix T38302: sequencer animation data lost in original scene when copying scene.
authorBrecht Van Lommel <brechtvanlommel@gmail.com>
Tue, 21 Jan 2014 14:15:47 +0000 (15:15 +0100)
committerBrecht Van Lommel <brechtvanlommel@gmail.com>
Tue, 21 Jan 2014 14:17:35 +0000 (15:17 +0100)
source/blender/blenkernel/intern/scene.c

index 65d1863873ce4da4c9b9c24b101fe3985fddf57d..ca6ff4dc1e5f1c0b304ae9eed834a032e66b6178 100644 (file)
@@ -219,7 +219,9 @@ Scene *BKE_scene_copy(Scene *sce, int type)
                BLI_strncpy(scen->sequencer_colorspace_settings.name, sce->sequencer_colorspace_settings.name,
                            sizeof(scen->sequencer_colorspace_settings.name));
 
-               /* remove animation used by sequencer */
+               /* copy action and remove animation used by sequencer */
+               BKE_copy_animdata_id_action(&scen->id);
+
                if (type != SCE_COPY_FULL)
                        remove_sequencer_fcurves(scen);
 
@@ -290,7 +292,6 @@ Scene *BKE_scene_copy(Scene *sce, int type)
 
        /* world */
        if (type == SCE_COPY_FULL) {
-               BKE_copy_animdata_id_action((ID *)scen);
                if (scen->world) {
                        id_us_plus((ID *)scen->world);
                        scen->world = BKE_world_copy(scen->world);