remove the script-message commands that older mpv version don't support

https://github.com/ankitects/anki/pull/671#issuecomment-647798343
This commit is contained in:
Damien Elmes 2020-06-23 14:30:42 +10:00
parent e231895cc2
commit ef55c0a2ee

View File

@ -338,7 +338,6 @@ class MpvManager(MPV, SoundOrVideoPlayer):
assert isinstance(tag, SoundOrVideoTag)
self._on_done = on_done
path = os.path.join(os.getcwd(), tag.filename)
self.command("script-message", "osc-visibility", "never", "no-osd")
self.command("loadfile", path, "append-play")
gui_hooks.av_player_did_begin_playing(self, tag)
@ -355,9 +354,6 @@ class MpvManager(MPV, SoundOrVideoPlayer):
if val and self._on_done:
self._on_done()
def on_start_file(self) -> None:
self.command("script-message", "osc-visibility", "auto", "no-osd")
def shutdown(self) -> None:
self.close()