Hi.

> The SDL2 documentation recommends you to register constants with:
> 
> Uint32 SDL_RegisterEvents(int numevents);
>    numevents = the number of events to be allocated.
>    Returns the beginning event number, or (Uint32)-1 if there are not
> enough user-defined events left.
> 
> The SDL_RegisterEvents result is not known at compile time, so one
> can't use them as case conditions. So, Is there a workaround for
> building these constants at compile time?
If you know how many events were registered, then you can create
constants.  Else, you can't.

> 
> Best,
> R

Guillermo "Ñuño" Martínez
_______________________________________________
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
https://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

Reply via email to