Merge pull request #159 from sualfred/develop

Don't clear playlist if busy spinner is active
This commit is contained in:
Sebastian S 2019-01-19 13:48:22 +01:00 committed by GitHub
commit 17951fa402
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -84,9 +84,9 @@ class Monitor(xbmc.Monitor):
Otherwise the next played item will be added the previous queue. Otherwise the next played item will be added the previous queue.
''' '''
if method == "Player.OnStop": if method == "Player.OnStop":
xbmc.sleep(2000) # let's wait for the player so we don't clear the canceled playlist by mistake. xbmc.sleep(3000) # let's wait for the player so we don't clear the canceled playlist by mistake.
if xbmc.getCondVisibility("!Player.HasMedia"): if xbmc.getCondVisibility("!Player.HasMedia + !Window.IsVisible(busydialog)"):
xbmc.executebuiltin("Playlist.Clear") xbmc.executebuiltin("Playlist.Clear")
LOG.info("[ playlist ] cleared") LOG.info("[ playlist ] cleared")