X-Git-Url: https://git.artsoft.org/?a=blobdiff_plain;f=src%2Flibgame%2Fsdl.h;h=ad7dca8c1a95ee9cdf4535838be523469ead2c0f;hb=98ae5fc5e9274fea99a2ed8873b78fc2110ce3ce;hp=688e79c7502af13ee226269b81447f9990b7821d;hpb=7373d54bd6896193f7f20ed0ff148dacee9d084e;p=rocksndiamonds.git diff --git a/src/libgame/sdl.h b/src/libgame/sdl.h index 688e79c7..ad7dca8c 100644 --- a/src/libgame/sdl.h +++ b/src/libgame/sdl.h @@ -64,7 +64,8 @@ typedef SDL_TextInputEvent TextEvent; typedef SDL_Event PauseResumeEvent; typedef SDL_WindowEvent WindowEvent; typedef SDL_KeyboardEvent KeyEvent; -typedef SDL_Event ClientMessageEvent; + +typedef SDL_EventFilter EventFilter; // structure definitions @@ -89,6 +90,21 @@ struct MouseCursorInfo byte mask[CURSOR_MAX_WIDTH * CURSOR_MAX_HEIGHT / 8]; }; +struct UserEventInfo +{ + // same as in "struct SDL_UserEvent" + Uint32 type; + Uint32 timestamp; + Uint32 windowID; + Sint32 code; + + // changed to use integer values instead of void pointers + Uint32 value1; + Uint32 value2; +}; + +typedef struct UserEventInfo UserEvent; + // SDL symbol definitions @@ -107,7 +123,8 @@ struct MouseCursorInfo #define EVENT_TEXTINPUT SDL_TEXTINPUT #define EVENT_KEYPRESS SDL_KEYDOWN #define EVENT_KEYRELEASE SDL_KEYUP -#define EVENT_CLIENTMESSAGE SDL_QUIT +#define EVENT_USER SDL_USEREVENT +#define EVENT_QUIT SDL_QUIT #define KSYM_UNDEFINED SDLK_UNKNOWN @@ -406,6 +423,7 @@ void SDLOpenAudio(void); void SDLCloseAudio(void); void SDLWaitEvent(Event *); +void SDLCorrectRawMousePosition(int *, int *); void HandleJoystickEvent(Event *); void SDLInitJoysticks(void);