diff options
author | emersion <contact@emersion.fr> | 2018-07-07 13:16:39 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-07-07 13:16:39 +0100 |
commit | 57fd65c5b53279abe35c2e446e6770d492dd748d (patch) | |
tree | 24d3e5e0ef93aecdb14da44453bcbeaf509ae8a5 /swaylock/password.c | |
parent | c498c73b6d70bfd13337dd5fe10260d0058f125c (diff) | |
parent | b78c29a83f7e0c637da94b259644cf08376b22ca (diff) |
Merge pull request #2225 from martinetd/swaylock-verified
swaylock: fix the displaying of "verified"
Diffstat (limited to 'swaylock/password.c')
-rw-r--r-- | swaylock/password.c | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/swaylock/password.c b/swaylock/password.c index bb32286e..d844ec98 100644 --- a/swaylock/password.c +++ b/swaylock/password.c @@ -97,7 +97,20 @@ void swaylock_handle_key(struct swaylock_state *state, case XKB_KEY_Return: state->auth_state = AUTH_STATE_VALIDATING; damage_state(state); - wl_display_roundtrip(state->display); + while (wl_display_dispatch(state->display) != -1 && state->run_display) { + bool ok = 1; + struct swaylock_surface *surface; + wl_list_for_each(surface, &state->surfaces, link) { + if (surface->dirty) { + ok = 0; + } + } + if (ok) { + break; + } + } + wl_display_flush(state->display); + if (attempt_password(&state->password)) { state->run_display = false; break; |