move refcounting of key presses to input-emulation (#169)

This commit is contained in:
Ferdinand Schober
2024-08-06 16:46:32 +02:00
committed by GitHub
parent 68361b25d1
commit 8f7890c9be
13 changed files with 225 additions and 218 deletions

View File

@@ -42,8 +42,8 @@ async fn ping_task(
let ping_clients: Vec<ClientHandle> = if receiving {
// if receiving we care about clients with pressed keys
client_manager
.get_client_states_mut()
.filter(|(_, (_, s))| !s.pressed_keys.is_empty())
.get_client_states()
.filter(|(_, (_, s))| s.has_pressed_keys)
.map(|(h, _)| h)
.collect()
} else {