1
0
mirror of https://github.com/mifi/lossless-cut.git synced 2024-11-22 02:12:30 +01:00

fix edit menu removal

This commit is contained in:
Mikael Finstad 2018-09-25 00:19:57 +02:00
parent 3e3f046685
commit f46be1781c

View File

@ -10,10 +10,10 @@ const releasesPage = 'https://github.com/mifi/lossless-cut/releases';
module.exports = (app, mainWindow, newVersion) => {
const menu = defaultMenu(app, electron.shell);
const editMenuIndex = menu.findIndex(item => item.Label === 'Edit');
const editMenuIndex = menu.findIndex(item => item.label === 'Edit');
if (editMenuIndex >= 0) menu.splice(editMenuIndex, 1);
menu.splice((process.platform === 'darwin' ? 1 : 0), 0, {
const fileMenu = {
label: 'File',
submenu: [
{
@ -44,7 +44,9 @@ module.exports = (app, mainWindow, newVersion) => {
},
},
],
});
};
menu.splice((process.platform === 'darwin' ? 1 : 0), 0, fileMenu);
const helpIndex = menu.findIndex(item => item.role === 'help');
if (helpIndex >= 0) {