Repository navigation
Conversation
…racter Hyprland can enable DPMS on the same keypress that Qt still delivers to the password field. When the lock has blanked the displays, intercept that key before TextInput inserts it, wake the screen, and ignore the character. Amp-Thread-ID: https://ampcode.com/threads/T-01a0a1f2-cda2-7477-9564-53cfcd45dbb7 Co-authored-by: Amp <amp@ampcode.com>
Treat the wake key like Escape: drop the buffered password and swallow the key so it is not inserted. After idle blank, the user cannot reasonably know what was already typed. Amp-Thread-ID: https://ampcode.com/threads/T-01a0a1f2-cda2-7477-9564-53cfcd45dbb7 Co-authored-by: Amp <amp@ampcode.com>
Amp-Thread-ID: https://ampcode.com/threads/T-01a0a1f2-cda2-7477-9564-53cfcd45dbb7 Co-authored-by: Amp <amp@ampcode.com>
03864a4 to
d64d6f2
Compare
Automated AI review
Outcome: On a lit lock screen, the first password key can be dropped because A stale
|
|
Reviewed at d64d6f2 by Claude Opus 5.5 and Codex Medium. The fix works for the case it targets, but it introduces a regression: after a volume or brightness key wakes the blanked lock, the first character of the password is dropped. What it fixes, confirmed live. On a worker built from the Omarchy ISO, with the shell linked to this branch, I locked the session, waited for the idle blank, and woke the panel with a real Space keypress through a uinput keyboard. On the merge base 86a2e58 the space went into the password and the unlock failed. On this head the unlock succeeded. What it breaks, also confirmed live. Volume, brightness and media keys are Smaller points, from both reviewers:
Tests. The lock tests under Related. #9211 swallows the wake key from the same handler, keyed on the same Waiting on the author. The maintainer has both this PR and #9211 to choose between once the stale-flag case is handled. |
|
Moved this PR to draft. I reproduced the regression in the offscreen Qt harness: with a stale Volume/brightness binds can wake the display without reaching the lock, leaving that flag stale. Polling DPMS would only narrow the race window; querying it when the key reaches QML can already report “on” for the actual wake key. A reliable approach appears to require Hyprland to identify and suppress the wake key before forwarding it, including repeats until release. That would need a companion upstream change. Which path would maintainers prefer: merge with the known regression, close this PR, or keep it as a draft pending a Hyprland fix? My preference is to avoid merging with the regression. |
|
Following the merge of #7806, The merged repeat filter fixes password-field flooding. Consuming the first wake key and clearing buffered input remain separate work in this draft. The reported stale displaysBlank regression can still discard the first password character after media/brightness wake and needs fixing. Scope checked by GPT-6 in Codex and Codex Medium against the discussion and landed change; review independence is not guaranteed. No tests were rerun for this cleanup. Omabot on behalf of DHH |
Problem
Waking a blanked lock screen with a keypress also inserts that character into the password field, so you have to delete it before typing the password.
Hyprland can enable DPMS on the same key that Qt still delivers to the focused
TextInput. After idle blank, any half-typed password is also guesswork.Change
The lock already tracks
displaysBlank. When that is true, the password field now treats the wake key like Escape: intercept it withKeys.BeforeItem, request a wake, clear the buffered password, and accept the event so it is not typed.Verified locally on Omarchy 4.0.3: lock, wait for the panel to blank, press Space — the screen wakes, the field is empty, and no password dot appears.
Tests
./test/shell.d/lock-wake-key-test.sh