Ignore resize events for unfocused windows

This commit is contained in:
Ethan Lee
2021-02-14 22:51:07 -05:00
parent 39abcfa8d9
commit 47df6c9d66

View File

@@ -252,7 +252,12 @@ void KeyPoll::Poll()
{
/* Window Resize */
case SDL_WINDOWEVENT_RESIZED:
if (SDL_GetWindowFlags(
SDL_GetWindowFromID(evt.window.windowID)
) & SDL_WINDOW_INPUT_FOCUS)
{
resetWindow = true;
}
break;
/* Window Focus */