navit  0.5.3-trunk
event.h
Go to the documentation of this file.
1 
20 #ifdef __cplusplus
21 extern "C" {
22 #endif
23 
24 struct event_idle;
25 struct event_timeout;
26 struct event_watch;
27 struct callback;
28 struct callback_list;
29 struct file;
30 
35 };
36 
37 struct event_methods {
38  void (*main_loop_run)(void);
39  void (*main_loop_quit)(void);
40  struct event_watch *(*add_watch)(int fd, enum event_watch_cond cond, struct callback *cb);
41  void (*remove_watch)(struct event_watch *ev);
42  struct event_timeout *(*add_timeout)(int timeout, int multi, struct callback *cb);
43  void (*remove_timeout)(struct event_timeout *ev);
44  struct event_idle *(*add_idle)(int priority, struct callback *cb);
45  void (*remove_idle)(struct event_idle *ev);
46  void (*call_callback)(struct callback_list *cb);
47 };
48 
49 
50 /* prototypes */
51 enum event_watch_cond;
52 struct callback;
53 struct callback_list;
54 struct event_idle;
55 struct event_timeout;
56 struct event_watch;
57 void event_main_loop_run(void);
58 void event_main_loop_quit(void);
59 int event_main_loop_has_quit(void);
60 struct event_watch *event_add_watch(int fd, enum event_watch_cond cond, struct callback *cb);
61 void event_remove_watch(struct event_watch *ev);
62 struct event_timeout *event_add_timeout(int timeout, int multi, struct callback *cb);
63 void event_remove_timeout(struct event_timeout *ev);
64 struct event_idle *event_add_idle(int priority, struct callback *cb);
65 void event_remove_idle(struct event_idle *ev);
67 char const *event_system(void);
68 int event_request_system(const char *system, const char *requestor);
69 /* end of prototypes */
70 #ifdef __cplusplus
71 }
72 #endif
void event_call_callback(struct callback_list *cb)
Definition: event.c:104
char const * event_system(void)
Definition: event.c:109
event_watch_cond
Definition: event.h:31
@ event_watch_cond_write
Definition: event.h:33
@ event_watch_cond_except
Definition: event.h:34
@ event_watch_cond_read
Definition: event.h:32
void event_remove_timeout(struct event_timeout *ev)
Definition: event.c:88
int event_request_system(const char *system, const char *requestor)
Definition: event.c:113
void event_remove_watch(struct event_watch *ev)
Definition: event.c:68
int event_main_loop_has_quit(void)
Definition: event.c:58
struct event_timeout * event_add_timeout(int timeout, int multi, struct callback *cb)
Definition: event.c:83
void event_remove_idle(struct event_idle *ev)
Definition: event.c:99
void event_main_loop_quit(void)
Definition: event.c:52
void event_main_loop_run(void)
Definition: event.c:47
struct event_idle * event_add_idle(int priority, struct callback *cb)
Definition: event.c:94
struct event_watch * event_add_watch(int fd, enum event_watch_cond cond, struct callback *cb)
Definition: event.c:63
Definition: callback.c:37
Definition: callback.c:27
Definition: event_glib.c:115
struct callback * cb
Definition: event_glib.c:117
Definition: event.h:37
void(* call_callback)(struct callback_list *cb)
Definition: event.h:46
void(* remove_idle)(struct event_idle *ev)
Definition: event.h:45
void(* remove_timeout)(struct event_timeout *ev)
Definition: event.h:43
void(* main_loop_quit)(void)
Definition: event.h:39
void(* remove_watch)(struct event_watch *ev)
Definition: event.h:41
void(* main_loop_run)(void)
Definition: event.h:38
Definition: event_glib.c:82
struct callback * cb
Definition: event_glib.c:84
int multi
Definition: graphics_android.c:1076
Definition: event_glib.c:44
struct callback * cb
Definition: event_qt5.cpp:53
int fd
Definition: event_qt5.cpp:54
Definition: file.h:36