RawKeyboard class

An interface for listening to raw key events.

Raw key events pass through as much information as possible from the underlying platform's key events, which makes them provide a high level of fidelity but a low level of portability.

A RawKeyboard is useful for listening to raw key events and hardware buttons that are represented as keys. Typically used by games and other apps that use keyboards for purposes other than text entry.

See also:

Properties

hashCode int
The hash code for this object. [...]
read-only, inherited
runtimeType Type
A representation of the runtime type of the object.
read-only, inherited

Methods

addListener(void listener) → void
Calls the listener every time the user presses or releases a key. [...]
removeListener(void listener) → void
Stop calling the listener every time the user presses or releases a key. [...]
noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed. [...]
@pragma('vm:entry-point'), inherited
toString() String
Returns a string representation of this object.
inherited

Operators

operator ==(dynamic other) bool
The equality operator. [...]
inherited

Static Properties

instance RawKeyboard
The shared instance of RawKeyboard.
final