From fb16fdd26477c0090c8e8b26e062b6968a40fe80 Mon Sep 17 00:00:00 2001 From: Ian Douglas Scott Date: Wed, 1 Sep 2021 13:29:33 -0700 Subject: [PATCH] Fix `StatusNotiferWatcher` behavior --- src/status_notifier_watcher.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/status_notifier_watcher.rs b/src/status_notifier_watcher.rs index eab00d7a..82f77096 100644 --- a/src/status_notifier_watcher.rs +++ b/src/status_notifier_watcher.rs @@ -56,7 +56,7 @@ fn name_acquired(connection: gio::DBusConnection, _name: &str) { .unwrap(); let items = Arc::new(Mutex::new(Vec::::new())); let method_call = clone!(@strong items => move |connection: gio::DBusConnection, - _sender: &str, + sender: &str, path: &str, interface: &str, method: &str, @@ -65,6 +65,7 @@ fn name_acquired(connection: gio::DBusConnection, _name: &str) { match method { "RegisterStatusNotifierItem" => { let (service,) = args.get::<(String,)>().unwrap(); + let service = format!("{}{}", sender, service); connection.emit_signal(None, path, interface, "StatusNotifierItemRegistered", Some(&(&service,).to_variant())).unwrap(); // XXX emit unreigstered items.lock().unwrap().push(service);