-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
The comment added in commit 8a0bc97 ("[egui_glium] Fix paste") seems to assume that `winit` "should have translated" common "paste" keyboard combos to a `Cut`/`Copy`/`Paste` "KeyCode", but completely glossed over the fact that this `KeyCode` (now also `NamedKey`) maps to a special key dedicated to this purpose found on some keyboards and OSes. Make sure that this key is still handled in addition to the combo that is detected. --- Note that this PR does not compile as it is (and I have hence not tested this nor even ran into this limitation), just noticed this inconsistency while failing to understand a code comment. We'd have to decide if the variants should be added to `egui::Key` or if these helper functions need to take `winit` keys (`ScanCode` or `NamedKey`) directly? I should have an old keyboard with a physical paste key in a drawer somewhere. And on Android there are special copy/paste events that can be sent by a virtual keyboard or the debug shell, so that this can be properly tested before it is merged. (Except that the current `clipboard` implementation is not supported on Android)
- Loading branch information
Showing
2 changed files
with
66 additions
and
43 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters