[][src]Struct fermium::events::SDL_MouseWheelEvent

#[repr(C)]pub struct SDL_MouseWheelEvent {
    pub type_: SDL_EventType,
    pub timestamp: u32,
    pub windowID: u32,
    pub which: u32,
    pub x: i32,
    pub y: i32,
    pub direction: SDL_MouseWheelDirection,
}

Mouse wheel event structure (event.wheel.*)

Fields

type_: SDL_EventType

Should always be SDL_MOUSEWHEEL

timestamp: u32

In milliseconds, populated using [SDL_GetTicks].

windowID: u32

The window with mouse focus, if any.

which: u32

The mouse instance id, or SDL_TOUCH_MOUSEID.

x: i32

The amount scrolled horizontally, positive to the right and negative to the left

y: i32

The amount scrolled vertically, positive away from the user and negative toward the user

direction: SDL_MouseWheelDirection

SDL_MOUSEWHEEL_NORMAL or SDL_MOUSEWHEEL_FLIPPED.

When SDL_MOUSEWHEEL_FLIPPED, the values in X and Y will be opposite. Multiply by -1 to change them back.

Trait Implementations

impl Clone for SDL_MouseWheelEvent[src]

impl Copy for SDL_MouseWheelEvent[src]

impl Debug for SDL_MouseWheelEvent[src]

impl Default for SDL_MouseWheelEvent[src]

impl Eq for SDL_MouseWheelEvent[src]

impl Hash for SDL_MouseWheelEvent[src]

impl Ord for SDL_MouseWheelEvent[src]

impl PartialEq<SDL_MouseWheelEvent> for SDL_MouseWheelEvent[src]

impl PartialOrd<SDL_MouseWheelEvent> for SDL_MouseWheelEvent[src]

impl StructuralEq for SDL_MouseWheelEvent[src]

impl StructuralPartialEq for SDL_MouseWheelEvent[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.