Commit f6b00677 authored by Timm Bäder's avatar Timm Bäder 👎

GtkSeparator: Don't leak the gadget

parent 35c243b2
......@@ -216,6 +216,17 @@ gtk_separator_init (GtkSeparator *separator)
NULL);
}
static void
gtk_separator_finalize (GObject *object)
{
GtkSeparatorPrivate *priv = GTK_SEPARATOR (object)->priv;
g_clear_object (&priv->gadget);
G_OBJECT_CLASS (gtk_separator_parent_class)->finalize (object);
}
static void
gtk_separator_class_init (GtkSeparatorClass *class)
{
......@@ -224,6 +235,7 @@ gtk_separator_class_init (GtkSeparatorClass *class)
object_class->set_property = gtk_separator_set_property;
object_class->get_property = gtk_separator_get_property;
object_class->finalize = gtk_separator_finalize;
widget_class->get_preferred_width = gtk_separator_get_preferred_width;
widget_class->get_preferred_height = gtk_separator_get_preferred_height;
......
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