[gimp/gimp-2-8] app: remove the "confirm-on-close" preference
- From: Michael Natterer <mitch src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gimp/gimp-2-8] app: remove the "confirm-on-close" preference
- Date: Tue, 28 Jan 2014 21:47:43 +0000 (UTC)
commit b101f38f0a7cd0b31a8c9c2b90842f75d20e97c0
Author: Michael Natterer <mitch gimp org>
Date: Mon May 7 14:02:36 2012 +0200
app: remove the "confirm-on-close" preference
the warning dialog cannot be disabled any longer now.
(cherry picked from commit e2c8a60665499cc945838fbd5a99964b09ec8892)
app/config/gimpdisplayconfig.c | 20 +++++++++-----------
app/config/gimpdisplayconfig.h | 1 -
app/config/gimprc-blurbs.h | 3 ---
app/dialogs/preferences-dialog.c | 7 -------
app/display/gimpdisplayshell-close.c | 3 +--
5 files changed, 10 insertions(+), 24 deletions(-)
---
diff --git a/app/config/gimpdisplayconfig.c b/app/config/gimpdisplayconfig.c
index 91c8c3d..36a46b2 100644
--- a/app/config/gimpdisplayconfig.c
+++ b/app/config/gimpdisplayconfig.c
@@ -59,7 +59,6 @@ enum
PROP_SHOW_PAINT_TOOL_CURSOR,
PROP_IMAGE_TITLE_FORMAT,
PROP_IMAGE_STATUS_FORMAT,
- PROP_CONFIRM_ON_CLOSE,
PROP_MONITOR_XRESOLUTION,
PROP_MONITOR_YRESOLUTION,
PROP_MONITOR_RES_FROM_GDK,
@@ -76,6 +75,7 @@ enum
PROP_USE_EVENT_HISTORY,
/* ignored, only for backward compatibility: */
+ PROP_CONFIRM_ON_CLOSE,
PROP_XOR_COLOR
};
@@ -185,10 +185,6 @@ gimp_display_config_class_init (GimpDisplayConfigClass *klass)
IMAGE_STATUS_FORMAT_BLURB,
GIMP_CONFIG_DEFAULT_IMAGE_STATUS_FORMAT,
GIMP_PARAM_STATIC_STRINGS);
- GIMP_CONFIG_INSTALL_PROP_BOOLEAN (object_class, PROP_CONFIRM_ON_CLOSE,
- "confirm-on-close", CONFIRM_ON_CLOSE_BLURB,
- TRUE,
- GIMP_PARAM_STATIC_STRINGS);
GIMP_CONFIG_INSTALL_PROP_RESOLUTION (object_class, PROP_MONITOR_XRESOLUTION,
"monitor-xresolution",
MONITOR_XRESOLUTION_BLURB,
@@ -267,6 +263,10 @@ gimp_display_config_class_init (GimpDisplayConfigClass *klass)
GIMP_PARAM_STATIC_STRINGS);
/* only for backward compatibility: */
+ GIMP_CONFIG_INSTALL_PROP_BOOLEAN (object_class, PROP_CONFIRM_ON_CLOSE,
+ "confirm-on-close", NULL,
+ TRUE,
+ GIMP_PARAM_STATIC_STRINGS);
GIMP_CONFIG_INSTALL_PROP_RGB (object_class, PROP_XOR_COLOR,
"xor-color", NULL,
FALSE, &color,
@@ -366,9 +366,6 @@ gimp_display_config_set_property (GObject *object,
g_free (display_config->image_status_format);
display_config->image_status_format = g_value_dup_string (value);
break;
- case PROP_CONFIRM_ON_CLOSE:
- display_config->confirm_on_close = g_value_get_boolean (value);
- break;
case PROP_MONITOR_XRESOLUTION:
display_config->monitor_xres = g_value_get_double (value);
break;
@@ -416,6 +413,8 @@ gimp_display_config_set_property (GObject *object,
case PROP_USE_EVENT_HISTORY:
display_config->use_event_history = g_value_get_boolean (value);
break;
+
+ case PROP_CONFIRM_ON_CLOSE:
case PROP_XOR_COLOR:
/* ignored */
break;
@@ -481,9 +480,6 @@ gimp_display_config_get_property (GObject *object,
case PROP_IMAGE_STATUS_FORMAT:
g_value_set_string (value, display_config->image_status_format);
break;
- case PROP_CONFIRM_ON_CLOSE:
- g_value_set_boolean (value, display_config->confirm_on_close);
- break;
case PROP_MONITOR_XRESOLUTION:
g_value_set_double (value, display_config->monitor_xres);
break;
@@ -526,6 +522,8 @@ gimp_display_config_get_property (GObject *object,
case PROP_USE_EVENT_HISTORY:
g_value_set_boolean (value, display_config->use_event_history);
break;
+
+ case PROP_CONFIRM_ON_CLOSE:
case PROP_XOR_COLOR:
/* ignored */
break;
diff --git a/app/config/gimpdisplayconfig.h b/app/config/gimpdisplayconfig.h
index 427e50e..2c6a7e5 100644
--- a/app/config/gimpdisplayconfig.h
+++ b/app/config/gimpdisplayconfig.h
@@ -56,7 +56,6 @@ struct _GimpDisplayConfig
gboolean show_paint_tool_cursor;
gchar *image_title_format;
gchar *image_status_format;
- gboolean confirm_on_close;
gdouble monitor_xres;
gdouble monitor_yres;
gboolean monitor_res_from_gdk;
diff --git a/app/config/gimprc-blurbs.h b/app/config/gimprc-blurbs.h
index d8f6e44..2af5a29 100644
--- a/app/config/gimprc-blurbs.h
+++ b/app/config/gimprc-blurbs.h
@@ -42,9 +42,6 @@ N_("Specifies how the area around the image should be drawn.")
#define COLOR_PROFILE_POLICY_BLURB \
N_("How to handle embedded color profiles when opening a file.")
-#define CONFIRM_ON_CLOSE_BLURB \
-N_("Ask for confirmation before closing an image without saving.")
-
#define CURSOR_FORMAT_BLURB \
N_("Sets the pixel format to use for mouse pointers.")
diff --git a/app/dialogs/preferences-dialog.c b/app/dialogs/preferences-dialog.c
index a8e6d5b..259a5ee 100644
--- a/app/dialogs/preferences-dialog.c
+++ b/app/dialogs/preferences-dialog.c
@@ -1559,13 +1559,6 @@ prefs_dialog_new (Gimp *gimp,
_("Maximum _filesize for thumbnailing:"),
GTK_TABLE (table), 1, size_group);
- /* File Saving */
- vbox2 = prefs_frame_new (_("Saving Images"), GTK_CONTAINER (vbox), FALSE);
-
- prefs_check_button_add (object, "confirm-on-close",
- _("Confirm closing of unsa_ved images"),
- GTK_BOX (vbox2));
-
g_object_unref (size_group);
size_group = NULL;
diff --git a/app/display/gimpdisplayshell-close.c b/app/display/gimpdisplayshell-close.c
index 6857e50..bc37295 100644
--- a/app/display/gimpdisplayshell-close.c
+++ b/app/display/gimpdisplayshell-close.c
@@ -98,8 +98,7 @@ gimp_display_shell_close (GimpDisplayShell *shell,
if (! kill_it &&
image &&
gimp_image_get_display_count (image) == 1 &&
- gimp_image_is_dirty (image) &&
- shell->display->config->confirm_on_close)
+ gimp_image_is_dirty (image))
{
/* If there's a save dialog active for this image, then raise it.
* (see bug #511965)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]