From 505c12cb9c65ef82f217db25e4d93bffe9783306 Mon Sep 17 00:00:00 2001 From: Björn Linse Date: Sun, 26 Dec 2021 23:43:37 +0100 Subject: fix(api): nvim__set_hl_ns causes extra redraws --- src/nvim/api/vim.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src') diff --git a/src/nvim/api/vim.c b/src/nvim/api/vim.c index f81cdf9deb..4a0222234d 100644 --- a/src/nvim/api/vim.c +++ b/src/nvim/api/vim.c @@ -169,7 +169,7 @@ void nvim__set_hl_ns(Integer ns_id, Error *err) // event path for redraws caused by "fast" events. This could tie in with // better throttling of async events causing redraws, such as non-batched // nvim_buf_set_extmark calls from async contexts. - if (!provider_active && !ns_hl_changed) { + if (!provider_active && !ns_hl_changed && must_redraw < NOT_VALID) { multiqueue_put(main_loop.events, on_redraw_event, 0); } ns_hl_changed = true; -- cgit