Fix NO_TERMS compile, rename func

... to match others, from tty_curs_set to term_curs_set
This commit is contained in:
Pasi Kallinen
2024-04-02 14:31:33 +03:00
parent 7030b0b9fe
commit c4d4bafb44
4 changed files with 24 additions and 17 deletions
+11 -4
View File
@@ -542,7 +542,7 @@ tty_init_nhwindows(int *argcp UNUSED, char **argv UNUSED)
/* to port dependant tty setup */
tty_startup(&wid, &hgt);
setftty(); /* calls start_screen */
tty_curs_set(0);
term_curs_set(0);
/* set up tty descriptor */
ttyDisplay = (struct DisplayDesc *) alloc(sizeof (struct DisplayDesc));
@@ -808,7 +808,7 @@ tty_exit_nhwindows(const char *str)
{
winid i;
tty_curs_set(1);
term_curs_set(1);
tty_suspend_nhwindows(str);
/*
* Disable windows to avoid calls to window routines.
@@ -3934,6 +3934,13 @@ term_start_bgcolor(int color)
/* placeholder for now */
}
#endif /* !MSDOS && !WIN32 */
void
term_curs_set(int visibility UNUSED)
{
/* nothing */
}
#endif /* NO_TERMS */
void
@@ -3987,7 +3994,7 @@ tty_nhgetch(void)
HUPSKIP_RESULT('\033');
print_vt_code1(AVTC_INLINE_SYNC);
tty_curs_set(1);
term_curs_set(1);
(void) fflush(stdout);
/* Note: if raw_print() and wait_synch() get called to report terminal
* initialization problems, then wins[] and ttyDisplay might not be
@@ -4021,7 +4028,7 @@ tty_nhgetch(void)
}
#endif
}
tty_curs_set(0);
term_curs_set(0);
if (!i)
i = '\033'; /* map NUL to ESC since nethack doesn't expect NUL */
else if (i == EOF)