try mpv on Windows again

https://github.com/ankitects/anki/pull/621
This commit is contained in:
Damien Elmes 2020-05-27 09:21:41 +10:00
parent c37390ae14
commit d04699ad06

View File

@ -630,13 +630,12 @@ def setup_audio(taskman: TaskManager, base_folder: str) -> None:
# legacy global var
global mpvManager
if not isWin:
try:
mpvManager = MpvManager(base_folder)
except FileNotFoundError:
print("mpv not found, reverting to mplayer")
except aqt.mpv.MPVProcessError:
print("mpv too old, reverting to mplayer")
try:
mpvManager = MpvManager(base_folder)
except FileNotFoundError:
print("mpv not found, reverting to mplayer")
except aqt.mpv.MPVProcessError:
print("mpv too old, reverting to mplayer")
if mpvManager is not None:
av_player.players.append(mpvManager)