MCPcopy Create free account
hub / github.com/GNOME/gjs / wait_for

Function wait_for

test/gjs-test-toggle-queue.cpp:122–133  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

120}
121
122static void wait_for(int interval) {
123 AutoPointer<GMainLoop, GMainLoop, g_main_loop_unref> loop{
124 g_main_loop_new(nullptr, false)};
125 g_timeout_add_full(
126 G_PRIORITY_LOW, interval,
127 [](void* data) {
128 g_main_loop_quit(static_cast<GMainLoop*>(data));
129 return G_SOURCE_REMOVE;
130 },
131 loop, nullptr);
132 g_main_loop_run(loop);
133}
134
135static void toggles_handler(::ObjectInstance* object,
136 ::ToggleQueue::Direction direction) {

Calls

no outgoing calls

Tested by

no test coverage detected