Folded SDL_WINDOW_FULLSCREEN_EXCLUSIVE and SDL_WINDOW_FULLSCREEN_DESKTOP into a single SDL_WINDOW_FULLSCREEN flag

The fullscreen video mode used by the window can be used to determine whether it's in exclusive fullscreen or fullscreen desktop mode.
This commit is contained in:
Sam Lantinga
2023-02-01 11:30:28 -08:00
parent 14338ab459
commit ac75fe9324
36 changed files with 184 additions and 250 deletions

View File

@@ -73,7 +73,7 @@ static DWORD GetWindowStyle(SDL_Window *window)
{
DWORD style = 0;
if ((window->flags & SDL_WINDOW_FULLSCREEN_MASK) != 0) {
if ((window->flags & SDL_WINDOW_FULLSCREEN) != 0) {
style |= STYLE_FULLSCREEN;
} else {
if ((window->flags & SDL_WINDOW_BORDERLESS) != 0) {
@@ -908,7 +908,7 @@ void WIN_SetWindowFullscreen(_THIS, SDL_Window *window, SDL_VideoDisplay *displa
int x, y;
int w, h;
if (!fullscreen && (window->flags & SDL_WINDOW_FULLSCREEN_MASK) != 0) {
if (!fullscreen && (window->flags & SDL_WINDOW_FULLSCREEN) != 0) {
/* Resizing the window on hide causes problems restoring it in Wine, and it's unnecessary.
* Also, Windows would preview the minimized window with the wrong size.
*/