diff --git a/src/nano.c b/src/nano.c index 1b85c49f..435f4a88 100644 --- a/src/nano.c +++ b/src/nano.c @@ -2455,7 +2455,7 @@ int main(int argc, char **argv) if (currmenu != MMAIN) bottombars(MMAIN); - lastmessage = HUSH; + lastmessage = VACUUM; as_an_at = TRUE; /* Update the displayed current cursor position only when there diff --git a/src/nano.h b/src/nano.h index 62392b0f..2b86476b 100644 --- a/src/nano.h +++ b/src/nano.h @@ -147,7 +147,7 @@ typedef enum { } format_type; typedef enum { - HUSH, NOTICE, MILD, ALERT + VACUUM, HUSH, NOTICE, MILD, ALERT } message_type; typedef enum { diff --git a/src/prompt.c b/src/prompt.c index 27786199..f66da1c8 100644 --- a/src/prompt.c +++ b/src/prompt.c @@ -580,6 +580,8 @@ int do_prompt(bool allow_tabs, bool allow_files, /* Reserve five columns for colon plus angles plus answer, ":". */ prompt[actual_x(prompt, (COLS < 5) ? 0 : COLS - 5)] = '\0'; + lastmessage = VACUUM; + func = acquire_an_answer(&retval, allow_tabs, allow_files, &listed, history_list, refresh_func); free(prompt); @@ -602,7 +604,8 @@ int do_prompt(bool allow_tabs, bool allow_files, else if (func == do_enter) retval = (*answer == '\0') ? -2 : 0; - wipe_statusbar(); + if (lastmessage == VACUUM) + wipe_statusbar(); #ifdef ENABLE_TABCOMP /* If we've done tab completion, there might still be a list of