mirror of
https://github.com/clash-verge-rev/clash-verge-rev.git
synced 2026-01-29 08:45:41 +08:00
fix: windows cannot save window state(2)
This commit is contained in:
@@ -151,6 +151,9 @@ pub fn run() {
|
||||
if label == "main" {
|
||||
match event {
|
||||
tauri::WindowEvent::CloseRequested { api, .. } => {
|
||||
if core::handle::Handle::global().is_exiting() {
|
||||
return;
|
||||
}
|
||||
println!("closing window...");
|
||||
api.prevent_close();
|
||||
let window = core::handle::Handle::global().get_window().unwrap();
|
||||
|
||||
Reference in New Issue
Block a user