[gimp] app: don't use gimp_drawable_type() when saving to XCF



commit fb93b1344a9454c5e8bb1dcff0d5d15c401f9dba
Author: Michael Natterer <mitch gimp org>
Date:   Wed Apr 11 01:12:08 2012 +0200

    app: don't use gimp_drawable_type() when saving to XCF
    
    Instead, convert the drawable's format to a GimpImageType right here
    where needed.

 app/xcf/xcf-save.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)
---
diff --git a/app/xcf/xcf-save.c b/app/xcf/xcf-save.c
index cbd6f4d..a230e2a 100644
--- a/app/xcf/xcf-save.c
+++ b/app/xcf/xcf-save.c
@@ -29,6 +29,7 @@
 #include "core/core-types.h"
 
 #include "gegl/gimp-gegl-tile-compat.h"
+#include "gegl/gimp-gegl-utils.h"
 
 #include "core/gimp.h"
 #include "core/gimpcontainer.h"
@@ -1173,7 +1174,7 @@ xcf_save_layer (XcfInfo    *info,
   value = gimp_item_get_height (GIMP_ITEM (layer));
   xcf_write_int32_check_error (info, &value, 1);
 
-  value = gimp_drawable_type (GIMP_DRAWABLE (layer));
+  value = gimp_babl_format_get_image_type (gimp_drawable_get_format (GIMP_DRAWABLE (layer)));
   xcf_write_int32_check_error (info, &value, 1);
 
   /* write out the layers name */



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