pub enum KeyState {
Down,
Up,
}
Expand description
Describes the state a key is in.
Variants§
Down
The key is pressed down.
Often emitted in a keydown event, see also the MDN documentation on that.
Up
The key is not pressed / was just released.
Often emitted in a keyup event, see also the MDN documentation on that.
Implementations§
Trait Implementations§
Source§impl Ord for KeyState
impl Ord for KeyState
Source§impl PartialOrd for KeyState
impl PartialOrd for KeyState
impl Copy for KeyState
impl Eq for KeyState
impl StructuralPartialEq for KeyState
Auto Trait Implementations§
impl Freeze for KeyState
impl RefUnwindSafe for KeyState
impl Send for KeyState
impl Sync for KeyState
impl Unpin for KeyState
impl UnwindSafe for KeyState
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