Skip to content
Snippets Groups Projects
Commit 8a68ffac authored by deuce's avatar deuce
Browse files

Add PollEvent

parent cb087c63
No related branches found
No related tags found
No related merge requests found
...@@ -151,6 +151,10 @@ int load_sdl_funcs(struct sdlfuncs *sdlf) ...@@ -151,6 +151,10 @@ int load_sdl_funcs(struct sdlfuncs *sdlf)
xp_dlclose(sdl_dll); xp_dlclose(sdl_dll);
return(-1); return(-1);
} }
if((sdlf->PollEvent=xp_dlsym(sdl_dll, SDL_PollEvent))==NULL) {
xp_dlclose(sdl_dll);
return(-1);
}
if((sdlf->SetVideoMode=xp_dlsym(sdl_dll, SDL_SetVideoMode))==NULL) { if((sdlf->SetVideoMode=xp_dlsym(sdl_dll, SDL_SetVideoMode))==NULL) {
xp_dlclose(sdl_dll); xp_dlclose(sdl_dll);
return(-1); return(-1);
......
...@@ -41,6 +41,7 @@ struct sdlfuncs { ...@@ -41,6 +41,7 @@ struct sdlfuncs {
void (HACK_HACK_HACK *KillThread) (SDL_Thread *thread); void (HACK_HACK_HACK *KillThread) (SDL_Thread *thread);
void (HACK_HACK_HACK *WaitThread) (SDL_Thread *thread, int *status); void (HACK_HACK_HACK *WaitThread) (SDL_Thread *thread, int *status);
int (HACK_HACK_HACK *WaitEvent) (SDL_Event *event); int (HACK_HACK_HACK *WaitEvent) (SDL_Event *event);
int (HACK_HACK_HACK *PollEvent) (SDL_Event *event);
SDL_Surface *(HACK_HACK_HACK *SetVideoMode) (int width, int height, int bpp, Uint32 flags); SDL_Surface *(HACK_HACK_HACK *SetVideoMode) (int width, int height, int bpp, Uint32 flags);
void (HACK_HACK_HACK *FreeSurface) (SDL_Surface *surface); void (HACK_HACK_HACK *FreeSurface) (SDL_Surface *surface);
void (HACK_HACK_HACK *WM_SetCaption) (const char *title, const char *icon); void (HACK_HACK_HACK *WM_SetCaption) (const char *title, const char *icon);
......
...@@ -146,6 +146,10 @@ int load_sdl_funcs(struct sdlfuncs *sdlf) ...@@ -146,6 +146,10 @@ int load_sdl_funcs(struct sdlfuncs *sdlf)
xp_dlclose(sdl_dll); xp_dlclose(sdl_dll);
return(-1); return(-1);
} }
if((sdlf->PollEvent=xp_dlsym(sdl_dll, SDL_PollEvent))==NULL) {
xp_dlclose(sdl_dll);
return(-1);
}
if((sdlf->SetVideoMode=xp_dlsym(sdl_dll, SDL_SetVideoMode))==NULL) { if((sdlf->SetVideoMode=xp_dlsym(sdl_dll, SDL_SetVideoMode))==NULL) {
xp_dlclose(sdl_dll); xp_dlclose(sdl_dll);
return(-1); return(-1);
......
...@@ -35,6 +35,7 @@ struct sdlfuncs { ...@@ -35,6 +35,7 @@ struct sdlfuncs {
void (*KillThread) (SDL_Thread *thread); void (*KillThread) (SDL_Thread *thread);
void (*WaitThread) (SDL_Thread *thread, int *status); void (*WaitThread) (SDL_Thread *thread, int *status);
int (*WaitEvent) (SDL_Event *event); int (*WaitEvent) (SDL_Event *event);
int (*PollEvent) (SDL_Event *event);
SDL_Surface *(*SetVideoMode) (int width, int height, int bpp, Uint32 flags); SDL_Surface *(*SetVideoMode) (int width, int height, int bpp, Uint32 flags);
void (*FreeSurface) (SDL_Surface *surface); void (*FreeSurface) (SDL_Surface *surface);
void (*WM_SetCaption) (const char *title, const char *icon); void (*WM_SetCaption) (const char *title, const char *icon);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment