fix build, android
Signed-off-by: dignow <linlong1265@gmail.com>
This commit is contained in:
parent
3bb7123dd5
commit
c10fc26cce
@ -1563,10 +1563,10 @@ pub fn set_cur_session_id(session_id: SessionID) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
fn set_cur_session_id_(session_id: SessionID, keyboard_mode: &str) {
|
fn set_cur_session_id_(session_id: SessionID, _keyboard_mode: &str) {
|
||||||
super::flutter::set_cur_session_id(session_id);
|
super::flutter::set_cur_session_id(session_id);
|
||||||
#[cfg(windows)]
|
#[cfg(windows)]
|
||||||
crate::keyboard::update_grab_get_key_name(keyboard_mode);
|
crate::keyboard::update_grab_get_key_name(_keyboard_mode);
|
||||||
}
|
}
|
||||||
|
|
||||||
pub fn install_show_run_without_install() -> SyncReturn<bool> {
|
pub fn install_show_run_without_install() -> SyncReturn<bool> {
|
||||||
|
@ -214,6 +214,7 @@ static mut IS_0X021D_DOWN: bool = false;
|
|||||||
#[cfg(target_os = "macos")]
|
#[cfg(target_os = "macos")]
|
||||||
static mut IS_LEFT_OPTION_DOWN: bool = false;
|
static mut IS_LEFT_OPTION_DOWN: bool = false;
|
||||||
|
|
||||||
|
#[cfg(not(any(target_os = "android", target_os = "ios")))]
|
||||||
fn get_keyboard_mode() -> String {
|
fn get_keyboard_mode() -> String {
|
||||||
#[cfg(not(any(feature = "flutter", feature = "cli")))]
|
#[cfg(not(any(feature = "flutter", feature = "cli")))]
|
||||||
if let Some(session) = CUR_SESSION.lock().unwrap().as_ref() {
|
if let Some(session) = CUR_SESSION.lock().unwrap().as_ref() {
|
||||||
|
@ -83,6 +83,7 @@ pub const PA_SAMPLE_RATE: u32 = 48000;
|
|||||||
pub(crate) struct InstallingService; // please use new
|
pub(crate) struct InstallingService; // please use new
|
||||||
|
|
||||||
impl InstallingService {
|
impl InstallingService {
|
||||||
|
#[cfg(any(target_os = "windows", target_os = "linux"))]
|
||||||
pub fn new() -> Self {
|
pub fn new() -> Self {
|
||||||
*INSTALLING_SERVICE.lock().unwrap() = true;
|
*INSTALLING_SERVICE.lock().unwrap() = true;
|
||||||
Self
|
Self
|
||||||
|
@ -3,11 +3,12 @@ use async_trait::async_trait;
|
|||||||
use bytes::Bytes;
|
use bytes::Bytes;
|
||||||
use rdev::{Event, EventType::*, KeyCode};
|
use rdev::{Event, EventType::*, KeyCode};
|
||||||
#[cfg(not(any(target_os = "android", target_os = "ios")))]
|
#[cfg(not(any(target_os = "android", target_os = "ios")))]
|
||||||
use std::{collections::HashMap, sync::atomic::AtomicBool};
|
use std::sync::atomic::{AtomicBool, Ordering};
|
||||||
use std::{
|
use std::{
|
||||||
|
collections::HashMap,
|
||||||
ops::{Deref, DerefMut},
|
ops::{Deref, DerefMut},
|
||||||
str::FromStr,
|
str::FromStr,
|
||||||
sync::{atomic::Ordering, Arc, Mutex, RwLock},
|
sync::{Arc, Mutex, RwLock},
|
||||||
time::SystemTime,
|
time::SystemTime,
|
||||||
};
|
};
|
||||||
use uuid::Uuid;
|
use uuid::Uuid;
|
||||||
@ -285,7 +286,9 @@ impl<T: InvokeUiSession> Session<T> {
|
|||||||
#[cfg(feature = "flutter")]
|
#[cfg(feature = "flutter")]
|
||||||
pub fn refresh_video(&self, display: i32) {
|
pub fn refresh_video(&self, display: i32) {
|
||||||
if crate::common::is_support_multi_ui_session_num(self.lc.read().unwrap().version) {
|
if crate::common::is_support_multi_ui_session_num(self.lc.read().unwrap().version) {
|
||||||
self.send(Data::Message(LoginConfigHandler::refresh_display(display as _)));
|
self.send(Data::Message(LoginConfigHandler::refresh_display(
|
||||||
|
display as _,
|
||||||
|
)));
|
||||||
} else {
|
} else {
|
||||||
self.send(Data::Message(LoginConfigHandler::refresh()));
|
self.send(Data::Message(LoginConfigHandler::refresh()));
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user