reg_global_remove
};
+static gboolean
+timeout_cb(gpointer data)
+{
+ static int count = 0;
+ TPL_DEBUG("TIMEOUT count:%d", ++count);
+ return TRUE;
+}
+
+static GSource*
+_twe_thread_test_add_timeout(twe_thread *thread, struct wl_display *display)
+{
+ GSource *timeout;
+ timeout = g_timeout_source_new(1000);
+ g_source_set_callback(timeout, timeout_cb, display, NULL);
+ g_source_attach(timeout, g_main_loop_get_context(thread->ctx->twe_loop));
+ g_source_unref(timeout);
+
+ return timeout;
+}
+
+static void
+_twe_thread_test_del_timeout(GSource *timeout)
+{
+ g_source_destroy(timeout);
+ g_source_unref(timeout);
+}
+
void
main(void)
{
struct wl_registry *registry;
struct wl_event_queue *ev_queue;
int count = 0;
+ GSource *timeout;
twe_thread *t_thread = NULL;
}
}
+ _twe_thread_test_del_timeout(timeout);
twe_thread_destroy(t_thread);
}