mirror of
https://github.com/ankitects/anki.git
synced 2025-09-18 14:02:21 -04:00
Use our translation of 'Discard' (#2920)
* Use our translation of 'Discard' * Update qt/aqt/utils.py (dae)
This commit is contained in:
parent
f544bdd041
commit
dbfb46e6c8
2 changed files with 4 additions and 0 deletions
|
@ -4,6 +4,7 @@ actions-any-selected = Any selected
|
|||
actions-cancel = Cancel
|
||||
actions-choose = Choose
|
||||
actions-close = Close
|
||||
actions-discard = Discard
|
||||
actions-copy = Copy
|
||||
actions-create-copy = Create Copy
|
||||
actions-custom-study = Custom Study
|
||||
|
|
|
@ -164,6 +164,9 @@ class MessageBox(QMessageBox):
|
|||
b = self.addButton(button, QMessageBox.ButtonRole.ActionRole)
|
||||
elif isinstance(button, QMessageBox.StandardButton):
|
||||
b = self.addButton(button)
|
||||
# a translator has complained the default Qt translation is inappropriate, so we override it
|
||||
if button == QMessageBox.StandardButton.Discard:
|
||||
b.setText(tr.actions_discard())
|
||||
elif isinstance(button, tuple):
|
||||
b = self.addButton(button[0], button[1])
|
||||
else:
|
||||
|
|
Loading…
Reference in a new issue