mirror of
https://github.com/rustdesk/rustdesk.git
synced 2024-12-12 02:09:12 +08:00
fix build sciter
Signed-off-by: fufesou <shuanglongchen@yeah.net>
This commit is contained in:
parent
ae3efa1151
commit
72f5fbd6ad
@ -400,9 +400,9 @@ pub fn session_enter_or_leave(_session_id: SessionID, _enter: bool) -> SyncRetur
|
||||
let keyboard_mode = session.get_keyboard_mode();
|
||||
if _enter {
|
||||
set_cur_session_id_(_session_id, &keyboard_mode);
|
||||
session.enter(&keyboard_mode);
|
||||
session.enter(keyboard_mode);
|
||||
} else {
|
||||
session.leave(&keyboard_mode);
|
||||
session.leave(keyboard_mode);
|
||||
}
|
||||
}
|
||||
SyncReturn(())
|
||||
|
@ -409,8 +409,8 @@ impl sciter::EventHandler for SciterSession {
|
||||
fn login(String, String, String, bool);
|
||||
fn new_rdp();
|
||||
fn send_mouse(i32, i32, i32, bool, bool, bool, bool);
|
||||
fn enter();
|
||||
fn leave();
|
||||
fn enter(String);
|
||||
fn leave(String);
|
||||
fn ctrl_alt_del();
|
||||
fn transfer_file();
|
||||
fn tunnel();
|
||||
|
@ -273,12 +273,12 @@ function handler.onMouse(evt)
|
||||
case Event.MOUSE_ENTER:
|
||||
entered = true;
|
||||
stdout.println("enter");
|
||||
handler.enter();
|
||||
handler.enter(handler.get_keyboard_mode());
|
||||
return keyboard_enabled;
|
||||
case Event.MOUSE_LEAVE:
|
||||
entered = false;
|
||||
stdout.println("leave");
|
||||
handler.leave();
|
||||
handler.leave(handler.get_keyboard_mode());
|
||||
if (is_left_down && handler.peer_platform() == "Android") {
|
||||
is_left_down = false;
|
||||
handler.send_mouse((1 << 3) | 2, 0, 0, evt.altKey,
|
||||
|
@ -572,15 +572,15 @@ impl<T: InvokeUiSession> Session<T> {
|
||||
}
|
||||
|
||||
#[cfg(not(any(target_os = "android", target_os = "ios")))]
|
||||
pub fn enter(&self, keyboard_mode: &str) {
|
||||
pub fn enter(&self, keyboard_mode: String) {
|
||||
IS_IN.store(true, Ordering::SeqCst);
|
||||
keyboard::client::change_grab_status(GrabState::Run, keyboard_mode);
|
||||
keyboard::client::change_grab_status(GrabState::Run, &keyboard_mode);
|
||||
}
|
||||
|
||||
#[cfg(not(any(target_os = "android", target_os = "ios")))]
|
||||
pub fn leave(&self, keyboard_mode: &str) {
|
||||
pub fn leave(&self, keyboard_mode: String) {
|
||||
IS_IN.store(false, Ordering::SeqCst);
|
||||
keyboard::client::change_grab_status(GrabState::Wait, keyboard_mode);
|
||||
keyboard::client::change_grab_status(GrabState::Wait, &keyboard_mode);
|
||||
}
|
||||
|
||||
// flutter only TODO new input
|
||||
|
Loading…
Reference in New Issue
Block a user