Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- void
- gui_poll(bool active)
- {
- nsfb_event_t event;
- int timeout; /* timeout in miliseconds */
- //Render_Agar_GUI();
- /* run the scheduler and discover how long to wait for the next event */
- timeout = schedule_run();
- /* if active do not wait for event, return immediately */
- if (active)
- timeout = 0;
- /* if redraws are pending do not wait for event, return immediately */
- if (fbtk_get_redraw_pending(fbtk))
- timeout = 0;
- if (fbtk_event(fbtk, &event, timeout)) {
- if ((event.type == NSFB_EVENT_CONTROL) &&
- (event.value.controlcode == NSFB_CONTROL_QUIT))
- netsurf_quit = true;
- }
- fbtk_redraw(fbtk);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement