mirror of
https://github.com/weyne85/rustdesk.git
synced 2025-10-29 17:00:05 +00:00
Merge remote-tracking branch 'rd/master' into feat/x11/clipboard-file/init
Signed-off-by: ClSlaid <cailue@bupt.edu.cn>
This commit is contained in:
@@ -144,7 +144,7 @@ class Header: Reactor.Component {
|
||||
<span #action>{svg_action}</span>
|
||||
<span #display>{svg_display}</span>
|
||||
<span #keyboard>{svg_keyboard}</span>
|
||||
{recording_enabled && qualityMonitorData[4] != "AV1" ? <span #recording>{recording ? svg_recording_on : svg_recording_off}</span> : ""}
|
||||
{recording_enabled ? <span #recording>{recording ? svg_recording_on : svg_recording_off}</span> : ""}
|
||||
{this.renderKeyboardPop()}
|
||||
{this.renderDisplayPop()}
|
||||
{this.renderActionPop()}
|
||||
@@ -299,14 +299,22 @@ class Header: Reactor.Component {
|
||||
header.update();
|
||||
handler.record_status(recording);
|
||||
// 0 is just a dummy value. It will be ignored by the handler.
|
||||
if (recording)
|
||||
if (recording) {
|
||||
handler.refresh_video(0);
|
||||
else
|
||||
handler.record_screen(false, 0, display_width, display_height);
|
||||
if (handler.version_cmp(pi.version, '1.2.4') >= 0) handler.record_screen(recording, pi.current_display, display_width, display_height);
|
||||
}
|
||||
else {
|
||||
handler.record_screen(recording, pi.current_display, display_width, display_height);
|
||||
}
|
||||
}
|
||||
|
||||
event click $(#screen) (_, me) {
|
||||
if (pi.current_display == me.index) return;
|
||||
if (recording) {
|
||||
recording = false;
|
||||
handler.record_screen(false, pi.current_display, display_width, display_height);
|
||||
handler.record_status(false);
|
||||
}
|
||||
handler.switch_display(me.index);
|
||||
}
|
||||
|
||||
|
||||
@@ -243,6 +243,7 @@ impl InvokeUiSession for SciterHandler {
|
||||
pi_sciter.set_item("sas_enabled", pi.sas_enabled);
|
||||
pi_sciter.set_item("displays", Self::make_displays_array(&pi.displays));
|
||||
pi_sciter.set_item("current_display", pi.current_display);
|
||||
pi_sciter.set_item("version", pi.version.clone());
|
||||
self.call("updatePi", &make_args!(pi_sciter));
|
||||
}
|
||||
|
||||
@@ -469,6 +470,7 @@ impl sciter::EventHandler for SciterSession {
|
||||
fn restart_remote_device();
|
||||
fn request_voice_call();
|
||||
fn close_voice_call();
|
||||
fn version_cmp(String, String);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -757,6 +759,10 @@ impl SciterSession {
|
||||
log::error!("Failed to spawn IP tunneling: {}", err);
|
||||
}
|
||||
}
|
||||
|
||||
fn version_cmp(&self, v1: String, v2: String) -> i32 {
|
||||
(hbb_common::get_version_number(&v1) - hbb_common::get_version_number(&v2)) as i32
|
||||
}
|
||||
}
|
||||
|
||||
pub fn make_fd(id: i32, entries: &Vec<FileEntry>, only_count: bool) -> Value {
|
||||
|
||||
@@ -522,7 +522,6 @@ handler.updateQualityStatus = function(speed, fps, delay, bitrate, codec_format)
|
||||
bitrate ? qualityMonitorData[3] = bitrate:null;
|
||||
codec_format ? qualityMonitorData[4] = codec_format:null;
|
||||
qualityMonitor.update();
|
||||
if (codec_format) header.update();
|
||||
}
|
||||
|
||||
handler.setPermission = function(name, enabled) {
|
||||
|
||||
Reference in New Issue
Block a user