diff options
Diffstat (limited to 'src/nvim/popupmnu.c')
-rw-r--r-- | src/nvim/popupmnu.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/nvim/popupmnu.c b/src/nvim/popupmnu.c index 184285b5f6..19b92c5789 100644 --- a/src/nvim/popupmnu.c +++ b/src/nvim/popupmnu.c @@ -18,6 +18,7 @@ #include "nvim/search.h" #include "nvim/strings.h" #include "nvim/window.h" +#include "nvim/edit.h" static pumitem_T *pum_array = NULL; // items of displayed pum static int pum_size; // nr of items in "pum_array" @@ -540,7 +541,9 @@ static int pum_set_selected(int n, int repeat) if ((p_pvh > 0) && (p_pvh < g_do_tagpreview)) { g_do_tagpreview = p_pvh; } + RedrawingDisabled++; resized = prepare_tagpreview(false); + RedrawingDisabled--; g_do_tagpreview = 0; if (curwin->w_p_pvw) { @@ -607,6 +610,13 @@ static int pum_set_selected(int n, int repeat) curwin->w_cursor.col = 0; if ((curwin != curwin_save) && win_valid(curwin_save)) { + // When the first completion is done and the preview + // window is not resized, skip the preview window's + // status line redrawing. + if (ins_compl_active() && !resized) { + curwin->w_redr_status = FALSE; + } + // Return cursor to where we were validate_cursor(); redraw_later(SOME_VALID); |