From 89e2f346a8e12133e315bd4c927b0df5b99ed979 Mon Sep 17 00:00:00 2001 From: Jan Edmund Lazo Date: Sun, 31 Aug 2025 09:04:34 -0400 Subject: [PATCH] vim-patch:8.1.1751: when redrawing popups plines_win() may be called often Problem: When redrawing popups plines_win() may be called often. Solution: Pass a cache to mouse_comp_pos(). https://github.com/vim/vim/commit/9d5ffceb3fea247a88d4d3936e97b7f488aab6ff Co-authored-by: Bram Moolenaar --- src/nvim/mouse.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/nvim/mouse.c b/src/nvim/mouse.c index 87d97dde47..330095bbf6 100644 --- a/src/nvim/mouse.c +++ b/src/nvim/mouse.c @@ -1602,7 +1602,7 @@ void nv_mouse(cmdarg_T *cap) do_mouse(cap->oap, cap->cmdchar, BACKWARD, cap->count1, 0); } -/// Compute the position in the buffer line from the posn on the screen in +/// Compute the buffer line position from the screen position "rowp" / "colp" in /// window "win". /// Returns true if the position is below the last line. bool mouse_comp_pos(win_T *win, int *rowp, int *colp, linenr_T *lnump)