Make the double tap to lock feature behave well.

This commit is contained in:
László Monda
2018-06-07 14:42:23 +02:00
parent 2c91ef51db
commit b0d85795f4
2 changed files with 8 additions and 2 deletions

View File

@@ -20,8 +20,7 @@ void updateLayerStates(void)
if (action.type == KeyActionType_SwitchLayer) {
if (action.switchLayer.mode != SwitchLayerMode_Toggle) {
heldLayers[action.switchLayer.layer] = true;
}
if (action.switchLayer.mode != SwitchLayerMode_Hold && !keyState->previous && keyState->current) {
} else if (!keyState->previous) {
toggledLayers[action.switchLayer.layer] = true;
}
}