MCPcopy Create free account
hub / github.com/Julow/Unexpected-Keyboard / modify

Method modify

srcs/juloo.keyboard2/KeyModifier.java:18–30  ·  view source on GitHub ↗

Modify a key according to modifiers.

(KeyValue k, Pointers.Modifiers mods)

Source from the content-addressed store, hash-verified

16
17 /** Modify a key according to modifiers. */
18 public static KeyValue modify(KeyValue k, Pointers.Modifiers mods)
19 {
20 if (k == null)
21 return null;
22 int n_mods = mods.size();
23 KeyValue r = k;
24 for (int i = 0; i < n_mods; i++)
25 r = modify(r, mods.get(i));
26 /* Keys with an empty string are placeholder keys. */
27 if (r.getString().length() == 0)
28 return null;
29 return r;
30 }
31
32 /** Like [modify] but do not apply user modmaps. Used when evaluating macros
33 to avoid loops. */

Callers 3

modify_no_modmapMethod · 0.95
modifyKeyMethod · 0.95
applyMethod · 0.95

Calls 15

getStringMethod · 0.95
apply_compose_pendingMethod · 0.95
makeStringKeyMethod · 0.95
combine_hangul_medialMethod · 0.95
apply_ctrlMethod · 0.95
turn_into_keyeventMethod · 0.95
apply_fnMethod · 0.95
apply_gestureMethod · 0.95
apply_shiftMethod · 0.95
apply_dead_charMethod · 0.95

Tested by 1

applyMethod · 0.76