commit 1792b6a75b337d739dbc6cd16c3091e9f38923cd
parent 727770147a7589ab3a06722f4852c0237c8b3549
Author: Jason Franklin <j_fra@fastmail.us>
Date: Sun, 22 Apr 2018 10:19:13 -0400
Clear output when the NERDTree menu is aborted
Previously, exiting the NERDTree menu with "Ctrl-C" or "Esc" would
leave the last line of the menu visible. We can avoid this by
redrawing the screen when the menu is aborted in this manner.
Diffstat:
1 file changed, 5 insertions(+), 0 deletions(-)
diff --git a/lib/nerdtree/menu_controller.vim b/lib/nerdtree/menu_controller.vim
@@ -33,6 +33,11 @@ function! s:MenuController.showMenu()
endwhile
finally
call self._restoreOptions()
+
+ " Redraw when "Ctrl-C" or "Esc" is received.
+ if !l:done || self.selection == -1
+ redraw!
+ endif
endtry
if self.selection != -1