libinput
0.13.0
A wrapper library for input devices
|
Data Structures | |
struct | libinput_event |
The base event type. More... | |
struct | libinput_event_device_notify |
An event notifying the caller of a device being added or removed. More... | |
Functions | |
void | libinput_event_destroy (struct libinput_event *event) |
Destroy the event, freeing all associated resources. More... | |
enum libinput_event_type | libinput_event_get_type (struct libinput_event *event) |
Get the type of the event. More... | |
struct libinput * | libinput_event_get_context (struct libinput_event *event) |
Get the libinput context from the event. More... | |
struct libinput_device * | libinput_event_get_device (struct libinput_event *event) |
Return the device associated with this event. More... | |
struct libinput_event_pointer * | libinput_event_get_pointer_event (struct libinput_event *event) |
Return the pointer event that is this input event. More... | |
struct libinput_event_keyboard * | libinput_event_get_keyboard_event (struct libinput_event *event) |
Return the keyboard event that is this input event. More... | |
struct libinput_event_touch * | libinput_event_get_touch_event (struct libinput_event *event) |
Return the touch event that is this input event. More... | |
struct libinput_event_device_notify * | libinput_event_get_device_notify_event (struct libinput_event *event) |
Return the device event that is this input event. More... | |
struct libinput_event * | libinput_event_device_notify_get_base_event (struct libinput_event_device_notify *event) |
void libinput_event_destroy | ( | struct libinput_event * | event | ) |
Destroy the event, freeing all associated resources.
Resources obtained from this event must be considered invalid after this call.
event | An event retrieved by libinput_get_event(). |
struct libinput_event* libinput_event_device_notify_get_base_event | ( | struct libinput_event_device_notify * | event | ) |
struct libinput* libinput_event_get_context | ( | struct libinput_event * | event | ) |
Get the libinput context from the event.
event | The libinput event |
struct libinput_device* libinput_event_get_device | ( | struct libinput_event * | event | ) |
Return the device associated with this event.
For device added/removed events this is the device added or removed. For all other device events, this is the device that generated the event.
This device is not refcounted and its lifetime is that of the event. Use libinput_device_ref() before using the device outside of this scope.
struct libinput_event_device_notify* libinput_event_get_device_notify_event | ( | struct libinput_event * | event | ) |
Return the device event that is this input event.
If the event type does not match the device event types, this function returns NULL.
The inverse of this function is libinput_event_device_notify_get_base_event().
struct libinput_event_keyboard* libinput_event_get_keyboard_event | ( | struct libinput_event * | event | ) |
Return the keyboard event that is this input event.
If the event type does not match the keyboard event types, this function returns NULL.
The inverse of this function is libinput_event_keyboard_get_base_event().
struct libinput_event_pointer* libinput_event_get_pointer_event | ( | struct libinput_event * | event | ) |
Return the pointer event that is this input event.
If the event type does not match the pointer event types, this function returns NULL.
The inverse of this function is libinput_event_pointer_get_base_event().
struct libinput_event_touch* libinput_event_get_touch_event | ( | struct libinput_event * | event | ) |
Return the touch event that is this input event.
If the event type does not match the touch event types, this function returns NULL.
The inverse of this function is libinput_event_touch_get_base_event().
enum libinput_event_type libinput_event_get_type | ( | struct libinput_event * | event | ) |
Get the type of the event.
event | An event retrieved by libinput_get_event(). |