core :: Object :: class_factory
Implementation used byget_class
to create the specific class.
core :: Object :: defaultinit
mnit :: KeyEvent :: defaultinit
mnit :: InputEvent :: defaultinit
core :: Object :: is_same_instance
Return true ifself
and other
are the same instance (i.e. same identity).
core :: Object :: is_same_serialized
Isself
the same as other
in a serialization context?
core :: Object :: is_same_type
Return true ifself
and other
have the same dynamic type.
core :: Object :: output_class_name
Display class name on stdout (debug only).
# Keyboard or other keys event
interface KeyEvent
super InputEvent
# Key is currently down?
fun is_down: Bool is abstract
# Key is currently up?
fun is_up: Bool do return not is_down
# Key is the up arrow key?
fun is_arrow_up: Bool is abstract
# Key is the left arrow key?
fun is_arrow_left: Bool is abstract
# Key is the down arrow key?
fun is_arrow_down: Bool is abstract
# Key is the right arrow key?
fun is_arrow_right: Bool is abstract
# Key code, is plateform specific
fun code: Int is abstract
# Get Char value of key, if any
fun to_c: nullable Char is abstract
# Name of the key that raised `self`
#
# Use mainly for debug since it is implementation dependent.
fun name: String is abstract
end
lib/mnit/input.nit:73,1--105,3