add virtual display

Signed-off-by: fufesou <shuanglongchen@yeah.net>
This commit is contained in:
fufesou
2022-03-12 19:51:55 +08:00
parent e6bf858ae1
commit b734e8aee9
13 changed files with 153 additions and 13 deletions

View File

@@ -19,6 +19,7 @@ use std::{
process::Child,
sync::{Arc, Mutex},
};
use virtual_display;
pub type Childs = Arc<Mutex<(bool, HashMap<(String, String), Child>)>>;
@@ -364,6 +365,18 @@ impl UI {
}
}
// TODO: ui prompt
fn install_virtual_display(&self) {
match virtual_display::install_update_driver() {
Ok(_) => {
log::info!("Virtual Display: install virtual display done");
}
Err(e) => {
log::error!("Virtual Display: install virtual display failed {}", e);
}
}
}
fn install_path(&mut self) -> String {
#[cfg(windows)]
return crate::platform::windows::get_install_info().1;
@@ -690,6 +703,7 @@ impl sciter::EventHandler for UI {
fn get_sound_inputs();
fn set_options(Value);
fn set_option(String, String);
fn install_virtual_display();
fn get_software_update_url();
fn get_new_version();
fn get_version();