| Age | Commit message (Collapse) | Author | Files | Lines |
|
status.gaming is written by the shell's game detector and presentation is
the OR of it and the manual file, but statusctl read only the manual half.
A game therefore asserted the presentation effects while the waybar pill
still read deactivated.
Report gaming as a third state, for presentation only. The watch follows
status.gaming as well as its own file, and emits only on a real change so
an unchanged rewrite draws nothing.
Toggle is refused while a game holds the mode: the detector reasserts the
file within its poll, so the write would not stick. set stays allowed, the
manual half is worth setting for when the game exits.
gaming stays out of MODES. The detector owns that file and nothing here
may write it.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
|
|
PCSX2 joins gamescope, Steam and DuckStation in the game detector, so
presentation is set automatically while a PS2 game runs and the idle
lock, DND and breaktimer stay out of the way.
The binary is /usr/bin/pcsx2-qt, the same -qt shape as duckstation-qt,
so it takes the same pgrep -x exact name match and cannot self-match the
way the bracketed steam pattern has to guard against.
Verified against the real emulator rather than a stand-in: with
pcsx2-qt running, status.gaming reads 1.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
|
|
Game detection probed only gamescope and Steam, so a standalone
DuckStation session never turned presentation on. Add a third probe for
the duckstation-qt process.
pgrep -x rather than the bracketed pgrep -f the Steam path needs: this
is an exact match on the process name, so it cannot match the sh running
the check, and the binary name is under the 15 character comm limit so
it is not truncated.
|
|
Presentation is worth having automatically while a game runs: it is a
fullscreen app that already holds the screen, and the idle lock, DND and
breaktimer are all unwanted during it.
Detection is a 5s poll for a gamescope process or a Steam game binary,
either one enough. The Steam pattern is bracketed so pgrep -f cannot match
the sh running the check and report a game forever.
The result goes to its own status.gaming file, and presentation becomes the
OR of it and status.presentation. That separation is the point: a game
ending clears only the gaming half, so a presentation set by hand survives
a game session instead of being clobbered on exit.
|
|
|
|
The one rule worth writing down is which side writes: the daemon owns its
files and the shell only calls verbs.
|
|
dnd and presentation were the only modes, and presentation was the sole
holder of the Wayland idle inhibitor. That inhibitor is the only thing
that stops hypridle's loginctl lock-session at the 600s timeout, so
screen locking is on by default and there was no way to turn it off on
its own.
nolock is stored as "auto-lock disabled" so the file keeps the registry's
"missing means off" rule, and the row inverts it so the switch reads as
the default: lock on. Presentation now drives nolock the same way it
drives dnd, holding the prior value in memory and restoring it on exit,
so it needs no second inhibitor and the inhibitor has a single holder.
The page sets the disable permanently or for a number of minutes. The
deadline and its timer live in the singleton rather than the row because
the drawer page is destroyed on close while the effect has to outlive
it. The timer is shell-lifetime, the same class of limit as
dndBeforePresentation: a restart during a timed disable leaves the lock
off until it is toggled, which is safe because the user opted into the
disable.
The mode governs idle-triggered locking only. The SUPER+l bind and the
lock on suspend are separate paths and stay live.
|
|
statusctl watch reported class "down" for a missing state file and waybar's presentation rule drew a warning for it. That fires on every fresh session, before anything has written a file, which is the normal off state the registry's own invariant describes. The state was meant to flag a dead registry, but a crashed shell leaves a stale present file, not a missing one, so it never caught that case. get already read a missing file as 0; watch now matches it and the down state is gone.
|
|
F1: after a click the shared Switch writes checked directly, dropping
StatusRow's declarative binding, so an external mode change from waybar
or statusctl no longer moved the switch. Resync via onValueChanged.
F2: the spec claimed hyprctl clients counts idle inhibitors, which is
false for a layer-surface inhibitor; replace with the behavioral
hypridle marker check.
F3: README said the check covers both watch states; it exercises the
activated report and the absent-file down report.
F4: give breakProc an onExited check so a failed breaktimer.sh verb is
visible instead of silent.
F5: drop StatusTile's unused required st property and its injection.
F6: comment the startup-order limit on dndBeforePresentation.
|
|
A FileView fires its own fileChanged on setText, so a handler that writes
in response to a change loops unless it compares first. IdleInhibitor has
no window of its own and does nothing without one, so the singleton is
handed the keepalive window by shell.qml.
Both were read from the documentation while designing and confirmed while
implementing.
|