From 5817e83e339d2e909e36517671a56759a11ded29 Mon Sep 17 00:00:00 2001 From: Benno Schulenberg Date: Fri, 31 May 2019 10:18:22 +0200 Subject: [PATCH] tweaks: be more sparing in redrawing things when exiting from help viewer That is: don't redraw the title bar twice, don't redraw the bottom bars twice, nor unnecessarily redraw the whole screen. --- src/help.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/src/help.c b/src/help.c index bc7711ab..486a03ae 100644 --- a/src/help.c +++ b/src/help.c @@ -236,6 +236,7 @@ void do_help(void) tabsize = was_tabsize; #ifdef ENABLE_COLOR syntaxstr = was_syntax; + have_palette = FALSE; #endif free(title); @@ -246,21 +247,22 @@ void do_help(void) inhelp = FALSE; curs_set(0); + refresh_needed = TRUE; if (ISSET(NO_HELP)) { currmenu = oldmenu; window_init(); - } else + } else { + wipe_statusbar(); bottombars(oldmenu); - - prepare_for_display(); + } #ifdef ENABLE_BROWSER if (oldmenu == MBROWSER || oldmenu == MWHEREISFILE || oldmenu == MGOTODIR) browser_refresh(); else #endif - total_refresh(); + titlebar(NULL); } /* Allocate space for the help text for the current menu, and concatenate