Enum conrod::input::Button [−][src]
pub enum Button { Keyboard(Key), Mouse(MouseButton), Controller(ControllerButton), Hat(ControllerHat), }
Models different kinds of buttons.
Variants
Keyboard(Key)
A keyboard button.
Mouse(MouseButton)
A mouse button.
Controller(ControllerButton)
A controller button.
Hat(ControllerHat)
A controller hat (d-Pad)
Trait Implementations
impl Hash for Button
[src]
impl Hash for Button
fn hash<__H>(&self, state: &mut __H) where
__H: Hasher,
[src]
fn hash<__H>(&self, state: &mut __H) where
__H: Hasher,
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 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 Debug for Button
[src]
impl Debug for Button
fn fmt(&self, f: &mut Formatter) -> Result<(), Error>
[src]
fn fmt(&self, f: &mut Formatter) -> Result<(), Error>
Formats the value using the given formatter. Read more
impl From<ControllerButton> for Button
[src]
impl From<ControllerButton> for Button
fn from(btn: ControllerButton) -> Button
[src]
fn from(btn: ControllerButton) -> Button
Performs the conversion.
impl From<Key> for Button
[src]
impl From<Key> for Button
impl From<MouseButton> for Button
[src]
impl From<MouseButton> for Button
fn from(btn: MouseButton) -> Button
[src]
fn from(btn: MouseButton) -> Button
Performs the conversion.
impl Serialize for Button
[src]
impl Serialize for Button
fn serialize<__S>(
&self,
__serializer: __S
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error> where
__S: Serializer,
[src]
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 Button
[src]
impl Copy for Button
impl Eq for Button
[src]
impl Eq for Button
impl PartialEq<Button> for Button
[src]
impl PartialEq<Button> 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: &Button) -> bool
[src]
fn ne(&self, other: &Button) -> bool
This method tests for !=
.
impl<'de> Deserialize<'de> for Button
[src]
impl<'de> Deserialize<'de> for Button
fn deserialize<__D>(
__deserializer: __D
) -> Result<Button, <__D as Deserializer<'de>>::Error> where
__D: Deserializer<'de>,
[src]
fn deserialize<__D>(
__deserializer: __D
) -> Result<Button, <__D as Deserializer<'de>>::Error> where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more