aboutsummaryrefslogtreecommitdiffstats
path: root/mail
diff options
context:
space:
mode:
authorNot Zed <NotZed@Ximian.com>2003-01-13 14:07:10 +0800
committerMichael Zucci <zucchi@src.gnome.org>2003-01-13 14:07:10 +0800
commitcf4448abf4112f6d2edb780fe6b1edf27ad7ea82 (patch)
tree4907d57e5377274167cf46c7bf9bc21f4fcd1a2a /mail
parent8bb08170165e1d6eb8b5c3605c85db249d81b1f1 (diff)
downloadgsoc2013-evolution-cf4448abf4112f6d2edb780fe6b1edf27ad7ea82.tar.gz
gsoc2013-evolution-cf4448abf4112f6d2edb780fe6b1edf27ad7ea82.tar.zst
gsoc2013-evolution-cf4448abf4112f6d2edb780fe6b1edf27ad7ea82.zip
hook onto destroy to remove dialogue from active table. (error_response):
2003-01-13 Not Zed <NotZed@Ximian.com> * mail-mt.c (mail_msg_check_error): hook onto destroy to remove dialogue from active table. (error_response): Just destroy on any response, dont unref either. svn path=/trunk/; revision=19423
Diffstat (limited to 'mail')
-rw-r--r--mail/ChangeLog6
-rw-r--r--mail/mail-mt.c7
2 files changed, 11 insertions, 2 deletions
diff --git a/mail/ChangeLog b/mail/ChangeLog
index 30feef968c..c7955613a4 100644
--- a/mail/ChangeLog
+++ b/mail/ChangeLog
@@ -1,3 +1,9 @@
+2003-01-13 Not Zed <NotZed@Ximian.com>
+
+ * mail-mt.c (mail_msg_check_error): hook onto destroy to remove
+ dialogue from active table.
+ (error_response): Just destroy on any response, dont unref either.
+
2003-01-11 Jeffrey Stedfast <fejj@ximian.com>
* mail-format.c (mail_format_data_wrapper_write_to_stream):
diff --git a/mail/mail-mt.c b/mail/mail-mt.c
index adbdbb0828..189576d8d3 100644
--- a/mail/mail-mt.c
+++ b/mail/mail-mt.c
@@ -215,12 +215,14 @@ void mail_msg_free(void *msg)
/* hash table of ops->dialogue of active errors */
static GHashTable *active_errors = NULL;
-static void error_response(GtkObject *o, int button, void *data)
+static void error_destroy(GtkObject *o, void *data)
{
g_hash_table_remove(active_errors, data);
+}
+static void error_response(GtkObject *o, int button, void *data)
+{
gtk_widget_destroy((GtkWidget *)o);
- g_object_unref(o);
}
void mail_msg_check_error(void *msg)
@@ -268,6 +270,7 @@ void mail_msg_check_error(void *msg)
gd = (GtkDialog *)gtk_message_dialog_new(NULL, 0, GTK_MESSAGE_ERROR, GTK_BUTTONS_CLOSE, "%s", text);
g_hash_table_insert(active_errors, m->ops, gd);
g_signal_connect(gd, "response", G_CALLBACK(error_response), m->ops);
+ g_signal_connect(gd, "destroy", G_CALLBACK(error_destroy), m->ops);
gtk_widget_show((GtkWidget *)gd);
}