Minor code refactoring

This commit is contained in:
Louis-Antoine 2020-01-02 00:47:20 +01:00
parent 17636ccc01
commit 3af00ac93e
2 changed files with 1 additions and 9 deletions

View file

@ -3212,10 +3212,7 @@ boolean M_Responder(event_t *ev)
case KEY_ESCAPE: // Pop up menu case KEY_ESCAPE: // Pop up menu
if (chat_on) if (chat_on)
{
HU_clearChatChars(); HU_clearChatChars();
chat_on = false;
}
else else
M_StartControlPanel(); M_StartControlPanel();
return true; return true;

View file

@ -380,12 +380,7 @@ static void SDLdoUngrabMouse(void)
void SDLforceUngrabMouse(void) void SDLforceUngrabMouse(void)
{ {
if (SDL_WasInit(SDL_INIT_VIDEO)==SDL_INIT_VIDEO && window != NULL) if (SDL_WasInit(SDL_INIT_VIDEO)==SDL_INIT_VIDEO && window != NULL)
{ SDLdoUngrabMouse();
SDL_ShowCursor(SDL_ENABLE);
SDL_SetWindowGrab(window, SDL_FALSE);
wrapmouseok = SDL_FALSE;
SDL_SetRelativeMouseMode(SDL_FALSE);
}
} }
void I_UpdateMouseGrab(void) void I_UpdateMouseGrab(void)