1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
|
password.c | 10 ++++++++--
1 file changed, 8 insertions(+), 2 deletions(-)
diff --git a/password.c b/password.c
index a3e7674..b8d9167 100644
--- a/password.c
+++ b/password.c
@@ -107,6 +107,7 @@ void swaylock_handle_key(struct swaylock_state *state,
break;
case XKB_KEY_Delete:
case XKB_KEY_BackSpace:
+ if (false) {
if (backspace(&state->password)) {
state->auth_state = AUTH_STATE_BACKSPACE;
} else {
@@ -115,12 +116,15 @@ void swaylock_handle_key(struct swaylock_state *state,
damage_state(state);
schedule_indicator_clear(state);
schedule_password_clear(state);
+ }
break;
case XKB_KEY_Escape:
+ if (false) {
clear_password_buffer(&state->password);
state->auth_state = AUTH_STATE_CLEAR;
damage_state(state);
schedule_indicator_clear(state);
+ }
break;
case XKB_KEY_Caps_Lock:
case XKB_KEY_Shift_L:
@@ -133,10 +137,12 @@ void swaylock_handle_key(struct swaylock_state *state,
case XKB_KEY_Alt_R:
case XKB_KEY_Super_L:
case XKB_KEY_Super_R:
+ if (false) {
state->auth_state = AUTH_STATE_INPUT_NOP;
damage_state(state);
schedule_indicator_clear(state);
schedule_password_clear(state);
+ }
break;
case XKB_KEY_m: /* fallthrough */
case XKB_KEY_d:
@@ -148,7 +154,7 @@ void swaylock_handle_key(struct swaylock_state *state,
// fallthrough
case XKB_KEY_c: /* fallthrough */
case XKB_KEY_u:
- if (state->xkb.control) {
+ if (false) {
clear_password_buffer(&state->password);
state->auth_state = AUTH_STATE_CLEAR;
damage_state(state);
@@ -157,7 +163,7 @@ void swaylock_handle_key(struct swaylock_state *state,
}
// fallthrough
default:
- if (codepoint) {
+ if (false) {
append_ch(&state->password, codepoint);
state->auth_state = AUTH_STATE_INPUT;
damage_state(state);
|