pub fn install_tray(
app: &App,
tooltip: &str,
menu: &Menu<Wry>,
on_menu_item: impl Fn(&AppHandle, &str) + Send + Sync + 'static,
on_left_click: impl Fn(&AppHandle) + Send + Sync + 'static,
) -> Result<()>Expand description
Install a tray icon using the app’s default window icon, with tooltip,
menu, and the two behaviors every launcher-style tray needs:
on_menu_item fires with the clicked item’s id; on_left_click fires on
a tray-icon left click (mouse up).