mirror of
https://github.com/LorenEteval/Furious.git
synced 2026-10-07 06:18:05 +03:00
Centralize application settings UI
Signed-off-by: Loren Eteval <loren.eteval@proton.me>
This commit is contained in:
@@ -42,6 +42,10 @@ registerAppSettings(
|
||||
'ShowProgressBarWhenConnecting', isBinary=True, default=AppBinarySettings.ON_
|
||||
)
|
||||
registerAppSettings('ShowTabAndSpacesInEditor', isBinary=True)
|
||||
registerAppSettings(
|
||||
'SystemProxyMode',
|
||||
validRange=list(mode.value for mode in AppBuiltinProxyMode),
|
||||
)
|
||||
|
||||
|
||||
class SettingsController:
|
||||
@@ -135,6 +139,14 @@ class SettingsController:
|
||||
cls._setBinary('ForceToLocalhostWhenSettingLocalProxy', enabled)
|
||||
showMBoxNewChangesNextTime()
|
||||
|
||||
@staticmethod
|
||||
def setSystemProxyMode(mode: str):
|
||||
"""Persist how Furious manages the operating-system proxy."""
|
||||
validModes = tuple(item.value for item in AppBuiltinProxyMode)
|
||||
|
||||
if mode in validModes:
|
||||
AppSettings.set('SystemProxyMode', mode)
|
||||
|
||||
@classmethod
|
||||
def setAutoUpdateAssets(cls, enabled: bool):
|
||||
"""Persist automatic core-asset updates."""
|
||||
|
||||
Reference in New Issue
Block a user