Dark mode will be decided based on itself in admin mode

Signed-off-by: Loren Eteval <loren.eteval@proton.me>
This commit is contained in:
Loren Eteval
2025-12-02 15:07:25 +08:00
parent fbbe57cc17
commit d1ce01e7bc
+5 -3
View File
@@ -279,9 +279,11 @@ class Application(ApplicationFactory, SingletonApplication):
return backgroudColor.lightness() < 128
@staticmethod
def isDarkModeEnabled():
return AppSettings.isStateON_('DarkMode')
def isDarkModeEnabled(self):
if not SystemRuntime.isAdmin():
return AppSettings.isStateON_('DarkMode')
else:
return self.isDarkMode()
def switchToDarkMode(self):
self.setStyleSheet(qdarkstyle.load_stylesheet_pyside6())