Only minimize the window for an assert if it's in exclusive fullscreen mode
This commit is contained in:
parent
ac75fe9324
commit
177a6f38e0
|
@ -213,7 +213,7 @@ static SDL_AssertState SDLCALL SDL_PromptAssertion(const SDL_AssertData *data, v
|
||||||
/* Leave fullscreen mode, if possible (scary!) */
|
/* Leave fullscreen mode, if possible (scary!) */
|
||||||
window = SDL_GetFocusWindow();
|
window = SDL_GetFocusWindow();
|
||||||
if (window) {
|
if (window) {
|
||||||
if ((SDL_GetWindowFlags(window) & SDL_WINDOW_FULLSCREEN) != 0) {
|
if (window->fullscreen_exclusive) {
|
||||||
SDL_MinimizeWindow(window);
|
SDL_MinimizeWindow(window);
|
||||||
} else {
|
} else {
|
||||||
/* !!! FIXME: ungrab the input if we're not fullscreen? */
|
/* !!! FIXME: ungrab the input if we're not fullscreen? */
|
||||||
|
|
|
@ -182,7 +182,9 @@ void loop()
|
||||||
if (event.type == SDL_EVENT_KEY_UP) {
|
if (event.type == SDL_EVENT_KEY_UP) {
|
||||||
SDL_bool updateCursor = SDL_FALSE;
|
SDL_bool updateCursor = SDL_FALSE;
|
||||||
|
|
||||||
if (event.key.keysym.sym == SDLK_LEFT) {
|
if (event.key.keysym.sym == SDLK_a) {
|
||||||
|
SDL_assert(!"Keyboard generated assert");
|
||||||
|
} else if (event.key.keysym.sym == SDLK_LEFT) {
|
||||||
--system_cursor;
|
--system_cursor;
|
||||||
if (system_cursor < 0) {
|
if (system_cursor < 0) {
|
||||||
system_cursor = SDL_NUM_SYSTEM_CURSORS - 1;
|
system_cursor = SDL_NUM_SYSTEM_CURSORS - 1;
|
||||||
|
|
Loading…
Reference in a new issue