diff --git a/clutter/clutter-timeline.c b/clutter/clutter-timeline.c index c6f68ca17..93ffdd9ff 100644 --- a/clutter/clutter-timeline.c +++ b/clutter/clutter-timeline.c @@ -1220,26 +1220,33 @@ clutter_timeline_is_playing (ClutterTimeline *timeline) * be started and will not be positioned to the current position of * @timeline: you will have to start it with clutter_timeline_start(). * - * Return Value: (transfer full): a new #ClutterTimeline, cloned + * The only cloned properties are: + * + * #ClutterTimeline:duration + * #ClutterTimeline:loop + * #ClutterTimeline:delay + * #ClutterTimeline:direction + * + * + * Return value: (transfer full): a new #ClutterTimeline, cloned * from @timeline * * Since: 0.4 + * + * Deprecated: 1.10: Use clutter_timeline_new() or g_object_new() + * instead */ ClutterTimeline * clutter_timeline_clone (ClutterTimeline *timeline) { - ClutterTimeline *copy; - g_return_val_if_fail (CLUTTER_IS_TIMELINE (timeline), NULL); - copy = g_object_new (CLUTTER_TYPE_TIMELINE, + return g_object_new (CLUTTER_TYPE_TIMELINE, "duration", clutter_timeline_get_duration (timeline), "loop", clutter_timeline_get_loop (timeline), "delay", clutter_timeline_get_delay (timeline), "direction", clutter_timeline_get_direction (timeline), NULL); - - return copy; } /** diff --git a/clutter/clutter-timeline.h b/clutter/clutter-timeline.h index b0272de15..736528867 100644 --- a/clutter/clutter-timeline.h +++ b/clutter/clutter-timeline.h @@ -138,6 +138,7 @@ gboolean clutter_timeline_has_marker (Clutter void clutter_timeline_advance_to_marker (ClutterTimeline *timeline, const gchar *marker_name); +CLUTTER_DEPRECATED_FOR(clutter_timeline_new) ClutterTimeline * clutter_timeline_clone (ClutterTimeline *timeline); G_END_DECLS