diff options
author | zaxl <zaxl@ffa7fe5e-494d-0410-b361-a75ebd5db220> | 2008-11-07 12:29:44 +0000 |
---|---|---|
committer | zaxl <zaxl@ffa7fe5e-494d-0410-b361-a75ebd5db220> | 2008-11-07 12:29:44 +0000 |
commit | 01faa77dc857be70df9da067fa32aa47750f75d8 (patch) | |
tree | ebb741253dbb524f8ca43beada5023b0ab594251 /navit/event.h | |
parent | a638f55d07d81c385c588d10ae7eb93f5e70400f (diff) | |
download | navit-01faa77dc857be70df9da067fa32aa47750f75d8.tar.gz |
Add:core: event_call_callback infrastructure|
To be used from threads that want to call the callback
from the main(gui) thread. Users must provide
synhronization of the callback data.
Difference with using timeouts are:
Threads can have own timers
Timer events are low priority, this must be called ASAP.
git-svn-id: http://svn.code.sf.net/p/navit/code/trunk/navit@1674 ffa7fe5e-494d-0410-b361-a75ebd5db220
Diffstat (limited to 'navit/event.h')
-rw-r--r-- | navit/event.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/navit/event.h b/navit/event.h index 0f02278fd..fb0c37d47 100644 --- a/navit/event.h +++ b/navit/event.h @@ -42,6 +42,7 @@ struct event_methods { void (*remove_timeout)(struct event_timeout *ev); struct event_idle *(*add_idle)(struct callback *cb); void (*remove_idle)(struct event_idle *ev); + void (*call_callback)(struct callback *cb); }; @@ -55,6 +56,7 @@ void event_remove_timeout(struct event_timeout *ev); struct event_idle *event_add_idle(struct callback *cb); void event_remove_idle(struct event_idle *ev); int event_request_system(char *system, char *requestor); +void event_call_callback(struct callback *cb); /* end of prototypes */ #ifdef __cplusplus } |