mirror of
https://github.com/rustdesk/rustdesk.git
synced 2026-09-18 18:31:02 +03:00
refact: remove feature plugin-framework (#15854)
* refact: remove feature plugin-framework Signed-off-by: fufesou <linlong1266@gmail.com> * refact: remove unused translations Signed-off-by: fufesou <linlong1266@gmail.com> * fix: delete settings tab observable with correct type Signed-off-by: fufesou <linlong1266@gmail.com> --------- Signed-off-by: fufesou <linlong1266@gmail.com>
This commit is contained in:
@@ -190,9 +190,6 @@ pub fn core_main() -> Option<Vec<String>> {
|
||||
crate::platform::elevate_or_run_as_system(click_setup, _is_elevate, _is_run_as_system);
|
||||
return None;
|
||||
}
|
||||
#[cfg(all(feature = "flutter", feature = "plugin_framework"))]
|
||||
#[cfg(not(any(target_os = "android", target_os = "ios")))]
|
||||
init_plugins(&args);
|
||||
if args.is_empty() || crate::common::is_empty_uni_link(&args[0]) {
|
||||
#[cfg(target_os = "macos")]
|
||||
{
|
||||
@@ -737,22 +734,6 @@ pub fn core_main() -> Option<Vec<String>> {
|
||||
crate::platform::gtk_sudo::exec();
|
||||
}
|
||||
return None;
|
||||
} else {
|
||||
#[cfg(all(feature = "flutter", feature = "plugin_framework"))]
|
||||
#[cfg(not(any(target_os = "android", target_os = "ios")))]
|
||||
if args[0] == "--plugin-install" {
|
||||
if args.len() == 2 {
|
||||
crate::plugin::change_uninstall_plugin(&args[1], false);
|
||||
} else if args.len() == 3 {
|
||||
crate::plugin::install_plugin_with_url(&args[1], &args[2]);
|
||||
}
|
||||
return None;
|
||||
} else if args[0] == "--plugin-uninstall" {
|
||||
if args.len() == 2 {
|
||||
crate::plugin::change_uninstall_plugin(&args[1], true);
|
||||
}
|
||||
return None;
|
||||
}
|
||||
}
|
||||
}
|
||||
//_async_logger_holder.map(|x| x.flush());
|
||||
@@ -762,23 +743,6 @@ pub fn core_main() -> Option<Vec<String>> {
|
||||
return Some(args);
|
||||
}
|
||||
|
||||
#[inline]
|
||||
#[cfg(all(feature = "flutter", feature = "plugin_framework"))]
|
||||
#[cfg(not(any(target_os = "android", target_os = "ios")))]
|
||||
fn init_plugins(args: &Vec<String>) {
|
||||
if args.is_empty() || "--server" == (&args[0] as &str) {
|
||||
#[cfg(debug_assertions)]
|
||||
let load_plugins = true;
|
||||
#[cfg(not(debug_assertions))]
|
||||
let load_plugins = crate::platform::is_installed();
|
||||
if load_plugins {
|
||||
crate::plugin::init();
|
||||
}
|
||||
} else if "--service" == (&args[0] as &str) {
|
||||
hbb_common::allow_err!(crate::plugin::remove_uninstalled());
|
||||
}
|
||||
}
|
||||
|
||||
fn import_config(path: &str) {
|
||||
use hbb_common::{config::*, get_exe_time, get_modified_time};
|
||||
let path2 = path.replace(".toml", "2.toml");
|
||||
|
||||
Reference in New Issue
Block a user