[gimp] app: add an "interactive" boolean inside gimp_export_image()
- From: Michael Natterer <mitch src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gimp] app: add an "interactive" boolean inside gimp_export_image()
- Date: Sat, 9 Nov 2013 23:03:40 +0000 (UTC)
commit 206df0026654c7d2a1eff317a02e86e317e6ae80
Author: Michael Natterer <mitch gimp org>
Date: Sun Nov 10 00:02:11 2013 +0100
app: add an "interactive" boolean inside gimp_export_image()
instead of using "format_name", which is confusing, and file plug-ins
will soon pass their format name again.
libgimp/gimpexport.c | 8 ++++++--
1 files changed, 6 insertions(+), 2 deletions(-)
---
diff --git a/libgimp/gimpexport.c b/libgimp/gimpexport.c
index 3dfadb9..17f2c66 100644
--- a/libgimp/gimpexport.c
+++ b/libgimp/gimpexport.c
@@ -694,6 +694,7 @@ gimp_export_image (gint32 *image_ID,
gint32 i;
gint32 n_layers;
gint32 *layers;
+ gboolean interactive = FALSE;
gboolean added_flatten = FALSE;
gboolean has_layer_masks = FALSE;
gboolean background_has_alpha = TRUE;
@@ -714,8 +715,11 @@ gimp_export_image (gint32 *image_ID,
if (capabilities & GIMP_EXPORT_CAN_HANDLE_LAYERS)
capabilities |= GIMP_EXPORT_CAN_HANDLE_ALPHA;
+ if (FALSE /* format_name */)
+ interactive = TRUE;
+
/* ask for confirmation if the user is not saving a layer (see bug #51114) */
- if (format_name &&
+ if (interactive &&
! gimp_item_is_layer (*drawable_ID) &&
! (capabilities & GIMP_EXPORT_CAN_HANDLE_LAYERS))
{
@@ -918,7 +922,7 @@ gimp_export_image (gint32 *image_ID,
{
actions = g_slist_reverse (actions);
- if (format_name)
+ if (interactive)
retval = export_dialog (actions, format_name);
else
retval = GIMP_EXPORT_EXPORT;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]