Fix keybinding in entry editor in localized installation#3030
Merged
Conversation
Check keycode to avoid localization problems
Member
|
Alternative solution without using the deprecated function: private Optional<KeyCode> determineKeyCodeFromKeyEvent(java.awt.event.KeyEvent keyEvent) {
// special treatment of localized KeyEvents
if (keyEvent.getKeyCode() == java.awt.event.KeyEvent.VK_DELETE) {
return Optional.of(KeyCode.DELETE);
}
return Arrays.stream(KeyCode.values()).filter(k -> k.getName().equals(java.awt.event.KeyEvent.getKeyText(keyEvent.getKeyCode()))).findFirst();
}But this only solves the problem for the "delete" key - so we still might have other yet unidentified problems. So we should decide which route to take ;-) |
Member
|
I would give a +1 for @Siedlerchr's solution, since we surely do not catch all possible keys and the maintable is our next target after the entry editor 😇. |
koppor
approved these changes
Jul 20, 2017
Siedlerchr
added a commit
that referenced
this pull request
Jul 31, 2017
* upstream/master: (41 commits) update xmlunit from 2.3.0 -> 2.4.0 update wiremock from 2.6.0 -> 2.7.0 update controlsfx from 8.40.12 -> 8.40.13 Fix group freeze by running markBasechange in swing thread (#3058) Localization: French: translation of new entries (#3050) Fix ads fetcher (#3048) Update translation (#3041) Translate new strings (#3040) Fix navigation in entry editor increases modifies font size (#3037) Initial idea for architectural decision records (#3033) Readd comment Readd comment Fix keybdining in entry editor in localized installation (#3030) Structuring Upgrade shadowJar Modernizer improvements Replace Reimplement MappedList.kt (#3032) Use https for the maven ej-technologies repo Upgrade modernizer plugin Remove separator next to search bar ...
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Check keycode to avoid localization problems
Follow up from #2853
gradle localizationUpdate?