From 1a9a2ff9e0c86cb48831eec38485807a14340e65 Mon Sep 17 00:00:00 2001 From: Tunglies Date: Sun, 20 Apr 2025 23:49:06 +0800 Subject: [PATCH] fix: unexpected global hotkey regestion for windows 'Ctrl+Q' #3389 --- src-tauri/src/lib.rs | 26 -------------------------- 1 file changed, 26 deletions(-) diff --git a/src-tauri/src/lib.rs b/src-tauri/src/lib.rs index e30a7aa5..40afeb34 100644 --- a/src-tauri/src/lib.rs +++ b/src-tauri/src/lib.rs @@ -303,15 +303,6 @@ pub fn run() { hotkey::Hotkey::global().register("CMD+W", "hide") ); } - - #[cfg(not(target_os = "macos"))] - { - logging_error!( - Type::Hotkey, - true, - hotkey::Hotkey::global().register("Control+Q", "quit") - ); - }; { let is_enable_global_hotkey = Config::verge() .latest() @@ -336,14 +327,6 @@ pub fn run() { hotkey::Hotkey::global().unregister("CMD+W") ); } - #[cfg(not(target_os = "macos"))] - { - logging_error!( - Type::Hotkey, - true, - hotkey::Hotkey::global().unregister("Control+Q") - ); - }; { let is_enable_global_hotkey = Config::verge() .latest() @@ -368,15 +351,6 @@ pub fn run() { hotkey::Hotkey::global().unregister("CMD+W") ); } - - #[cfg(not(target_os = "macos"))] - { - logging_error!( - Type::Hotkey, - true, - hotkey::Hotkey::global().unregister("Control+Q") - ); - }; } _ => {} }