reuse USER_SAVE_PREVIEWS to not save thumbnails into blend file header
authorCampbell Barton <ideasman42@gmail.com>
Wed, 13 Jul 2011 19:16:25 +0000 (19:16 +0000)
committerCampbell Barton <ideasman42@gmail.com>
Wed, 13 Jul 2011 19:16:25 +0000 (19:16 +0000)
source/blender/windowmanager/intern/wm_files.c

index aabaf6d40557f478e8edf3dfcc024a3bf796834c..27fc0caecccc11996f8b25cdeffc6bb9f2c2b1e0 100644 (file)
@@ -725,8 +725,10 @@ int WM_write_file(bContext *C, const char *target, int fileflags, ReportList *re
 
        /* blend file thumbnail */
        /* save before exit_editmode, otherwise derivedmeshes for shared data corrupt #27765) */
-       ibuf_thumb= blend_file_thumb(CTX_data_scene(C), &thumb);
-       
+       if(U.flag & USER_SAVE_PREVIEWS) {
+               ibuf_thumb= blend_file_thumb(CTX_data_scene(C), &thumb);
+       }
+
        BLI_exec_cb(G.main, NULL, BLI_CB_EVT_SAVE_PRE);
 
        /* operator now handles overwrite checks */