PEP fixes
This commit is contained in:
parent
af1766697f
commit
587514a05e
1 changed files with 13 additions and 7 deletions
|
@ -292,11 +292,15 @@ class PlayUtils():
|
||||||
if type == "2":
|
if type == "2":
|
||||||
codec = stream.attrib.get('codec')
|
codec = stream.attrib.get('codec')
|
||||||
channelLayout = stream.attrib.get('audioChannelLayout', "")
|
channelLayout = stream.attrib.get('audioChannelLayout', "")
|
||||||
|
|
||||||
try:
|
try:
|
||||||
track = "%s %s - %s %s" % (audioNum+1, stream.attrib['language'], codec, channelLayout)
|
track = "%s %s - %s %s" % (audioNum+1,
|
||||||
|
stream.attrib['language'],
|
||||||
|
codec,
|
||||||
|
channelLayout)
|
||||||
except:
|
except:
|
||||||
track = "%s 'unknown' - %s %s" % (audioNum+1, codec, channelLayout)
|
track = "%s 'unknown' - %s %s" % (audioNum+1,
|
||||||
|
codec,
|
||||||
|
channelLayout)
|
||||||
audioStreamsList.append(index)
|
audioStreamsList.append(index)
|
||||||
audioStreams.append(tryEncode(track))
|
audioStreams.append(tryEncode(track))
|
||||||
audioNum += 1
|
audioNum += 1
|
||||||
|
@ -306,8 +310,8 @@ class PlayUtils():
|
||||||
try:
|
try:
|
||||||
track = "%s %s" % (subNum+1, stream.attrib['language'])
|
track = "%s %s" % (subNum+1, stream.attrib['language'])
|
||||||
except:
|
except:
|
||||||
track = "%s 'unknown' (%s)" % (subNum+1, stream.attrib.get('codec'))
|
track = "%s 'unknown' (%s)" % (subNum+1,
|
||||||
|
stream.attrib.get('codec'))
|
||||||
default = stream.attrib.get('default')
|
default = stream.attrib.get('default')
|
||||||
forced = stream.attrib.get('forced')
|
forced = stream.attrib.get('forced')
|
||||||
downloadable = stream.attrib.get('key')
|
downloadable = stream.attrib.get('key')
|
||||||
|
@ -334,9 +338,11 @@ class PlayUtils():
|
||||||
if resp > -1:
|
if resp > -1:
|
||||||
# User selected audio
|
# User selected audio
|
||||||
playurlprefs['audioStreamID'] = audioStreamsList[resp]
|
playurlprefs['audioStreamID'] = audioStreamsList[resp]
|
||||||
else: # User backed out of selection - let PMS decide
|
else:
|
||||||
|
# User backed out of selection - let PMS decide
|
||||||
pass
|
pass
|
||||||
else: # There's only one audiotrack.
|
else:
|
||||||
|
# There's only one audiotrack.
|
||||||
playurlprefs['audioStreamID'] = audioStreamsList[0]
|
playurlprefs['audioStreamID'] = audioStreamsList[0]
|
||||||
|
|
||||||
# Add audio boost
|
# Add audio boost
|
||||||
|
|
Loading…
Reference in a new issue