Enum pix_engine::event::ControllerButton
source · #[non_exhaustive]pub enum ControllerButton {
Show 22 variants
A,
B,
X,
Y,
Back,
Guide,
Start,
LeftStick,
RightStick,
LeftShoulder,
RightShoulder,
DPadUp,
DPadDown,
DPadLeft,
DPadRight,
Misc1,
Paddle1,
Paddle2,
Paddle3,
Paddle4,
Touchpad,
Unhandled,
}
Expand description
A Controller button
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
A
A button.
B
B button.
X
X button.
Y
Y button.
Back
Back button.
Guide
Guide button.
Start
Start button.
LeftStick
Left axis button.
RightStick
Right axis button.
LeftShoulder
Left shoulder button.
RightShoulder
Right shoulder button.
DPadUp
Directional pad up button.
DPadDown
Directional pad down button.
DPadLeft
Directional pad left button.
DPadRight
Directional pad right button.
Misc1
Misc Controller button
- Xbox Series X share button
- PS5 microphone button
- Nintendo Switch Pro capture button
- Amazon Luna microphone button
Paddle1
Xbox Elite paddle P1
Paddle2
Xbox Elite paddle P2
Paddle3
Xbox Elite paddle P3
Paddle4
Xbox Elite paddle P4
Touchpad
PS4/PS5 touchpad button
Unhandled
An unknown/unsupported button
Trait Implementations§
source§impl Clone for ControllerButton
impl Clone for ControllerButton
source§fn clone(&self) -> ControllerButton
fn clone(&self) -> ControllerButton
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for ControllerButton
impl Debug for ControllerButton
source§impl Default for ControllerButton
impl Default for ControllerButton
source§impl<'de> Deserialize<'de> for ControllerButton
impl<'de> Deserialize<'de> for ControllerButton
source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl Hash for ControllerButton
impl Hash for ControllerButton
source§impl PartialEq for ControllerButton
impl PartialEq for ControllerButton
source§fn eq(&self, other: &ControllerButton) -> bool
fn eq(&self, other: &ControllerButton) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl Serialize for ControllerButton
impl Serialize for ControllerButton
impl Copy for ControllerButton
impl Eq for ControllerButton
impl StructuralEq for ControllerButton
impl StructuralPartialEq for ControllerButton
Auto Trait Implementations§
impl RefUnwindSafe for ControllerButton
impl Send for ControllerButton
impl Sync for ControllerButton
impl Unpin for ControllerButton
impl UnwindSafe for ControllerButton
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
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more