| 110 |
while (c = igetch_t (60)) |
while (c = igetch_t (60)) |
| 111 |
{ |
{ |
| 112 |
if (c == KEY_NULL || c == KEY_TIMEOUT || c == CR) |
if (c == KEY_NULL || c == KEY_TIMEOUT || c == CR) |
| 113 |
break; |
break; |
| 114 |
if (c == LF) |
if (c == LF) |
| 115 |
continue; |
continue; |
| 116 |
if (c == BACKSPACE) |
if (c == BACKSPACE) |
| 161 |
} |
} |
| 162 |
|
|
| 163 |
int |
int |
| 164 |
|
get_data (int row, int col, char *prompt, char *buffer, int buffer_length, int echo_mode) |
| 165 |
|
{ |
| 166 |
|
int len; |
| 167 |
|
|
| 168 |
|
moveto (row, col); |
| 169 |
|
iflush (); |
| 170 |
|
prints (prompt); |
| 171 |
|
prints (buffer); |
| 172 |
|
iflush (); |
| 173 |
|
|
| 174 |
|
len = str_input (buffer, buffer_length, echo_mode); |
| 175 |
|
|
| 176 |
|
return len; |
| 177 |
|
} |
| 178 |
|
|
| 179 |
|
int |
| 180 |
display_file (const char *filename) |
display_file (const char *filename) |
| 181 |
{ |
{ |
| 182 |
char buffer[260]; |
char buffer[260]; |