feat(services): streamline DBus menu caching and notification handling

- Consolidate logger disabling, cache empty menus with TTL, and move name resolution to a dedicated resolver to reduce duplication and improve performance
This commit is contained in:
sankalp committed 2026-06-24 12:52:36 +05:45
1 parent 8ec0ae267d
commit 0594759fed
6 files changed
+161 -75

No files matched your search

+4 -7
View File
@@ -316,13 +316,10 @@ class ModusService(Service):
self.current_active_app_name = "Finder"
return
name = wmclass if wmclass else title
if name:
name = str(name).title()
if "." in name:
name = name.split(".")[-1]
else:
name = "Finder"
# Delegate name resolution to app_name_resolver (lazy import to avoid circular)
from utils.app_name_resolver import app_name_resolver
name = app_name_resolver.format_app_name(title, wmclass)
# Set wm_class FIRST so that signal handlers reading it get the new value
self.current_active_wm_class = wmclass