From 267f732397bee542d8d3535af55ca64ef5f65f84 Mon Sep 17 00:00:00 2001 From: cucadmuh <49571317+cucadmuh@users.noreply.github.com> Date: Sat, 2 May 2026 00:03:19 +0300 Subject: [PATCH] fix(tray): gate playback_state cfg for Windows and Linux only (#416) playback_state is only used for the Windows tray tooltip icon and the Linux now-playing menu row; compiling it on macOS triggered an unused_variables warning in CI. --- src-tauri/src/lib.rs | 1 + 1 file changed, 1 insertion(+) diff --git a/src-tauri/src/lib.rs b/src-tauri/src/lib.rs index ec7d3edc..1337dc4f 100644 --- a/src-tauri/src/lib.rs +++ b/src-tauri/src/lib.rs @@ -3690,6 +3690,7 @@ fn build_tray_icon(app: &tauri::AppHandle) -> tauri::Result { if g.is_empty() { None } else { Some(g.clone()) } }) .unwrap_or_else(|| "Psysonic".to_string()); + #[cfg(any(target_os = "windows", target_os = "linux"))] let playback_state = app .try_state::() .map(|s| s.0.lock().unwrap().clone())