[epiphany] ephy-page-menu-action: disconnect the visible handler on dispose
- From: Xan Lopez <xan src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [epiphany] ephy-page-menu-action: disconnect the visible handler on dispose
- Date: Tue, 17 Jan 2012 11:51:44 +0000 (UTC)
commit af6852c68bfad98d9175eb10ac3efbcc9112aac8
Author: Xan Lopez <xan igalia com>
Date: Tue Jan 17 12:51:07 2012 +0100
ephy-page-menu-action: disconnect the visible handler on dispose
src/ephy-page-menu-action.c | 10 ++++++++++
1 files changed, 10 insertions(+), 0 deletions(-)
---
diff --git a/src/ephy-page-menu-action.c b/src/ephy-page-menu-action.c
index 66ecabd..b42d13c 100644
--- a/src/ephy-page-menu-action.c
+++ b/src/ephy-page-menu-action.c
@@ -146,6 +146,16 @@ ephy_page_menu_action_dispose (GObject *object)
{
EphyPageMenuActionPrivate *priv = EPHY_PAGE_MENU_ACTION (object)->priv;
+ if (priv->menu) {
+ GtkWidget *button = NULL;
+ GSList *l = gtk_action_get_proxies (GTK_ACTION (object));
+
+ if (GTK_IS_BUTTON (l->data))
+ button = GTK_WIDGET (l->data);
+
+ g_signal_handlers_disconnect_by_func (priv->menu, G_CALLBACK (visible_cb), button);
+ }
+
g_clear_object (&priv->menu);
G_OBJECT_CLASS (ephy_page_menu_action_parent_class)->dispose (object);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]