mirror of
https://github.com/LorenEteval/Furious.git
synced 2026-10-06 22:08:11 +03:00
Fix "ADMINISTRATOR_NAME" is not retranslated
Signed-off-by: Loren Eteval <loren.eteval@proton.me>
This commit is contained in:
@@ -213,5 +213,4 @@ class SystemTrayIcon(
|
||||
self.setDisconnectedIcon()
|
||||
|
||||
def retranslate(self):
|
||||
# Nothing to do
|
||||
pass
|
||||
self.setCustomToolTip()
|
||||
|
||||
@@ -111,6 +111,7 @@ class AppMainWindow(AppQMainWindow):
|
||||
self.setWindowTitle(f'{_(APPLICATION_NAME)} ({_(ADMINISTRATOR_NAME)})')
|
||||
else:
|
||||
self.setWindowTitle(f'{_(APPLICATION_NAME)}')
|
||||
|
||||
# TODO: Need this?
|
||||
# self.setAttribute(QtCore.Qt.WidgetAttribute.WA_ShowWithoutActivating)
|
||||
|
||||
@@ -579,6 +580,12 @@ class AppMainWindow(AppQMainWindow):
|
||||
f'{size.toTuple()}'
|
||||
)
|
||||
|
||||
def retranslate(self):
|
||||
if SystemRuntime.isAdmin():
|
||||
self.setWindowTitle(f'{_(APPLICATION_NAME)} ({_(ADMINISTRATOR_NAME)})')
|
||||
else:
|
||||
self.setWindowTitle(f'{_(APPLICATION_NAME)}')
|
||||
|
||||
def cleanup(self):
|
||||
AppSettings.set('AppMainWindowGeometry', self.saveGeometry())
|
||||
AppSettings.set('AppMainWindowState', self.saveState())
|
||||
|
||||
Reference in New Issue
Block a user