diff options
author | Marco Pesenti Gritti <marco@it.gnome.org> | 2003-05-24 16:51:04 +0800 |
---|---|---|
committer | Marco Pesenti Gritti <mpeseng@src.gnome.org> | 2003-05-24 16:51:04 +0800 |
commit | ab25b91dc7b2d07a2762e799a7010d3f9438069c (patch) | |
tree | 56241585a3c0f06e1ed859c2bbce8e6919b83aed /lib/egg/eggtoolitem.c | |
parent | a98d9364cb5395aca5adc9fa4db219df7545ab98 (diff) | |
download | gsoc2013-epiphany-ab25b91dc7b2d07a2762e799a7010d3f9438069c.tar gsoc2013-epiphany-ab25b91dc7b2d07a2762e799a7010d3f9438069c.tar.gz gsoc2013-epiphany-ab25b91dc7b2d07a2762e799a7010d3f9438069c.tar.bz2 gsoc2013-epiphany-ab25b91dc7b2d07a2762e799a7010d3f9438069c.tar.lz gsoc2013-epiphany-ab25b91dc7b2d07a2762e799a7010d3f9438069c.tar.xz gsoc2013-epiphany-ab25b91dc7b2d07a2762e799a7010d3f9438069c.tar.zst gsoc2013-epiphany-ab25b91dc7b2d07a2762e799a7010d3f9438069c.zip |
Update
2003-05-24 Marco Pesenti Gritti <marco@it.gnome.org>
* lib/egg/eggradiotoolbutton.c:
* lib/egg/eggseparatortoolitem.c:
* lib/egg/eggtoggletoolbutton.c:
* lib/egg/eggtoolbar.c:
* lib/egg/eggtoolbar.h:
* lib/egg/eggtoolbutton.c:
* lib/egg/eggtoolbutton.h:
* lib/egg/eggtoolitem.c:
Update
Diffstat (limited to 'lib/egg/eggtoolitem.c')
-rw-r--r-- | lib/egg/eggtoolitem.c | 35 |
1 files changed, 25 insertions, 10 deletions
diff --git a/lib/egg/eggtoolitem.c b/lib/egg/eggtoolitem.c index 49445d48f..0ffc5b298 100644 --- a/lib/egg/eggtoolitem.c +++ b/lib/egg/eggtoolitem.c @@ -46,6 +46,7 @@ enum { static void egg_tool_item_init (EggToolItem *toolitem); static void egg_tool_item_class_init (EggToolItemClass *class); +static void egg_tool_item_finalize (GObject *object); static void egg_tool_item_set_property (GObject *object, guint prop_id, @@ -118,6 +119,7 @@ egg_boolean_handled_accumulator (GSignalInvocationHint *ihint, return continue_emission; } + static void egg_tool_item_class_init (EggToolItemClass *klass) { @@ -130,6 +132,7 @@ egg_tool_item_class_init (EggToolItemClass *klass) object_class->set_property = egg_tool_item_set_property; object_class->get_property = egg_tool_item_get_property; + object_class->finalize = egg_tool_item_finalize; widget_class->realize = egg_tool_item_realize; widget_class->unrealize = egg_tool_item_unrealize; @@ -197,10 +200,22 @@ egg_tool_item_init (EggToolItem *toolitem) } static void -egg_tool_item_set_property (GObject *object, - guint prop_id, - const GValue *value, - GParamSpec *pspec) +egg_tool_item_finalize (GObject *object) +{ + EggToolItem *item = EGG_TOOL_ITEM (object); + + if (item->menu_item) + g_object_unref (item->menu_item); + + if (G_OBJECT_CLASS (parent_class)->finalize) + G_OBJECT_CLASS (parent_class)->finalize (object); +} + +static void +egg_tool_item_set_property (GObject *object, + guint prop_id, + const GValue *value, + GParamSpec *pspec) { EggToolItem *toolitem = EGG_TOOL_ITEM (object); @@ -218,10 +233,10 @@ egg_tool_item_set_property (GObject *object, } static void -egg_tool_item_get_property (GObject *object, - guint prop_id, - GValue *value, - GParamSpec *pspec) +egg_tool_item_get_property (GObject *object, + guint prop_id, + GValue *value, + GParamSpec *pspec) { EggToolItem *toolitem = EGG_TOOL_ITEM (object); @@ -476,7 +491,7 @@ egg_tool_item_set_expand (EggToolItem *tool_item, void egg_tool_item_set_pack_end (EggToolItem *tool_item, - gboolean pack_end) + gboolean pack_end) { g_return_if_fail (EGG_IS_TOOL_ITEM (tool_item)); @@ -642,7 +657,7 @@ egg_tool_item_get_proxy_menu_item (EggToolItem *tool_item, void egg_tool_item_set_proxy_menu_item (EggToolItem *tool_item, const gchar *menu_item_id, - GtkWidget *menu_item) + GtkWidget *menu_item) { g_return_if_fail (EGG_IS_TOOL_ITEM (tool_item)); g_return_if_fail (menu_item == NULL || GTK_IS_MENU_ITEM (menu_item)); |