Enum gilrs::ev::Button [−][src]
#[repr(u16)]pub enum Button { South, East, North, West, C, Z, LeftTrigger, LeftTrigger2, RightTrigger, RightTrigger2, Select, Start, Mode, LeftThumb, RightThumb, DPadUp, DPadDown, DPadLeft, DPadRight, Unknown, }
Gamepad's elements which state can be represented by value from 0.0 to 1.0.
Variants
South
East
North
West
C
Z
LeftTrigger
LeftTrigger2
RightTrigger
RightTrigger2
Select
Start
Mode
LeftThumb
RightThumb
DPadUp
DPadDown
DPadLeft
DPadRight
Unknown
Methods
impl Button
[src]
impl Button
pub fn is_action(self) -> bool
[src]
pub fn is_action(self) -> bool
pub fn is_trigger(self) -> bool
[src]
pub fn is_trigger(self) -> bool
pub fn is_stick(self) -> bool
[src]
pub fn is_stick(self) -> bool
pub fn is_dpad(self) -> bool
[src]
pub fn is_dpad(self) -> bool
pub fn to_nec(self) -> Option<Code>
[src]
pub fn to_nec(self) -> Option<Code>
Trait Implementations
impl Debug for Button
[src]
impl Debug for Button
fn fmt(&self, f: &mut Formatter) -> Result
[src]
fn fmt(&self, f: &mut Formatter) -> Result
Formats the value using the given formatter. Read more
impl Clone for Button
[src]
impl Clone for Button
fn clone(&self) -> Button
[src]
fn clone(&self) -> Button
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
fn clone_from(&mut self, source: &Self)
1.0.0
[src]Performs copy-assignment from source
. Read more
impl Copy for Button
[src]
impl Copy for Button
impl Eq for Button
[src]
impl Eq for Button
impl PartialEq for Button
[src]
impl PartialEq for Button
fn eq(&self, other: &Button) -> bool
[src]
fn eq(&self, other: &Button) -> bool
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]
fn ne(&self, other: &Rhs) -> bool
1.0.0
[src]This method tests for !=
.
impl Hash for Button
[src]
impl Hash for Button
fn hash<__H: Hasher>(&self, state: &mut __H)
[src]
fn hash<__H: Hasher>(&self, state: &mut __H)
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]
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
1.3.0
[src]Feeds a slice of this type into the given [Hasher
]. Read more
impl Default for Button
[src]
impl Default for Button