Fix#16666
When restoring from the maximized state while the maximized size was
used when creating the window, the window manager restores to something
sensible instead of using the last restored size we used.
As the maximized size has no real use, don't store and use it.
The modern web is mostly HTTPS now, and some browsers may start giving
warnings when one uses a plain HTTP connection.
Only update the protocol when the HTTPS connection exists and fully
works. Code from external projects/tools is kept as is.
The shaking effect can make the game screen go out of bounds and that's
totally fine.
Constraining here breaks it by shrinking the screen instead.
This fixes Trac#16233.
This has never crashed in Android but it seems it was pure luck.
The standard extended save code tries to get a thumbnail from the
screen and causes assertion fault with default implementation.
surfacesdl forces RGB565 pixel format for the hardware screen
but the first supported format returned by detectSupportedFormats()
may be very different (RGB565 VS ABGR8888 on PSP2 for example)
thus a pixel format conversion is done at each blitting when
calling SDL_BlitSurface().
On PSP2 with BladeRunner this conversion + blitting takes ~60ms.
By moving the hardware screen format first on the
detectSupportedFormats() we will use RGB565 for all surfaces.
By removing the format conversion on PSP2 we go down to ~2-3ms per frame.
Cursor's srcSurface is formally PIXELFORMAT_CLUT8 but this is not true,
it's 4-bit or 8-bit bitplanes. On the other hand, AtariSurface is
PIXELFORMAT_CLUT8, PIXELFORMAT_RGB332 or PIXELFORMAT_RGB121 so these
can't be asserted for equality.
Previous implementation had to create a new surface every time srcRect
has been changed and as a bonus, it would (harmlessly but still) do a
read-modify-write past the screen buffer.
- Introduce AtariSurface: a surface which represents either a
bitplane-based or pixel-based surface (on SuperVidel, as an inherited
SuperVidelSurface). Screen::surf / Screen::offsettedSurf are its
instances.
- Graphics::Surface::create / free now handle all Atari-related surfaces
via dlmalloc: ST RAM (TT/Falcon), VRAM (SuperVidel - 0xA0xxxxxx) and
VRAM for generic surfaces (SuperBlitter - 0xA1xxxxxx or ST/TT RAM).
This allowed me to remove all the hacky stuff from atari-graphics and
atari-superblitter.h.
- blit-atari.cpp now contains only blitting code
(SuperBlitter/move16/fallback), SV code is in
atari-supervidel.{cpp,h}.
- Take advantage of Common::ScopedPtr and Graphics::ManagedSurface's
dispose flag for Screen::surf as well Graphics::ManagedSurface's
ownership for Screen::offsettedSurf.
- Improve recoverability if an error/assert happens in
AtariGraphicsManager's c-tor/d-tor.
It causes more harm than good and I don't think it helps with
performance that much either. Its only semi-valid use case was C2P
direct rendering for sprites (which nobody uses). However, direct
rendering in its current form is about to be removed in a near future,
so...