mirror of
https://github.com/ankitects/anki.git
synced 2025-09-18 22:12:21 -04:00
formatting and debug statement tweak
This commit is contained in:
parent
26426cb11e
commit
2cba721702
3 changed files with 3 additions and 6 deletions
|
@ -455,7 +455,7 @@ def _run(argv=None, exec=True):
|
||||||
QCoreApplication.setAttribute(Qt.AA_UseSoftwareOpenGL)
|
QCoreApplication.setAttribute(Qt.AA_UseSoftwareOpenGL)
|
||||||
|
|
||||||
if isWin and qtminor == 15 and qtpoint == 0:
|
if isWin and qtminor == 15 and qtpoint == 0:
|
||||||
os.environ["QT_QPA_PLATFORM"]="windows:altgr"
|
os.environ["QT_QPA_PLATFORM"] = "windows:altgr"
|
||||||
|
|
||||||
# create the app
|
# create the app
|
||||||
QCoreApplication.setApplicationName("Anki")
|
QCoreApplication.setApplicationName("Anki")
|
||||||
|
|
|
@ -162,10 +162,7 @@ def allroutes(pathin):
|
||||||
# swallow it - user likely surfed away from
|
# swallow it - user likely surfed away from
|
||||||
# review screen before an image had finished
|
# review screen before an image had finished
|
||||||
# downloading
|
# downloading
|
||||||
return flask.make_response(
|
return flask.make_response(str(error), HTTPStatus.INTERNAL_SERVER_ERROR,)
|
||||||
str(error),
|
|
||||||
HTTPStatus.INTERNAL_SERVER_ERROR,
|
|
||||||
)
|
|
||||||
|
|
||||||
|
|
||||||
def _redirectWebExports(path):
|
def _redirectWebExports(path):
|
||||||
|
|
|
@ -342,7 +342,7 @@ class MpvManager(MPV, SoundOrVideoPlayer):
|
||||||
self.command("keybind", "ctrl+w", "stop")
|
self.command("keybind", "ctrl+w", "stop")
|
||||||
self.command("keybind", "ctrl+c", "stop")
|
self.command("keybind", "ctrl+c", "stop")
|
||||||
except MPVCommandError:
|
except MPVCommandError:
|
||||||
print("mpv too old")
|
print("mpv too old for key rebinding")
|
||||||
|
|
||||||
def play(self, tag: AVTag, on_done: OnDoneCallback) -> None:
|
def play(self, tag: AVTag, on_done: OnDoneCallback) -> None:
|
||||||
assert isinstance(tag, SoundOrVideoTag)
|
assert isinstance(tag, SoundOrVideoTag)
|
||||||
|
|
Loading…
Reference in a new issue