[gimp] app: saving as XCF should clean the dirty flags …



commit 0c3e6675b06f1795d6b6881cc3e6222ce6164089
Author: Jehan <jehan girinstud io>
Date:   Sat Jul 11 17:04:20 2015 +0200

    app: saving as XCF should clean the dirty flags…
    
    and associate the image to the saved file, even when saved with
    `gimp-xcf-save` or `gimp-file-save` with ".xcf" extension.

 app/xcf/xcf.c |   14 +++++++++++---
 1 files changed, 11 insertions(+), 3 deletions(-)
---
diff --git a/app/xcf/xcf.c b/app/xcf/xcf.c
index bbcf09d..4061fd8 100644
--- a/app/xcf/xcf.c
+++ b/app/xcf/xcf.c
@@ -407,9 +407,17 @@ xcf_save_invoker (GimpProcedure         *procedure,
         }
 
       if (! success)
-        g_propagate_prefixed_error (error, my_error,
-                                    _("Error writing '%s': "),
-                                    filename);
+        {
+          g_propagate_prefixed_error (error, my_error,
+                                      _("Error writing '%s': "),
+                                      filename);
+        }
+      else
+        {
+          gimp_image_set_file (image, file);
+          gimp_image_saved (image, file);
+          gimp_image_clean_all (image);
+        }
 
       g_object_unref (info.output);
 


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