mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-26 19:51:11 +00:00
input-selector: Fix missing pad activation notification
A new active pad might not be notified in some cases, which results in the current track number not being set in playbin. The active-pad notification is only sent in the chain and sink_event functions, and only when the buffer or event that triggered the active pad selection is from the newly activated pad. So in the other case the notification will never be sent. https://bugzilla.gnome.org/show_bug.cgi?id=704691
This commit is contained in:
parent
0c513e3d97
commit
9bc26c5f25
1 changed files with 2 additions and 2 deletions
|
@ -461,7 +461,7 @@ gst_selector_pad_event (GstPad * pad, GstObject * parent, GstEvent * event)
|
|||
active_sinkpad = gst_input_selector_activate_sinkpad (sel, pad);
|
||||
GST_INPUT_SELECTOR_UNLOCK (sel);
|
||||
|
||||
if (prev_active_sinkpad != active_sinkpad && pad == active_sinkpad) {
|
||||
if (prev_active_sinkpad != active_sinkpad) {
|
||||
if (prev_active_sinkpad)
|
||||
g_object_notify (G_OBJECT (prev_active_sinkpad), "active");
|
||||
g_object_notify (G_OBJECT (active_sinkpad), "active");
|
||||
|
@ -1050,7 +1050,7 @@ gst_selector_pad_chain (GstPad * pad, GstObject * parent, GstBuffer * buf)
|
|||
|
||||
GST_INPUT_SELECTOR_UNLOCK (sel);
|
||||
|
||||
if (prev_active_sinkpad != active_sinkpad && pad == active_sinkpad) {
|
||||
if (prev_active_sinkpad != active_sinkpad) {
|
||||
if (prev_active_sinkpad)
|
||||
g_object_notify (G_OBJECT (prev_active_sinkpad), "active");
|
||||
g_object_notify (G_OBJECT (active_sinkpad), "active");
|
||||
|
|
Loading…
Reference in a new issue