Fix persistence of last window size and position
This commit is contained in:
parent
aa5dabd1d8
commit
ec4d9e857a
1 changed files with 5 additions and 0 deletions
|
@ -844,6 +844,8 @@ async function createWindow() {
|
|||
|
||||
mainWindow.on('resize', captureWindowStats);
|
||||
mainWindow.on('move', captureWindowStats);
|
||||
mainWindow.on('maximize', captureWindowStats);
|
||||
mainWindow.on('unmaximize', captureWindowStats);
|
||||
|
||||
if (!ciMode && config.get<boolean>('openDevTools')) {
|
||||
// Open the DevTools.
|
||||
|
@ -950,6 +952,9 @@ async function createWindow() {
|
|||
return;
|
||||
}
|
||||
|
||||
// Persist pending window settings to ephemeralConfig
|
||||
debouncedSaveStats.flush();
|
||||
|
||||
windowState.markRequestedShutdown();
|
||||
await requestShutdown();
|
||||
windowState.markReadyForShutdown();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue