I'm trying to make my program work in Delphi using a translated version of Bob Pendelton's FastEvents library, which is basically a wrapper around SDL_Events that has some beneficial features I'm interested in. Problem is, I can't get it to return any events.
This routine never returns:
[pascal]procedure FE_WaitEvent(event: PSDL_Event);
while SDL_PollEvent(event) <= 0 do
I've initialized SDL and the FastEvents unit before calling this, and both initialized successfully.
[pascal] assert(SDL_Init(SDL_INIT_AUDIO or SDL_INIT_TIMER) = 0);
assert(FE_Init = 0);[/pascal]
The routine is running in a dedicated input-management thread. I was told how to do this on the SDL development list (see this thread for details) and have followed the instructions I was given. I also removed the applicable form's OnKeyDown event handler, just to see if that would make a difference. It didn't. So does anyone know what I'm doing wrong?