pub struct Buttons(pub u32);Expand description
Virtual gamepad buttons (bit positions per spec/ABI.md).
Tuple Fields§
§0: u32Implementations§
Source§impl Buttons
impl Buttons
pub const A: u32 = sys::GASM_BTN_A
pub const B: u32 = sys::GASM_BTN_B
pub const X: u32 = sys::GASM_BTN_X
pub const Y: u32 = sys::GASM_BTN_Y
pub const L: u32 = sys::GASM_BTN_L
pub const R: u32 = sys::GASM_BTN_R
pub const SELECT: u32 = sys::GASM_BTN_SELECT
pub const START: u32 = sys::GASM_BTN_START
pub const UP: u32 = sys::GASM_BTN_UP
pub const DOWN: u32 = sys::GASM_BTN_DOWN
pub const LEFT: u32 = sys::GASM_BTN_LEFT
pub const RIGHT: u32 = sys::GASM_BTN_RIGHT
pub fn held(self, mask: u32) -> bool
Trait Implementations§
impl Copy for Buttons
impl Eq for Buttons
impl StructuralPartialEq for Buttons
Auto Trait Implementations§
impl Freeze for Buttons
impl RefUnwindSafe for Buttons
impl Send for Buttons
impl Sync for Buttons
impl Unpin for Buttons
impl UnsafeUnpin for Buttons
impl UnwindSafe for Buttons
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