Trait smithay::backend::input::PointerAxisEvent [−][src]
pub trait PointerAxisEvent<B: InputBackend>: Event<B> { fn amount(&self, axis: Axis) -> Option<f64>; fn amount_discrete(&self, axis: Axis) -> Option<f64>; fn source(&self) -> AxisSource; }
Expand description
Trait for pointer events generated by scrolling on an axis.
Required methods
Amount of scrolling in pixels on the given Axis
.
Guaranteed to be Some
when source returns either AxisSource::Finger
or AxisSource::Continuous
.
fn amount_discrete(&self, axis: Axis) -> Option<f64>
fn amount_discrete(&self, axis: Axis) -> Option<f64>
Amount of scrolling in discrete steps on the given Axis
.
Guaranteed to be Some
when source returns either AxisSource::Wheel
or AxisSource::WheelTilt
.
fn source(&self) -> AxisSource
fn source(&self) -> AxisSource
Source of the scroll event.