Revert "Upgrade electron"

This reverts commit cefd9e95db.
This commit is contained in:
Thomas Nordquist
2019-04-09 23:56:20 +02:00
parent 1e8a451a68
commit 5be21475ce
3 changed files with 11 additions and 9 deletions

View File

@@ -93,8 +93,9 @@ const viewMenu: MenuItemConstructorOptions = {
click: () => {
const window = BrowserWindow.getFocusedWindow()
if (window) {
const zoom = window.webContents.getZoomFactor()
window.webContents.setZoomFactor(Math.min(zoom + 0.1, 2.0))
window.webContents.getZoomFactor((zoom) => {
window.webContents.setZoomFactor(Math.min(zoom + 0.1, 2.0))
})
}
},
},
@@ -104,8 +105,9 @@ const viewMenu: MenuItemConstructorOptions = {
click: () => {
const window = BrowserWindow.getFocusedWindow()
if (window) {
const zoom = window.webContents.getZoomFactor()
window.webContents.setZoomFactor(Math.max(zoom - 0.1, 0.5))
window.webContents.getZoomFactor((zoom) => {
window.webContents.setZoomFactor(Math.max(zoom - 0.1, 0.5))
})
}
},
},