diff --git a/lib/gui/etcher.js b/lib/gui/etcher.js index 81e94b74..aad2cac0 100644 --- a/lib/gui/etcher.js +++ b/lib/gui/etcher.js @@ -17,6 +17,7 @@ 'use strict'; const electron = require('electron'); +const _ = require('lodash'); const path = require('path'); let mainWindow = null; @@ -69,6 +70,15 @@ electron.app.on('ready', () => { mode: 'detach' }); }); + + // Disable refreshing the browser window + // This is supposed to be handled by the `will-navigate` + // event, however there seems to be an issue where such + // event is not fired in macOS + // See: https://github.com/electron/electron/issues/8841 + electron.globalShortcut.register('CmdOrCtrl+R', _.noop); + electron.globalShortcut.register('F5', _.noop); + }); mainWindow.on('blur', () => {