New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 823763 link

Starred by 4 users

Issue metadata

Status: Fixed
Owner:
Last visit > 30 days ago
Closed: Mar 2018
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Chrome
Pri: 2
Type: Feature



Sign in to add a comment

Allow Linux apps to handle any keyboard shortcut

Project Member Reported by tbuck...@chromium.org, Mar 20 2018

Issue description

Today Chrome will handle shortcuts like Ctrl+N, Ctrl+T.

Ideally Chrome would only handle these shortcuts if the Linux app does not. However, if we cannot detect whether the Linux app has handled it, we should instead have Linux apps handle all shortcuts that do not contain the Search/Launcher key.

 
Labels: Hotlist-Announce

Comment 2 by vapier@chromium.org, Mar 20 2018

what about Assistant/Power/media-top-row keys ?
Status: Assigned (was: Available)
The keyboard ack protocol we use for arc++ makes it possible to handle this in sommelier instances on the guest side and potentially use a different set of accelerators per application. I'll try to add a flag that makes it possible to specific what keyboard combinations that should be consumed by the app.

I'm going to use the following format and XKB keysym names unless someone has a better suggestion:

--reserve-accelerators=Ctrl+N,Alt+0

Please provide a default set of reserved accelerators. The user can always override it but would still be nice to have a decent default value.

Comment 4 by vapier@chromium.org, Mar 21 2018

if the container apps had the same policy wrt shortcuts as Android apps, i think that'd make perfect sense.  i don't know what that policy is currently though :).
Android apps get to process all key events except a really small set of truly reserved ones. If the Android app tells us that it didn't handle the event, then Chrome will consume it. Android framework allows us to do this.

Wayland clients can use this wayland extension we added for arc++ to ack handled events but none of the standard Linux apps do of course. I don't think we can expect toolkits and apps to update to this in the near future either.

So we need something less sophisticated for regular wayland clients and X11.

Comment 6 by vapier@chromium.org, Mar 21 2018

i would say that, for the top row keys (all the media/brightness/etc...), we should let the OS consume them first.  only when you press search+top keys would they get passed through (although Chrome would also turn those into F-keys).

wrt the assistant key, i think we want to start with only Chrome consuming it and not letting apps see it.
Landed a change to sommelier that makes all keyboard shortcuts that are not special and reserved by Chrome go to the apps. This is likely an improvement over having Chrome steal all these shortcuts. I'm going to follow up with a sommelier setting that allows the user to add shortcuts that they still want Chrome to handle.
Cc: puneetster@chromium.org
Status: Fixed (was: Assigned)
Sommelier 0.17 will pass all keyboard shortcuts that Chrome allows apps to handle to the app.

Keyboard shortcuts that we still want Chrome to handle can be specified using --accelerators flags or SOMMELIER_ACCELERATORS variable. E.g. use "systemctl --edit sommelier@0.service" and add Environment="SOMMELIER_ACCELERATORS=<Alt>Equal,<Control>W" to have those keyboard shortcuts still go to Chrome.

Our crostini settings package can provide a default set of keyboard shortcuts that we think Chrome should still handle.
Tip, if you want launcher button to still bring up the app list when a crostini app has keyboard focus then add "Super_L" to SOMMELIER_ACCELERATORS.
Components: OS>Systems>Containers
Cc: tbuck...@chromium.org
 Issue 826839  has been merged into this issue.
 Issue 829188  has been merged into this issue.
Labels: -Restrict-View-Google

Sign in to add a comment