mirror of
https://github.com/ankitects/anki.git
synced 2025-09-24 08:46:37 -04:00
Merge branch 'master' of https://github.com/hssm/anki
This commit is contained in:
commit
c89199aee9
2 changed files with 12 additions and 1 deletions
|
@ -756,6 +756,17 @@ select id from cards where odue > 0 and (type=1 or queue=2) and not odid""")
|
||||||
"Fixed %d cards with invalid properties.", cnt) % cnt)
|
"Fixed %d cards with invalid properties.", cnt) % cnt)
|
||||||
self.db.execute("update cards set odue=0 where id in "+
|
self.db.execute("update cards set odue=0 where id in "+
|
||||||
ids2str(ids))
|
ids2str(ids))
|
||||||
|
# cards with odid set when not in a dyn deck
|
||||||
|
dids = [id for id in self.decks.allIds() if not self.decks.isDyn(id)]
|
||||||
|
ids = self.db.list("""
|
||||||
|
select id from cards where odid > 0 and did in %s""" % ids2str(dids))
|
||||||
|
if ids:
|
||||||
|
cnt = len(ids)
|
||||||
|
problems.append(
|
||||||
|
ngettext("Fixed %d card with invalid properties.",
|
||||||
|
"Fixed %d cards with invalid properties.", cnt) % cnt)
|
||||||
|
self.db.execute("update cards set odid=0, odue=0 where id in "+
|
||||||
|
ids2str(ids))
|
||||||
# tags
|
# tags
|
||||||
self.tags.registerNotes()
|
self.tags.registerNotes()
|
||||||
# field cache
|
# field cache
|
||||||
|
|
|
@ -1763,7 +1763,7 @@ class FavouritesLineEdit(QLineEdit):
|
||||||
# name of current saved filter (if query matches)
|
# name of current saved filter (if query matches)
|
||||||
self.name = None
|
self.name = None
|
||||||
self.buttonClicked.connect(self.onClicked)
|
self.buttonClicked.connect(self.onClicked)
|
||||||
self.connect(self, SIGNAL("textEdited(QString)"), self.updateButton)
|
self.connect(self, SIGNAL("textChanged(QString)"), self.updateButton)
|
||||||
|
|
||||||
def resizeEvent(self, event):
|
def resizeEvent(self, event):
|
||||||
buttonSize = self.button.sizeHint()
|
buttonSize = self.button.sizeHint()
|
||||||
|
|
Loading…
Reference in a new issue