diff --git a/Cargo.lock b/Cargo.lock index b8836b3..18b1342 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1604,10 +1604,10 @@ dependencies = [ "serde", "serde_json", "smithay-client-toolkit", - "stray", "strip-ansi-escapes", "swayipc-async", "sysinfo", + "system-tray", "tokio", "tracing", "tracing-appender", @@ -2738,23 +2738,6 @@ version = "1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a2eb9349b6444b326872e140eb1cf5e7c522154d69e7a0ffb0fb81c06b37543f" -[[package]] -name = "stray" -version = "0.1.3" -source = "git+https://github.com/jakestanger/stray?branch=fix/connection-errors#d2ba068e2b1e4bc1ab62950612cb8ea08576fca1" -dependencies = [ - "anyhow", - "byteorder", - "chrono", - "log", - "serde", - "thiserror", - "tokio", - "tokio-stream", - "tracing", - "zbus", -] - [[package]] name = "strip-ansi-escapes" version = "0.1.1" @@ -2887,6 +2870,24 @@ dependencies = [ "version-compare", ] +[[package]] +name = "system-tray" +version = "0.1.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3c8f7f19237d2149a8e4b56409c579b26a98748e3cfadba93762c4746c4c7ae2" +dependencies = [ + "anyhow", + "byteorder", + "chrono", + "log", + "serde", + "thiserror", + "tokio", + "tokio-stream", + "tracing", + "zbus", +] + [[package]] name = "target-lexicon" version = "0.12.7" diff --git a/Cargo.toml b/Cargo.toml index 756e96d..aa8e823 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -52,7 +52,7 @@ music = ["regex"] sys_info = ["sysinfo", "regex"] -tray = ["stray"] +tray = ["system-tray"] upower = ["upower_dbus", "zbus", "futures-lite"] @@ -122,7 +122,7 @@ mpris = { version = "2.0.1", optional = true } sysinfo = { version = "0.29.7", optional = true } # tray -stray = { version = "0.1.3", optional = true } +system-tray = { version = "0.1.4", optional = true } # upower upower_dbus = { version = "0.3.2", optional = true } @@ -137,7 +137,4 @@ futures-util = { version = "0.3.21", optional = true } # shared regex = { version = "1.8.4", default-features = false, features = [ "std", -], optional = true } # music, sys_info - -[patch.crates-io] -stray = { git = "https://github.com/jakestanger/stray", branch = "fix/connection-errors" } +], optional = true } # music, sys_info \ No newline at end of file diff --git a/src/clients/system_tray.rs b/src/clients/system_tray.rs index f10a897..7948191 100644 --- a/src/clients/system_tray.rs +++ b/src/clients/system_tray.rs @@ -5,10 +5,10 @@ use color_eyre::Report; use lazy_static::lazy_static; use std::collections::BTreeMap; use std::sync::{Arc, Mutex}; -use stray::message::menu::TrayMenu; -use stray::message::tray::StatusNotifierItem; -use stray::message::{NotifierItemCommand, NotifierItemMessage}; -use stray::StatusNotifierWatcher; +use system_tray::message::menu::TrayMenu; +use system_tray::message::tray::StatusNotifierItem; +use system_tray::message::{NotifierItemCommand, NotifierItemMessage}; +use system_tray::StatusNotifierWatcher; use tokio::spawn; use tokio::sync::{broadcast, mpsc}; use tracing::{debug, error, trace}; @@ -24,7 +24,7 @@ pub struct TrayEventReceiver { } impl TrayEventReceiver { - async fn new() -> stray::error::Result { + async fn new() -> system_tray::error::Result { let id = format!("ironbar-{}", get_unique_usize()); let (tx, rx) = mpsc::channel(16); diff --git a/src/modules/tray.rs b/src/modules/tray.rs index 7444598..78245e2 100644 --- a/src/modules/tray.rs +++ b/src/modules/tray.rs @@ -11,9 +11,9 @@ use gtk::{ }; use serde::Deserialize; use std::collections::HashMap; -use stray::message::menu::{MenuItem as MenuItemInfo, MenuType}; -use stray::message::tray::StatusNotifierItem; -use stray::message::{NotifierItemCommand, NotifierItemMessage}; +use system_tray::message::menu::{MenuItem as MenuItemInfo, MenuType}; +use system_tray::message::tray::StatusNotifierItem; +use system_tray::message::{NotifierItemCommand, NotifierItemMessage}; use tokio::spawn; use tokio::sync::mpsc; use tokio::sync::mpsc::{Receiver, Sender};