pub enum Event {
CursorEntered,
CursorLeft,
CursorMoved {
position: Point,
},
ButtonPressed(Button),
ButtonReleased(Button),
WheelScrolled {
delta: ScrollDelta,
},
}
Expand description
A mouse event.
Note: This type is largely incomplete! If you need to track additional events, feel free to open an issue and share your use case!
Variants§
CursorEntered
The mouse cursor entered the window.
CursorLeft
The mouse cursor left the window.
CursorMoved
The mouse cursor was moved
ButtonPressed(Button)
A mouse button was pressed.
ButtonReleased(Button)
A mouse button was released.
WheelScrolled
The mouse wheel was scrolled.
Fields
§
delta: ScrollDelta
The scroll movement.
Trait Implementations§
impl Copy for Event
impl StructuralPartialEq for Event
Auto Trait Implementations§
impl Freeze for Event
impl RefUnwindSafe for Event
impl Send for Event
impl Sync for Event
impl Unpin for Event
impl UnwindSafe for Event
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