gimp r25104 - in branches/gimp-2-4: . plug-ins/common



Author: mitch
Date: Thu Mar 13 17:14:48 2008
New Revision: 25104
URL: http://svn.gnome.org/viewvc/gimp?rev=25104&view=rev

Log:
2008-03-13  Michael Natterer  <mitch gimp org>

	Merged from trunk:

	* plug-ins/common/tiff-load.c (load_image): set the original
	filename only if all pages were loaded as layers; if a subset was
	loaded, set the filename to "<filename>.tiff-n-of-m-pages" so a
	simple "save" won't overwrite the original file without the user
	changing the filename explicitely.



Modified:
   branches/gimp-2-4/ChangeLog
   branches/gimp-2-4/plug-ins/common/tiff-load.c

Modified: branches/gimp-2-4/plug-ins/common/tiff-load.c
==============================================================================
--- branches/gimp-2-4/plug-ins/common/tiff-load.c	(original)
+++ branches/gimp-2-4/plug-ins/common/tiff-load.c	Thu Mar 13 17:14:48 2008
@@ -741,6 +741,14 @@
               images_list = g_list_prepend (images_list,
                                             GINT_TO_POINTER (image));
             }
+          else if (pages->o_pages != pages->n_pages)
+            {
+              gchar *fname = g_strdup_printf (_("%s-%d-of-%d-pages"), filename,
+                                              pages->n_pages, pages->o_pages);
+
+              gimp_image_set_filename (image, fname);
+              g_free (fname);
+            }
           else
             {
               gimp_image_set_filename (image, filename);



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]