perf(statusline): UI elements are always redrawn on K_EVENT

Problem:    'statusline'-format UI elements are redrawn on each K_EVENT.
Solution:   Only redraw UI elements when something relevant has changed.
This commit is contained in:
Luuk van Baal
2023-03-08 12:36:03 +01:00
parent 1fb585a9db
commit fe11079721
7 changed files with 167 additions and 151 deletions

View File

@@ -611,7 +611,7 @@ int showmode(void)
// the ruler is after the mode message and must be redrawn
win_T *last = lastwin_nofloating();
if (redrawing() && last->w_status_height == 0 && global_stl_height() == 0) {
win_redr_ruler(last, true);
win_redr_ruler(last);
}
redraw_cmdline = false;