mirror of
https://github.com/rustdesk/rustdesk.git
synced 2024-11-28 15:49:04 +08:00
Merge pull request #6460 from fufesou/feat/install_idd_when_installing_app
feat, install indirect display driver when installing the app
This commit is contained in:
commit
b2bb69fe42
@ -203,6 +203,8 @@ pub fn core_main() -> Option<Vec<String>> {
|
|||||||
} else if args[0] == "--install-cert" {
|
} else if args[0] == "--install-cert" {
|
||||||
#[cfg(windows)]
|
#[cfg(windows)]
|
||||||
hbb_common::allow_err!(crate::platform::windows::install_cert(&args[1]));
|
hbb_common::allow_err!(crate::platform::windows::install_cert(&args[1]));
|
||||||
|
#[cfg(all(windows, feature = "virtual_display_driver"))]
|
||||||
|
hbb_common::allow_err!(crate::virtual_display_manager::install_update_driver());
|
||||||
return None;
|
return None;
|
||||||
} else if args[0] == "--uninstall-cert" {
|
} else if args[0] == "--uninstall-cert" {
|
||||||
#[cfg(windows)]
|
#[cfg(windows)]
|
||||||
|
@ -53,6 +53,13 @@ impl VirtualDisplayManager {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
pub fn install_update_driver() -> ResultType<()> {
|
||||||
|
VIRTUAL_DISPLAY_MANAGER
|
||||||
|
.lock()
|
||||||
|
.unwrap()
|
||||||
|
.install_update_driver()
|
||||||
|
}
|
||||||
|
|
||||||
pub fn plug_in_headless() -> ResultType<()> {
|
pub fn plug_in_headless() -> ResultType<()> {
|
||||||
let mut manager = VIRTUAL_DISPLAY_MANAGER.lock().unwrap();
|
let mut manager = VIRTUAL_DISPLAY_MANAGER.lock().unwrap();
|
||||||
manager.prepare_driver()?;
|
manager.prepare_driver()?;
|
||||||
|
Loading…
Reference in New Issue
Block a user