mirror of
https://github.com/clash-verge-rev/clash-verge-rev.git
synced 2024-11-16 11:42:21 +08:00
chore: remove useless exit codes and hooks
This commit is contained in:
parent
e92074e586
commit
40ff3fd4bf
|
@ -428,7 +428,6 @@ fn on_menu_event(app_handle: &AppHandle, event: MenuEvent) {
|
||||||
"restart_clash" => feat::restart_clash_core(),
|
"restart_clash" => feat::restart_clash_core(),
|
||||||
"restart_app" => tauri::process::restart(&app_handle.env()),
|
"restart_app" => tauri::process::restart(&app_handle.env()),
|
||||||
"quit" => {
|
"quit" => {
|
||||||
println!("quit");
|
|
||||||
feat::quit();
|
feat::quit();
|
||||||
}
|
}
|
||||||
_ => {}
|
_ => {}
|
||||||
|
|
|
@ -110,7 +110,6 @@ pub fn quit() {
|
||||||
let _ = resolve::save_window_size_position(&app_handle, true);
|
let _ = resolve::save_window_size_position(&app_handle, true);
|
||||||
resolve::resolve_reset();
|
resolve::resolve_reset();
|
||||||
app_handle.exit(0);
|
app_handle.exit(0);
|
||||||
std::process::exit(0);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -135,9 +135,6 @@ pub fn run() {
|
||||||
.expect("error while running tauri application");
|
.expect("error while running tauri application");
|
||||||
|
|
||||||
app.run(|app_handle, e| match e {
|
app.run(|app_handle, e| match e {
|
||||||
tauri::RunEvent::ExitRequested { api, .. } => {
|
|
||||||
api.prevent_exit();
|
|
||||||
}
|
|
||||||
tauri::RunEvent::WindowEvent { label, event, .. } => {
|
tauri::RunEvent::WindowEvent { label, event, .. } => {
|
||||||
if label == "main" {
|
if label == "main" {
|
||||||
match event {
|
match event {
|
||||||
|
|
Loading…
Reference in New Issue
Block a user