From: Christian Heller Date: Tue, 27 Oct 2020 07:02:18 +0000 (+0100) Subject: Fix edit mode key retrieval. X-Git-Url: https://plomlompom.com/repos/%7B%7Bdb.prefix%7D%7D/te"st.html?a=commitdiff_plain;h=26f34308d92c8cd30007feff4a1201b8bf0fb185;p=plomrogue2-experiments Fix edit mode key retrieval. --- diff --git a/new2/rogue_chat_nocanvas_monochrome.html b/new2/rogue_chat_nocanvas_monochrome.html index db7e303..bea6f0a 100644 --- a/new2/rogue_chat_nocanvas_monochrome.html +++ b/new2/rogue_chat_nocanvas_monochrome.html @@ -448,10 +448,10 @@ document.addEventListener('keydown', (event) => { websocket.send('TASK:MOVE DOWN'); }; } else if (tui.mode == 'edit') { - if (event.key.length === 1) { + if (event.key != "Shift" && event.key.length == 1) { websocket.send("TASK:WRITE " + quote(event.key)); + tui.switch_mode('play'); } - tui.switch_mode('play'); } else if (tui.mode == 'study') { if (event.key === 'c') { tui.switch_mode('chat');