mirror of
https://github.com/ankitects/anki.git
synced 2025-12-13 06:46:55 -05:00
Turn on check_untyped_defs for aqt.taglimit
* Add type hints taglimit * Turn on check_untyped_defs for aqt.taglimit
This commit is contained in:
parent
ca8265a695
commit
7356756868
2 changed files with 5 additions and 1 deletions
|
|
@ -1,5 +1,6 @@
|
||||||
# Copyright: Ankitects Pty Ltd and contributors
|
# Copyright: Ankitects Pty Ltd and contributors
|
||||||
# License: GNU AGPL, version 3 or later; http://www.gnu.org/copyleft/agpl.html
|
# License: GNU AGPL, version 3 or later; http://www.gnu.org/copyleft/agpl.html
|
||||||
|
from typing import List, Optional
|
||||||
|
|
||||||
import aqt
|
import aqt
|
||||||
from aqt.qt import *
|
from aqt.qt import *
|
||||||
|
|
@ -9,8 +10,9 @@ from aqt.utils import restoreGeom, saveGeom
|
||||||
class TagLimit(QDialog):
|
class TagLimit(QDialog):
|
||||||
def __init__(self, mw, parent):
|
def __init__(self, mw, parent):
|
||||||
QDialog.__init__(self, parent, Qt.Window)
|
QDialog.__init__(self, parent, Qt.Window)
|
||||||
|
self.tags: Union[str, List] = ""
|
||||||
self.mw = mw
|
self.mw = mw
|
||||||
self.parent = parent
|
self.parent: Optional[QWidget] = parent
|
||||||
self.deck = self.parent.deck
|
self.deck = self.parent.deck
|
||||||
self.dialog = aqt.forms.taglimit.Ui_Dialog()
|
self.dialog = aqt.forms.taglimit.Ui_Dialog()
|
||||||
self.dialog.setupUi(self)
|
self.dialog.setupUi(self)
|
||||||
|
|
|
||||||
|
|
@ -76,3 +76,5 @@ check_untyped_defs=true
|
||||||
check_untyped_defs=true
|
check_untyped_defs=true
|
||||||
[mypy-aqt.deckconf]
|
[mypy-aqt.deckconf]
|
||||||
check_untyped_defs=true
|
check_untyped_defs=true
|
||||||
|
[mypy-aqt.taglimit]
|
||||||
|
check_untyped_defs=true
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue