// 判断是否绑定快捷键 let isRegister = globalShortcut.isRegistered('ctrl+e') ? 'Register success' : 'Register Error' console.log(isRegister);
-----------------------
app.on('will-quit',function(){ // 注销全局快捷键 globalShortcut.unregister('ctrl+e') globalShortcut.unregisterAll() })