Skip to content

Commit dd6facc

Browse files
committed
Fix translations (#418)
1 parent e2bd2d6 commit dd6facc

2 files changed

Lines changed: 5 additions & 5 deletions

File tree

OpenNumismat/EditCoinDialog/ExtTable.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
from PySide6.QtCore import Qt, QDate, QLocale, QTimer, QSettings, QT_TRANSLATE_NOOP
22
from PySide6.QtGui import QStandardItemModel, QStandardItem
3-
from PySide6.QtWidgets import QCheckBox, QHBoxLayout, QMessageBox, QPushButton, QTableView, QVBoxLayout
3+
from PySide6.QtWidgets import QApplication, QCheckBox, QHBoxLayout, QMessageBox, QPushButton, QTableView, QVBoxLayout
44

55
from OpenNumismat.Collection.CollectionFields import FieldTypes as Type
66
from OpenNumismat.EditCoinDialog.BaseFormLayout import BaseFormLayout, FormItem
@@ -306,7 +306,7 @@ def _format_data(self, field, data):
306306
text = data
307307
for act, title in self.Actions:
308308
if act == data:
309-
text = title
309+
text = QApplication.translate("PriceAction", title)
310310
break
311311
else:
312312
text = str(data)

OpenNumismat/EditCoinDialog/FormItems.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1388,11 +1388,11 @@ def __init__(self, parent=None):
13881388

13891389
for code, title in self.Actions:
13901390
if code == 'buy':
1391-
self.addItem(statusIcon('owned'), title, code)
1391+
self.addItem(statusIcon('owned'), QApplication.translate("PriceAction", title), code)
13921392
elif code == 'sell':
1393-
self.addItem(statusIcon('sold'), title, code)
1393+
self.addItem(statusIcon('sold'), QApplication.translate("PriceAction", title), code)
13941394
elif code == 'auction':
1395-
self.addItem(statusIcon('pass'), title, code)
1395+
self.addItem(statusIcon('pass'), QApplication.translate("PriceAction", title), code)
13961396
else:
13971397
self.addItem(title, code)
13981398

0 commit comments

Comments
 (0)