feat(src/window): switch configuration from JSON to TOML and refactor pinned apps handling

This commit is contained in:
sankalp committed 2026-07-04 06:29:01 +05:45
1 parent e5a02015b3
commit 0d11b68add
7 files changed
+333 -41

No files matched your search

+12
View File
@@ -15,6 +15,8 @@ from window.controlcenter.main import ModusControlCenter
from window.notification.notification_center import NotificationCenter
from window.panel.components.enhanced_system_tray import apply_enhanced_system_tray
from window.panel.components.globalmenu import GlobalMenu
from window.panel.components.custom_mods import CustomMods
from window.panel.components.google_lens_indicator import GoogleLensIndicator
from window.panel.components.indicators import (
BatteryIndicator,
BluetoothIndicator,
@@ -109,6 +111,8 @@ class Panel(Window):
)
setup_cursor_hover(self.datetime_btn, "pointer")
self.google_lens_indicator = GoogleLensIndicator()
self.custom_mods = CustomMods(parent_window=self)
self.workspace_indicator = WorkspaceIndicator()
self.recording_indicator = RecordingIndicator()
@@ -235,6 +239,10 @@ class Panel(Window):
# Right
right_children = []
if config_data.get("custom_mods", True):
right_children.append(self.custom_mods)
if config_data.get("google_lens", True):
right_children.append(self.google_lens_indicator)
if config_data.get("workspace_indicator", True):
right_children.append(self.workspace_indicator)
@@ -268,6 +276,8 @@ class Panel(Window):
keys = {
"imac_button",
"global_menu",
"google_lens",
"custom_mods",
"workspace_indicator",
"systray",
"battery",
@@ -328,6 +338,8 @@ class Panel(Window):
# Destroy components
for component in [
self.globalmenu,
self.google_lens_indicator,
self.custom_mods,
self.workspace_indicator,
self.recording_indicator,
self.indicators,