mirror of
https://github.com/VallierDev/uu-remote-linux.git
synced 2026-11-16 16:50:41 +01:00
Release v0.2.6: input diagnostics (#46), Mac terminal fix
Log unsupported CONTROL input actions (names only) and the server NumLock state for numpad keys; skip the SDL window test on macOS (main-thread SDL). Co-Authored-By: Claude Opus 5.5 <[email protected]>
This commit is contained in:
1 parent
72c1e6101f
commit
72559f9ef9
6 files changed
+41
-2
No files matched your search
Generated
+1
-1
@@ -2741,7 +2741,7 @@ checksum = "06abde3611657adf66d383f00b093d7faecc7fa57071cce2578660c9f1010821"
|
||||
|
||||
[[package]]
|
||||
name = "uu-remote-linux"
|
||||
version = "0.2.5"
|
||||
version = "0.2.6"
|
||||
dependencies = [
|
||||
"async-trait",
|
||||
"base64 0.22.1",
|
||||
|
||||
+1
-1
@@ -1,6 +1,6 @@
|
||||
[package]
|
||||
name = "uu-remote-linux"
|
||||
version = "0.2.5"
|
||||
version = "0.2.6"
|
||||
edition = "2021"
|
||||
default-run = "uuremote-server"
|
||||
authors = ["uu-remote-linux contributors"]
|
||||
|
||||
@@ -0,0 +1,19 @@
|
||||
控制端可打开官方 Mac 被控端的终端;输入问题诊断日志。/ Viewer terminal works with the official Mac host; input diagnostics.
|
||||
|
||||
### 控制端修复 / Viewer — fixed
|
||||
- **连接官方 Mac 被控端的终端**:之前一连上就断开(「Terminal channel closed」)。Mac 被控端把终端的应答发在终端通道上,
|
||||
控制端现在能识别。已实机验证:可打开终端并正常回显。Mac 被控端的端口映射也已实测可用。
|
||||
Terminal sessions with the official Mac host now open (verified live); port mapping with it was verified too.
|
||||
|
||||
### 主机端诊断 / Host diagnostics(#46)
|
||||
- 收到不认识的输入事件时记一条日志(只有动作名和字段名,**不含输入内容**),用于排查手机输入法打字无反应。
|
||||
- 小键盘按键记录被控端当前的 NumLock 状态(只记开/关,不记按键),用于排查小键盘不出数字。
|
||||
- Logs unsupported input actions (names only, never typed text) and the server's NumLock state for numpad keys.
|
||||
|
||||
### 其他 / Other
|
||||
- README 标题与开头加入控制端介绍并放上截图(#44)。
|
||||
|
||||
### 下载 / Download
|
||||
`uu-remote-linux-v0.2.6-x86_64-linux.tar.gz`:主机 `uuremote-server`(X11 版)与控制端 `uuremote-viewer`(x86_64,glibc ≥ 2.35;控制端需 SDL2、GTK3、ffmpeg),附带 `contrib/`。
|
||||
|
||||
**非官方项目,与网易无关。** / **Unofficial, not affiliated with NetEase.**
|
||||
@@ -248,6 +248,14 @@ impl InputInjector {
|
||||
if AUDIT.fetch_add(1,std::sync::atomic::Ordering::Relaxed) < 8 {
|
||||
log::info!("Desktop keyboard injection outcome: result={result}");
|
||||
}
|
||||
// KP_0..KP_9 type digits only with NumLock on (#46); record the server's NumLock state, not the key.
|
||||
static NUMPAD: std::sync::atomic::AtomicUsize = std::sync::atomic::AtomicUsize::new(0);
|
||||
if (0x60..=0x6f).contains(&key) && is_press && self.backend==crate::desktop_backend::DesktopBackend::X11
|
||||
&& NUMPAD.fetch_add(1,std::sync::atomic::Ordering::Relaxed) < 4 {
|
||||
let (mut x,mut y,mut mask)=(0,0,0u32);
|
||||
let state=unsafe { x11_pointer_state(&mut x,&mut y,&mut mask) };
|
||||
log::info!("Desktop numpad key: result={result} numlock={}", state==0 && mask & 0x10 != 0);
|
||||
}
|
||||
if result == 0 {
|
||||
let mut held=self.held.lock().unwrap();
|
||||
if is_press {held.keys.insert(symbol);} else {held.keys.remove(&symbol);}
|
||||
|
||||
@@ -163,6 +163,8 @@ pub async fn run(session:&mut Session,window:&mut Window,decoder:&mut dyn super:
|
||||
|
||||
#[cfg(test)] mod tests {
|
||||
use super::*;
|
||||
// macOS: SDL video must start on the main thread, which the test harness does not use; CI runs it on Linux.
|
||||
#[cfg_attr(target_os="macos",ignore)]
|
||||
#[tokio::test] async fn clipboard_requests_use_existing_window(){
|
||||
if std::env::var_os("UU_VIEWER_CLIPBOARD_TEST_CHILD").is_none(){
|
||||
let output=std::process::Command::new(std::env::current_exe().unwrap())
|
||||
|
||||
@@ -1071,6 +1071,16 @@ impl WebRtcSession {
|
||||
});}
|
||||
|
||||
},
|
||||
Ok(crate::control_protocol::ControlMessage::Unsupported(v)) => {
|
||||
// Action name and key names only, never values (an IME text event would carry typed text).
|
||||
static UNSUPPORTED: std::sync::atomic::AtomicUsize = std::sync::atomic::AtomicUsize::new(0);
|
||||
if UNSUPPORTED.fetch_add(1, std::sync::atomic::Ordering::Relaxed) < 16 {
|
||||
let action = v.get("action").and_then(serde_json::Value::as_str)
|
||||
.filter(|a| a.len() <= 40 && a.bytes().all(|b| b.is_ascii_alphanumeric() || b == b'_')).unwrap_or("?");
|
||||
let keys: Vec<&str> = v.as_object().map(|o| o.keys().map(String::as_str).take(12).collect()).unwrap_or_default();
|
||||
log::info!("Unsupported CONTROL input: action={action} keys={keys:?}");
|
||||
}
|
||||
},
|
||||
_ => {}
|
||||
}
|
||||
} else if channel_name.contains("STREAMER") {
|
||||
|
||||
Reference in new issue
Block a user