refactor: wip

This commit is contained in:
GyDi
2022-11-17 17:07:13 +08:00
parent f5f865a139
commit 84c12dee80
21 changed files with 324 additions and 1498 deletions

View File

@@ -1,4 +1,3 @@
use crate::log_err;
use crate::{config::Config, feat, utils::resolve};
use anyhow::Result;
use tauri::{
@@ -109,8 +108,8 @@ impl Tray {
}
"open_window" => resolve::create_window(app_handle),
"system_proxy" => log_err!(feat::toggle_system_proxy()),
"tun_mode" => log_err!(feat::toggle_tun_mode()),
"system_proxy" => feat::toggle_system_proxy(),
"tun_mode" => feat::toggle_tun_mode(),
"restart_clash" => feat::restart_clash_core(),
"restart_app" => api::process::restart(&app_handle.env()),
"quit" => {