From a80c4c1ef746f09bb62555625d2d41413a3a9836 Mon Sep 17 00:00:00 2001 From: chax Date: Mon, 10 Dec 2018 01:09:13 +0100 Subject: [PATCH 1/2] fixes #4583 --- quantum/process_keycode/process_terminal.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/quantum/process_keycode/process_terminal.c b/quantum/process_keycode/process_terminal.c index 6998639f206c..d9622953388d 100644 --- a/quantum/process_keycode/process_terminal.c +++ b/quantum/process_keycode/process_terminal.c @@ -273,11 +273,17 @@ bool process_terminal(uint16_t keycode, keyrecord_t *record) { disable_terminal(); return false; } + + if (keycode >= QK_MOD_TAP && keycode <= QK_MOD_TAP_MAX) { + keycode = keycode & 0xFF; + } + if (keycode < 256) { uint8_t str_len; char char_to_add; switch (keycode) { case KC_ENTER: + case KC_KP_ENTER: push_to_cmd_buffer(); current_cmd_buffer_pos = 0; process_terminal_command(); From 6de7d069725cc0b287a4124e20f6aa69f9218ad6 Mon Sep 17 00:00:00 2001 From: chax Date: Mon, 10 Dec 2018 10:11:17 +0100 Subject: [PATCH 2/2] #4583 - terminal also handles layer tap now --- quantum/process_keycode/process_terminal.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/quantum/process_keycode/process_terminal.c b/quantum/process_keycode/process_terminal.c index d9622953388d..e791deffc10b 100644 --- a/quantum/process_keycode/process_terminal.c +++ b/quantum/process_keycode/process_terminal.c @@ -274,7 +274,7 @@ bool process_terminal(uint16_t keycode, keyrecord_t *record) { return false; } - if (keycode >= QK_MOD_TAP && keycode <= QK_MOD_TAP_MAX) { + if ((keycode >= QK_MOD_TAP && keycode <= QK_MOD_TAP_MAX) || (keycode >= QK_LAYER_TAP && keycode <= QK_LAYER_TAP_MAX)) { keycode = keycode & 0xFF; }