diff options
| author | Jules Aguillon | 2022-06-24 20:26:27 +0200 |
|---|---|---|
| committer | Jules Aguillon | 2022-06-24 20:26:27 +0200 |
| commit | ab987c776c7ddc0fab594f20f4ddf49d98848ccd (patch) | |
| tree | abf1c5cbeaecbb30bb67e57db6044117a7260a4a /srcs/juloo.keyboard2/Keyboard2.java | |
| parent | 6e5be63e25bf2ff2de5c9de5ccd4bc581c639155 (diff) | |
| download | unexpected-keyboard-ab987c776c7ddc0fab594f20f4ddf49d98848ccd.tar.gz unexpected-keyboard-ab987c776c7ddc0fab594f20f4ddf49d98848ccd.zip | |
Fix localized key not in predefined position
The "loc " prefix for predefining a place for an "extra key" was broken
since 31d6a70.
The FLAG_LOCALIZED flag cannot be used anymore, as adding it to any key
would turn it into a different key that wouldn't be recognized by parts
of the code comparing the keys (placing the extra keys).
Add an other layer in KeyboardData to store such informations.
Diffstat (limited to 'srcs/juloo.keyboard2/Keyboard2.java')
| -rw-r--r-- | srcs/juloo.keyboard2/Keyboard2.java | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/srcs/juloo.keyboard2/Keyboard2.java b/srcs/juloo.keyboard2/Keyboard2.java index f57d7fe..2a54111 100644 --- a/srcs/juloo.keyboard2/Keyboard2.java +++ b/srcs/juloo.keyboard2/Keyboard2.java @@ -296,10 +296,9 @@ public class Keyboard2 extends InputMethodService return; KeyboardData layout = getLayout(_config.programming_layout).mapKeys(new KeyboardData.MapKeyValues() { - public KeyValue apply(KeyValue key) + public KeyValue apply(KeyValue key, boolean localized) { - if (key != null - && key.getKind() == KeyValue.Kind.Event + if (key.getKind() == KeyValue.Kind.Event && key.getEvent() == KeyValue.Event.SWITCH_PROGRAMMING) return KeyValue.getKeyByName("switch_text"); return key; |
