Enum piston_window::prelude::HatState
source · pub enum HatState {
Centered,
Up,
Right,
Down,
Left,
RightUp,
RightDown,
LeftUp,
LeftDown,
}
Expand description
Stores controller hat state.
Variants§
Centered
Centered (no direction).
Up
Up direction.
Right
Right direction.
Down
Down direction.
Left
Left direction.
RightUp
Right-up direction.
RightDown
Right-down direction.
LeftUp
Left-up direction.
LeftDown
Left-down direction.
Trait Implementations§
source§impl<'de> Deserialize<'de> for HatState
impl<'de> Deserialize<'de> for HatState
source§fn deserialize<__D>(
__deserializer: __D
) -> Result<HatState, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D
) -> Result<HatState, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl Ord for HatState
impl Ord for HatState
source§impl PartialEq for HatState
impl PartialEq for HatState
source§impl PartialOrd for HatState
impl PartialOrd for HatState
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moresource§impl Serialize for HatState
impl Serialize for HatState
source§fn serialize<__S>(
&self,
__serializer: __S
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
impl Copy for HatState
impl Eq for HatState
impl StructuralPartialEq for HatState
Auto Trait Implementations§
impl Freeze for HatState
impl RefUnwindSafe for HatState
impl Send for HatState
impl Sync for HatState
impl Unpin for HatState
impl UnwindSafe for HatState
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