mirror of
https://github.com/ankitects/anki.git
synced 2025-09-18 14:02:21 -04:00
rename some of the files in aqt/qt/
This commit is contained in:
parent
20873107ac
commit
83af294a8c
5 changed files with 5 additions and 5 deletions
|
@ -13,7 +13,7 @@ try:
|
||||||
if not os.getenv("DISABLE_QT5_COMPAT"):
|
if not os.getenv("DISABLE_QT5_COMPAT"):
|
||||||
print("Running with temporary Qt5 compatibility shims.")
|
print("Running with temporary Qt5 compatibility shims.")
|
||||||
print("Run with DISABLE_QT5_COMPAT=1 to confirm compatibility with Qt6.")
|
print("Run with DISABLE_QT5_COMPAT=1 to confirm compatibility with Qt6.")
|
||||||
from . import compat # needs to be imported first
|
from . import qt5_compat # needs to be imported first
|
||||||
from .qt6 import *
|
from .qt6 import *
|
||||||
except:
|
except:
|
||||||
from .qt5 import * # type: ignore
|
from .qt5 import * # type: ignore
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
# pylint: skip-file
|
# pylint: skip-file
|
||||||
|
|
||||||
"""
|
"""
|
||||||
PyQt5-only code
|
PyQt5-only audio code
|
||||||
"""
|
"""
|
||||||
|
|
||||||
import wave
|
import wave
|
|
@ -401,6 +401,6 @@ for module, type_to_enum_list in _enum_map:
|
||||||
# Mock the removed PyQt5.Qt module
|
# Mock the removed PyQt5.Qt module
|
||||||
##########################################################################
|
##########################################################################
|
||||||
|
|
||||||
from . import qt5qt
|
from . import qt5_qt_module
|
||||||
|
|
||||||
sys.modules["PyQt5.Qt"] = qt5qt
|
sys.modules["PyQt5.Qt"] = qt5_qt_module
|
|
@ -671,7 +671,7 @@ class RecordDialog(QDialog):
|
||||||
namedtmp("rec.wav"), self.mw, self._parent
|
namedtmp("rec.wav"), self.mw, self._parent
|
||||||
)
|
)
|
||||||
else:
|
else:
|
||||||
from aqt.qt.qt5extra import QtAudioInputRecorder as Qt5Recorder
|
from aqt.qt.qt5_audio import QtAudioInputRecorder as Qt5Recorder
|
||||||
|
|
||||||
self._recorder = Qt5Recorder(namedtmp("rec.wav"), self.mw, self._parent)
|
self._recorder = Qt5Recorder(namedtmp("rec.wav"), self.mw, self._parent)
|
||||||
self._recorder.start(self._start_timer)
|
self._recorder.start(self._start_timer)
|
||||||
|
|
Loading…
Reference in a new issue