diff options
| author | B. Watson <urchlay@slackware.uk> | 2026-03-28 06:35:19 -0400 |
|---|---|---|
| committer | B. Watson <urchlay@slackware.uk> | 2026-03-28 06:35:19 -0400 |
| commit | f8d11de72ddbefd87532102f04cf182a3f122529 (patch) | |
| tree | 3e71fc341357d2908be3f5b7b63bc9e472be408b /src/irc.c | |
| parent | b6a51ea52ab2b58e9b6687170547be7536c0fa9c (diff) | |
| download | fujinet-chat-f8d11de72ddbefd87532102f04cf182a3f122529.tar.gz | |
Save a few bytes...
Diffstat (limited to 'src/irc.c')
| -rw-r--r-- | src/irc.c | 36 |
1 files changed, 18 insertions, 18 deletions
@@ -78,7 +78,7 @@ static void do_pong(void) { } static void bold(void) { - scr_print_active("\x02"); + scr_putc_active('\x02'); } static void hilite_bold(void) { @@ -88,30 +88,28 @@ static void hilite_bold(void) { static void do_chan_nick(void) { if(hilite) { bell(); - // scr_hilite_active(); new_scr_status = SCR_HILITE; } hilite_bold(); - scr_print_active("<"); + scr_putc_active('<'); hilite_bold(); scr_print_active(msg_src); if(scr_active == SCR_SERVER) { /* if we don't have a window for it */ - scr_print_active("/"); + scr_putc_active('/'); scr_print_active(msg_dest); } hilite_bold(); - scr_print_active(">"); + scr_putc_active('>'); hilite_bold(); - scr_print_active(" "); + scr_putc_active(' '); } static void do_priv_nick(void) { if(msg_src) { - scr_print_active("*"); + scr_putc_active('*'); scr_print_active(msg_src); scr_print_active("* "); - // scr_hilite_active(); new_scr_status = SCR_HILITE; bell(); } @@ -147,14 +145,14 @@ static void print_ping_time(char *p) { scr_print_active(" lag: "); itoa(sec, numbuf, 10); scr_print_active(numbuf); - scr_print_active("."); + scr_putc_active('.'); itoa(frac, numbuf, 10); scr_print_active(numbuf); - scr_print_active(" sec"); + scr_putc_active('s'); /* // for debugging: - scr_print_active(" "); + scr_putc_active(' '); itoa(pingtime, numbuf, 10); scr_print_active(numbuf); */ @@ -203,7 +201,7 @@ static void do_ctcp(int is_notice) { if(streq_i(ctcp_type, "ACTION")) { scr_print_active("* "); scr_print_active(msg_src); - scr_print_active(" "); + scr_putc_active(' '); scr_print_active(p); scr_eol_active(); return; @@ -355,7 +353,7 @@ static void do_mode(void) { scr_print_active(" sets mode: "); for(i = 0; i < msg_argcount; i++) { scr_print_active(msg_args[i]); - scr_print_active(" "); + scr_putc_active(' '); } if(msg_text) scr_print_active(msg_text); scr_eol_active(); @@ -367,18 +365,18 @@ static void do_mode(void) { static void do_catchall(int arg) { if(msg_src) { scr_print_active(msg_src); - scr_print_active(" "); + scr_putc_active(' '); } scr_print_active(msg_cmd); for(; arg < msg_argcount; arg++) { - scr_print_active(" "); + scr_putc_active(' '); scr_print_active(msg_args[arg]); } if(msg_text) { - scr_print_active(" "); + scr_putc_active(' '); scr_print_active(msg_text); } scr_eol_active(); @@ -586,8 +584,10 @@ static void dispatch_msg(void) { } if(scr_active != scr_current) { - scr_status[scr_active] = new_scr_status; - scr_show_status(scr_current); + if(scr_status[scr_active] < new_scr_status) { + scr_status[scr_active] = new_scr_status; + scr_show_status(scr_current); + } } } |
