mirror of
https://github.com/feschber/lan-mouse.git
synced 2026-03-12 15:50:55 +03:00
adjust error handling
This commit is contained in:
committed by
Ferdinand Schober
parent
37a8f729ea
commit
ef3ebc59bd
@@ -1,4 +1,5 @@
|
||||
use async_trait::async_trait;
|
||||
use error::EmulationError;
|
||||
use std::fmt::Display;
|
||||
|
||||
use input_event::Event;
|
||||
@@ -70,7 +71,11 @@ impl Display for Backend {
|
||||
|
||||
#[async_trait]
|
||||
pub trait InputEmulation: Send {
|
||||
async fn consume(&mut self, event: Event, handle: EmulationHandle);
|
||||
async fn consume(
|
||||
&mut self,
|
||||
event: Event,
|
||||
handle: EmulationHandle,
|
||||
) -> Result<(), EmulationError>;
|
||||
async fn create(&mut self, handle: EmulationHandle);
|
||||
async fn destroy(&mut self, handle: EmulationHandle);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user