[gnome-builder] create-project: release template upon ::destroy
- From: Christian Hergert <chergert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-builder] create-project: release template upon ::destroy
- Date: Sat, 28 Jul 2018 07:08:18 +0000 (UTC)
commit 08c619c71c1b485c14e4d6b55a70e253e1861664
Author: Christian Hergert <chergert redhat com>
Date: Fri Jul 27 23:41:05 2018 -0700
create-project: release template upon ::destroy
src/plugins/create-project/gbp-create-project-template-icon.c | 11 ++++++-----
1 file changed, 6 insertions(+), 5 deletions(-)
---
diff --git a/src/plugins/create-project/gbp-create-project-template-icon.c
b/src/plugins/create-project/gbp-create-project-template-icon.c
index 3feebd5da..e8276b51c 100644
--- a/src/plugins/create-project/gbp-create-project-template-icon.c
+++ b/src/plugins/create-project/gbp-create-project-template-icon.c
@@ -90,13 +90,13 @@ gbp_create_project_template_icon_set_property (GObject *object,
}
static void
-gbp_create_project_template_icon_finalize (GObject *object)
+gbp_create_project_template_icon_destroy (GtkWidget *widget)
{
- GbpCreateProjectTemplateIcon *self = GBP_CREATE_PROJECT_TEMPLATE_ICON (object);
+ GbpCreateProjectTemplateIcon *self = (GbpCreateProjectTemplateIcon *)widget;
- g_object_unref (self->template);
+ g_clear_object (&self->template);
- G_OBJECT_CLASS (gbp_create_project_template_icon_parent_class)->finalize (object);
+ GTK_WIDGET_CLASS (gbp_create_project_template_icon_parent_class)->destroy (widget);
}
static void
@@ -107,7 +107,8 @@ gbp_create_project_template_icon_class_init (GbpCreateProjectTemplateIconClass *
object_class->set_property = gbp_create_project_template_icon_set_property;
object_class->get_property = gbp_create_project_template_icon_get_property;
- object_class->finalize = gbp_create_project_template_icon_finalize;
+
+ widget_class->destroy = gbp_create_project_template_icon_destroy;
properties [PROP_TEMPLATE] =
g_param_spec_object ("template",
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]