Commit 22147517 authored by Morten Welinder's avatar Morten Welinder

GUI: Plug leak.

parent 14533071
2015-01-05 Morten Welinder <terra@gnome.org>
* gnumeric-cell-renderer-toggle.c
(gnumeric_cell_renderer_toggle_dispose): Plug leak.
2015-01-01 Morten Welinder <terra@gnome.org>
* gnumeric-cell-renderer-text.c
......
......@@ -87,6 +87,14 @@ gnumeric_cell_renderer_toggle_get_type (void)
return cell_toggle_type;
}
static void
gnumeric_cell_renderer_toggle_dispose (GObject *obj)
{
GnumericCellRendererToggle *celltoggle = GNUMERIC_CELL_RENDERER_TOGGLE (obj);
g_clear_object (&celltoggle->pixbuf);
G_OBJECT_CLASS (parent_class)->dispose (obj);
}
static void
gnumeric_cell_renderer_toggle_class_init (GnumericCellRendererToggleClass *class)
{
......@@ -97,6 +105,7 @@ gnumeric_cell_renderer_toggle_class_init (GnumericCellRendererToggleClass *class
object_class->get_property = gnumeric_cell_renderer_toggle_get_property;
object_class->set_property = gnumeric_cell_renderer_toggle_set_property;
object_class->dispose = gnumeric_cell_renderer_toggle_dispose;
cell_class->render = gnumeric_cell_renderer_toggle_render;
cell_class->get_size = gnumeric_cell_renderer_toggle_get_size;
......@@ -127,8 +136,7 @@ gnumeric_cell_renderer_toggle_get_property (GObject *object,
switch (param_id) {
case PROP_PIXBUF:
g_value_set_object (value,
celltoggle->pixbuf ? G_OBJECT (celltoggle->pixbuf) : NULL);
g_value_set_object (value, celltoggle->pixbuf);
break;
default:
G_OBJECT_WARN_INVALID_PROPERTY_ID (object, param_id, pspec);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment