Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix Linux fullscreen mode doesn't preserve maximized state #75838

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

jmb462
Copy link
Contributor

@jmb462 jmb462 commented Apr 8, 2023

Fix #75804

Unlike what happens under Windows, the maximized state was not saved when switching to full screen.
Added a was_maximized variable to restore previous windowed state while leaving fullscreen.

@jmb462 jmb462 requested a review from a team as a code owner April 8, 2023 21:06
@Calinou Calinou added this to the 4.1 milestone Apr 8, 2023
@akien-mga akien-mga changed the title Fix linux fullscreen mode doesn't preserve maximized state Fix Linux fullscreen mode doesn't preserve maximized state Jun 19, 2023
@akien-mga akien-mga requested a review from bruvzg June 19, 2023 19:56
Copy link
Member

@Calinou Calinou left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested locally (rebased on top of master 7641936), it works. The logic looks good to me.

Copy link
Member

@akien-mga akien-mga left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Won't this fail if you have multiple windows?

In the Windows platform there is also a was_maximized boolean but it's part of the WindowData, so it's window-specific. Here it's a single boolean for the whole DisplayServer so maximizing or windowing any window will impact the value, causing unexpected behavior.

Also I assume the macOS DisplayServer needs the same treatment?

@akien-mga akien-mga modified the milestones: 4.1, 4.2 Jun 22, 2023
@akien-mga akien-mga added cherrypick:4.1 Considered for cherry-picking into a future 4.1.x release and removed cherrypick:4.0 labels Jun 22, 2023
@YuriSizov YuriSizov removed the cherrypick:4.1 Considered for cherry-picking into a future 4.1.x release label Nov 13, 2023
@YuriSizov YuriSizov modified the milestones: 4.2, 4.3 Nov 13, 2023
@YuriSizov
Copy link
Contributor

I guess this is related to (and the opposite of) #84504?

@KoBeWi KoBeWi modified the milestones: 4.3, 4.4 Jul 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Editor: Leaving fullscreen mode does not preserve maximized state (DisplayServer regression)
5 participants