From 09f067fca38c9f89ad088e8c096c4df3998575e2 Mon Sep 17 00:00:00 2001 From: Bram Moolenaar Date: Sun, 11 Apr 2021 13:29:18 +0200 Subject: patch 8.2.2754: :sleep! does not always hide the cursor Problem: :sleep! does not always hide the cursor. Solution: Add the cursor_is_asleep flag. (Jeremy Lerner, closes #8097, closes #7998) --- src/gui.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'src/gui.c') diff --git a/src/gui.c b/src/gui.c index 0265f7c96..c0374c561 100644 --- a/src/gui.c +++ b/src/gui.c @@ -1120,6 +1120,11 @@ gui_update_cursor( || gui.row != gui.cursor_row || gui.col != gui.cursor_col) { gui_undraw_cursor(); + + // If a cursor-less sleep is ongoing, leave the cursor invisible + if (cursor_is_sleeping()) + return; + if (gui.row < 0) return; #ifdef HAVE_INPUT_METHOD -- cgit v1.2.1