mirror of
https://github.com/clash-verge-rev/clash-verge-rev.git
synced 2026-10-26 22:22:13 +08:00
feat(hotkey): add global reactivate_profiles shortcut (#5527)
* feat(hotkey): add global reactivate_profiles shortcut * feat(profile): expose validation state for reactivation shortcuts
This commit is contained in:
@@ -9,6 +9,7 @@ pub enum NotificationEvent<'a> {
|
||||
SystemProxyToggled,
|
||||
TunModeToggled,
|
||||
LightweightModeEntered,
|
||||
ProfilesReactivated,
|
||||
AppQuit,
|
||||
#[cfg(target_os = "macos")]
|
||||
AppHidden,
|
||||
@@ -54,6 +55,11 @@ pub async fn notify_event<'a>(event: NotificationEvent<'a>) {
|
||||
let body = rust_i18n::t!("notifications.lightweightModeEntered.body").to_string();
|
||||
notify(&title, &body);
|
||||
}
|
||||
NotificationEvent::ProfilesReactivated => {
|
||||
let title = rust_i18n::t!("notifications.profilesReactivated.title").to_string();
|
||||
let body = rust_i18n::t!("notifications.profilesReactivated.body").to_string();
|
||||
notify(&title, &body);
|
||||
}
|
||||
NotificationEvent::AppQuit => {
|
||||
let title = rust_i18n::t!("notifications.appQuit.title").to_string();
|
||||
let body = rust_i18n::t!("notifications.appQuit.body").to_string();
|
||||
|
||||
Reference in New Issue
Block a user