refactor(tray): remove --no-tray code path and env-based tray bypass

This commit is contained in:
Slinetrac
2025-12-25 10:42:03 +08:00
parent af0e72d119
commit 4ab2720ac4
2 changed files with 0 additions and 10 deletions

View File

@@ -3,12 +3,5 @@ fn main() {
#[cfg(feature = "tokio-trace")]
console_subscriber::init();
// Check for --no-tray command line argument
#[cfg(target_os = "linux")]
if std::env::args().any(|x| x == "--no-tray") {
unsafe {
std::env::set_var("CLASH_VERGE_DISABLE_TRAY", "1");
}
}
app_lib::run();
}

View File

@@ -154,9 +154,6 @@ pub async fn init_work_config() {
}
pub(super) async fn init_tray() {
if std::env::var("CLASH_VERGE_DISABLE_TRAY").unwrap_or_default() == "1" {
return;
}
logging_error!(Type::Setup, Tray::global().init().await);
}