notification daemon
git clone https://git.lucas.co/cce-notifier.git
refactor: build the app with Application::create
Application::new(qh, sender) took the session's Wayland queue handle,
which no client ever used, and calloop's sender; cce-ui is retiring it
for create(sender: AppSender<_>), which names no window system. The
body is unchanged: an app that keeps calloop's sender converts the
AppSender into it on the first line, and the now-unused QueueHandle and
EngineState imports go.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
src/main.rs | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/src/main.rs b/src/main.rs
index 364a14d..a8a1205 100644
--- a/src/main.rs
+++ b/src/main.rs
@@ -3,7 +3,6 @@ use std::collections::HashMap;
use zbus::zvariant::Value;
use zbus::{connection, interface};
-use wayland_client::QueueHandle;
use cce_ui::engine::{
Application, EngineState, LayerAnchor, LayerKeyboardInteractivity, LayerKind, LayerSettings,
@@ -605,7 +604,9 @@ impl Application for NotifierApp {
true
}
- fn new(_qh: &QueueHandle<EngineState<Self>>, sender: calloop::channel::Sender<Self::Message>) -> Self {
+ fn create(sender: cce_ui::engine::AppSender<Self::Message>) -> Self {
+ // The app keeps calloop's sender; `AppSender` converts into it.
+ let sender: calloop::channel::Sender<Self::Message> = sender.into();
Self {
seen_renderer: false,
hidden_since_renderer: false,