mirror of
https://github.com/qmk/qmk_firmware.git
synced 2025-07-17 21:22:05 +00:00
fixup new struct issues
This commit is contained in:
parent
88e3a8ae15
commit
990e769382
@ -206,9 +206,10 @@ __attribute__((weak)) uint8_t pointing_modes_map_count(void) {
|
||||
*
|
||||
* @return uint16_t keycode at pointing mode map location
|
||||
*/
|
||||
uint16_t keycode_at_pointing_modes_map_location_raw(pointing_modes_map_location_t map_loc) {
|
||||
if (map_loc.map_id < pointing_modes_map_count()) {
|
||||
return pgm_read_word(&pointing_modes_maps[map_loc.map_id][map_loc.dir]);
|
||||
uint16_t keycode_at_pointing_modes_map_location_raw(uint8_t map_loc) {
|
||||
pointing_modes_map_location_t pm_map_loc = {.raw = map_loc};
|
||||
if (pm_map_loc.map_id < pointing_modes_map_count()) {
|
||||
return pgm_read_word(&pointing_modes_maps[pm_map_loc.map_id][pm_map_loc.dir]);
|
||||
}
|
||||
return KC_NO;
|
||||
}
|
||||
@ -223,7 +224,7 @@ uint16_t keycode_at_pointing_modes_map_location_raw(pointing_modes_map_location_
|
||||
*
|
||||
* @return uint16_t keycode at pointing mode map location
|
||||
*/
|
||||
__attribute__((weak)) uint16_t keycode_at_pointing_modes_map_location(pointing_modes_map_location_t map_loc) {
|
||||
__attribute__((weak)) uint16_t keycode_at_pointing_modes_map_location(uint8_t map_loc) {
|
||||
return keycode_at_pointing_modes_map_location_raw(map_loc);
|
||||
}
|
||||
#endif // POINTING_DEVICE_MODES_ENABLE && POINTING_MODES_MAP_ENABLE
|
||||
|
@ -112,7 +112,7 @@ const key_override_t* key_override_get(uint16_t key_override_idx);
|
||||
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
// Pointing Mode Mapping
|
||||
|
||||
#if defined(POINTING_DEVICE_MODES_ENABLE)
|
||||
#if defined(POINTING_DEVICE_MODES_ENABLE) && defined(POINTING_MODES_MAP_ENABLE)
|
||||
|
||||
// Get the number of pointing mode maps, stored in firmware
|
||||
uint8_t pointing_modes_map_count_raw(void);
|
||||
@ -124,4 +124,4 @@ uint16_t keycode_at_pointing_modes_map_location_raw(uint8_t map_loc);
|
||||
// Get the keycode for the encoder mapping location, potentially stored dynamically
|
||||
uint16_t keycode_at_pointing_modes_map_location(uint8_t map_loc);
|
||||
|
||||
#endif // defined(POINTING_DEVICE_MODES_ENABLE)
|
||||
#endif // defined(POINTING_DEVICE_MODES_ENABLE)&& defined(POINTING_MODES_MAP_ENABLE)
|
||||
|
Loading…
Reference in New Issue
Block a user