[empathy/mc5: 220/483] Hook up to the destroy signal in EmpathyAccountWidget
- From: Sjoerd Simons <sjoerds src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [empathy/mc5: 220/483] Hook up to the destroy signal in EmpathyAccountWidget
- Date: Fri, 21 Aug 2009 17:17:54 +0000 (UTC)
commit c8fc859d6d2bda4110e0dcb5fa4e213162d1c1c4
Author: Cosimo Cecchi <cosimoc gnome org>
Date: Wed Jul 29 23:38:00 2009 +0200
Hook up to the destroy signal in EmpathyAccountWidget
libempathy-gtk/empathy-account-widget.c | 11 +++++++++++
1 files changed, 11 insertions(+), 0 deletions(-)
---
diff --git a/libempathy-gtk/empathy-account-widget.c b/libempathy-gtk/empathy-account-widget.c
index 5cfff21..2b6439f 100644
--- a/libempathy-gtk/empathy-account-widget.c
+++ b/libempathy-gtk/empathy-account-widget.c
@@ -708,6 +708,13 @@ account_widget_build_groupwise (EmpathyAccountWidget *self,
}
static void
+account_widget_destroy_cb (GtkWidget *widget,
+ EmpathyAccountWidget *self)
+{
+ g_object_unref (self);
+}
+
+static void
do_set_property (GObject *object,
guint prop_id,
const GValue *value,
@@ -832,6 +839,10 @@ do_constructed (GObject *obj)
account_widget_handle_apply_sensitivity (self);
gtk_widget_show (priv->apply_button);
+ /* hook up to widget destruction to unref ourselves */
+ g_signal_connect (self->ui_details->widget, "destroy",
+ G_CALLBACK (account_widget_destroy_cb), self);
+
empathy_builder_unref_and_keep_widget (self->ui_details->gui, self->ui_details->widget);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]