1
0

switch to evdev_rs::ReadFlag::BLOCKING

closes #4
This commit is contained in:
Daniel Prilik
2021-02-14 11:52:25 -05:00
parent 6c719dc59e
commit 815764b1a4

View File

@@ -78,7 +78,7 @@ impl EventsWorker {
loop { loop {
let _ = self let _ = self
.events .events
.send(match device.next_event(evdev_rs::ReadFlag::NORMAL) { .send(match device.next_event(evdev_rs::ReadFlag::BLOCKING) {
Ok((read_status, event)) => RawInputEvent::Event(read_status, event), Ok((read_status, event)) => RawInputEvent::Event(read_status, event),
// this error corresponds to the device disconnecting, which is fine // this error corresponds to the device disconnecting, which is fine
Err(e) if e.raw_os_error() == Some(19) => break, Err(e) if e.raw_os_error() == Some(19) => break,