-
Notifications
You must be signed in to change notification settings - Fork 0
Layout Lock And Startup
Automatic restore and startup restore solve different problems. Both use the same saved profiles, but their behavior is intentionally different.
Automatic restore is an event-driven desktop guard for one selected profile. Its live On/Off state appears in the tray menu, tray tooltip, app header, sidebar, Dashboard, and Settings.
It can react to:
- Windows Show Desktop
- returning to the desktop after a game or fullscreen app
These triggers can be enabled independently in Settings.
For game safety, an automatic event restore:
- does not launch closed apps
- does not activate every restored window
- does not synthesize keyboard or mouse input
- does not run while a game/fullscreen app is foreground
- does not poll the desktop on a recurring timer
The worker blocks on Windows events and coalesces repeated shell events into one restore request.
Turning Automatic restore on first restores the selected profile. The guard is armed only after that restore reaches a usable result. A paused, failed, or missing-monitor restore leaves it off so the UI never claims protection that is not actually running.
While a restore is active, duplicate tray and app commands are disabled and the live status says Restoring.
Show Desktop minimizes normal application windows. When its trigger is enabled, WindowAutoLayout waits for the shell transition, then restores the already-running managed windows. Tray-hidden apps still need their hidden/minimized recovery options enabled.
The guard recognizes named latency-sensitive games such as Valorant and also treats a true fullscreen foreground window as latency-sensitive. It records the transition, waits until the game is no longer foreground, and cancels the restore if a game/fullscreen window becomes active again.
Startup uses the current user's Run key:
HKCU\Software\Microsoft\Windows\CurrentVersion\Run
Expected command:
"<installed WindowAutoLayout.exe>" --startup-restore
No administrator rights are required to register it.
- Windows starts WindowAutoLayout hidden.
- The native tray process registers its controls.
- The configured startup delay lets displays and startup apps settle.
- If Restore on launch is enabled, the default profile restores.
- Closed apps launch only when Launch apps that are closed is enabled.
- The app remains resident in tray mode.
An 8-second delay is a reasonable starting point. Increase it when OBS plugins, display drivers, or startup apps regularly take longer.
Leave it off while intentionally arranging or recapturing a layout. The explicit Restore now command still works from the app or tray at any time, unless a game/fullscreen app is foreground and the safety gate pauses it.
WindowAutoLayout documentation. Repository: https://github.com/Riqqqque/WindowAutoLayout