mirror of
https://github.com/ankitects/anki.git
synced 2025-09-18 22:12:21 -04:00
Remove actionCreateFilteredDeck2 and use modifier
This commit is contained in:
parent
7fc32db0c9
commit
16462941ab
3 changed files with 9 additions and 20 deletions
|
@ -24,8 +24,6 @@ browsing-change-to = Change { $val } to:
|
||||||
browsing-clear-unused = Clear Unused
|
browsing-clear-unused = Clear Unused
|
||||||
browsing-clear-unused-tags = Clear Unused Tags
|
browsing-clear-unused-tags = Clear Unused Tags
|
||||||
browsing-created = Created
|
browsing-created = Created
|
||||||
browsing-create-filtered-deck = Create Filtered Deck...
|
|
||||||
browsing-create-filtered-deck_2 = Create Filtered Deck (2nd Filter)...
|
|
||||||
browsing-ctrlandshiftande = Ctrl+Shift+E
|
browsing-ctrlandshiftande = Ctrl+Shift+E
|
||||||
browsing-current-deck = Current Deck
|
browsing-current-deck = Current Deck
|
||||||
browsing-current-note-type = Current note type:
|
browsing-current-note-type = Current note type:
|
||||||
|
|
|
@ -489,9 +489,7 @@ class Browser(QMainWindow):
|
||||||
if not isMac:
|
if not isMac:
|
||||||
f.actionClose.setVisible(False)
|
f.actionClose.setVisible(False)
|
||||||
qconnect(f.actionCreateFilteredDeck.triggered, self.createFilteredDeck)
|
qconnect(f.actionCreateFilteredDeck.triggered, self.createFilteredDeck)
|
||||||
qconnect(f.actionCreateFilteredDeck2.triggered, self.createFilteredDeck2)
|
f.actionCreateFilteredDeck.setShortcuts(["Ctrl+G", "Ctrl+Alt+G"])
|
||||||
if self.mw.col.schedVer() == 1:
|
|
||||||
f.menuEdit.removeAction(f.actionCreateFilteredDeck2)
|
|
||||||
# notes
|
# notes
|
||||||
qconnect(f.actionAdd.triggered, self.mw.onAddCard)
|
qconnect(f.actionAdd.triggered, self.mw.onAddCard)
|
||||||
qconnect(f.actionAdd_Tags.triggered, lambda: self.addTags())
|
qconnect(f.actionAdd_Tags.triggered, lambda: self.addTags())
|
||||||
|
@ -1199,11 +1197,13 @@ where id in %s"""
|
||||||
|
|
||||||
def createFilteredDeck(self) -> None:
|
def createFilteredDeck(self) -> None:
|
||||||
search = self.form.searchEdit.lineEdit().text()
|
search = self.form.searchEdit.lineEdit().text()
|
||||||
aqt.dialogs.open("DynDeckConfDialog", self.mw, search=search)
|
if (
|
||||||
|
self.mw.col.schedVer() != 1
|
||||||
def createFilteredDeck2(self) -> None:
|
and self.mw.app.keyboardModifiers() & Qt.AltModifier
|
||||||
search = self.form.searchEdit.lineEdit().text()
|
):
|
||||||
aqt.dialogs.open("DynDeckConfDialog", self.mw, search_2=search)
|
aqt.dialogs.open("DynDeckConfDialog", self.mw, search_2=search)
|
||||||
|
else:
|
||||||
|
aqt.dialogs.open("DynDeckConfDialog", self.mw, search=search)
|
||||||
|
|
||||||
# Preview
|
# Preview
|
||||||
######################################################################
|
######################################################################
|
||||||
|
|
|
@ -232,7 +232,6 @@
|
||||||
<addaction name="actionClose"/>
|
<addaction name="actionClose"/>
|
||||||
<addaction name="separator"/>
|
<addaction name="separator"/>
|
||||||
<addaction name="actionCreateFilteredDeck"/>
|
<addaction name="actionCreateFilteredDeck"/>
|
||||||
<addaction name="actionCreateFilteredDeck2"/>
|
|
||||||
</widget>
|
</widget>
|
||||||
<widget class="QMenu" name="menuJump">
|
<widget class="QMenu" name="menuJump">
|
||||||
<property name="title">
|
<property name="title">
|
||||||
|
@ -588,20 +587,12 @@
|
||||||
</action>
|
</action>
|
||||||
<action name="actionCreateFilteredDeck">
|
<action name="actionCreateFilteredDeck">
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>BROWSING_CREATE_FILTERED_DECK</string>
|
<string>QT_MISC_CREATE_FILTERED_DECK</string>
|
||||||
</property>
|
</property>
|
||||||
<property name="shortcut">
|
<property name="shortcut">
|
||||||
<string notr="true">Ctrl+G</string>
|
<string notr="true">Ctrl+G</string>
|
||||||
</property>
|
</property>
|
||||||
</action>
|
</action>
|
||||||
<action name="actionCreateFilteredDeck2">
|
|
||||||
<property name="text">
|
|
||||||
<string>BROWSING_CREATE_FILTERED_DECK_2</string>
|
|
||||||
</property>
|
|
||||||
<property name="shortcut">
|
|
||||||
<string notr="true">Ctrl+Shift+G</string>
|
|
||||||
</property>
|
|
||||||
</action>
|
|
||||||
</widget>
|
</widget>
|
||||||
<resources>
|
<resources>
|
||||||
<include location="icons.qrc"/>
|
<include location="icons.qrc"/>
|
||||||
|
|
Loading…
Reference in a new issue