mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-08-25 18:39:00 +02:00
gmain: Add GMainContextPusher convenience API
This is like `GMutexLocker`, in that if you are able to use `g_autoptr()`, it makes popping a `GMainContext` off the thread-default main context stack easier when exiting a function. A few uses of `G_GNUC_{BEGIN,END}_IGNORE_DEPRECATIONS` are needed to avoid warnings when building apps against GLib with `GLIB_VERSION_MAX_ALLOWED < GLIB_VERSION_2_64`. Signed-off-by: Philip Withnall <withnall@endlessm.com>
This commit is contained in:
@@ -781,6 +781,11 @@ g_main_set_poll_func
|
||||
g_main_context_invoke
|
||||
g_main_context_invoke_full
|
||||
|
||||
<SUBSECTION>
|
||||
GMainContextPusher
|
||||
g_main_context_pusher_new
|
||||
g_main_context_pusher_free
|
||||
|
||||
<SUBSECTION>
|
||||
g_main_context_get_thread_default
|
||||
g_main_context_ref_thread_default
|
||||
|
Reference in New Issue
Block a user