mirror of
https://github.com/clash-verge-rev/clash-verge-rev.git
synced 2026-01-28 07:14:40 +08:00
refactor(handle): remove startup_completed field and related method from Handle struct
This commit is contained in:
@@ -15,7 +15,6 @@ use super::notification::{FrontendEvent, NotificationSystem};
|
||||
pub struct Handle {
|
||||
pub(super) notification_system: Arc<Mutex<NotificationSystem>>,
|
||||
is_exiting: AtomicBool,
|
||||
startup_completed: AtomicBool,
|
||||
}
|
||||
|
||||
singleton!(Handle, HANDLE);
|
||||
@@ -95,10 +94,6 @@ impl Handle {
|
||||
handle.notification_system.lock().send_event(event);
|
||||
}
|
||||
|
||||
pub fn mark_startup_completed(&self) {
|
||||
self.startup_completed.store(true, Ordering::Release);
|
||||
}
|
||||
|
||||
pub fn set_is_exiting(&self) {
|
||||
self.is_exiting.store(true, Ordering::Release);
|
||||
self.notification_system.lock().shutdown();
|
||||
|
||||
@@ -302,8 +302,6 @@ impl WindowManager {
|
||||
return false;
|
||||
}
|
||||
|
||||
handle::Handle::global().mark_startup_completed();
|
||||
|
||||
true
|
||||
})
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user