Skip to content

Commit

Permalink
x11: Don't mess with fullscreen vs maximized window state on unmapped…
Browse files Browse the repository at this point in the history
… windows.
  • Loading branch information
icculus committed Feb 20, 2016
1 parent dddd6a5 commit a4627c5
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/video/x11/SDL_x11window.c
Expand Up @@ -1208,8 +1208,10 @@ X11_SetWindowFullscreenViaWM(_THIS, SDL_Window * window, SDL_VideoDisplay * _dis

/* Fullscreen windows sometimes end up being marked maximized by
window managers. Force it back to how we expect it to be. */
if (!fullscreen && (window->flags & SDL_WINDOW_MAXIMIZED) == 0) {
SetWindowMaximized(_this, window, SDL_FALSE);
if (X11_IsWindowMapped(_this, window)) {
if (!fullscreen && ((window->flags & SDL_WINDOW_MAXIMIZED) == 0)) {
SetWindowMaximized(_this, window, SDL_FALSE);
}
}

X11_XFlush(display);
Expand Down

0 comments on commit a4627c5

Please sign in to comment.