diff src/edit.c @ 8891:d7ba3f9b9ba6 v7.4.1732

commit https://github.com/vim/vim/commit/429fcfbf9a9275367fe9441a50a3dcd773497d84 Author: Bram Moolenaar <Bram@vim.org> Date: Thu Apr 14 16:22:04 2016 +0200 patch 7.4.1732 Problem: Folds may close when using autocomplete. (Anmol Sethi) Solution: Increment/decrement disable_fold. (Christian Brabandt, closes https://github.com/vim/vim/issues/643)
author Christian Brabandt <cb@256bit.org>
date Thu, 14 Apr 2016 16:30:05 +0200
parents a541dd5cfd3a
children 219d80fee92f
line wrap: on
line diff
--- a/src/edit.c
+++ b/src/edit.c
@@ -1424,8 +1424,10 @@ doESCkey:
 
 docomplete:
 	    compl_busy = TRUE;
+	    disable_fold_update++;  /* don't redraw folds here */
 	    if (ins_complete(c, TRUE) == FAIL)
 		compl_cont_status = 0;
+	    disable_fold_update--;
 	    compl_busy = FALSE;
 	    break;
 #endif /* FEAT_INS_EXPAND */