aboutsummaryrefslogtreecommitdiff
path: root/src/edbox.c
diff options
context:
space:
mode:
authorB. Watson <urchlay@slackware.uk>2026-03-21 02:49:05 -0400
committerB. Watson <urchlay@slackware.uk>2026-03-21 02:49:05 -0400
commit2f8babf83a0c3ed8d8b26fa9b13b540b6f54fd3f (patch)
tree6468ae5b7b6a5c3a01cddcd31cb50125855dd236 /src/edbox.c
parent3d015eaa5b94b66a80cfc31e6f95780cb00a2e4c (diff)
downloadfujinet-chat-2f8babf83a0c3ed8d8b26fa9b13b540b6f54fd3f.tar.gz
Esc now acts as a latch for the Start key (irssi-like, plus easier for XEGS/1200XL users).
Diffstat (limited to 'src/edbox.c')
-rw-r--r--src/edbox.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/src/edbox.c b/src/edbox.c
index d5728c2..d3b0b11 100644
--- a/src/edbox.c
+++ b/src/edbox.c
@@ -236,6 +236,7 @@ static void normal_keystroke(void) {
}
void edbox_keystroke(void) {
+ extern char start_latch;
char c;
while(OS.ch == 0xff)
@@ -266,9 +267,14 @@ void edbox_keystroke(void) {
c = 0x7d; /* ascii: } */
break;
case 0x1c: /* key: ESC */
- c = 0x60; /* ascii: ` */
+ keyclick();
+ if(!edbox_len) edbox_hide();
+ start_latch = 1;
+ return;
break;
case 0x5c: /* key: shift ESC */
+ c = 0x60; /* ascii: ` */
+ break;
case 0x9c: /* key: ctrl ESC */
c = 0x7e; /* ascii: ~ */
break;
@@ -277,7 +283,6 @@ void edbox_keystroke(void) {
case 0xbc: /* ctrl-caps */
OS.shflok ^= 0x40;
keyclick();
- OS.ch = 0xff;
return;
break;
case 0x27: /* atari key */