mirror of
https://github.com/AgentSeal/codeburn.git
synced 2026-11-24 13:57:02 +00:00
The rail was laid out against whichever monitor the window happened to be on and clamped to that one work area, so it could not be dragged onto a second display and a relaunch would not have found it there. A placement now names its display, the way the mac keeps its rail on the screen it was left on. The name is a hint rather than an address: a display that is gone falls back to the one the window is on, which is what unplugging a monitor should do. A drag takes the monitor list once, at the press, and then picks the display under the pointer by arithmetic; asking the window for its monitors sixty times a second would be sixty trips through the event loop, and the mac's own drag does the same containment test against a captured screen list. Display changes reach the rail through the cursor thread that is already running: once a second it compares a fingerprint of the desktop (display count, virtual screen bounds, primary work area), which costs three user32 reads and no event loop, and lays the rail out again when it moves. That is the counterpart of the mac's didChangeScreenParameters. The new frame is announced, because the page paints into the frame it was last handed and a window that moves on this side is otherwise invisible to it. |
||
|---|---|---|
| .. | ||
| dist | ||
| Scripts | ||
| src | ||
| src-tauri | ||
| .gitignore | ||
| DEVELOPMENT.md | ||
| index.html | ||
| package-lock.json | ||
| package.json | ||
| tokens.json | ||
| tsconfig.json | ||
| vite.config.ts | ||