Added SDL_WINDOWEVENT_HIT_TEST.

This lets windows know when they are dropping a mouse event because their
hit test reported something other than SDL_HITTEST_NORMAL. It lets them know
exactly where in the event queue this happened.

This patch is based on work in Unreal Engine 4's fork of SDL,
compliments of Epic Games.
This commit is contained in:
Ryan C. Gordon 2015-04-21 10:10:59 -04:00
parent d4aedf9951
commit aa4952fdef
4 changed files with 17 additions and 11 deletions

View file

@ -160,8 +160,8 @@ typedef enum
SDL_WINDOWEVENT_LEAVE, /**< Window has lost mouse focus */
SDL_WINDOWEVENT_FOCUS_GAINED, /**< Window has gained keyboard focus */
SDL_WINDOWEVENT_FOCUS_LOST, /**< Window has lost keyboard focus */
SDL_WINDOWEVENT_CLOSE /**< The window manager requests that the
window be closed */
SDL_WINDOWEVENT_CLOSE, /**< The window manager requests that the window be closed */
SDL_WINDOWEVENT_HIT_TEST /** Window had a hit test that wasn't SDL_HITTEST_NORMAL. */
} SDL_WindowEventID;
/**