mirror of
https://github.com/ankitects/anki.git
synced 2025-09-24 16:56:36 -04:00
don't hard code models
This commit is contained in:
parent
0081ff32d0
commit
9fd4000c0b
1 changed files with 3 additions and 8 deletions
|
@ -176,14 +176,9 @@ class AddModel(QDialog):
|
|||
self.dialog = ankiqt.forms.addmodel.Ui_AddModel()
|
||||
self.dialog.setupUi(self)
|
||||
self.models = {}
|
||||
for name in (
|
||||
"Basic",
|
||||
"Japanese",
|
||||
"English",
|
||||
"Cantonese",
|
||||
"Mandarin",
|
||||
"Heisig"):
|
||||
# hard code the order so that most common come first
|
||||
names = stdmodels.models.keys()
|
||||
names.sort()
|
||||
for name in names:
|
||||
m = stdmodels.byName(name)
|
||||
item = QListWidgetItem(m.name)
|
||||
self.dialog.models.addItem(item)
|
||||
|
|
Loading…
Reference in a new issue