[gnumeric] Recent: plug leak.
- From: Morten Welinder <mortenw src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnumeric] Recent: plug leak.
- Date: Wed, 7 Jan 2015 01:19:42 +0000 (UTC)
commit 3a1aee566952c0ff270a408bf5177d3284a4e7bd
Author: Morten Welinder <terra gnome org>
Date: Tue Jan 6 20:19:11 2015 -0500
Recent: plug leak.
src/dialogs/ChangeLog | 4 ++++
src/dialogs/dialog-recent.c | 9 +++++++++
2 files changed, 13 insertions(+), 0 deletions(-)
---
diff --git a/src/dialogs/ChangeLog b/src/dialogs/ChangeLog
index 3df549a..6016148 100644
--- a/src/dialogs/ChangeLog
+++ b/src/dialogs/ChangeLog
@@ -1,3 +1,7 @@
+2015-01-06 Morten Welinder <terra gnome org>
+
+ * dialog-recent.c (cb_destroy): Plug leak.
+
2015-01-05 Morten Welinder <terra gnome org>
* dialog-define-names.c (cb_name_guru_destroy): Plug leak.
diff --git a/src/dialogs/dialog-recent.c b/src/dialogs/dialog-recent.c
index 6f8c660..39d612e 100644
--- a/src/dialogs/dialog-recent.c
+++ b/src/dialogs/dialog-recent.c
@@ -76,6 +76,14 @@ cb_response (GtkWidget *dialog,
}
}
+static void
+cb_destroy (GtkDialog *dialog)
+{
+ /* Trigger tear-down. */
+ g_object_set_data (G_OBJECT (dialog), "gui", NULL);
+}
+
+
static gboolean
cb_key_press (GtkWidget *widget, GdkEventKey *event)
{
@@ -326,6 +334,7 @@ dialog_recent_used (WBCGtk *wbcg)
/* ---------------------------------------- */
g_object_set_data_full (G_OBJECT (dialog), "gui", gui, g_object_unref);
+ g_signal_connect (dialog, "destroy", G_CALLBACK (cb_destroy), NULL);
go_gtk_nonmodal_dialog (wbcg_toplevel (wbcg), GTK_WINDOW (dialog));
gtk_widget_show_all (GTK_WIDGET (dialog));
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]