[nautilus] desktop-window: disconnect the gsettings handler on dispose
- From: Cosimo Cecchi <cosimoc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [nautilus] desktop-window: disconnect the gsettings handler on dispose
- Date: Wed, 6 Apr 2011 16:25:17 +0000 (UTC)
commit 25aa3e7f391c905236397a38cf052b0b12bc792a
Author: Cosimo Cecchi <cosimoc gnome org>
Date: Wed Apr 6 12:17:56 2011 -0400
desktop-window: disconnect the gsettings handler on dispose
src/nautilus-desktop-window.c | 13 +++++++++++++
1 files changed, 13 insertions(+), 0 deletions(-)
---
diff --git a/src/nautilus-desktop-window.c b/src/nautilus-desktop-window.c
index b475056..20c81f3 100644
--- a/src/nautilus-desktop-window.c
+++ b/src/nautilus-desktop-window.c
@@ -48,6 +48,18 @@ G_DEFINE_TYPE (NautilusDesktopWindow, nautilus_desktop_window,
NAUTILUS_TYPE_WINDOW);
static void
+nautilus_desktop_window_dispose (GObject *obj)
+{
+ NautilusDesktopWindow *window = NAUTILUS_DESKTOP_WINDOW (obj);
+
+ g_signal_handlers_disconnect_by_func (nautilus_preferences,
+ nautilus_desktop_window_update_directory,
+ window);
+
+ G_OBJECT_CLASS (nautilus_desktop_window_parent_class)->dispose (obj);
+}
+
+static void
nautilus_desktop_window_constructed (GObject *obj)
{
GtkAction *action;
@@ -278,6 +290,7 @@ nautilus_desktop_window_class_init (NautilusDesktopWindowClass *klass)
GObjectClass *oclass = G_OBJECT_CLASS (klass);
oclass->constructed = nautilus_desktop_window_constructed;
+ oclass->dispose = nautilus_desktop_window_dispose;
wclass->realize = realize;
wclass->unrealize = unrealize;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]