mirror of
https://github.com/ankitects/anki.git
synced 2025-09-20 15:02:21 -04:00
Used ngettext on some strings
This commit is contained in:
parent
42a23a8f55
commit
4d348544f9
1 changed files with 6 additions and 4 deletions
|
@ -430,12 +430,14 @@ class EditDeck(QMainWindow):
|
|||
self.dialog.tagList.setCurrentIndex(0)
|
||||
|
||||
def updateFilterLabel(self):
|
||||
self.setWindowTitle(_("Browser (%(cur)d "
|
||||
"of %(tot)d cards shown; %(sel)d selected)") %
|
||||
selected = len(self.dialog.tableView.selectionModel().selectedRows())
|
||||
self.setWindowTitle(ngettext("Browser (%(cur)d "
|
||||
"of %(tot)d card shown; %(sel)s)", "Browser (%(cur)d "
|
||||
"of %(tot)d cards shown; %(sel)s)", self.deck.cardCount) %
|
||||
{
|
||||
"cur": len(self.model.cards),
|
||||
"tot": self.deck.cardCount,
|
||||
"sel": len(self.dialog.tableView.selectionModel().selectedRows())
|
||||
"sel": ngettext("%d selected", "%d selected", selected) % selected
|
||||
})
|
||||
|
||||
def onEvent(self):
|
||||
|
@ -871,7 +873,7 @@ where id in %s""" % ids2str(sf))
|
|||
self.updateSearch()
|
||||
self.updateAfterCardChange()
|
||||
if changed is not None:
|
||||
ui.utils.showInfo(_("%(a)d of %(b)d facts updated") % {
|
||||
ui.utils.showInfo(ngettext("%(a)d of %(b)d fact updated", "%(a)d of %(b)d facts updated", len(sf)) % {
|
||||
'a': changed,
|
||||
'b': len(sf),
|
||||
}, parent=self)
|
||||
|
|
Loading…
Reference in a new issue