Skip to content

Commit 1ab8dd9

Browse files
authored
fix(core): system-tray cargo feature usage, fixes #1798 (#1801)
1 parent f5a480f commit 1ab8dd9

3 files changed

Lines changed: 10 additions & 4 deletions

File tree

.changes/system-tray-usage-fix.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
---
2+
"tauri-runtime": patch
3+
"tauri-runtime-wry": patch
4+
---
5+
6+
Fixes `system-tray` feature usage.

core/tauri-runtime-wry/Cargo.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,5 +20,5 @@ uuid = { version = "0.8.2", features = [ "v4" ] }
2020

2121
[features]
2222
dox = [ "wry/dox" ]
23-
menu = [ "wry/menu" ]
24-
system-tray = [ "wry/tray" ]
23+
menu = [ "wry/menu", "tauri-runtime/menu" ]
24+
system-tray = [ "wry/tray", "tauri-runtime/system-tray" ]

core/tauri-runtime/src/lib.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -51,8 +51,8 @@ pub enum Error {
5151
#[error("JSON error: {0}")]
5252
Json(#[from] serde_json::Error),
5353
/// Encountered an error creating the app system tray.
54-
#[cfg(feature = "menu")]
55-
#[cfg_attr(doc_cfg, doc(cfg(feature = "menu")))]
54+
#[cfg(feature = "system-tray")]
55+
#[cfg_attr(doc_cfg, doc(cfg(feature = "system-tray")))]
5656
#[error("error encountered during tray setup: {0}")]
5757
SystemTray(Box<dyn std::error::Error + Send>),
5858
/// Failed to load window icon.

0 commit comments

Comments
 (0)