diff options
| author | B. Watson <urchlay@slackware.uk> | 2026-03-25 03:08:11 -0400 |
|---|---|---|
| committer | B. Watson <urchlay@slackware.uk> | 2026-03-25 03:08:11 -0400 |
| commit | b74d292847b22cf282ff8ae7d1b51df34176ce4d (patch) | |
| tree | 4717814a5390d1672840c2c417ebb4d9606480d8 /src/main.c | |
| parent | 8f19c016edd9f258c1b39eb44647c685b245f2fc (diff) | |
| download | fujinet-chat-b74d292847b22cf282ff8ae7d1b51df34176ce4d.tar.gz | |
Banish cgetc(), and all its annoyances. Much more flexible and precise keyboard control, see keytab.[ch] and kgetc.[ch]
Diffstat (limited to 'src/main.c')
| -rw-r--r-- | src/main.c | 10 |
1 files changed, 3 insertions, 7 deletions
@@ -11,13 +11,12 @@ #include <stdio.h> #include <string.h> #include <ctype.h> -#include <conio.h> // for cgetc() only #include "nio.h" #include "irc.h" #include "screen.h" #include "edbox.h" #include "config.h" -#include "keyclick.h" +#include "kgetc.h" #include "indic8.h" unsigned char err; // error code of last operation. @@ -156,13 +155,10 @@ void reconnect(void) { } scr_print_current(" to reconnect.\n"); - while(OS.cdtmf3 == 0xff && OS.ch == 0xff) + while(OS.cdtmf3 == 0xff && !keypress()) /* NOP */; - if(OS.ch != 0xff) { - keyclick(); - OS.ch = 0xff; - } + if(keypress()) kgetc(); } void main(void) { |
