Repository navigation
Detect menu items invoked via keybinding and dispatch keybinding on renderer - #64228
Conversation
…eybinding on renderer
|
I resolved the merge conflict but let SteVen Batten (@sbatten) handle this PR for inclusion as the owner of menus. |
|
I think this will work well for the resolution of keybindings when not using the menu, but the menu itself will still show the keybinding it resolves against the global context and the enablement of that item will also be resolved against the global context. |
|
Thanks SteVen Batten (@sbatten) for the review. I've addressed your comments.
Sure. I suggest we create another issue to track that. The original issue #35225 complains about the key bindings and not about the menu displaying the keybindings. I think they are different problems with different severity and I think they should be tackled independently. |
|
SteVen Batten (@sbatten) Is that a 👍 to merge ? |
|
alexandrudima yes, this can be merged |
|
Alexandru Dima (@alexdima) I'm seeing a regression on this, but #35225 is locked and I can't comment. Should I open a new issue? |
|
Jake Simones (@jesaerys) Yes, please open a new issue. |
Fixes #35225
This PR uses the observation from #35225 (comment) , that Electron gives an event when a menu item is invoked which contains the information about modifier key status. Through a heuristic (that the modifiers must match) we execute, only on mac, a separate code path where the keybinding is sent to the renderer and it is there interpreted using the keybinding service.