From 4fdcc5497503658324fda2e0073d830276b24b60 Mon Sep 17 00:00:00 2001 From: Ben Harris Date: Sat, 5 Nov 2022 17:39:42 +0000 Subject: [PATCH] js: Make SoftRight act as CURSOR_SELECT2 as well This way, the front end can intercept one of SoftLeft and SoftRight as a menu key and leave the other one for the puzzle. And while we don't have a working menu, I can use whichever is more convenient. --- emcc.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/emcc.c b/emcc.c index 02833df..c223b14 100644 --- a/emcc.c +++ b/emcc.c @@ -301,7 +301,8 @@ bool key(int keycode, const char *key, const char *chr, int location, keyevent = CURSOR_RIGHT; else if (!strnullcmp(key, "ArrowDown") || !strnullcmp(key, "Down")) keyevent = CURSOR_DOWN; - else if (!strnullcmp(key, "SoftLeft")) /* Left soft key on KaiOS */ + else if (!strnullcmp(key, "SoftLeft") || !strnullcmp(key, "SoftRight")) + /* Left and right soft key on KaiOS. */ keyevent = CURSOR_SELECT2; else if (!strnullcmp(key, "End")) /*