Wait for a screen event.
int screen_get_event(screen_context_t ctx, screen_event_t ev, uint64_t timeout)
The context to retrieve events from. This context must have been created using screen_create_context().
An event previously allocated with screen_create_event(). Any contents in this event will be replaced with the next event.
The maximum time to wait for an event to occur if one has not been queued up already. 0 indicates that the call must not wait at all if there are no events associated with the specified context. -1 indicates that the call must not return until an event is ready.
Library:libscreen (For the qcc command, use the -l screen option to link against this library)
Function Type: Immediate Execution
This function gets the next event associated with the given context. If no events have been queued, the function will wait up to the specified amount of time for an event to occur. If the function times out before an event becomes available, an event with a SCREEN_EVENT_NONE type will be returned.
0 if the event was retrieved, or -1 if an error occurred (errno is set).
Last modified: 2014-11-17