Commit Graph
44 Commits
Author SHA1 Message Date
sankalp 732dd9c0ee fix: formating 2026-07-18 14:21:24 +05:45
sankalp 1d3cecc255 fix(dialogs): log exception in wifi password connection timeout handler
except Exception: pass was hiding UI state errors during timeout
handling.
2026-07-18 14:13:56 +05:45
sankalp 2d982cf286 fix(shared): add tick_widget=self to AnimatedScrollable height_animator
Without tick_widget the Animator falls back to GLib.timeout_add which
fires even when the widget is hidden, wasting CPU on invisible scroll
windows (WiFi/BT connection lists).
2026-07-18 14:13:44 +05:45
sankalp a47abda55a fix: resolve wifi crashes, shell injections, race conditions, and add debug mode
- Remove transient NEED_AUTH/DISCONNECTED error paths from wifi connect
- Guard double-callback in connect_wifi_bssid/connect_wifi_with_password
- Shell-quote user paths in wallpaper, screenshot, screenrecorder services
- Fix OSD hide-timer use-after-free and applet_window stale source ID
- Fix brightness poll timer leak on read failure
- Fix spotlight search stale idle source removal
- Lock dbusmenu _cache mutation under _registry_lock
- Fix entry.revision written outside _registry_lock scope
- Add fabric-cli exec wrapper for lock screen (lock_screen.lock())
- Replace hyprlock with lock screen in power menu and dropdown
- Add debug mode toggle in settings (controls log verbosity)
- Add diagnostic logging to globalmenu click chain
2026-07-16 11:47:53 +05:45
sankalp 9eb62d7ea3 feat(config): wire up wallpapers_dir, osd, window_switcher, global_menu settings
- wallpapers_dir: read from config, fallback ~/Pictures/Wallpapers
- osd: skip show_audio_osd/show_brightness_osd when disabled
- window_switcher: skip show_switcher when disabled
- global_menu_cache_enabled: bypass GTK class cache when false
- global_menu_method: control discovery strategies (auto/hyprland/dbus)

All keys added to constants.py defaults, settings UI, and config.toml
2026-07-15 10:31:28 +05:45
sankalp 6f2d0bf444 chore: refactor imports and adopt new utils utilities 2026-07-14 18:45:52 +05:45
sankalp 2d22df94ca refactor: drive UI from service signals, drop redundant polling
- bluetooth.py / wifi.py: remove 5s periodic refresh timers; rely on
  service `changed`/`device-added`/`device-removed`/`notify` signals
- expanded_player.py: remove 500ms metadata poll; rely on
  `meta-change`/`artwork-change` signals
- player.py (notch): connect previously dangling `artwork-change` handler
- popup_win.py: silence harmless "nothing connected" warning on destroy()

No behaviour change; eliminates dead timers and log spam.
2026-07-14 13:46:21 +05:45
sankalp f72542a231 refactor: log swallowed exceptions across src/
Replace silent swallow-excepts (pass/return/continue) with
logger.warning recording the caught error, preserving behaviour.
2026-07-14 13:02:21 +05:45
sankalp 1dcce186a7 refactor(src/shared): simplify active_ids set comprehension 2026-07-14 02:35:44 +05:45
sankalp 112f4b1039 refactor(services): convert weather + gamemode to Fabric services
Weather: move networking, caching and scheduling out of the Weather widget
into a WeatherService singleton. Reuse one httpx.Client for the app lifetime,
drop the 4-worker pool and the multi-entry dict caches (single-value fields),
query Nominatim only on location change, remove debounce and the /tmp-style
polling. Widget now observes the `updated` signal and never hits the network.

GameMode: turn the standalone CLI script into a GameModeService (Service
singleton) exposing an `enabled` Property and `changed` signal. Drive Hyprland
via `hyprctl eval hl.config(...)` instead of the deprecated `hyprctl keyword`
batch (rejected under the Lua config in Hyprland 0.55+), read state via
`hl.get_config`, and keep `hyprctl reload` for disable. Fix game-mode state
parsing so unrecognized `hl.get_config` output no longer falsely reports
active. BatteryWidget's GameModeButton now subscribes to the service.

Remove now-unused LOCATION_CACHE_TIMEOUT.
2026-07-14 00:37:52 +05:45
sankalp f3f17bb5fc refactor(services): split screen capture into screenshot + recorder services
Split the monolithic ScreenCapture service into focused Screenshot and
ScreenRecorder services behind a pluggable capture backend.

- Add shared/capture.py: CaptureBackend abstraction + HyprlandCaptureBackend
  (hyprshot/grim/slurp/wf-recorder) and reusable CaptureNotifier
- Add services/screenshot.py and services/screenrecorder.py with Fabric
  properties/signals; recording state kept in memory (no /tmp files)
- Keep services/screencapture.py as a backwards-compatible facade so
  existing widgets and signals keep working
- Resolve monitors via Hyprland IPC helpers in services/modus.py instead of
  spawning `hyprctl monitors -j` per capture
- Implement real window recording (slurp window boxes) and split the
  record-window / record-region UI mappings
- Register screenshot_service / screen_recorder_service singletons
- Remove dead src/utils/inhibit.py duplicate; minor modus.lua quoting fix
2026-07-13 23:52:32 +05:45
sankalp 54ff85ffc9 fix(services/spotlight): improve MPRIS artwork handling and scope keyword searches to single plugin
- mpris: native MediaArt cache lookup, dedupe play/pause emission, safe
  cleanup, artwork polling for already-playing browser players, drop
  os.system seek fallback
- spotlight: scope plugin keyword and detect() matches to a single plugin
  via search_single instead of global search; register clipboard keywords
  (clip/clipboard)
2026-07-13 22:20:19 +05:45
sankalp 66632f0989 refactor(core): rename APP_NAME to 'modus', cleanup shared widgets
- Change APP_NAME from 'modus1' to 'modus' in shared/data.py
- Remove unused flat_scale widget
- Add missing imports in animator and customrevealer
- Delete src/utils/uinput.py (unused)
- Remove unused import in utils/functions.py
2026-07-12 20:18:05 +05:45
sankalp 096231bc44 style: enforce consistent codestyle via ruff config and auto-fixes
- Configure ruff: isort, pyupgrade, bugbear, flake8 rules
- Auto-fix import sorting, redundant parens, exception chaining
- Remove from __future__ import annotations (Python 3.13+)
- Convert debug print() to logger calls
- Fix typo applicaiton → application in icon_resolver
- Remove bare returns in animator setters
- Move TYPE_CHECKING imports to runtime where used at runtime
2026-07-12 18:38:13 +05:45
sankalp afd826d0c0 refactor(services): enhance TodoService with callbacks, UUID IDs, and UTF‑8 file handling 2026-07-12 09:33:41 +05:45
sankalp 0fbccca46e refactor: add stop_animation method to SlideRevealer and integrate with destroy 2026-07-09 22:33:33 +05:45
sankalp de9ab766c4 refactor!(shared): remove unused constants and deprecated methods 2026-07-09 18:56:05 +05:45
sankalp 06be28535a refactor: clean up service implementations and remove dead code 2026-07-08 12:24:39 +05:45
sankalp 7fdb3be0b3 refactor(config): replace get_relative_path with toml_file 2026-07-06 17:38:29 +05:45
sankalp 8bf198f745 feat(battery): replace Battery() with Battery.get_initial() for proper initialization 2026-07-05 23:04:52 +05:45
sankalp 5240abd23d refactor(src/shared/widgets): replace @cache with @lru_cache(maxsize=512) for progress-related functions 2026-07-05 20:56:31 +05:45
sankalp 3e8dde6f35 refactor: adjust layer and event handling in dismissal UI 2026-07-04 21:22:28 +05:45
sankalp 89eb8db97b feat(config): switch configuration parsing to TOML and add google_lens support 2026-07-04 06:29:38 +05:45
sankalp f68c076d98 chore(src/shared): update dialog titles and import ordering 2026-07-04 01:25:24 +05:45
sankalp ae29326401 refactor(src/shared/widgets/flat_scale): simplify flat_scale drawing and add draw_value flag 2026-07-04 00:33:31 +05:45
sankalp 7dad927f21 feat(src/shared/window): add animate parameter to control scroll animation 2026-07-03 20:52:56 +05:45
sankalp 3a05e123e7 refactor(src/shared): adjust default bezier curve for smoother scrolling
Use more balanced control points to improve animation responsiveness and visual flow
2026-06-24 12:53:11 +05:45
sankalp c34ade9423 fix(src/shared/window): suppress harmless disconnect errors in logger
Reduce noise by only logging disconnect errors that aren't "nothing connected"
2026-06-17 05:32:07 +05:45
sankalp f4d0f46e35 feat(src/shared/dialogs): set wmclass for about dialog
Ensure the About dialog specifies a proper WM_CLASS for correct window identification
2026-06-17 05:31:50 +05:45
sankalp 1aed6ea816 refactor(src/shared): replace print statements with logger.error
Use centralized logging instead of stdout prints to improve observability and consistency
2026-06-17 05:21:02 +05:45
sankalp 13c3036a62 feat(src/shared/window): add snap_to_size method for instant resizing without animation
Allows resizing to a specific height instantly without animation
2026-06-17 05:14:46 +05:45
sankalp 929e525589 feat(src/shared/window): addanimated scrollable window and close_applet cleanup
Introduce Animator‑driven height transitions for smoother scrolling and ensure proper cleanup when the applet window closes.
2026-06-17 04:52:26 +05:45
sankalp bceebd646c feat(src/shared/widgets):add bezier_curve property and trigger animation on active 2026-06-17 04:52:09 +05:45
sankalp 9231460c6b chore(src/shared/styles): delete legacytheme and widget CSS 2026-06-17 03:20:29 +05:45
sankalp fa2c157663 fix(src/shared/window): fix window visibility check and margin duplication
Fixes logic error causing popup window to be created when invisible and prevents redundant margin updates.
2026-06-17 03:18:06 +05:45
sankalp bffedbe3ae feat(src/shared/styles): narrowmin-width to match standard player width
Reduced min-width to align with design specifications and maintain consistent UI across platforms.
2026-06-17 03:17:49 +05:45
sankalp 87884eef09 feat(src/shared): add flat scale widget and smooth-switch styling
Implement animated flat scale widget with CSS styling and smooth-switch UI enhancements
2026-06-17 01:46:19 +05:45
sankalp 0c266e9150 refactor(src/shared/styles): replace var(--radius-*) with apply(radius-*) throughout shared styles
Use apply() to align with the updated CSS variable system and ensure consistent radius theming
2026-06-16 22:24:02 +05:45
sankalp 5502f85dd1 refactor(src/shared/styles): replace hardcoded CSS values with design token variables
Introduce consistent design tokens for radii and colors, replacing alpha() and hardcoded values with theme variables for easier theming and maintenance.

- New Features:   - Add CSS variable usage for radii (var(--radius-*)) and color tokens (@border-subtle, @text-main, @accent)
- Enhancements:
  - Replace hardcoded border, radius, and color definitions with variable references
  - Align styling with the project's theme system
- Bug Fixes:
  - No bug fixes included
2026-05-14 15:31:01 +05:45
sankalp 704c8b229c feat(src/shared): introduce settings window and refine visibility configurationAdd a dedicated settings window with full CSS styling and improve UI consistency
- New Settings window implementation with styling and layout
- Updated visibility configuration to use direct configuration keys
- Simplified layer‑shell positioning logic and improved reliability

Enhancements- Refactored MouseCapture geometry calculations for cleaner code
- Integrated size‑allocate handler to maintain input region sync
- Added global About window singleton and improved toggle behavior

Bug Fixes
- Fixed potential index errors in MouseCapture coordinate calculations- Resolved missing imports and path issues for icon assets
2026-05-03 22:06:35 +05:45
sankalp 6577c19dcb related to memory leak 2026-04-23 16:09:52 +05:45
sankalp 7eb21daf2f hope it fix memory leak 2026-04-22 21:18:39 +05:45
sankalp 30a8ab5510 refactor(src/shared/styles): drop unused color definitionsRemoved the colors.css file that defined unused theme variables, reducing bundle size and eliminating stale style references.
- New Features: —
- Enhancements: removed unused color definitions
- Bug Fixes: —
2026-04-10 18:41:57 +05:45
sankalp e4813f35a0 feat(root): implement dynamic todo list refresh and UI enhancements
This change adds a mechanism to refresh the todo list dynamically when the underlying service updates, improving UI responsiveness and user experience. It also updates documentation and removes deprecated files.

- New Features:
  - Added `_refresh_todos` method to rebuild the todo list when `get_todo_service().todos` changes.
  - Introduced `TodoListCapture` class for mouse capture handling of the todo list window.
- Enhancements:
  - Updated README with corrected image paths, installation tips, and manual installation commands.
  - Introduced `start.py` to launch the application or lock mode.
  - Removed deprecated `config.json` and `debug_memory.py`.
- Bug Fixes:
  - Fixed lock screen screenshot path in README.
2026-04-10 17:11:32 +05:45