[][src]Enum sunrise_keyboard::ps2::Key

enum Key {
    Letter(LetterKey),
    Control(ControlKey),
    Scancode(HidKeyboardScancode),
    Unknown,
}

A key is either a letter key, a control key, or not attributed

Variants

Letter(LetterKey)
Control(ControlKey)
Scancode(HidKeyboardScancode)
Unknown

Implementations

impl Key[src]

const fn ctrl(s: &'static str) -> Key[src]

Create a control key with the given human-readable name.

const fn letter(l: u8, u: u8) -> Key[src]

Create a letter key with the given lowercase and uppercase representations.

const fn scancode(scancode: HidKeyboardScancode) -> Key[src]

Create a scancode key with the given scancode.

Trait Implementations

impl Clone for Key[src]

impl Copy for Key[src]

impl Debug for Key[src]

Auto Trait Implementations

impl RefUnwindSafe for Key

impl Send for Key

impl Sync for Key

impl Unpin for Key

impl UnwindSafe for Key

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<T> SizedIPCBuffer for T[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.