From 42c23d386432df0b79b4835bc711e27724a91cbc Mon Sep 17 00:00:00 2001 From: Jules Aguillon Date: Tue, 31 Dec 2024 12:10:02 +0100 Subject: Refactor: Simplify double tap for capslock This doesn't fix a bug but remove some tricky code. The shift key is no longer different when the "double tap for capslock" option is on. The handling of the option is moved to Pointer instead and becomes simpler. --- srcs/juloo.keyboard2/Keyboard2View.java | 5 ----- 1 file changed, 5 deletions(-) (limited to 'srcs/juloo.keyboard2/Keyboard2View.java') diff --git a/srcs/juloo.keyboard2/Keyboard2View.java b/srcs/juloo.keyboard2/Keyboard2View.java index f124b6b..6f6be2a 100644 --- a/srcs/juloo.keyboard2/Keyboard2View.java +++ b/srcs/juloo.keyboard2/Keyboard2View.java @@ -104,11 +104,6 @@ public class Keyboard2View extends View _keyboard = kw; _shift_kv = KeyValue.getKeyByName("shift"); _shift_key = _keyboard.findKeyWithValue(_shift_kv); - if (_shift_key == null) - { - _shift_kv = _shift_kv.withFlags(_shift_kv.getFlags() | KeyValue.FLAG_LOCK); - _shift_key = _keyboard.findKeyWithValue(_shift_kv); - } _compose_kv = KeyValue.getKeyByName("compose"); _compose_key = _keyboard.findKeyWithValue(_compose_kv); KeyModifier.set_modmap(_keyboard.modmap); -- cgit v1.2.3