w32_common: fix video zoom reset on window restore from maximize (fixes #17695)#17708
Open
0xjah wants to merge 8 commits intompv-player:masterfrom
Open
w32_common: fix video zoom reset on window restore from maximize (fixes #17695)#177080xjah wants to merge 8 commits intompv-player:masterfrom
0xjah wants to merge 8 commits intompv-player:masterfrom
Conversation
kasper93
reviewed
Apr 7, 2026
video/out/w32_common.c
Outdated
| }; | ||
|
|
||
| // Only apply size_constraint during initial setup or when forcing position. | ||
| // This prevents resetting video zoom when restoring from maximized state. |
Member
There was a problem hiding this comment.
The constraint should only apply when video would be bigger than screen, and only when reset_size is true. I don't see how any of those conditions can be true when restoring.
Author
|
Fixed in the new PR. The constraint now only applies when both conditions are true:
During a restore from maximized, neither condition is met |
Author
|
@kasper93 is there anything else should i implement or fix |
env vars are case insensitive on windows so getenv should compare them as such. Fixes: mpv-player#17577 (comment)
Window controls are not clickable from the very top of the window, they have a margin to the top that makes them harder to click. Make them clickable also from the very top to make them easier to activate. The close button with the default windowcontrols_alignment=right specifically is already clickable from the rightmost part of the window. Partial fix of mpv-player#9791 (other buttons also need to be updated).
There is an area between the 2 lines of bottombar and topbar that is not clickable, e.g. between the menu and play_pause icons. Make it all clickable so it's easier to click buttons. This also allows clicking from the bottom in slimbottombar and from the top in topbottombar.
a02fb2c to
881e75e
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fix issue #17695 where maximizing and restoring the player window would reset
the video to its original size, losing any custom zoom settings.
The window_resize() function was always applying a size_constraint set to 100%
of screen size. Now the constraint is only applied during initial setup or when
forcing position, preserving the user's video zoom level when restoring from maximize.
Fixes #17695