This commit is contained in:
Moritz Ruth 2024-02-01 17:06:23 +01:00
parent ebb0552a13
commit bf48f12c8c
Signed by: moritzruth
GPG key ID: C9BBAB79405EE56D
5 changed files with 370 additions and 2 deletions

View file

@ -4,7 +4,6 @@ use log::warn;
use parse_display::Display;
use regex::Regex;
use serde::Deserialize;
use tokio::select;
use tokio::sync::broadcast;
use deckster_mode::shared::handler_communication::{
@ -246,7 +245,7 @@ async fn manage_knob(path: KnobPath, config: KnobConfig, mut events: broadcast::
}
loop {
select! {
tokio::select! {
Ok(volume_state) = volume_states.recv() => {
entity_state = volume_state.entities_by_id().values().find(|entity| state_matches(&config.target, entity)).map(Arc::clone);
update_knob_style(&entity_state);