forked from kofal.net/zmk
feat(core): Make physical layout key rotation optional (#2770)
To be able to save on flash space, for layouts on space constrained devices that don't require rotation, make key rotation props optional behind a new Kconfig flag.
This commit is contained in:
@@ -46,9 +46,11 @@ BUILD_ASSERT(
|
||||
.height = (int16_t)(int32_t)DT_INST_PHA_BY_IDX(n, keys, i, height), \
|
||||
.x = (int16_t)(int32_t)DT_INST_PHA_BY_IDX(n, keys, i, x), \
|
||||
.y = (int16_t)(int32_t)DT_INST_PHA_BY_IDX(n, keys, i, y), \
|
||||
.rx = (int16_t)(int32_t)DT_INST_PHA_BY_IDX(n, keys, i, rx), \
|
||||
.ry = (int16_t)(int32_t)DT_INST_PHA_BY_IDX(n, keys, i, ry), \
|
||||
.r = (int16_t)(int32_t)DT_INST_PHA_BY_IDX(n, keys, i, r), \
|
||||
COND_CODE_1(IS_ENABLED(CONFIG_ZMK_PHYSICAL_LAYOUT_KEY_ROTATION), \
|
||||
(.rx = (int16_t)(int32_t)DT_INST_PHA_BY_IDX(n, keys, i, rx), \
|
||||
.ry = (int16_t)(int32_t)DT_INST_PHA_BY_IDX(n, keys, i, ry), \
|
||||
.r = (int16_t)(int32_t)DT_INST_PHA_BY_IDX(n, keys, i, r), ), \
|
||||
()) \
|
||||
}
|
||||
|
||||
#define ZMK_LAYOUT_INST(n) \
|
||||
|
||||
Reference in New Issue
Block a user