mirror of
https://github.com/arsenetar/dupeguru.git
synced 2025-05-08 09:49:51 +00:00
Add missing translation hooks
This commit is contained in:
parent
39d353d073
commit
a93bd3aeee
@ -80,9 +80,9 @@ class ExcludeListDialog(QDialog):
|
|||||||
gridlayout.addWidget(self.testLine, 6, 0)
|
gridlayout.addWidget(self.testLine, 6, 0)
|
||||||
|
|
||||||
layout.addLayout(gridlayout)
|
layout.addLayout(gridlayout)
|
||||||
self.inputLine.setPlaceholderText("Type a python regular expression here...")
|
self.inputLine.setPlaceholderText(tr("Type a python regular expression here..."))
|
||||||
self.inputLine.setFocus()
|
self.inputLine.setFocus()
|
||||||
self.testLine.setPlaceholderText("Type a file system path or filename here...")
|
self.testLine.setPlaceholderText(tr("Type a file system path or filename here..."))
|
||||||
self.testLine.setClearButtonEnabled(True)
|
self.testLine.setClearButtonEnabled(True)
|
||||||
|
|
||||||
# --- model --> view
|
# --- model --> view
|
||||||
|
@ -7,6 +7,8 @@ from PyQt5.QtGui import QFont, QFontMetrics, QIcon, QColor
|
|||||||
|
|
||||||
from qtlib.column import Column
|
from qtlib.column import Column
|
||||||
from qtlib.table import Table
|
from qtlib.table import Table
|
||||||
|
from hscommon.trans import trget
|
||||||
|
tr = trget("ui")
|
||||||
|
|
||||||
|
|
||||||
class ExcludeListTable(Table):
|
class ExcludeListTable(Table):
|
||||||
@ -31,7 +33,7 @@ class ExcludeListTable(Table):
|
|||||||
if role == Qt.CheckStateRole and row.markable:
|
if role == Qt.CheckStateRole and row.markable:
|
||||||
return Qt.Checked if row.marked else Qt.Unchecked
|
return Qt.Checked if row.marked else Qt.Unchecked
|
||||||
if role == Qt.ToolTipRole and not row.markable:
|
if role == Qt.ToolTipRole and not row.markable:
|
||||||
return "Compilation error: " + row.get_cell_value("error")
|
return tr("Compilation error: ") + row.get_cell_value("error")
|
||||||
if role == Qt.DecorationRole and not row.markable:
|
if role == Qt.DecorationRole and not row.markable:
|
||||||
return QIcon.fromTheme("dialog-error", QIcon(":/error"))
|
return QIcon.fromTheme("dialog-error", QIcon(":/error"))
|
||||||
return None
|
return None
|
||||||
|
Loading…
x
Reference in New Issue
Block a user