mirror of
https://github.com/electron/electron.git
synced 2026-05-02 03:00:22 -04:00
Merge pull request #5718 from felixrieseberg/windows-fullscreenable
Fix setFullscreen() on Windows
This commit is contained in:
@@ -142,6 +142,11 @@ void NativeWindow::InitFromOptions(const mate::Dictionary& options) {
|
||||
bool fullscreen = false;
|
||||
if (options.Get(options::kFullscreen, &fullscreen) && !fullscreen)
|
||||
fullscreenable = false;
|
||||
// On Windows, we can only enter fullscreen via API
|
||||
// Ensure that setFullscreen(true) is usable by default
|
||||
#if defined(OS_WIN)
|
||||
fullscreenable = true;
|
||||
#endif
|
||||
// Overriden by 'fullscreenable'.
|
||||
options.Get(options::kFullScreenable, &fullscreenable);
|
||||
SetFullScreenable(fullscreenable);
|
||||
|
||||
Reference in New Issue
Block a user