Mercurial > vim
diff src/edit.c @ 3516:ebec52bc2800 v7.3.519
updated for version 7.3.519
Problem: When completefunction returns it cannot indicate end of completion
mode.
Solution: Recognize completefunction returning -3. (Mtsushita Shougo)
author | Bram Moolenaar <bram@vim.org> |
---|---|
date | Fri, 18 May 2012 16:35:21 +0200 |
parents | 75037f9bc97a |
children | 65f905eb14cd |
line wrap: on
line diff
--- a/src/edit.c +++ b/src/edit.c @@ -5205,9 +5205,17 @@ ins_complete(c) } /* Return value -2 means the user complete function wants to - * cancel the complete without an error. */ + * cancel the complete without an error. + * Return value -3 does the same as -2 and leaves CTRL-X mode.*/ if (col == -2) return FAIL; + if (col == -3) + { + ctrl_x_mode = 0; + edit_submode = NULL; + msg_clr_cmdline(); + return FAIL; + } /* * Reset extended parameters of completion, when start new