Enum sdl2::joystick::HatState
[−]
[src]
pub enum HatState { Centered, Up, Right, Down, Left, RightUp, RightDown, LeftUp, Leftdown, }
This is represented in SDL2 as a bitfield but obviously not all combinations make sense: 5 for instance would mean up and down at the same time... To simplify things I turn it into an enum which is how the SDL2 docs present it anyway (using macros).
Variants
Centered
Up
Right
Down
Left
RightUp
RightDown
LeftUp
Leftdown
Methods
impl HatState
[src]
Trait Implementations
impl Copy for HatState
[src]
impl Clone for HatState
[src]
fn clone(&self) -> HatState
[src]
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more
impl Eq for HatState
[src]
impl PartialEq for HatState
[src]
fn eq(&self, __arg_0: &HatState) -> bool
[src]
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &Rhs) -> bool
1.0.0[src]
This method tests for !=
.
impl Hash for HatState
[src]
fn hash<__H: Hasher>(&self, __arg_0: &mut __H)
[src]
Feeds this value into the given [Hasher
]. Read more
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
1.3.0[src]
H: Hasher,
Feeds a slice of this type into the given [Hasher
]. Read more