diff --git a/Cargo.lock b/Cargo.lock index 4cebc74c..9f47ebb9 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -664,12 +664,6 @@ dependencies = [ "libc", ] -[[package]] -name = "lazy_static" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bbd2bcb4c963f2ddae06a2efc7e9f3591312473c50c6685e1f298068316e66fe" - [[package]] name = "libc" version = "0.2.186" @@ -857,7 +851,6 @@ dependencies = [ "dirs", "futures", "gossamer-rs", - "lazy_static", "libc", "libloading", "notify", diff --git a/Cargo.toml b/Cargo.toml index 434ed13a..fb727d8e 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -54,7 +54,6 @@ serde_json = "1" # Shared state (replaces Tauri State<> extractor) once_cell = "1" -lazy_static = "1.4.0" # HTTP clients for service bridges (BoJ, VeriSimDB, ECHIDNA, Fleet, Hypatia, etc.) reqwest = { version = "0.12", features = ["json", "blocking", "stream"] } diff --git a/src-gossamer/src/system_tray/mod.rs b/src-gossamer/src/system_tray/mod.rs index b633abf2..367a478b 100644 --- a/src-gossamer/src/system_tray/mod.rs +++ b/src-gossamer/src/system_tray/mod.rs @@ -6,7 +6,7 @@ //! Provides system tray icon and menu for PanLL, including service toggling //! for Burble and Gossamer. -use std::sync::{Arc, Mutex}; +use std::sync::Mutex; /// System tray state struct SystemTrayState { @@ -16,7 +16,7 @@ struct SystemTrayState { } impl SystemTrayState { - fn new() -> Self { + const fn new() -> Self { Self { tray_handle: None, burble_enabled: true, @@ -25,12 +25,8 @@ impl SystemTrayState { } } -lazy_static::lazy_static! { - /// Global system tray state - static ref SYSTEM_TRAY_STATE: Arc> = { - Arc::new(Mutex::new(SystemTrayState::new())) - }; -} +/// Global system tray state +static SYSTEM_TRAY_STATE: Mutex = Mutex::new(SystemTrayState::new()); /// Initialize the system tray pub fn init(app: &gossamer_rs::App) -> Result<(), String> {