2 * ion/libmainloop/defer.c
4 * Copyright (c) Tuomo Valkonen 1999-2007.
6 * See the included file LICENSE for details.
9 #ifndef ION_LIBMAINLOOP_DEFER_H
10 #define ION_LIBMAINLOOP_DEFER_H
12 #include <libtu/types.h>
13 #include <libtu/obj.h>
14 #include <libextl/extl.h>
16 INTRSTRUCT(WDeferred);
18 typedef void WDeferredAction(Obj*);
20 extern void mainloop_execute_deferred();
21 extern void mainloop_execute_deferred_on_list(WDeferred **list);
23 extern bool mainloop_defer_action(Obj *obj, WDeferredAction *action);
24 extern bool mainloop_defer_action_on_list(Obj *obj, WDeferredAction *action,
27 extern bool mainloop_defer_destroy(Obj *obj);
29 extern bool mainloop_defer_extl(ExtlFn fn);
30 extern bool mainloop_defer_extl_on_list(ExtlFn fn, WDeferred **list);
32 #endif /* ION_LIBMAINLOOP_DEFER_H */