NetSurf
|
Go to the source code of this file.
Functions | |
nserror | win32_schedule (int ival, void(*callback)(void *p), void *p) |
Schedule a callback. More... | |
int | schedule_run (void) |
Process scheduled callbacks up to current time. More... | |
void | list_schedule (void) |
LOG all current scheduled events. More... | |
void list_schedule | ( | void | ) |
LOG all current scheduled events.
Definition at line 210 of file schedule.c.
References max_scheduled, MS_NOW, nscallback::next, NSLOG, schedule_list, nscallback::timeout, and nscallback::tv.
int schedule_run | ( | void | ) |
Process scheduled callbacks up to current time.
This walks the list of outstanding scheduled events and dispatches them if they have met their scheduled time. Due to legacy issues there are a couple of subtleties with how this operates:
Process scheduled callbacks up to current time.
Definition at line 137 of file schedule.c.
References nscallback::callback, _nsbeos_callback_t::callback, _nsgtk_callback_t::callback, sched_entry::callback, _nsbeos_callback_t::callback_killed, _nsgtk_callback_t::callback_killed, callbacks, _nsbeos_callback_t::context, _nsgtk_callback_t::context, cur_scheduled, earliest_callback_timeout, MS_NOW, nscallback::next, sched_entry::next, NSLOG, nscallback::p, sched_entry::p, pending_callbacks, sched_active, sched_queue, sched_time, schedule_list, this_run, sched_entry::time, nscallback::timeout, _nsbeos_callback_t::timeout, timercmp, timersub, and nscallback::tv.
Referenced by atari_poll(), framebuffer_run(), nsbeos_gui_poll(), nsgtk_main(), riscos_poll(), and win32_run().
nserror win32_schedule | ( | int | ival, |
void(*)(void *p) | callback, | ||
void * | p | ||
) |
Schedule a callback.
ival | interval before the callback should be made in ms |
callback | callback function |
p | user parameter, passed to callback function |
The callback function will be called as soon as possible after t ms have passed.
Definition at line 99 of file schedule.c.
References nscallback::callback, nscallback::next, NSERROR_NOMEM, NSERROR_OK, NSLOG, nscallback::p, schedule_list, schedule_remove(), timeradd, and nscallback::tv.
Referenced by nsws_download_clear_data(), nsws_download_update_label(), and nsws_download_update_progress().