Fix error when showing empty menu.
This commit is contained in:
parent
f07d8c5677
commit
22927c9478
2 changed files with 1 additions and 5 deletions
|
@ -99,7 +99,7 @@ Menu.setApplicationMenu = (menu) ->
|
|||
if process.platform is 'darwin'
|
||||
# Force menuWillShow to be called
|
||||
menuWillShow = (menu) ->
|
||||
menu.delegate.menuWillShow()
|
||||
menu.delegate?.menuWillShow()
|
||||
menuWillShow item.submenu for item in menu.items when item.submenu?
|
||||
menuWillShow menu
|
||||
|
||||
|
|
|
@ -127,10 +127,6 @@ app.on('ready', function() {
|
|||
},
|
||||
]
|
||||
},
|
||||
{
|
||||
label: 'Help',
|
||||
submenu: [],
|
||||
}
|
||||
];
|
||||
|
||||
var menu = Menu.buildFromTemplate(template);
|
||||
|
|
Loading…
Add table
Reference in a new issue