fix menus on macos
This commit is contained in:
parent
0988794b48
commit
510652043d
44
src/main.js
44
src/main.js
|
|
@ -2884,28 +2884,26 @@ async function updateMenu() {
|
||||||
} else {
|
} else {
|
||||||
activeFrame = false
|
activeFrame = false
|
||||||
}
|
}
|
||||||
if (macOS) {
|
const appSubmenu = await Submenu.new({
|
||||||
const appSubmenu = await Submenu.new({
|
text: 'Lightningbeam',
|
||||||
text: 'Lightningbeam',
|
items: [
|
||||||
items: [
|
{
|
||||||
{
|
text: 'About Lightningbeam',
|
||||||
text: 'About Lightningbeam',
|
enabled: true,
|
||||||
enabled: true,
|
action:about
|
||||||
action:about
|
},
|
||||||
},
|
{
|
||||||
{
|
text: 'Settings',
|
||||||
text: 'Settings',
|
enabled: false,
|
||||||
enabled: false,
|
action: () => {}
|
||||||
action: () => {}
|
},
|
||||||
},
|
{
|
||||||
{
|
text: 'Quit Lightningbeam',
|
||||||
text: 'Quit Lightningbeam',
|
enabled: true,
|
||||||
enabled: true,
|
action: quit,
|
||||||
action: quit,
|
},
|
||||||
},
|
]
|
||||||
]
|
})
|
||||||
})
|
|
||||||
}
|
|
||||||
const fileSubmenu = await Submenu.new({
|
const fileSubmenu = await Submenu.new({
|
||||||
text: 'File',
|
text: 'File',
|
||||||
items: [
|
items: [
|
||||||
|
|
@ -3066,7 +3064,7 @@ async function updateMenu() {
|
||||||
|
|
||||||
let items = [fileSubmenu, editSubmenu, modifySubmenu, timelineSubmenu, viewSubmenu, helpSubmenu]
|
let items = [fileSubmenu, editSubmenu, modifySubmenu, timelineSubmenu, viewSubmenu, helpSubmenu]
|
||||||
if (macOS) {
|
if (macOS) {
|
||||||
items.unshift([appSubmenu])
|
items.unshift(appSubmenu)
|
||||||
}
|
}
|
||||||
const menu = await Menu.new({
|
const menu = await Menu.new({
|
||||||
items: items,
|
items: items,
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue