mirror of
https://github.com/mofeng-git/One-KVM.git
synced 2026-11-01 18:30:51 +08:00
perf(audio,hid): 减少 PCM 复制和鼠标热路径分配与轮询
This commit is contained in:
@@ -871,7 +871,7 @@ impl HidBackend for OtgBackend {
|
||||
let extent = self.screen_resolution.read().unwrap_or((1920, 1080));
|
||||
let (buttons, reports) = state.plan(event, buttons, extent);
|
||||
self.mouse_buttons.store(buttons, Ordering::Relaxed);
|
||||
for report in reports {
|
||||
for report in reports.iter().copied() {
|
||||
match report {
|
||||
MouseReport::Absolute { buttons, x, y } => {
|
||||
self.send_mouse_report_absolute(buttons, x, y, 0)?
|
||||
|
||||
Reference in New Issue
Block a user