Skip to content

Commit

Permalink
[Bug] Fix tri layer compiler issue if NO_ACTION_LAYER is defined (#19821
Browse files Browse the repository at this point in the history
)
  • Loading branch information
drashna authored Feb 12, 2023
1 parent 9c6942e commit b1f4d49
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions quantum/action_layer.c
Original file line number Diff line number Diff line change
Expand Up @@ -350,6 +350,7 @@ action_t layer_switch_get_action(keypos_t key) {
return action_for_key(layer_switch_get_layer(key), key);
}

#ifndef NO_ACTION_LAYER
layer_state_t update_tri_layer_state(layer_state_t state, uint8_t layer1, uint8_t layer2, uint8_t layer3) {
layer_state_t mask12 = ((layer_state_t)1 << layer1) | ((layer_state_t)1 << layer2);
layer_state_t mask3 = (layer_state_t)1 << layer3;
Expand All @@ -359,3 +360,4 @@ layer_state_t update_tri_layer_state(layer_state_t state, uint8_t layer1, uint8_
void update_tri_layer(uint8_t layer1, uint8_t layer2, uint8_t layer3) {
layer_state_set(update_tri_layer_state(layer_state, layer1, layer2, layer3));
}
#endif

0 comments on commit b1f4d49

Please sign in to comment.