Add 'Start Speaking' and 'Stop Speaking' menu item (Mac)

Probably improves the accessibility situation a little bit: #439
This commit is contained in:
Feross Aboukhadijeh
2017-02-09 15:05:38 -08:00
parent 00f2e5ccd6
commit c298950d34

View File

@@ -324,7 +324,7 @@ function getMenuTemplate () {
]
if (process.platform === 'darwin') {
// Add WebTorrent app menu (Mac)
// WebTorrent menu (Mac)
template.unshift({
label: config.APP_NAME,
submenu: [
@@ -367,7 +367,25 @@ function getMenuTemplate () {
]
})
// Add Window menu (Mac)
// Edit menu (Mac)
template[2].submenu.push(
{
type: 'separator'
},
{
label: 'Speech',
submenu: [
{
role: 'startspeaking'
},
{
role: 'stopspeaking'
}
]
}
)
// Window menu (Mac)
template.splice(6, 0, {
role: 'window',
submenu: [