mirror of
https://github.com/ankitects/anki.git
synced 2025-12-13 06:46:55 -05:00
fix browser updateTitle()
This commit is contained in:
parent
1c5f94d46f
commit
c1e6149a1b
2 changed files with 6 additions and 7 deletions
|
|
@ -14,6 +14,7 @@ from typing import Callable, List, Optional, Sequence, Tuple, Union, cast
|
||||||
import anki
|
import anki
|
||||||
import aqt
|
import aqt
|
||||||
import aqt.forms
|
import aqt.forms
|
||||||
|
from anki.lang import without_unicode_isolation
|
||||||
from anki.cards import Card
|
from anki.cards import Card
|
||||||
from anki.collection import Collection
|
from anki.collection import Collection
|
||||||
from anki.consts import *
|
from anki.consts import *
|
||||||
|
|
@ -820,10 +821,10 @@ class Browser(QMainWindow):
|
||||||
def updateTitle(self):
|
def updateTitle(self):
|
||||||
selected = len(self.form.tableView.selectionModel().selectedRows())
|
selected = len(self.form.tableView.selectionModel().selectedRows())
|
||||||
cur = len(self.model.cards)
|
cur = len(self.model.cards)
|
||||||
print("fixme: browser updateTitle()")
|
|
||||||
self.setWindowTitle(
|
self.setWindowTitle(
|
||||||
"Browse (%(cur)d cards shown; %(sel)s)"
|
without_unicode_isolation(
|
||||||
% {"cur": cur, "sel": self.col.tr(TR.BROWSING_SELECTED, count=selected)}
|
tr(TR.BROWSING_WINDOW_TITLE, total=cur, selected=selected)
|
||||||
|
)
|
||||||
)
|
)
|
||||||
return selected
|
return selected
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -114,7 +114,5 @@ browsing-note-deleted = { $count ->
|
||||||
[one] { $count } note deleted.
|
[one] { $count } note deleted.
|
||||||
*[other] { $count } notes deleted.
|
*[other] { $count } notes deleted.
|
||||||
}
|
}
|
||||||
browsing-selected = { $count ->
|
browsing-window-title = Browse ({ $selected } of { $total } cards selected)
|
||||||
[one] { $count } selected
|
|
||||||
*[other] { $count } selected
|
|
||||||
}
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue