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: maximize/unmaximize firing on linux #32441
Conversation
1dba51d
to
c85ea14
Compare
Release Notes Persisted
|
I was unable to backport this PR to "14-x-y" cleanly; |
I was unable to backport this PR to "15-x-y" cleanly; |
I was unable to backport this PR to "16-x-y" cleanly; |
I have automatically backported this PR to "17-x-y", please check out #32492 |
@codebytere has manually backported this PR to "16-x-y", please check out #32497 |
@codebytere has manually backported this PR to "15-x-y", please check out #32498 |
@codebytere has manually backported this PR to "14-x-y", please check out #32499 |
Description of Change
Closes #28699.
Fixes an issue where the 'maximize' and 'unmaximize' events didn't fire properly on linux.
This was happening as a result of changes made in #27280 to address CL:2577887 and CL:2585750. In the resultant change, we assigned
was_maximized_
at the top ofWindowStateWatcher::OnEvent
- given that this was being called in the function after the event had taken place, the previous value would match the current value using this logic and thus it would never be the case thatis_minimized != was_minimized_
oris_maximized != was_maximized_
and thus the events would never fire.Fix this by assigning
was_minimized_
andwas_maximized_
in places that properly allow the change to be reflected.Tested with https://gist.github.com/Jelmerro/5a5a8b0cfcf69a24993b47bd7526d242
cc @dsanders11 since this should allow you to better test #32438
Checklist
npm test
passesRelease Notes
Notes: Fixed an issue where the 'maximize' and 'unmaximize' events didn't fire properly on linux.