### Preflight Checklist

- [X] I have read the [Contributing Guidelines](https://github.com/electron/electron/blob/master/CONTRIBUTING.md) for this project.
- [X] I agree to follow the [Code of Conduct](https://github.com/electron/electron/blob/master/CODE_OF_CONDUCT.md) that this project adheres to.
- [X] I have searched the [issue tracker](https://www.github.com/electron/electron/issues) for a feature request that matches the one I want to file, without success.

### Electron Version

12.0.5

### What operating system are you using?

Windows

### Operating System Version

Windows 10

### What arch are you using?

x64

### Last Known Working Electron version

_No response_

### Expected Behavior

According to the doc [`BrowserWindow.getAllWindows`](https://www.electronjs.org/docs/api/browser-window#browserwindowgetallwindows): Returns `BrowserWindow[]` - An array of all opened browser windows. I expect that behaviour always.

### Actual Behavior

In the [`window-all-closed`](https://www.electronjs.org/docs/api/app#event-window-all-closed) event handler the `BrowserWindow.getAllWindows` is not empty, it returns the closed window.

Note: when running inside Electron Fiddle, the `console.error` from the `window-all-closed` does not appear in the Fiddle's console when the app quits. It appears in the Fiddle's console when you Run the app again.

### Testcase Gist URL

https://gist.github.com/8b63d0581b49793ce8bdddfe0aecaed3
shell/browser/native_window.cc
if (options.Get(options::kMovable, &movable)) {
    SetMovable(movable);
  }
  bool has_shadow;
  if (options.Get(options::kHasShadow, &has_shadow)) {
    SetHasShadow(has_shadow);
  }
  double opacity;
  if (options.Get(options::kOpacity, &opacity)) {
    SetOpacity(opacity);
  }
  bool top;
  if (options.Get(options::kAlwaysOnTop, &top) && top) {
    SetAlwaysOnTop(ui::ZOrderLevel::kFloatingWindow);
  }
  bool fullscreenable = true;
  bool fullscreen = false;
  if (options.Get(options::kFullscreen, &fullscreen) && !fullscreen) {
    
#if defined(OS_MAC)
    fullscreenable = false;
#endif
  }
  
  options.Get(options::kFullScreenable, &fullscreenable);
  SetFullScreenable(fullscreenable);
  if (fullscreen) {
    SetFullScreen(true);
  }
  bool skip;