Merge pull request #74781 from NousResearch/bb/pane-context-menus

Stop right-click showing a lone Select All on bare surfaces
This commit is contained in:
brooklyn! 2026-07-30 06:01:51 -05:00 committed by GitHub
commit 14db1a99e2
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -5642,8 +5642,12 @@ function installContextMenu(window) {
}
}
// Bare right-click on non-editable, non-selected, non-media content (a pane
// body, the sidebar, chrome): the renderer's own context menus own those
// surfaces, and anywhere without one shows nothing — not a lone, useless
// "Select All" from the native fallback.
if (!template.length) {
template.push({ role: 'selectAll' })
return
}
Menu.buildFromTemplate(template).popup({ window })