F10 shortcut needs reworking for GNOME 3.32
Problem
There is not a direct way to activate the primary-menu in GNOME 3.32 apps.
Some apps have overridden F10 to open the primary menu but this breaks keyboard accessibility of the rest of the headerbar.
Current GTK behavior
F10 selects the first item in the headerbar, if present. Otherwise, F10 selects the first item in the menubar if present. Pressing F10 again when the menubar is focused, unfocuses the menubar, but does nothing when the headerbar is focused.
This behavior was set 5 years ago (the menubar behavior is much older).
Current user docs
Super+F10 Open the application menu on the top bar.
Shift+F10 or Menu Pop up the context menu for the current selection, as if you had right-clicked.
Ctrl+F10 In the file manager, pop up the context menu for the current folder, as if you had right-clicked on the background and not on any item.
Alt+F10 or Super+↑ Maximize a window. Press Alt+F10 or Super+↓ to restore a maximized window to its original size.
https://help.gnome.org/users/gnome-help/stable/keyboard-nav.html
Proposed behavior for F10
- If a menu is open, pressing F10 should deactivate the menu.
- Otherwise… if there is a primary-menu in the headerbar, select and open the primary-menu.
- Else if there is a secondary-menu in the headerbar, select and open the secondary-menu.
- Else if there is a headerbar, select the first item in the headerbar.
- Else if there is a menubar, select and open the first item in the menubar.
- When the primary-menu or secondary-menu is open, pressing → should navigate to the next item in the headerbar.
- … and pressing ← should navigate to the previous item.
- Keyboard navigation of the headerbar should wrap around (like it does with menubars). Pressing → from the last selectable item should navigate to the first item and pressing ← from the first item should navigate to the last item.
Follow up
The user docs need to be updated to remove Super+F10 and add F10 when this is done.