1
0
Fork 0

[Keyboard] Fixes to make snes_macropad play nicer with qmk configurator (#22432)

* [Keyboard] Change default implementation for get_layer_name_user

Will now show the layer number instead of "Unknown", since this is
what will be shown if QMK Configurator is used to compile the
firmware.

* [Keyboard] Update the layout info

This makes it look sort of like a macropad + gamepad rather than an 4x6
ortholinear keyboard.

* [Keyboard] Fix default implementation of get_layer_name_user

Based on feedback from code review the implementation was swapped in
favor of using get_u8_str. This implied a change to the argument type
from int to uint8_t, which cascaded into the existing keymaps. (This
made sense in general, since the return type of get_highest_layer is
also a uint8_t.)
This commit is contained in:
John Barbero 2023-11-12 06:30:31 +01:00 committed by GitHub
parent 0189c485b9
commit c2326c05c0
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 17 additions and 17 deletions

View file

@ -57,8 +57,8 @@ static void oled_render_keylog(void) {
oled_write_char(key_name, false);
}
__attribute__((weak)) const char * get_layer_name_user(int layer) {
return "Unknown";
__attribute__((weak)) const char * get_layer_name_user(uint8_t layer) {
return get_u8_str(layer, ' ');
}
static void oled_render_layer(void) {