From: Daniel Karbach Date: Mon, 26 Oct 2015 16:25:04 +0000 (+0100) Subject: also exit message state on quit X-Git-Url: https://git.localhorst.tv/?a=commitdiff_plain;h=9fe65e5284b4df9612249483f6b261a84dddc09d;p=blank.git also exit message state on quit --- diff --git a/src/shared/states.cpp b/src/shared/states.cpp index f98382e..1b90715 100644 --- a/src/shared/states.cpp +++ b/src/shared/states.cpp @@ -138,7 +138,7 @@ void MessageState::ClearMessage() { } void MessageState::Handle(const SDL_Event &e) { - if (e.type == SDL_KEYDOWN) { + if (e.type == SDL_QUIT || e.type == SDL_KEYDOWN) { env.state.Pop(); } }