Delay window resize when minimized

On some window managers (e.g. on Windows), performing a resize while the
window is minimized does nothing (the restored window keeps its old
size).

Therefore, like for maximized and fullscreen states, wait for the window
to be restored to apply a resize.

Refs #3947 <https://github.com/Genymobile/scrcpy/issues/3947>
This commit is contained in:
Romain Vimont
2023-05-08 21:02:01 +02:00
parent 6298ef095f
commit e926bf1fe8
2 changed files with 13 additions and 5 deletions

View File

@@ -56,6 +56,7 @@ struct sc_screen {
bool has_frame;
bool fullscreen;
bool maximized;
bool minimized;
// To enable/disable mouse capture, a mouse capture key (LALT, LGUI or
// RGUI) must be pressed. This variable tracks the pressed capture key.