[file-roller] batch add: exit if the user cancel the operation
- From: Paolo Bacchilega <paobac src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [file-roller] batch add: exit if the user cancel the operation
- Date: Mon, 6 Aug 2012 18:57:19 +0000 (UTC)
commit 073fc8d1010f097cc979615eb2aaa901e7e28fd5
Author: Paolo Bacchilega <paobac src gnome org>
Date: Mon Aug 6 19:39:53 2012 +0200
batch add: exit if the user cancel the operation
src/dlg-batch-add.c | 8 +++-----
1 files changed, 3 insertions(+), 5 deletions(-)
---
diff --git a/src/dlg-batch-add.c b/src/dlg-batch-add.c
index b4b8d6a..24f36f0 100644
--- a/src/dlg-batch-add.c
+++ b/src/dlg-batch-add.c
@@ -49,7 +49,7 @@ typedef struct {
int *supported_types;
GtkWidget *archive_type_combo_box;
GList *file_list;
- gboolean add_clicked;
+ gboolean creating;
const char *last_mime_type;
gboolean single_file;
} DialogData;
@@ -86,7 +86,7 @@ destroy_cb (GtkWidget *widget,
/*g_settings_set_boolean (data->settings, PREF_BATCH_ADD_OTHER_OPTIONS, data->add_clicked ? FALSE : gtk_expander_get_expanded (GTK_EXPANDER (GET_WIDGET ("a_other_options_expander"))));*/
g_settings_set_boolean (data->settings_general, PREF_GENERAL_ENCRYPT_HEADER, gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (GET_WIDGET ("a_encrypt_header_checkbutton"))));
- if (! data->add_clicked)
+ if (! data->creating)
fr_window_stop_batch (data->window);
g_object_unref (data->builder);
@@ -143,8 +143,6 @@ add_clicked_cb (GtkWidget *widget,
gboolean do_not_add = FALSE;
GError *error = NULL;
- data->add_clicked = TRUE;
-
/* Collect data */
archive_name = g_uri_escape_string (gtk_entry_get_text (GTK_ENTRY (GET_WIDGET ("a_add_to_entry"))), NULL, FALSE);
@@ -493,7 +491,7 @@ dlg_batch_add_files (FrWindow *window,
data->window = window;
data->file_list = file_list;
data->single_file = ((file_list->next == NULL) && _g_file_query_is_file (G_FILE (file_list->data)));
- data->add_clicked = FALSE;
+ data->creating = FALSE;
/* Set widgets data. */
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]