mirror of
https://github.com/rustdesk/rustdesk.git
synced 2026-03-26 06:31:03 +03:00
fix: linux, window, workaround, mint, mate (#10146)
* refact: linux, window, workaround, mint, mate Signed-off-by: fufesou <linlong1266@gmail.com> * refact: case insensitive Signed-off-by: fufesou <linlong1266@gmail.com> --------- Signed-off-by: fufesou <linlong1266@gmail.com>
This commit is contained in:
@@ -19,6 +19,7 @@ use hbb_common::allow_err;
|
||||
use hbb_common::{
|
||||
config::{self, LocalConfig, PeerConfig, PeerInfoSerde},
|
||||
fs, lazy_static, log,
|
||||
message_proto::Hash,
|
||||
rendezvous_proto::ConnType,
|
||||
ResultType,
|
||||
};
|
||||
@@ -2341,6 +2342,25 @@ pub fn main_audio_support_loopback() -> SyncReturn<bool> {
|
||||
SyncReturn(is_surpport)
|
||||
}
|
||||
|
||||
pub fn get_os_distro_info() -> SyncReturn<String> {
|
||||
#[cfg(target_os = "linux")]
|
||||
{
|
||||
let distro = &hbb_common::platform::linux::DISTRO;
|
||||
SyncReturn(
|
||||
serde_json::to_string(&HashMap::from([
|
||||
("name", distro.name.clone()),
|
||||
("id", distro.id.clone()),
|
||||
("version_id", distro.version_id.clone()),
|
||||
]))
|
||||
.unwrap_or_default(),
|
||||
)
|
||||
}
|
||||
#[cfg(not(target_os = "linux"))]
|
||||
{
|
||||
SyncReturn("".to_owned())
|
||||
}
|
||||
}
|
||||
|
||||
#[cfg(target_os = "android")]
|
||||
pub mod server_side {
|
||||
use hbb_common::{config, log};
|
||||
|
||||
Reference in New Issue
Block a user