mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-27 04:01:08 +00:00
GESTimeline: remove layers before removing tracks in dispose ()
This commit is contained in:
parent
d2019f3a3d
commit
d2b2ac0d51
1 changed files with 10 additions and 5 deletions
|
@ -104,16 +104,21 @@ ges_timeline_dispose (GObject * object)
|
||||||
timeline->discoverer = NULL;
|
timeline->discoverer = NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
while (timeline->tracks) {
|
|
||||||
TrackPrivate *priv = (TrackPrivate *) timeline->tracks->data;
|
|
||||||
ges_timeline_remove_track (timeline, priv->track);
|
|
||||||
}
|
|
||||||
|
|
||||||
while (timeline->layers) {
|
while (timeline->layers) {
|
||||||
GESTimelineLayer *layer = (GESTimelineLayer *) timeline->layers->data;
|
GESTimelineLayer *layer = (GESTimelineLayer *) timeline->layers->data;
|
||||||
ges_timeline_remove_layer (timeline, layer);
|
ges_timeline_remove_layer (timeline, layer);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* FIXME: it should be possible to remove tracks before removing
|
||||||
|
* layers, but at the moment this creates a problem because the track
|
||||||
|
* objects aren't notified that their gnlobjects have been destroyed.
|
||||||
|
*/
|
||||||
|
|
||||||
|
while (timeline->tracks) {
|
||||||
|
TrackPrivate *priv = (TrackPrivate *) timeline->tracks->data;
|
||||||
|
ges_timeline_remove_track (timeline, priv->track);
|
||||||
|
}
|
||||||
|
|
||||||
G_OBJECT_CLASS (ges_timeline_parent_class)->dispose (object);
|
G_OBJECT_CLASS (ges_timeline_parent_class)->dispose (object);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue