refactor handle_applicationShouldOpenUntitledFile

This commit is contained in:
rustdesk
2023-02-09 18:11:32 +08:00
parent 4f25b03a10
commit fcd1f9b4a3
3 changed files with 23 additions and 16 deletions

View File

@@ -42,11 +42,7 @@ pub extern "C" fn rustdesk_core_main() -> bool {
#[cfg(target_os = "macos")]
#[no_mangle]
pub extern "C" fn handle_applicationShouldOpenUntitledFile() {
hbb_common::log::debug!("icon clicked on finder");
let x = std::env::args().nth(1).unwrap_or_default();
if x == "--server" || x == "--cm" {
crate::platform::macos::check_main_window();
}
crate::platform::macos::handle_applicationShouldOpenUntitledFile();
}
#[cfg(windows)]