Closed sojuz151 closed 4 years ago
Yeah, that looks good. I would prefer to have this kind of thing in upstream swaylock, but from the swaywm#50 issue you linked, that doesn't seem too likely.
The only scary part is that the delay-password branch adds a new short option -g
. That'll be a problem if the upstream swaylock project ever adds a -g
option which means something else. I think I may want to remove -g
and leave only --grace
.
Alright, I merged it in (with some changes): https://github.com/mortie/swaylock-effects/commit/c0f6b94f9f732429f23a8696578a1260c010ce13
https://github.com/mortie/swaylock-effects/commit/0a3fcf6760e5c1ec45879dcf59061f589f6e47c5 I made it such that a mouse event will also unlock the screen during the grace period.
I imagine the common use case for the grace feature will be together with swayidle, so it will probably feel weird to only be able to "abort" a lock with the keyboard and not with the mouse.
As discussed here: https://github.com/swaywm/swaylock/issues/50 Should be enough to merge this patch: https://github.com/swaywm/swaylock/compare/master...gdamjan:delay-password