Re: [AD] ALLEGRO_TIMEOUT

[ Thread Index | Date Index | More lists.liballeg.org/allegro-developers Archives ]


On 6 Nov 2010, at 1:56 , Thomas Fjellstrom wrote:
> Nope, its used with the al_wait_for_event_until. And might be used elsewhere. 

In the public API it isn't used anywhere else that I can see from the documentation.
I've documented what it's used for, but I do have to wonder whether it makes sense to have a dedicated type that has a constructor function and one use function.
Wouldn't it make more sense to have

bool al_wait_for_event_until(ALLEGRO_EVENT_QUEUE *queue,
   ALLEGRO_EVENT *ret_event, double seconds)

rather than the pair of

void al_init_timeout(ALLEGRO_TIMEOUT *timeout, double seconds)
bool al_wait_for_event_until(ALLEGRO_EVENT_QUEUE *queue,
   ALLEGRO_EVENT *ret_event, ALLEGRO_TIMEOUT *timeout)

?

Evert



Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/