Merge branch 'release-2.0' into develop

This commit is contained in:
Stein Magnus Jodal 2016-08-07 09:49:40 +02:00
commit d16494ce0d
2 changed files with 14 additions and 3 deletions

View File

@ -36,7 +36,7 @@ Bug fix release.
:issue:`1487`)
- Audio: Better handling of seek when position does not match the expected
pending position. (Fixes: :issue:`1462`, PR: :issue:`1496`)
pending position. (Fixes: :issue:`1462`, :issue:`1505`, PR: :issue:`1496`)
- Audio: Handle bad date tags from audio, thanks to Mario Lang and Tom Parker
who fixed this in parallel. (Fixes: :issue:`1506`, PR: :issue:`1525`,
@ -47,6 +47,10 @@ Bug fix release.
- Audio: Ensure audio tags are never ``None``. (Fixes: :issue:`1449`)
- Audio: Update :meth:`mopidy.audio.Audio.set_metadata` to postpone sending
tags if there is a pending track change. (Fixes: :issue:`1357`, PR:
:issue:`1538`)
- Core: Avoid endless loop if all tracks in the tracklist are unplayable and
consume mode is off. (Fixes: :issue:`1221`, :issue:`1454`, PR: :issue:`1455`)

View File

@ -374,6 +374,10 @@ class _Handler(object):
logger.debug('Audio event: tags_changed(tags=%r)', tags.keys())
AudioListener.send('tags_changed', tags=tags.keys())
if self._audio._pending_metadata:
self._audio._playbin.send_event(self._audio._pending_metadata)
self._audio._pending_metadata = None
def on_segment(self, segment):
gst_logger.debug(
'Got SEGMENT pad event: '
@ -412,6 +416,7 @@ class Audio(pykka.ThreadingActor):
self._tags = {}
self._pending_uri = None
self._pending_tags = None
self._pending_metadata = None
self._playbin = None
self._outputs = None
@ -804,8 +809,10 @@ class Audio(pykka.ThreadingActor):
'Sending TAG event for track %r: %r',
track.uri, taglist.to_string())
event = Gst.Event.new_tag(taglist)
# TODO: check if we get this back on our own bus?
self._playbin.send_event(event)
if self._pending_uri:
self._pending_metadata = event
else:
self._playbin.send_event(event)
def get_current_tags(self):
"""