This commit is contained in:
Thomas Nordquist
2019-05-01 02:46:06 +02:00
8 changed files with 59 additions and 24 deletions

View File

@@ -14,6 +14,8 @@ if (!isDev() && !runningUiTestOnCi()) {
const electronTelemetry = electronTelemetryFactory('9b0c8ca04a361eb8160d98c5', buildOptions)
}
app.commandLine.appendSwitch('--no-sandbox')
autoUpdater.logger = log
log.info('App starting...')
@@ -33,7 +35,7 @@ async function createWindow() {
loadDevTools()
}
const iconPath = path.join(__dirname, 'icon.png')
const iconPath = path.join(__dirname, '..', '..', 'icon.png')
// Create the browser window.
mainWindow = new BrowserWindow({
width: 1024,
@@ -42,13 +44,14 @@ async function createWindow() {
webPreferences: {
nodeIntegration: true,
devTools: true,
sandbox: false,
},
icon: iconPath,
})
mainWindow.once('ready-to-show', () => {
if (mainWindow) {
runningUiTestOnCi && mainWindow.setFullScreen(true)
runningUiTestOnCi() && mainWindow.setFullScreen(true)
mainWindow.show()
}
})