Skip to content

Commit

Permalink
Upgrade to Electron 4 and other dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
sindresorhus committed Dec 20, 2018
1 parent 3bd0520 commit 2744a35
Show file tree
Hide file tree
Showing 4 changed files with 61 additions and 48 deletions.
2 changes: 1 addition & 1 deletion browser.js
Expand Up @@ -426,7 +426,7 @@ document.addEventListener('DOMContentLoaded', () => {
document.body.appendChild(style);

// Set the zoom factor if it was set before quitting
const zoomFactor = config.get('zoomFactor') || 1.0;
const zoomFactor = config.get('zoomFactor') || 1;
setZoom(zoomFactor);

// Enable OS specific styles
Expand Down
6 changes: 2 additions & 4 deletions index.js
Expand Up @@ -189,6 +189,7 @@ function createMainWindow() {
webPreferences: {
preload: path.join(__dirname, 'browser.js'),
nodeIntegration: false,
contextIsolation: true,
plugins: true
}
});
Expand Down Expand Up @@ -379,10 +380,7 @@ app.on('activate', () => {

app.on('before-quit', () => {
isQuitting = true;

if (!mainWindow.isFullScreen()) {
config.set('lastWindowState', mainWindow.getBounds());
}
config.set('lastWindowState', mainWindow.getNormalBounds());
});

ipcMain.on('notification', (event, {title, body, icon, silent, fileName}) => {
Expand Down
95 changes: 55 additions & 40 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions package.json
Expand Up @@ -37,11 +37,11 @@
},
"devDependencies": {
"del-cli": "^1.1.0",
"electron": "3.0.12",
"electron-builder": "20.38.3",
"electron": "^4.0.0",
"electron-builder": "^20.38.4",
"np": "^3.1.0",
"stylelint": "^9.8.0",
"stylelint-config-xo": "^0.11.0",
"stylelint-config-xo": "^0.12.0",
"xo": "^0.23.0"
},
"xo": {
Expand Down

0 comments on commit 2744a35

Please sign in to comment.