Module piston::input []

Modules

generic_event

Trait for generic events

keyboard

Back-end agnostic keyboard keys.

mouse

Back-end agnostic mouse buttons.

Structs

AfterRenderArgs

After render arguments.

EventId

Used to identify events arguments provided by traits.

IdleArgs

Idle arguments, such as expected idle time in seconds.

RenderArgs

Render arguments

UpdateArgs

Update arguments, such as delta time in seconds

Enums

Button

Models different kinds of buttons.

Event

Adds render and update events to input events

Input

Models input events.

Key

Represent a keyboard key. Keycodes follows SDL http://wiki.libsdl.org/SDLKeycodeLookup

Motion

Models different kinds of motion.

MouseButton

Represent a mouse button.

Traits

AfterRenderEvent

After rendering and buffers are swapped.

CursorEvent

When window gets or looses cursor

FocusEvent

When window gets or looses focus

GenericEvent

Implemented by all events

IdleEvent

When background tasks should be performed

MouseCursorEvent

The position of the mouse cursor

MouseRelativeEvent

The relative movement of mouse cursor

MouseScrollEvent

The scroll of the mouse wheel

PressEvent

The press of a button

ReleaseEvent

The release of a button

RenderEvent

When the next frame should be rendered

ResizeEvent

When the window is resized

TextEvent

When receiving text from user, such as typing a character

UpdateEvent

When the application state should be updated