mirror of
https://github.com/swaywm/sway.git
synced 2024-12-30 17:06:40 +01:00
Merge pull request #536 from jcaesar/master
swaylock: Interpret XKB_KEY_BackSpace as a deletion instead of a normal key.
This commit is contained in:
commit
f590acc84c
1 changed files with 8 additions and 0 deletions
|
@ -108,6 +108,14 @@ void notify_key(enum wl_keyboard_key_state state, xkb_keysym_t sym, uint32_t cod
|
||||||
password = malloc(password_size);
|
password = malloc(password_size);
|
||||||
password[0] = '\0';
|
password[0] = '\0';
|
||||||
break;
|
break;
|
||||||
|
case XKB_KEY_BackSpace:
|
||||||
|
{
|
||||||
|
int i = strlen(password);
|
||||||
|
if (i > 0) {
|
||||||
|
password[i - 1] = '\0';
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
}
|
||||||
default:
|
default:
|
||||||
{
|
{
|
||||||
int i = strlen(password);
|
int i = strlen(password);
|
||||||
|
|
Loading…
Reference in a new issue