mirror of
https://gitlab.freedesktop.org/wayland/wayland.git
synced 2025-10-28 05:40:14 -04:00
As well as wl_display_dispatch_queue_pending_single. The motivation is writing libwayland bindings for a dynamic language with exceptions/non-local returns. Since it is invalid for a wl_dispatcher_func_t callback provided to libwayland to not return, there is no way to prevent dispatching of further events in the case of an exception in the dynamic language event handler. Furthermore, since creating/destroying Wayland objects in an event handler affects the dispatching of subsequent events by libwayland, it is not possible to collect Wayland events in a queue outside libwayland and dispatch them one-by-one after wl_display_dispatch_pending() returns. Adding libwayland API to dispatch at most one pending event solves this problem cleanly. The bindings can have libwayland dispatch a single event, wait for wl_display_dispatch_pending_single() to return, run the dynamic language event handler (which may longjmp away), and continue the loop for as long as there are more events to dispatch. References: https://codeberg.org/ifreund/janet-wayland Signed-off-by: Isaac Freund <mail@isaacfreund.com> |
||
|---|---|---|
| .. | ||
| data | ||
| array-test.c | ||
| client-test.c | ||
| compositor-introspection-test.c | ||
| connection-test.c | ||
| cpp-compile-test.cpp | ||
| display-test.c | ||
| enum-validator-test.c | ||
| event-loop-test.c | ||
| exec-fd-leak-checker.c | ||
| fixed-test.c | ||
| headers-protocol-core-test.c | ||
| headers-protocol-test.c | ||
| headers-test.c | ||
| interface-test.c | ||
| list-test.c | ||
| map-test.c | ||
| meson.build | ||
| message-test.c | ||
| newsignal-test.c | ||
| os-wrappers-test.c | ||
| protocol-logger-test.c | ||
| proxy-test.c | ||
| queue-test.c | ||
| resources-test.c | ||
| sanity-test.c | ||
| scanner-test-gen.sh | ||
| scanner-test.sh | ||
| signal-test.c | ||
| socket-test.c | ||
| test-compositor.c | ||
| test-compositor.h | ||
| test-helpers.c | ||
| test-runner.c | ||
| test-runner.h | ||