mirror of
https://github.com/rustdesk/rustdesk.git
synced 2026-07-14 11:37:12 +08:00
37141afece
Signed-off-by: fufesou <linlong1266@gmail.com>
34 lines
783 B
Rust
34 lines
783 B
Rust
#![cfg_attr(
|
|
all(not(debug_assertions), target_os = "windows"),
|
|
windows_subsystem = "windows"
|
|
)]
|
|
|
|
use librustdesk::*;
|
|
|
|
#[cfg(any(target_os = "android", target_os = "ios", feature = "flutter"))]
|
|
fn main() {
|
|
if !common::global_init() {
|
|
eprintln!("Global initialization failed.");
|
|
return;
|
|
}
|
|
common::test_rendezvous_server();
|
|
common::test_nat_type();
|
|
common::global_clean();
|
|
}
|
|
|
|
#[cfg(not(any(
|
|
target_os = "android",
|
|
target_os = "ios",
|
|
feature = "flutter"
|
|
)))]
|
|
fn main() {
|
|
#[cfg(all(windows, not(feature = "inline")))]
|
|
unsafe {
|
|
winapi::um::shellscalingapi::SetProcessDpiAwareness(2);
|
|
}
|
|
if let Some(args) = crate::core_main::core_main().as_mut() {
|
|
ui::start(args);
|
|
}
|
|
common::global_clean();
|
|
}
|