1
0
Fork 0
forked from wry/wry

autocommit 2022-03-30 22:27:19 CEST

This commit is contained in:
Julian Orth 2022-03-30 22:27:19 +02:00
parent a8136ed88c
commit ab4ac883ee
19 changed files with 434 additions and 76 deletions

View file

@ -24,6 +24,10 @@ pub trait InputDevice {
fn on_change(&self, cb: Rc<dyn Fn()>);
fn grab(&self, grab: bool);
fn has_capability(&self, cap: InputDeviceCapability) -> bool;
fn set_left_handed(&self, left_handed: bool);
fn set_accel_profile(&self, profile: InputDeviceAccelProfile);
fn set_accel_speed(&self, speed: f64);
fn set_transform_matrix(&self, matrix: [[f64; 2]; 2]);
}
#[derive(Debug, Copy, Clone)]
@ -37,6 +41,12 @@ pub enum InputDeviceCapability {
Switch,
}
#[derive(Debug, Copy, Clone)]
pub enum InputDeviceAccelProfile {
Flat,
Adaptive,
}
pub enum BackendEvent {
NewOutput(Rc<dyn Output>),
NewInputDevice(Rc<dyn InputDevice>),