mirror of
https://github.com/clash-verge-rev/clash-verge-rev.git
synced 2026-11-13 14:22:08 +08:00
fix: resolve macOS lightweight mode exit synchronization issues and improve logging levels #5241
This commit is contained in:
@@ -10,6 +10,8 @@ mod feat;
|
||||
mod module;
|
||||
mod process;
|
||||
pub mod utils;
|
||||
#[cfg(target_os = "macos")]
|
||||
use crate::module::lightweight;
|
||||
#[cfg(target_os = "linux")]
|
||||
use crate::utils::linux;
|
||||
#[cfg(target_os = "macos")]
|
||||
@@ -287,6 +289,11 @@ pub fn run() {
|
||||
pub async fn handle_reopen(has_visible_windows: bool) {
|
||||
handle::Handle::global().init();
|
||||
|
||||
if lightweight::is_in_lightweight_mode() {
|
||||
lightweight::exit_lightweight_mode().await;
|
||||
return;
|
||||
}
|
||||
|
||||
if !has_visible_windows {
|
||||
handle::Handle::global().set_activation_policy_regular();
|
||||
let _ = WindowManager::show_main_window().await;
|
||||
|
||||
Reference in New Issue
Block a user