From 9d86604800dfdf94a1077cca009a436c7219f082 Mon Sep 17 00:00:00 2001 From: angelblue05 Date: Thu, 17 Sep 2015 16:00:58 -0500 Subject: [PATCH] Support strm file playback regardless of method --- resources/lib/PlayUtils.py | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/resources/lib/PlayUtils.py b/resources/lib/PlayUtils.py index a5b97af1..09517c32 100644 --- a/resources/lib/PlayUtils.py +++ b/resources/lib/PlayUtils.py @@ -79,6 +79,10 @@ class PlayUtils(): self.logMsg("Can't direct play: Server does not allow or support it.", 1) return False + if result['Path'].endswith('.strm'): + # Allow strm loading when direct playing + return True + location = result[u'LocationType'] # File needs to be "FileSystem" if u'FileSystem' in location: @@ -159,6 +163,11 @@ class PlayUtils(): return True def directStream(self, result, server, id, type = "Video"): + + if result['Path'].endswith('.strm'): + # Allow strm loading when direct streaming + playurl = self.directPlay(result) + return playurl try: if "ThemeVideo" in type: @@ -192,6 +201,11 @@ class PlayUtils(): return True def transcoding(self, result, server, id): + + if result['Path'].endswith('.strm'): + # Allow strm loading when transcoding + playurl = self.directPlay(result) + return playurl try: # Play transcoding