|
|
@ -118,11 +118,11 @@ EventHandlerResult SpaceCadet::onKeyswitchEvent(Key &mapped_key, KeyAddr key_add
|
|
|
|
++i
|
|
|
|
++i
|
|
|
|
) {
|
|
|
|
) {
|
|
|
|
|
|
|
|
|
|
|
|
if (map[i].flagged
|
|
|
|
if (map[i].flagged
|
|
|
|
&& map[i].input != mapped_key) {
|
|
|
|
&& map[i].input != mapped_key) {
|
|
|
|
other_mapped_key_flagged = true;
|
|
|
|
other_mapped_key_flagged = true;
|
|
|
|
break;
|
|
|
|
break;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
//This will only set one key, and, if it isn't in our map, it clears everything for the non-pressed key
|
|
|
|
//This will only set one key, and, if it isn't in our map, it clears everything for the non-pressed key
|
|
|
@ -141,8 +141,7 @@ EventHandlerResult SpaceCadet::onKeyswitchEvent(Key &mapped_key, KeyAddr key_add
|
|
|
|
//Only activate this as part of the mapping if there isn't already a
|
|
|
|
//Only activate this as part of the mapping if there isn't already a
|
|
|
|
//key waiting for timeout. This allows us to return OK later and for
|
|
|
|
//key waiting for timeout. This allows us to return OK later and for
|
|
|
|
//this loop to inject all the other flagged keys
|
|
|
|
//this loop to inject all the other flagged keys
|
|
|
|
if (!other_mapped_key_flagged)
|
|
|
|
if (!other_mapped_key_flagged) {
|
|
|
|
{
|
|
|
|
|
|
|
|
//The keypress was valid and a match. Mark it as flagged and reset the counter
|
|
|
|
//The keypress was valid and a match. Mark it as flagged and reset the counter
|
|
|
|
map[i].flagged = true;
|
|
|
|
map[i].flagged = true;
|
|
|
|
map[i].start_time = Runtime.millisAtCycleStart();
|
|
|
|
map[i].start_time = Runtime.millisAtCycleStart();
|
|
|
|