[][src]Struct kurenai::key_event::KeyEvent

pub struct KeyEvent { /* fields omitted */ }

This struct shows which key is down and which is up.

Implementations

impl KeyEvent[src]

pub fn new() -> Self[src]

This function creates a new instance. Pass it to KeyEvent::run().

pub fn run(key_event_rc: Rc<RefCell<Self>>)[src]

This function calls add_event_listener_with_callback() and starts to serve KeyEvent.

impl KeyEvent[src]

pub fn enter(&self) -> bool[src]

If the Enter key is down(up), this function returns true(false).

pub fn arrow_left(&self) -> bool[src]

If the ArrowLeft key is down(up), this function returns true(false).

pub fn arrow_up(&self) -> bool[src]

If the ArrowUp key is down(up), this function returns true(false).

pub fn arrow_right(&self) -> bool[src]

If the ArrowRight key is down(up), this function returns true(false).

pub fn arrow_down(&self) -> bool[src]

If the ArrowDown key is down(up), this function returns true(false).

pub fn digit_0(&self) -> bool[src]

If the Digit0 key is down(up), this function returns true(false).

pub fn digit_1(&self) -> bool[src]

If the Digit1 key is down(up), this function returns true(false).

pub fn digit_2(&self) -> bool[src]

If the Digit2 key is down(up), this function returns true(false).

pub fn digit_3(&self) -> bool[src]

If the Digit3 key is down(up), this function returns true(false).

pub fn digit_4(&self) -> bool[src]

If the Digit4 key is down(up), this function returns true(false).

pub fn digit_5(&self) -> bool[src]

If the Digit5 key is down(up), this function returns true(false).

pub fn digit_6(&self) -> bool[src]

If the Digit6 key is down(up), this function returns true(false).

pub fn digit_7(&self) -> bool[src]

If the Digit7 key is down(up), this function returns true(false).

pub fn digit_8(&self) -> bool[src]

If the Digit8 key is down(up), this function returns true(false).

pub fn digit_9(&self) -> bool[src]

If the Digit9 key is down(up), this function returns true(false).

pub fn key_a(&self) -> bool[src]

If the KeyA key is down(up), this function returns true(false).

pub fn key_b(&self) -> bool[src]

If the KeyB key is down(up), this function returns true(false).

pub fn key_c(&self) -> bool[src]

If the KeyC key is down(up), this function returns true(false).

pub fn key_d(&self) -> bool[src]

If the KeyD key is down(up), this function returns true(false).

pub fn key_e(&self) -> bool[src]

If the KeyE key is down(up), this function returns true(false).

pub fn key_f(&self) -> bool[src]

If the KeyF key is down(up), this function returns true(false).

pub fn key_g(&self) -> bool[src]

If the KeyG key is down(up), this function returns true(false).

pub fn key_h(&self) -> bool[src]

If the KeyH key is down(up), this function returns true(false).

pub fn key_i(&self) -> bool[src]

If the KeyI key is down(up), this function returns true(false).

pub fn key_j(&self) -> bool[src]

If the KeyJ key is down(up), this function returns true(false).

pub fn key_k(&self) -> bool[src]

If the KeyK key is down(up), this function returns true(false).

pub fn key_l(&self) -> bool[src]

If the KeyL key is down(up), this function returns true(false).

pub fn key_m(&self) -> bool[src]

If the KeyM key is down(up), this function returns true(false).

pub fn key_n(&self) -> bool[src]

If the KeyN key is down(up), this function returns true(false).

pub fn key_o(&self) -> bool[src]

If the KeyO key is down(up), this function returns true(false).

pub fn key_p(&self) -> bool[src]

If the KeyP key is down(up), this function returns true(false).

pub fn key_q(&self) -> bool[src]

If the KeyQ key is down(up), this function returns true(false).

pub fn key_r(&self) -> bool[src]

If the KeyR key is down(up), this function returns true(false).

pub fn key_s(&self) -> bool[src]

If the KeyS key is down(up), this function returns true(false).

pub fn key_t(&self) -> bool[src]

If the KeyT key is down(up), this function returns true(false).

pub fn key_u(&self) -> bool[src]

If the KeyU key is down(up), this function returns true(false).

pub fn key_v(&self) -> bool[src]

If the KeyV key is down(up), this function returns true(false).

pub fn key_w(&self) -> bool[src]

If the KeyW key is down(up), this function returns true(false).

pub fn key_x(&self) -> bool[src]

If the KeyX key is down(up), this function returns true(false).

pub fn key_y(&self) -> bool[src]

If the KeyY key is down(up), this function returns true(false).

pub fn key_z(&self) -> bool[src]

If the KeyZ key is down(up), this function returns true(false).

Trait Implementations

impl Clone for KeyEvent[src]

impl Copy for KeyEvent[src]

impl Debug for KeyEvent[src]

Auto Trait Implementations

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> 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.