Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

swaylock: Fix caps lock not updating immediately #3367

Merged
merged 1 commit into from
Jan 6, 2019
Merged

swaylock: Fix caps lock not updating immediately #3367

merged 1 commit into from
Jan 6, 2019

Conversation

oscarwcl
Copy link
Contributor

@oscarwcl oscarwcl commented Jan 2, 2019

Partially fixes #2788. This change makes it so the lock screen is redrawn whenever the caps lock modifier state changes, rather on relying on the keypress event. This didn't work because caps lock is disabled when the key is released, not pressed, so the caps lock indicator does not go away until the next keypress event.

This doesn't fully implement the suggestions in #2788, but is a more basic fix that just makes it so the caps lock indicator is always accurate. I'd be happy to have a go implementng them if anyone's interested, although it doesn't personally seem to me that they'd be that useful.

Partially fixes #2788. This change makes it so the lock screen is
redrawn whenever the caps lock modifier state changes, rather
on relying on the keypress event. This didn't work because
caps lock is disabled when the key is released, not pressed,
so the caps lock indicator does not go away until the next
keypress event.
@RedSoxFan
Copy link
Member

This doesn't fully implement the suggestions in #2788, but is a more basic fix that just makes it so the caps lock indicator is always accurate. I'd be happy to have a go implementng them if anyone's interested, although it doesn't personally seem to me that they'd be that useful.

It looks like there are three things in that issue:

  1. Persistent Caps Lock ON with Caps Lock OFF for the next key press
    This PR mostly hits this bullet, it's just missing the Caps Lock OFF for a key press. Personally, I think this is good enough and if someone really wants the last bit, another PR (or even a local patch) can be submitted/applied.

  2. --indicator-ring-caps-lock (along with something like --disable-caps-lock-text)
    I do like this idea, but it can be done in a separate PR.

  3. Only showing caps lock on entry
    If this does get implements, I think it should be optional, but I don't personally have any strong opinion either way on implementing this.

@ddevault ddevault merged commit 728e570 into swaywm:master Jan 6, 2019
@ddevault
Copy link
Contributor

ddevault commented Jan 6, 2019

Thanks!

@colemickens
Copy link
Contributor

Cool, another thank you from me!

rbnis added a commit to rbnis/sway that referenced this pull request Jan 10, 2019
Implements customization for the indicator as proposed in swaywm#2788 with comments from swaywm#3367 in mind.
The default behaviour does not change exept for the caps lock text color.
rbnis added a commit to rbnis/sway that referenced this pull request Jan 10, 2019
Implements customization for the indicator as proposed in swaywm#2788 with comments from swaywm#3367 in mind.
The default behaviour does not change exept for the caps lock text color.
rbnis added a commit to rbnis/sway that referenced this pull request Jan 10, 2019
Implements customization for the indicator as proposed in swaywm#2788 with comments from swaywm#3367 in mind.
The default behaviour does not change exept for the caps lock text color.
RedSoxFan pushed a commit that referenced this pull request Jan 10, 2019
Implements customization for the indicator as proposed in #2788 with comments from #3367 in mind.
The default behaviour does not change exept for the caps lock text color.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

swaylock: capslock indicator is unhelpful
4 participants