mirror of
https://github.com/AgentSeal/codeburn.git
synced 2026-11-29 02:39:13 +00:00
A locked session or sleeping displays kept the refresh loop spawning a Node process every two minutes for a figure nobody could look at. The mac stops on screensDidSleep and refreshes on didWake; this is the Windows half of that. The notifications need a window to be delivered to, so there is a hidden one on a thread of its own with its own message pump, in the shape of the dock's cursor thread. It registers for session change (lock and unlock), for the console display state, and for suspend and resume. A message-only window would not do here: WM_POWERBROADCAST is not delivered to one. The loop keeps its timer while the machine is unattended and skips the fetch, so the first tick after the screens come back finds fresh numbers even if a notification was never delivered. Waking, unlocking or the screens coming back refreshes at once, in every mode but Manual, as on the mac. An open popover clears a latched flag on its own, since it is proof the screens are on. |
||
|---|---|---|
| .. | ||
| capabilities | ||
| icons | ||
| src | ||
| build.rs | ||
| Cargo.lock | ||
| Cargo.toml | ||
| tauri.conf.json | ||