mirror of
https://github.com/feschber/lan-mouse.git
synced 2026-03-11 07:10:54 +03:00
adjust error handling
This commit is contained in:
committed by
Ferdinand Schober
parent
37a8f729ea
commit
ef3ebc59bd
@@ -38,16 +38,12 @@ async fn input_emulation_test(config: Config) -> Result<()> {
|
||||
let relative_motion = (new_offset.0 - offset.0, new_offset.1 - offset.1);
|
||||
offset = new_offset;
|
||||
let (relative_x, relative_y) = (relative_motion.0 as f64, relative_motion.1 as f64);
|
||||
emulation
|
||||
.consume(
|
||||
Event::Pointer(PointerEvent::Motion {
|
||||
time: 0,
|
||||
relative_x,
|
||||
relative_y,
|
||||
}),
|
||||
0,
|
||||
)
|
||||
.await;
|
||||
let event = Event::Pointer(PointerEvent::Motion {
|
||||
time: 0,
|
||||
relative_x,
|
||||
relative_y,
|
||||
});
|
||||
emulation.consume(event, 0).await?;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user