summaryrefslogtreecommitdiff
path: root/tmk_core/common/action.c
diff options
context:
space:
mode:
Diffstat (limited to 'tmk_core/common/action.c')
-rw-r--r--tmk_core/common/action.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/tmk_core/common/action.c b/tmk_core/common/action.c
index bb4e66c9c8..3991a8a9ef 100644
--- a/tmk_core/common/action.c
+++ b/tmk_core/common/action.c
@@ -406,8 +406,8 @@ void process_action(keyrecord_t *record, action_t action)
/* Default Layer Bitwise Operation */
if (!event.pressed) {
uint8_t shift = action.layer_bitop.part*4;
- uint32_t bits = ((uint32_t)action.layer_bitop.bits)<<shift;
- uint32_t mask = (action.layer_bitop.xbit) ? ~(((uint32_t)0xf)<<shift) : 0;
+ layer_state_t bits = ((layer_state_t)action.layer_bitop.bits)<<shift;
+ layer_state_t mask = (action.layer_bitop.xbit) ? ~(((layer_state_t)0xf)<<shift) : 0;
switch (action.layer_bitop.op) {
case OP_BIT_AND: default_layer_and(bits | mask); break;
case OP_BIT_OR: default_layer_or(bits | mask); break;
@@ -420,8 +420,8 @@ void process_action(keyrecord_t *record, action_t action)
if (event.pressed ? (action.layer_bitop.on & ON_PRESS) :
(action.layer_bitop.on & ON_RELEASE)) {
uint8_t shift = action.layer_bitop.part*4;
- uint32_t bits = ((uint32_t)action.layer_bitop.bits)<<shift;
- uint32_t mask = (action.layer_bitop.xbit) ? ~(((uint32_t)0xf)<<shift) : 0;
+ layer_state_t bits = ((layer_state_t)action.layer_bitop.bits)<<shift;
+ layer_state_t mask = (action.layer_bitop.xbit) ? ~(((layer_state_t)0xf)<<shift) : 0;
switch (action.layer_bitop.op) {
case OP_BIT_AND: layer_and(bits | mask); break;
case OP_BIT_OR: layer_or(bits | mask); break;