wl_event_loop - Online Linux Manual PageSection : 3
Updated : Thu Jan 28 2021
Source : Version 1.19.0
Note : Wayland
NAMEwl_event_loop − An event loop context.
SYNOPSIS
#include <wayland−server−core.h>
Public Member Functionsstruct wl_event_loop * wl_event_loop_create (void)
void wl_event_loop_destroy (struct wl_event_loop *loop)
void wl_event_loop_dispatch_idle (struct wl_event_loop *loop)
int wl_event_loop_dispatch (struct wl_event_loop *loop, int timeout)
int wl_event_loop_get_fd (struct wl_event_loop *loop)
void wl_event_loop_add_destroy_listener (struct wl_event_loop *loop, struct wl_listener *listener)
struct wl_listener * wl_event_loop_get_destroy_listener (struct wl_event_loop *loop, wl_notify_func_t notify)
Detailed DescriptionAn event loop context. Usually you create an event loop context, add sources to it, and call wl_event_loop_dispatch() in a loop to process events. See also wl_event_source
Member Function Documentation
void wl_event_loop_add_destroy_listener (struct wl_event_loop * loop, struct wl_listener * listener)Register a destroy listener for an event loop context Parameters loop The event loop context whose destruction to listen for.
listener The listener with the callback to be called. See also wl_listener
struct wl_event_loop * wl_event_loop_create (void)Create a new event loop context Returns A new event loop context object. This creates a new event loop context. Initially this context is empty. Event sources need to be explicitly added to it. Normally the event loop is run by calling wl_event_loop_dispatch() in a loop until the program terminates. Alternatively, an event loop can be embedded in another event loop by its file descriptor, see wl_event_loop_get_fd().
void wl_event_loop_destroy (struct wl_event_loop * loop)Destroy an event loop context Parameters loop The event loop to be destroyed. This emits the event loop destroy signal, closes the event loop file descriptor, and frees loop. If the event loop has existing sources, those cannot be safely removed afterwards. Therefore one must call wl_event_source_remove() on all event sources before destroying the event loop context.
int wl_event_loop_dispatch (struct wl_event_loop * loop, int timeout)Wait for events and dispatch them Parameters loop The event loop whose sources to wait for.
timeout The polling timeout in milliseconds. Returns 0 for success, -1 for polling (or timer update) error. All the associated event sources are polled. This function blocks until any event source delivers an event (idle sources excluded), or the timeout expires. A timeout of -1 disables the timeout, causing the function to block indefinitely. A timeout of zero causes the poll to always return immediately. All idle sources are dispatched before blocking. An idle source is destroyed when it is dispatched. After blocking, all other ready sources are dispatched. Then, idle sources are dispatched again, in case the dispatched events created idle sources. Finally, all sources marked with wl_event_source_check() are dispatched in a loop until their dispatch functions all return zero.
void wl_event_loop_dispatch_idle (struct wl_event_loop * loop)Dispatch the idle sources Parameters loop The event loop whose idle sources are dispatched. See also wl_event_loop_add_idle()
struct wl_listener * wl_event_loop_get_destroy_listener (struct wl_event_loop * loop, wl_notify_func_t notify)Get the listener struct for the specified callback Parameters loop The event loop context to inspect.
notify The destroy callback to find. Returns The wl_listener registered to the event loop context with the given callback pointer.
int wl_event_loop_get_fd (struct wl_event_loop * loop)Get the event loop file descriptor Parameters loop The event loop context. Returns The aggregate file descriptor. This function returns the aggregate file descriptor, that represents all the event sources (idle sources excluded) associated with the given event loop context. When any event source makes an event available, it will be reflected in the aggregate file descriptor. When the aggregate file descriptor delivers an event, one can call wl_event_loop_dispatch() on the event loop context to dispatch all the available events.
AuthorGenerated automatically by Doxygen for Wayland from the source code. 0
Johanes Gumabo
Data Size : 20,532 byte
man-wl_event_loop.3Build : 2024-12-05, 20:55 :
Visitor Screen : x
Visitor Counter ( page / site ) : 3 / 165,160
Visitor ID : :
Visitor IP : 18.191.218.234 :
Visitor Provider : AMAZON-02 :
Provider Position ( lat x lon ) : 39.962500 x -83.006100 : x
Provider Accuracy Radius ( km ) : 1000 :
Provider City : Columbus :
Provider Province : Ohio , : ,
Provider Country : United States :
Provider Continent : North America :
Visitor Recorder : Version :
Visitor Recorder : Library :
Online Linux Manual Page : Version : Online Linux Manual Page - Fedora.40 - march=x86-64 - mtune=generic - 24.12.05
Online Linux Manual Page : Library : lib_c - 24.10.03 - march=x86-64 - mtune=generic - Fedora.40
Online Linux Manual Page : Library : lib_m - 24.10.03 - march=x86-64 - mtune=generic - Fedora.40
Data Base : Version : Online Linux Manual Page Database - 24.04.13 - march=x86-64 - mtune=generic - fedora-38
Data Base : Library : lib_c - 23.02.07 - march=x86-64 - mtune=generic - fedora.36
Very long time ago, I have the best tutor, Wenzel Svojanovsky . If someone knows the email address of Wenzel Svojanovsky , please send an email to johanes_gumabo@yahoo.co.id .
If error, please print screen and send to johanes_gumabo@yahoo.co.id
Under development. Support me via PayPal.