ref: 35d382019fa3fead56cfe77b64e720acc1c0da09
parent: f5ac13c847083a0499a258829be9c666cee7b00b
author: Ben Harris <bjh21@bjh21.me.uk>
date: Mon Oct 24 19:33:09 EDT 2022
js: Recognise KeyboardEvent.key == "Escape"
--- a/emcc.c
+++ b/emcc.c
@@ -277,6 +277,8 @@
keyevent = 127; /* Backspace / Delete */
else if (!strnullcmp(key, "Enter"))
keyevent = 13; /* return */
+ else if (!strnullcmp(key, "Escape"))
+ keyevent = 27;
else if (!strnullcmp(key, "ArrowLeft") || !strnullcmp(key, "Left"))
keyevent = CURSOR_LEFT;
else if (!strnullcmp(key, "ArrowUp") || !strnullcmp(key, "Up"))