-
Notifications
You must be signed in to change notification settings - Fork 607
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[menubar] Support keyboard shortcuts #95
Comments
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
Adds the ability to set shortcuts for menu items, using the same format on the Dart side that will be used for Action shorcuts. Currently only the macOS platform implementation uses them. There are some limitations around non-ascii keys, which will be resolved via a full generated keymap once this is folded into Flutter, but common cases are special-cased, and more special-casing can be added as needed by clients. Adds various shortcuts to the testbed app, exercising various modifiers and special cases. Partially addresses google#95
Adds the ability to set shortcuts for menu items, using the same format on the Dart side that will be used for Action shorcuts. Currently only the macOS platform implementation uses them. There are some limitations around non-ascii keys, which will be resolved via a full generated keymap once this is folded into Flutter, but common cases are special-cased, and more special-casing can be added as needed by clients. Adds various shortcuts to the testbed app, exercising various modifiers and special cases. Partially addresses #95
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
Workaround: https://github.com/RobertOdrowaz/flutter-desktop-embedding/tree/feature/short-cut-labels It implements only displaying of the shortcut labels the actual events still need to be handled in flutter e.g. using the I don't have enough expertise in GTK and win32 programming to resolve this issue completely. I believe the Linux implementation would work correctly if flutter didn't have precedence in event handling and consume the key events first. The windows implementation doesn't include event handling at all. |
The current menu support doesn't allow for keyboard shortcuts, which is definitely necessary.
(It might also be useful to have some kind of generic way for widgets to handle keyboard shortcuts, but that would need more thought about how focus works in a desktop Flutter environment.)
The text was updated successfully, but these errors were encountered: