show warning instead of crashing when recording on darwin-arm64

This commit is contained in:
Damien Elmes 2021-10-29 14:43:59 +10:00
parent 83af294a8c
commit dc56b43c32

View file

@ -711,6 +711,10 @@ class RecordDialog(QDialog):
def record_audio(
parent: QWidget, mw: aqt.AnkiQt, encode: bool, on_done: Callable[[str], None]
) -> None:
if sys.platform.startswith("darwin") and platform.machine() == "arm64":
showWarning("Recording currently only works in Anki's Intel build")
return
def after_record(path: str) -> None:
if not encode:
on_done(path)