sdl2 $ SDLKeyboardEvent :: SELF
Type of this instance, automatically specialized in every classcore :: Pointer :: address_is_null
Is the address behind this Object at NULL?core :: Object :: class_factory
Implementation used byget_class
to create the specific class.
core :: Object :: defaultinit
sdl2 :: SDLEvent :: defaultinit
core :: Pointer :: defaultinit
sdl2 :: SDLKeyboardEvent :: 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 button event
extern class SDLKeyboardEvent
super SDLEvent
# Is this is a key repeat?
fun repeat: Bool `{ return self->key.repeat; `}
# The key that was pressed or released
fun keysym: SDLKeysym `{ return &self->key.keysym; `}
redef fun to_s do return native_to_s.to_s
private fun native_to_s: CString `{
return (char*)SDL_GetKeyName(self->key.keysym.sym);
`}
end
lib/sdl2/events.nit:245,1--259,3
redef class SDLKeyboardEvent
redef fun to_gamnit_event(buffer) do return new GamnitKeyEvent(buffer, self)
end
lib/gamnit/gamnit_linux.nit:83,1--85,3