Fixes open file from Syncplay to VLC

This commit is contained in:
albertosottile 2018-04-24 15:59:54 +02:00
parent b827a57cab
commit 99e5e1ac0f

View File

@ -144,7 +144,6 @@ class VlcPlayer(BasePlayer):
def getMRL(self, fileURL):
if utils.isURL(fileURL):
fileURL = fileURL.encode('utf8')
fileURL = urllib.parse.quote(fileURL, safe="%/:=&?~#+!$,;'@()*[]")
return fileURL
@ -164,7 +163,7 @@ class VlcPlayer(BasePlayer):
if os.path.isfile(normedPath):
filePath = normedPath
if utils.isASCII(filePath) and not utils.isURL(filePath):
self._listener.sendLine('load-file: {}'.format(filePath.encode('ascii', 'ignore')))
self._listener.sendLine('load-file: {}'.format(filePath))
else:
fileURL = self.getMRL(filePath)
self._listener.sendLine('load-file: {}'.format(fileURL))