Merge pull request #3641 from t3chguy/t3chguy/electron_launch_hidden

add command line arg (--hidden) for electron app
pull/3272/merge
Matthew Hodgson 2017-04-22 03:02:48 +01:00 committed by GitHub
commit fb3ef89b50
1 changed files with 6 additions and 3 deletions

View File

@ -201,9 +201,12 @@ electron.app.on('ready', () => {
brand: vectorConfig.brand || 'Riot'
});
if (!process.argv.includes('--hidden')) {
mainWindow.once('ready-to-show', () => {
mainWindow.show();
});
}
mainWindow.on('closed', () => {
mainWindow = null;
});