Enum input_event::PointerEvent
source · pub enum PointerEvent {
Motion {
time: u32,
dx: f64,
dy: f64,
},
Button {
time: u32,
button: u32,
state: u32,
},
Axis {
time: u32,
axis: u8,
value: f64,
},
AxisDiscrete120 {
axis: u8,
value: i32,
},
Frame {},
}Variants§
Motion
relative motion event
Button
mouse button event
Axis
axis event, scroll event for touchpads
AxisDiscrete120
discrete axis event, scroll event for mice - 120 = one scroll tick
Frame
frame event
Trait Implementations§
source§impl Clone for PointerEvent
impl Clone for PointerEvent
source§fn clone(&self) -> PointerEvent
fn clone(&self) -> PointerEvent
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moresource§impl Debug for PointerEvent
impl Debug for PointerEvent
source§impl Display for PointerEvent
impl Display for PointerEvent
source§impl From<&PointerEvent> for Vec<u8>
impl From<&PointerEvent> for Vec<u8>
source§fn from(event: &PointerEvent) -> Self
fn from(event: &PointerEvent) -> Self
Converts to this type from the input type.
source§impl PartialEq for PointerEvent
impl PartialEq for PointerEvent
source§impl TryFrom<Vec<u8>> for PointerEvent
impl TryFrom<Vec<u8>> for PointerEvent
§type Error = ProtocolError
type Error = ProtocolError
The type returned in the event of a conversion error.
impl Copy for PointerEvent
impl StructuralPartialEq for PointerEvent
Auto Trait Implementations§
impl Freeze for PointerEvent
impl RefUnwindSafe for PointerEvent
impl Send for PointerEvent
impl Sync for PointerEvent
impl Unpin for PointerEvent
impl UnwindSafe for PointerEvent
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit)source§impl<T> CloneToUninit for Twhere
T: Copy,
impl<T> CloneToUninit for Twhere
T: Copy,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit)