pub struct InputState {
pub primary_pointer: PrimaryPointerState,
pub keyboard: KeyboardState,
}Expand description
A stateful view of the input data for a frame, rather than processing it event-by-event.
Fields§
§primary_pointer: PrimaryPointerStateThe state of the primary pointer.
keyboard: KeyboardStateThe state of the keyboard.
Implementations§
Source§impl InputState
impl InputState
Sourcepub fn clear_frame(&mut self)
pub fn clear_frame(&mut self)
Clear the per-frame state to prepare for a new frame.
Trait Implementations§
Source§impl Debug for InputState
impl Debug for InputState
Source§impl Default for InputState
impl Default for InputState
Source§fn default() -> InputState
fn default() -> InputState
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for InputState
impl RefUnwindSafe for InputState
impl Send for InputState
impl Sync for InputState
impl Unpin for InputState
impl UnwindSafe for InputState
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