diff --git a/shell/browser/native_window_mac.mm b/shell/browser/native_window_mac.mm index a7f14b4454379..2e19613ded451 100644 --- a/shell/browser/native_window_mac.mm +++ b/shell/browser/native_window_mac.mm @@ -1781,8 +1781,6 @@ void ViewDidMoveToSuperview(NSView* self, SEL _cmd) { } void NativeWindowMac::SetActive(bool is_key) { - if (is_key) - widget()->Activate(); is_active_ = is_key; } diff --git a/spec-main/api-browser-window-spec.ts b/spec-main/api-browser-window-spec.ts index 7b117d96b5fd0..a85ad8ce4aa05 100644 --- a/spec-main/api-browser-window-spec.ts +++ b/spec-main/api-browser-window-spec.ts @@ -4256,6 +4256,20 @@ describe('BrowserWindow module', () => { await leaveFullScreen; expect(w.isFullScreen()).to.be.false('isFullScreen'); }); + + it('multiple windows inherit correct fullscreen state', async () => { + const w = new BrowserWindow(); + const enterFullScreen = emittedOnce(w, 'enter-full-screen'); + w.setFullScreen(true); + await enterFullScreen; + expect(w.isFullScreen()).to.be.true('isFullScreen'); + await delay(); + const w2 = new BrowserWindow({ show: false }); + const enterFullScreen2 = emittedOnce(w2, 'enter-full-screen'); + w2.show(); + await enterFullScreen2; + expect(w2.isFullScreen()).to.be.true('isFullScreen'); + }); }); describe('closable state', () => {