Commit 59b0f81b authored by Benno Schulenberg's avatar Benno Schulenberg
Browse files

display: redraw title bar and edit window only when needed

When we are in the file browser, browser_refresh() will take care of
redrawing the title bar and the file list, so total_refresh() should
leave those two subwindows alone in that case.

This fixes https://savannah.gnu.org/bugs/?51147.
parent 6ad3d3d6
Showing with 5 additions and 3 deletions
+5 -3
...@@ -3140,17 +3140,19 @@ void total_redraw(void) ...@@ -3140,17 +3140,19 @@ void total_redraw(void)
#endif #endif
} }
/* Unconditionally redraw the entire screen, and then refresh it using /* Redraw the entire screen, then refresh the title bar and the content of
* the current file. */ * the edit window (when not in the file browser), and the bottom bars. */
void total_refresh(void) void total_refresh(void)
{ {
total_redraw(); total_redraw();
if (currmenu != MBROWSER && currmenu != MWHEREISFILE && currmenu != MGOTODIR)
titlebar(title); titlebar(title);
#ifdef ENABLE_HELP #ifdef ENABLE_HELP
if (inhelp) if (inhelp)
wrap_the_help_text(TRUE); wrap_the_help_text(TRUE);
else else
#endif #endif
if (currmenu != MBROWSER && currmenu != MWHEREISFILE && currmenu != MGOTODIR)
edit_refresh(); edit_refresh();
bottombars(currmenu); bottombars(currmenu);
} }
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment