summaryrefslogtreecommitdiff
path: root/src/river_protocols
diff options
context:
space:
mode:
authorMaxVerevkin <maxxverrr@gmail.com>2022-11-27 22:11:08 +0200
committerMaxVerevkin <maxxverrr@gmail.com>2022-11-27 22:11:08 +0200
commitf6727acdd4cc112c51d3dd71df61689738e31de9 (patch)
treee6607e9056bb6cd39115f99e611c5df5a967eb3a /src/river_protocols
parentd28693c9d293ea7c348c0e9e1a4e89ccff6dcae4 (diff)
downloadi3bar-mango-f6727acdd4cc112c51d3dd71df61689738e31de9.tar.gz
WIP: support river-status-unstable-v1 version 3
Depends on https://github.com/riverwm/river/pull/673
Diffstat (limited to 'src/river_protocols')
-rw-r--r--src/river_protocols/status.rs14
1 files changed, 13 insertions, 1 deletions
diff --git a/src/river_protocols/status.rs b/src/river_protocols/status.rs
index 1779719..4424c58 100644
--- a/src/river_protocols/status.rs
+++ b/src/river_protocols/status.rs
@@ -19,7 +19,7 @@ impl RiverStatusState {
where
D: Dispatch<zriver_status_manager_v1::ZriverStatusManagerV1, (), D> + 'static,
{
- let status_manager = globals.bind(qh, 1..=1, ())?;
+ let status_manager = globals.bind(qh, 1..=3, ())?;
Ok(Self {
status_manager,
output_statuses: Vec::new(),
@@ -88,6 +88,14 @@ pub trait RiverStatusHandler: Sized {
output_status: &RiverOutputStatus,
tags: Vec<u32>,
);
+
+ fn layout_name_updated(
+ &mut self,
+ conn: &Connection,
+ qh: &QueueHandle<Self>,
+ output_status: &RiverOutputStatus,
+ layout_name: Option<String>,
+ );
}
#[derive(Debug, Clone)]
@@ -176,6 +184,10 @@ where
.collect();
data.views_tags_updated(conn, qh, &status, tags);
}
+ Event::LayoutName { name } => {
+ data.layout_name_updated(conn, qh, &status, Some(name))
+ }
+ Event::LayoutNameClear => data.layout_name_updated(conn, qh, &status, None),
}
}
}