new_trackelement =
GES_TRACK_ELEMENT (ges_timeline_element_copy (GES_TIMELINE_ELEMENT
- (trackelement), TRUE));
+ (trackelement), FALSE));
if (new_trackelement == NULL) {
GST_WARNING_OBJECT (trackelement, "Could not create a copy");
continue;
ges_container_add (GES_CONTAINER (new_object),
GES_TIMELINE_ELEMENT (new_trackelement));
+ ges_track_element_copy_properties (GES_TIMELINE_ELEMENT (trackelement),
+ GES_TIMELINE_ELEMENT (new_trackelement));
}
return new_object;
#define GNL_OBJECT_TRACK_ELEMENT_QUARK (g_quark_from_string ("gnl_object_track_element_quark"))
G_GNUC_INTERNAL gboolean ges_track_element_set_track (GESTrackElement * object, GESTrack * track);
G_GNUC_INTERNAL guint32 _ges_track_element_get_layer_priority (GESTrackElement * element);
+G_GNUC_INTERNAL void ges_track_element_copy_properties (GESTimelineElement * element,
+ GESTimelineElement * elementcopy);
#endif /* __GES_INTERNAL_H__ */
static gboolean _set_duration (GESTimelineElement * element,
GstClockTime duration);
static gboolean _set_priority (GESTimelineElement * element, guint32 priority);
-static void _deep_copy (GESTimelineElement * element,
- GESTimelineElement * copy);
static GParamSpec **default_list_children_properties (GESTrackElement * object,
guint * n_properties);
element_class->set_duration = _set_duration;
element_class->set_inpoint = _set_inpoint;
element_class->set_priority = _set_priority;
- element_class->deep_copy = _deep_copy;
+ element_class->deep_copy = ges_track_element_copy_properties;
klass->create_gnl_object = ges_track_element_create_gnl_object_func;
/* There is no 'get_props_hashtable' default implementation */
}
void
-_deep_copy (GESTimelineElement * element, GESTimelineElement * elementcopy)
+ges_track_element_copy_properties (GESTimelineElement * element,
+ GESTimelineElement * elementcopy)
{
GParamSpec **specs;
guint n, n_specs;
&n_specs);
for (n = 0; n < n_specs; ++n) {
g_value_init (&val, specs[n]->value_type);
- g_object_get_property (G_OBJECT (element), specs[n]->name, &val);
+ ges_track_element_get_child_property_by_pspec (GES_TRACK_ELEMENT (element),
+ specs[n], &val);
ges_track_element_set_child_property_by_pspec (copy, specs[n], &val);
g_value_unset (&val);
}