Fix playback startup
This commit is contained in:
parent
a650c42cfd
commit
7e676eb043
2 changed files with 4 additions and 5 deletions
|
@ -87,12 +87,10 @@ class KodiMonitor(xbmc.Monitor):
|
||||||
with app.APP.lock_playqueues:
|
with app.APP.lock_playqueues:
|
||||||
_playback_cleanup()
|
_playback_cleanup()
|
||||||
elif method == 'Playlist.OnAdd':
|
elif method == 'Playlist.OnAdd':
|
||||||
with app.APP.lock_playqueues:
|
|
||||||
self._playlist_onadd(data)
|
self._playlist_onadd(data)
|
||||||
elif method == 'Playlist.OnRemove':
|
elif method == 'Playlist.OnRemove':
|
||||||
self._playlist_onremove(data)
|
self._playlist_onremove(data)
|
||||||
elif method == 'Playlist.OnClear':
|
elif method == 'Playlist.OnClear':
|
||||||
with app.APP.lock_playqueues:
|
|
||||||
self._playlist_onclear(data)
|
self._playlist_onclear(data)
|
||||||
elif method == "VideoLibrary.OnUpdate":
|
elif method == "VideoLibrary.OnUpdate":
|
||||||
# Manually marking as watched/unwatched
|
# Manually marking as watched/unwatched
|
||||||
|
|
|
@ -322,6 +322,8 @@ class QueuePlay(backgroundthread.KillableThread):
|
||||||
LOG.debug('Widget video playback detected')
|
LOG.debug('Widget video playback detected')
|
||||||
video_widget_playback = True
|
video_widget_playback = True
|
||||||
# Release default.py
|
# Release default.py
|
||||||
|
utils.window('plex.playlist.play', value='true')
|
||||||
|
# The playlist will be ready anyway
|
||||||
utils.window('plex.playlist.ready', value='true')
|
utils.window('plex.playlist.ready', value='true')
|
||||||
playqueue = PQ.get_playqueue_from_type(v.KODI_TYPE_AUDIO)
|
playqueue = PQ.get_playqueue_from_type(v.KODI_TYPE_AUDIO)
|
||||||
playqueue.clear()
|
playqueue.clear()
|
||||||
|
@ -397,7 +399,6 @@ class QueuePlay(backgroundthread.KillableThread):
|
||||||
playqueue.start_playback(start_position)
|
playqueue.start_playback(start_position)
|
||||||
elif video_widget_playback:
|
elif video_widget_playback:
|
||||||
LOG.info('Start widget video playback')
|
LOG.info('Start widget video playback')
|
||||||
utils.window('plex.playlist.play', value='true')
|
|
||||||
playqueue.start_playback()
|
playqueue.start_playback()
|
||||||
else:
|
else:
|
||||||
LOG.info('Start normal playback')
|
LOG.info('Start normal playback')
|
||||||
|
|
Loading…
Reference in a new issue