fix uninstall service on mac from main window because of ipc close
myself
This commit is contained in:
parent
722b82e1a5
commit
4b33ee6309
@ -241,9 +241,6 @@ pub fn uninstall_service(show_new_window: bool) -> bool {
|
||||
);
|
||||
if uninstalled {
|
||||
crate::ipc::set_option("stop-service", "Y");
|
||||
let _ = crate::ipc::close_all_instances();
|
||||
// leave ipc a little time
|
||||
std::thread::sleep(std::time::Duration::from_millis(300));
|
||||
std::process::Command::new("launchctl")
|
||||
.args(&["remove", &format!("{}_server", crate::get_full_name())])
|
||||
.status()
|
||||
@ -262,6 +259,9 @@ pub fn uninstall_service(show_new_window: bool) -> bool {
|
||||
.arg(crate::get_app_name())
|
||||
.status()
|
||||
.ok();
|
||||
let _ = crate::ipc::close_all_instances();
|
||||
// leave ipc a little time
|
||||
std::thread::sleep(std::time::Duration::from_millis(300));
|
||||
quit_gui();
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user