mirror of
https://github.com/ankitects/anki.git
synced 2025-09-23 08:22:24 -04:00
warn when cram deck empty
This commit is contained in:
parent
eb491a7a55
commit
bf64e67913
1 changed files with 6 additions and 2 deletions
|
@ -5,7 +5,7 @@
|
|||
from aqt.qt import *
|
||||
import aqt
|
||||
from anki.utils import ids2str
|
||||
from aqt.utils import showInfo, showWarning, openHelp, getOnlyText
|
||||
from aqt.utils import showInfo, showWarning, openHelp, getOnlyText, askUser
|
||||
from operator import itemgetter
|
||||
|
||||
class DeckConf(QDialog):
|
||||
|
@ -116,7 +116,11 @@ class DeckConf(QDialog):
|
|||
def accept(self):
|
||||
if not self.saveConf():
|
||||
return
|
||||
self.mw.col.sched.rebuildDyn()
|
||||
if not self.mw.col.sched.rebuildDyn():
|
||||
if askUser(_("""\
|
||||
The provided search did not match any cards. Would you like to revise \
|
||||
it?""")):
|
||||
return
|
||||
self.mw.reset()
|
||||
QDialog.accept(self)
|
||||
|
||||
|
|
Loading…
Reference in a new issue