gst/playback/gstplaybin.c: Only remove visualisation from visbin if there is a visbin (or: don't throw warnings when ...

Original commit message from CVS:
* gst/playback/gstplaybin.c: (remove_sinks):
Only remove visualisation from visbin if there is a visbin (or:
don't throw warnings when closing totem without playing a file).
This commit is contained in:
Tim-Philipp Müller 2006-09-28 09:41:20 +00:00
parent 1980f16731
commit 0c3733c652
2 changed files with 10 additions and 2 deletions

View file

@ -1,3 +1,9 @@
2006-09-28 Tim-Philipp Müller <tim at centricular dot net>
* gst/playback/gstplaybin.c: (remove_sinks):
Only remove visualisation from visbin if there is a visbin (or:
don't throw warnings when closing totem without playing a file).
2006-09-27 Wim Taymans <wim@fluendo.com> 2006-09-27 Wim Taymans <wim@fluendo.com>
* gst-libs/gst/audio/gstbaseaudiosink.c: * gst-libs/gst/audio/gstbaseaudiosink.c:

View file

@ -1311,10 +1311,12 @@ remove_sinks (GstPlayBin * play_bin)
GST_ELEMENT_CAST (gst_element_get_parent (play_bin->visualisation)); GST_ELEMENT_CAST (gst_element_get_parent (play_bin->visualisation));
gst_element_set_state (play_bin->visualisation, GST_STATE_NULL); gst_element_set_state (play_bin->visualisation, GST_STATE_NULL);
gst_bin_remove (GST_BIN_CAST (vis_bin), play_bin->visualisation);
if (vis_bin) {
gst_bin_remove (GST_BIN_CAST (vis_bin), play_bin->visualisation);
gst_object_unref (vis_bin); gst_object_unref (vis_bin);
} }
}
if (play_bin->frame) { if (play_bin->frame) {
gst_buffer_unref (play_bin->frame); gst_buffer_unref (play_bin->frame);