[Scummvm-tracker] [ScummVM :: Bugs] #13054: MACOS: OPENGLSDL: Maximizing a window doesn’t set SDL_WINDOW_MAXIMIZED flag.
ScummVM :: Bugs
trac at scummvm.org
Sun Jun 5 16:42:09 UTC 2022
#13054: MACOS: OPENGLSDL: Maximizing a window doesn’t set SDL_WINDOW_MAXIMIZED
flag.
-------------------+-----------------------------
Reporter: macca8 | Owner: (none)
Type: defect | Status: new
Priority: normal | Component: Port: Mac OS X
Version: | Resolution:
Keywords: | Game:
-------------------+-----------------------------
Comment (by criezy):
My analysis here is different from what is described in the bug report.
On all of my tests the `SDL_WINDOW_MAXIMIZED` flag is correctly set when
using the green button to maximize the window, and the `window_maximized`
value is correct in the config file. However this could depend on the
macOS or SDL version (I am using macOS 11.6 and SDL 2.0.16).
However I still see the issue reported, but this is because we have an
issue in our code that creates the window as it reduces the size to make
sure the window with its borders is no bigger than the desktop size
(unless we want fullscreen):
https://github.com/scummvm/scummvm/blob/bde10f0dda17b5f3795381aa34e0f5b7939d0893/backends/platform/sdl
/sdl-window.cpp#L360-L382
Maximized is not fullscreen, but since on macOS it is borderless, we still
should not adjust the size with the border size there.
As an additional note:
> The style of the window when maximized (at least in macOS 10.11.6)
suggests that the SDL_WINDOW_FULLSCREEN_DESKTOP flag is set.
That is actually not the case. I checked it and a window maximized with
the green button has the `SDL_WINDOW_MAXIMIZED` flag set for me, but not
the `SDL_WINDOW_FULLSCREEN_DESKTOP` flag.
--
Ticket URL: <https://bugs.scummvm.org/ticket/13054#comment:2>
ScummVM :: Bugs <https://bugs.scummvm.org>
ScummVM
More information about the Scummvm-tracker
mailing list