pub struct MouseState {
pub current_position: Vec2,
pub prev_position: Vec2,
pub buttons: HashMap<MouseButton, MouseButtonMeta, BuildNoHashHasher<u16>>,
pub released_buttons: HashMap<MouseButton, MouseButtonMeta, BuildNoHashHasher<u16>>,
}Fields§
§current_position: Vec2Current position of the mouse pointer
prev_position: Vec2Position of the mouse pointer on the previous frame
Current state of each mouse button (if down)
mouse buttons that were released in the current frame
Trait Implementations§
Source§impl Default for MouseState
impl Default for MouseState
Source§fn default() -> MouseState
fn default() -> MouseState
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for MouseState
impl RefUnwindSafe for MouseState
impl Send for MouseState
impl Sync for MouseState
impl Unpin for MouseState
impl UnwindSafe for MouseState
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