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: child window alwaysOnTop level persistence #29813

Merged
merged 4 commits into from Jun 23, 2021
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
7 changes: 6 additions & 1 deletion shell/browser/native_window_mac.mm
Expand Up @@ -1805,10 +1805,15 @@ void ViewDidMoveToSuperview(NSView* self, SEL _cmd) {

// Set new parent window.
// Note that this method will force the window to become visible.
if (parent && attach)
if (parent && attach) {
// Attaching a window as a child window resets its window level, so
// save and restore it afterwards.
NSInteger level = window_.level;
[parent->GetNativeWindow().GetNativeNSWindow()
addChildWindow:window_
ordered:NSWindowAbove];
[window_ setLevel:level];
}
}

void NativeWindowMac::SetForwardMouseMessages(bool forward) {
Expand Down