Fix systray formatting
Some checks failed
Build Project / Build Linux (push) Failing after 1m11s

This commit is contained in:
jmb05
2026-11-03 01:14:50 +01:00
parent f88f3ba30d
commit 5ffed55e37

View File

@@ -10,9 +10,7 @@ pub fn _build() -> gtk::Box {
let host = TrayHost::new(); let host = TrayHost::new();
if let Ok(mut host) = host { if let Ok(mut host) = host {
glib::timeout_add_local( glib::timeout_add_local(Duration::from_millis(1_000), move || {
Duration::from_millis(1_000),
move || {
for event in host.poll().unwrap() { for event in host.poll().unwrap() {
match event { match event {
TrayEvent::ItemAdded(id) | TrayEvent::ItemChanged(id) => { TrayEvent::ItemAdded(id) | TrayEvent::ItemChanged(id) => {
@@ -30,8 +28,7 @@ pub fn _build() -> gtk::Box {
} }
} }
ControlFlow::Continue ControlFlow::Continue
} });
);
} else { } else {
error!(&LOGGER, "Couldn't get SystemTray"); error!(&LOGGER, "Couldn't get SystemTray");
} }