summaryrefslogtreecommitdiff
path: root/xfconf
diff options
context:
space:
mode:
authorBrian Tarricone <brian@tarricone.org>2008-04-15 10:36:24 +0000
committerBrian Tarricone <brian@tarricone.org>2008-04-15 10:36:24 +0000
commit776dc8267270d95ca5b680e25922fcf3ea6ea206 (patch)
treeab7596b1bdd6d2fbe79878f8232db6853fa15d2f /xfconf
parent15e7d6789aec2050e055a777caff71831d81c32e (diff)
downloadxfconf-776dc8267270d95ca5b680e25922fcf3ea6ea206.tar.gz
remove XfconfGBinding from channel's list if the GObject gets freed
(Old svn revision: 26845)
Diffstat (limited to 'xfconf')
-rw-r--r--xfconf/xfconf-binding.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/xfconf/xfconf-binding.c b/xfconf/xfconf-binding.c
index 7bb97b7..c1f7d54 100644
--- a/xfconf/xfconf-binding.c
+++ b/xfconf/xfconf-binding.c
@@ -93,6 +93,16 @@ xfconf_g_binding_object_destroyed(gpointer data,
GObject *where_the_object_was)
{
XfconfGBinding *binding = data;
+ GList *bindings = g_object_steal_data(G_OBJECT(binding->channel),
+ "--xfconf-g-bindings");
+
+ bindings = g_list_remove(bindings, binding);
+ if(bindings) {
+ g_object_set_data_full(G_OBJECT(binding->channel),
+ "--xfconf-g-bindings",
+ bindings, (GDestroyNotify)g_list_free);
+ }
+
binding->object = NULL;
xfconf_g_binding_free(binding);
}