summaryrefslogtreecommitdiff
path: root/quantum/keyboard.c
diff options
context:
space:
mode:
authorNick Brassel <nick@tzarc.org>2022-09-30 03:25:55 +1000
committerGitHub <noreply@github.com>2022-09-29 18:25:55 +0100
commitcbbb45c13f3de5ec28f62b6cd4a8b77143026500 (patch)
treeca148a07c46dc873d46f434f0aee4d4090139816 /quantum/keyboard.c
parent8349ff1e8bbca7f41e9bc446ac10e8a9be81c698 (diff)
Start moving towards introspection-based data retrieval (#18441)
Diffstat (limited to 'quantum/keyboard.c')
-rw-r--r--quantum/keyboard.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/quantum/keyboard.c b/quantum/keyboard.c
index 3b5e9b0200..c8025d059b 100644
--- a/quantum/keyboard.c
+++ b/quantum/keyboard.c
@@ -175,12 +175,11 @@ uint32_t get_matrix_scan_rate(void) {
#endif
#ifdef MATRIX_HAS_GHOST
-extern const uint16_t keymaps[][MATRIX_ROWS][MATRIX_COLS];
-static matrix_row_t get_real_keys(uint8_t row, matrix_row_t rowdata) {
+static matrix_row_t get_real_keys(uint8_t row, matrix_row_t rowdata) {
matrix_row_t out = 0;
for (uint8_t col = 0; col < MATRIX_COLS; col++) {
// read each key in the row data and check if the keymap defines it as a real key
- if (pgm_read_byte(&keymaps[0][row][col]) && (rowdata & (1 << col))) {
+ if (keycode_at_keymap_location(0, row, col) && (rowdata & (1 << col))) {
// this creates new row data, if a key is defined in the keymap, it will be set here
out |= 1 << col;
}