diff --git a/clutter/clutter-box.c b/clutter/clutter-box.c index 6b8253eac..f3c0648ab 100644 --- a/clutter/clutter-box.c +++ b/clutter/clutter-box.c @@ -281,7 +281,8 @@ clutter_box_set_property (GObject *gobject, switch (prop_id) { case PROP_LAYOUT_MANAGER: - priv->manager = g_value_dup_object (value); + priv->manager = g_value_get_object (value); + g_object_ref_sink (priv->manager); break; default: diff --git a/clutter/clutter-layout-manager.c b/clutter/clutter-layout-manager.c index f9e59087f..912ccd2d3 100644 --- a/clutter/clutter-layout-manager.c +++ b/clutter/clutter-layout-manager.c @@ -23,7 +23,9 @@ G_OBJECT_TYPE_NAME (_obj), \ (method)); } G_STMT_END -G_DEFINE_ABSTRACT_TYPE (ClutterLayoutManager, clutter_layout_manager, G_TYPE_OBJECT); +G_DEFINE_ABSTRACT_TYPE (ClutterLayoutManager, + clutter_layout_manager, + G_TYPE_INITIALLY_UNOWNED); static void layout_manager_real_get_preferred_width (ClutterLayoutManager *manager, diff --git a/clutter/clutter-layout-manager.h b/clutter/clutter-layout-manager.h index f93e68a02..e053c658e 100644 --- a/clutter/clutter-layout-manager.h +++ b/clutter/clutter-layout-manager.h @@ -30,7 +30,7 @@ typedef struct _ClutterLayoutManagerClass ClutterLayoutManagerClass; */ struct _ClutterLayoutManager { - GObject parent_instance; + GInitiallyUnowned parent_instance; }; /** @@ -43,7 +43,7 @@ struct _ClutterLayoutManager */ struct _ClutterLayoutManagerClass { - GObjectClass parent_class; + GInitiallyUnownedClass parent_class; void (* get_preferred_width) (ClutterLayoutManager *manager, ClutterContainer *container,