gimp r28101 - in branches/gimp-2-6: . app/pdb libgimp tools/pdbgen/pdb



Author: neo
Date: Wed Mar  4 18:30:56 2009
New Revision: 28101
URL: http://svn.gnome.org/viewvc/gimp?rev=28101&view=rev

Log:
reverted last change as we don't have gimp_image_get_display_name() in 
gimp-2-6


Modified:
   branches/gimp-2-6/ChangeLog
   branches/gimp-2-6/app/pdb/image-cmds.c
   branches/gimp-2-6/libgimp/gimpimage_pdb.c
   branches/gimp-2-6/tools/pdbgen/pdb/image.pdb

Modified: branches/gimp-2-6/app/pdb/image-cmds.c
==============================================================================
--- branches/gimp-2-6/app/pdb/image-cmds.c	(original)
+++ branches/gimp-2-6/app/pdb/image-cmds.c	Wed Mar  4 18:30:56 2009
@@ -535,7 +535,7 @@
       gimp_image_rotate (image, context, rotate_type, progress);
 
       if (progress)
-        gimp_progress_end (progress);
+        gimp_progress_end (progress);  
     }
 
   return gimp_procedure_get_return_values (procedure, success,
@@ -2190,7 +2190,12 @@
 
   if (success)
     {
-      name = g_strdup (gimp_image_get_display_name (image));
+      gchar *filename = gimp_image_get_filename (image);
+
+      if (filename)
+        name = g_filename_display_basename (filename);
+      else
+        name = g_strdup (_("Untitled"));
     }
 
   return_vals = gimp_procedure_get_return_values (procedure, success,
@@ -4684,7 +4689,7 @@
   gimp_procedure_set_static_strings (procedure,
                                      "gimp-image-get-name",
                                      "Returns the specified image's name.",
-                                     "This procedure returns the image's name. If the image has a filename, then this is the base name (the last component of the path).",
+                                     "This procedure returns the specified image's name.",
                                      "Spencer Kimball & Peter Mattis",
                                      "Spencer Kimball & Peter Mattis",
                                      "1995-1996",

Modified: branches/gimp-2-6/libgimp/gimpimage_pdb.c
==============================================================================
--- branches/gimp-2-6/libgimp/gimpimage_pdb.c	(original)
+++ branches/gimp-2-6/libgimp/gimpimage_pdb.c	Wed Mar  4 18:30:56 2009
@@ -2413,9 +2413,7 @@
  *
  * Returns the specified image's name.
  *
- * This procedure returns the image's name. If the image has a
- * filename, then this is the base name (the last component of the
- * path).
+ * This procedure returns the specified image's name.
  *
  * Returns: The name.
  */

Modified: branches/gimp-2-6/tools/pdbgen/pdb/image.pdb
==============================================================================
--- branches/gimp-2-6/tools/pdbgen/pdb/image.pdb	(original)
+++ branches/gimp-2-6/tools/pdbgen/pdb/image.pdb	Wed Mar  4 18:30:56 2009
@@ -429,7 +429,7 @@
   gimp_image_rotate (image, context, rotate_type, progress);
 
   if (progress)
-    gimp_progress_end (progress);
+    gimp_progress_end (progress);  
 }
 CODE
     );
@@ -2213,10 +2213,7 @@
 
 sub image_get_name {
     $blurb = "Returns the specified image's name.";
-    $help  =  <<'HELP';
-This procedure returns the image's name. If the image has a filename,
-then this is the base name (the last component of the path).
-HELP
+    $help  = "This procedure returns the specified image's name.";
 
     &std_pdb_misc;
 
@@ -2233,7 +2230,12 @@
     %invoke = (
 	code => <<'CODE'
 {
-  name = g_strdup (gimp_image_get_display_name (image));
+  gchar *filename = gimp_image_get_filename (image);
+
+  if (filename)
+    name = g_filename_display_basename (filename);
+  else
+    name = g_strdup (_("Untitled"));
 }
 CODE
     );
@@ -2243,7 +2245,7 @@
     $blurb = "Returns the specified image's resolution.";
 
     $help = <<'HELP';
-This procedure returns the specified image's resolution in dots per inch.
+This procedure returns the specified image's resolution in dots per inch. 
 This value is independent of any of the layers in this image.
 HELP
 
@@ -2274,7 +2276,7 @@
     $blurb = "Sets the specified image's resolution.";
 
     $help = <<'HELP';
-This procedure sets the specified image's resolution in dots per inch.
+This procedure sets the specified image's resolution in dots per inch. 
 This value is independent of any of the layers in this image.
 No scaling or resizing is performed.
 HELP



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