mirror of
https://github.com/MichMich/MagicMirror.git
synced 2025-06-27 11:50:00 +00:00
Prevent electron flashing white screen on startup (#3001)
see #1919 thanks @dfanica for providing the solution in [this comment](https://github.com/MichMich/MagicMirror/issues/1919#issuecomment-1369898385) tested this on a pi4 with bullseye 32-bit and 64-bit
This commit is contained in:
parent
ed90f0546f
commit
42d42ef452
@ -35,6 +35,7 @@ _This release is scheduled to be released on 2023-04-01._
|
|||||||
|
|
||||||
- Fix wrong day labels in envcanada forecast (#2987)
|
- Fix wrong day labels in envcanada forecast (#2987)
|
||||||
- Fix for missing default class name prefix for customEvents in calendar
|
- Fix for missing default class name prefix for customEvents in calendar
|
||||||
|
- Fixed electron flashing white screen on startup (#1919)
|
||||||
- Fix weathergov provider hourly forecast (#3008)
|
- Fix weathergov provider hourly forecast (#3008)
|
||||||
- Fix message display with HTML code into alert module (#2828)
|
- Fix message display with HTML code into alert module (#2828)
|
||||||
- Fix typo into french translation
|
- Fix typo into french translation
|
||||||
|
@ -46,8 +46,10 @@ function createWindow() {
|
|||||||
if (config.kioskmode) {
|
if (config.kioskmode) {
|
||||||
electronOptionsDefaults.kiosk = true;
|
electronOptionsDefaults.kiosk = true;
|
||||||
} else {
|
} else {
|
||||||
electronOptionsDefaults.fullscreen = true;
|
electronOptionsDefaults.show = false;
|
||||||
electronOptionsDefaults.autoHideMenuBar = true;
|
electronOptionsDefaults.frame = false;
|
||||||
|
electronOptionsDefaults.transparent = true;
|
||||||
|
electronOptionsDefaults.hasShadow = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
const electronOptions = Object.assign({}, electronOptionsDefaults, config.electronOptions);
|
const electronOptions = Object.assign({}, electronOptionsDefaults, config.electronOptions);
|
||||||
@ -117,6 +119,11 @@ function createWindow() {
|
|||||||
|
|
||||||
callback({ responseHeaders: curHeaders });
|
callback({ responseHeaders: curHeaders });
|
||||||
});
|
});
|
||||||
|
|
||||||
|
mainWindow.once("ready-to-show", () => {
|
||||||
|
mainWindow.setFullScreen(true);
|
||||||
|
mainWindow.show();
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
// This method will be called when Electron has finished
|
// This method will be called when Electron has finished
|
||||||
|
Loading…
x
Reference in New Issue
Block a user