You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Accessibility issue: Electron system tray context menu on Windows is not keyboard navigable #11587
It is possible to access system tray items and their respective context menus on Windows using the keyboard only. This functionality is important for accessibility reasons.
The system tray is selected using the key combination WINDOWS+B and then opened using the ENTER key. It is then possible to navigate to a specific icon using the arrow keys and select it with ENTER to open the icon's context menu. It should be possible to then navigate through this menu using the arrow keys and select a specific item with ENTER.
Actual behavior
Arrow key navigation and ENTER selection is not available for Electron apps' system tray icon context menus. Pressing the arrow keys while the system tray icon's context menu is open, after being opened using the keyboard steps above, produces no result.
How to reproduce
WINDOWS+B and then ENTER to open the list of icons
Arrow keys and to select the Electron app's icon
Press SHIFT+F-10 to open the icon's context menu
Observe that arrow keys are not useable within this icon's menu, but are for other icons.
Technical details
See notify_icon.cc's function NotifyIcon::PopUpContextMenu which makes a call to the ->RunMenuAt. I am new to the Electron codebase, but as far as I can tell, this is RunMenuAt call is defined in Chromium, meaning we can't change it directly, but will need to find another way to show context menus that is keyboard accessible.
changed the title [-]Accessibility issue: Electron system tray context menu on Windows is not keyboard navigatable[/-][+]Accessibility issue: Electron system tray context menu on Windows is not keyboard navigable[/+]on Jan 8, 2018
I still can't navigate the menu in my application with the arrow keys. I'm using electron 9.0.0. Others have referred to an electron-builder version, but I don't know about that. I'm using electron-packager to create my .exe.
Activity
[-]Accessibility issue: Electron system tray context menu on Windows is not keyboard navigatable[/-][+]Accessibility issue: Electron system tray context menu on Windows is not keyboard navigable[/+]josimi commentedon Jan 8, 2018
Looks like the missing key press handling functionality should be in Chromium's
/ui/views/controls/menu/menu_controller.cc.brentgti commentedon Nov 14, 2019
Did regression occur with this? I created an application with a tray menu, and I can't navigate it with the arrow keys on my keyboard. My code is here: https://github.com/brentgti/electron-Teams-links.
brentgti commentedon Nov 21, 2019
@josimi, @brenca:
Is this issue actually fixed, or maybe there's a regression issue here? My tray menu doesn't allow for navigation via keyboard. See https://github.com/brentgti/electron-Teams-links.
danikane commentedon Dec 7, 2019
I second that. Can't navigate with the keyboard.
1 remaining item
danikane commentedon Mar 12, 2020
Update:
Upgraded to Electron v8.1.1 and electron-builder 22.4.1, same behavior.
Thanks!
brentgti commentedon Jun 1, 2020
I still can't navigate the menu in my application with the arrow keys. I'm using electron 9.0.0. Others have referred to an electron-builder version, but I don't know about that. I'm using electron-packager to create my .exe.
danikane commentedon Jun 1, 2020
The fix was merged just 3 days ago, man...
Wait for a new release.
brentgti commentedon Jun 1, 2020
Sorry, I forgot how these things work 😳. Thanks for the reply.
danikane commentedon Jun 8, 2020
@brentgti https://github.com/electron/electron/releases/tag/v9.0.2
ckerr commentedon Jun 11, 2020
Reopening this issue since the previous fix had unintended side-effects.