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: window ordering on mac #29857
fix: window ordering on mac #29857
Conversation
fea7b82
to
6cc7ccd
Compare
6cc7ccd
to
3274104
Compare
const w2 = new BrowserWindow(); | ||
await delay(); | ||
expect(w2.isFullScreen()).to.be.true('isFullScreen'); | ||
}); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should we add more tests for the other behaviors you mentioned?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I couldn't find a good way to automate tests for scenarios 1 and 3. Scenario 1) requires to check that the Quick Panel from the OS receives the input event and Scenario 3) requires a custom window switcher like https://alt-tab-macos.netlify.app/ for example.
Is this possibly related? #28348 |
Nope it is unrelated. |
3274104
to
fc15683
Compare
Failing tests are unrelated, merging. |
Release Notes Persisted
|
I have automatically backported this PR to "14-x-y", please check out #30066 |
I have automatically backported this PR to "12-x-y", please check out #30067 |
/trop run backport-to 13-x-y |
The backport process for this PR has been manually initiated - sending your PR to |
I was unable to backport this PR to "13-x-y" cleanly; |
Backported in #29234 - missed owing to bad syntax for backport pr body |
Description of Change
Fixes #29758
The call to
NativeWidgetMac::Activate
added in #29204 tries to set the visibility state of the window viaNativeWidgetNSWindowBridge
with state kShowAndActivateWindow which eventually calls[NSWindow makeKeyAndOrderFront:]
This is all fine for normal cases, but under the following situations it triggers a series of
windowDidBecomeKey:
notifications that messes with window ordering.Since we are making the widget call in the key window notification code path, it is safe to remove this redundant call that is causing the above incorrect behaviors.
Checklist
npm test
passesRelease Notes
Notes: fix key window status on mac when opening panels or using custom window switchers