nano

nano with my custom patches
git clone git://bsandro.tech/nano
Log | Files | Refs | README | LICENSE

commit 5817e83e339d2e909e36517671a56759a11ded29
parent 122cabd3ba6bb1a7b935420f3e3c660683e70cca
Author: Benno Schulenberg <bensberg@telfort.nl>
Date:   Fri, 31 May 2019 10:18:22 +0200

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.

Diffstat:
Msrc/help.c | 10++++++----
1 file changed, 6 insertions(+), 4 deletions(-)

diff --git 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