Merge pull request #2643 from MMRIZE/develop

Add custom switches for electron mainWindow
This commit is contained in:
Michael Teeuw 2021-08-31 13:12:52 +02:00 committed by GitHub
commit e40ddd4b69
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 2 deletions

View File

@ -11,7 +11,8 @@ _This release is scheduled to be released on 2021-10-01._
### Added ### Added
- Added showTime parameter to clock module for enabling/disabling time display in digital clock - Added showTime parameter to clock module for enabling/disabling time display in analog clock
- Added custom electron switches from user config (`config.electronSwitches`)
### Updated ### Updated

View File

@ -19,7 +19,8 @@ let mainWindow;
* *
*/ */
function createWindow() { function createWindow() {
app.commandLine.appendSwitch("autoplay-policy", "no-user-gesture-required"); let electronSwitchesDefaults = ["autoplay-policy", "no-user-gesture-required"];
app.commandLine.appendSwitch(...new Set(electronSwitchesDefaults, config.electronSwitches));
let electronOptionsDefaults = { let electronOptionsDefaults = {
width: 800, width: 800,
height: 600, height: 600,