summaryrefslogtreecommitdiff
path: root/src/edit.c
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2016-08-02 22:36:02 +0200
committerBram Moolenaar <Bram@vim.org>2016-08-02 22:36:02 +0200
commit472472898ab71ac80a86fedc37f8eb91461788dd (patch)
tree3e8de60a24605e8fddeac5ceec0bd5a6d46b34d0 /src/edit.c
parent86f2cd5bc574c23fa276d7f57cd1300e24222913 (diff)
downloadvim-git-472472898ab71ac80a86fedc37f8eb91461788dd.tar.gz
patch 7.4.2146v7.4.2146
Problem: Not enough testing for popup menu. CTRL-E does not always work properly. Solution: Add more tests. When using CTRL-E check if the popup menu is visible. (Christian Brabandt)
Diffstat (limited to 'src/edit.c')
-rw-r--r--src/edit.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/edit.c b/src/edit.c
index a60d9229a..6dae4a01e 100644
--- a/src/edit.c
+++ b/src/edit.c
@@ -3891,8 +3891,9 @@ ins_compl_prep(int c)
&& pum_visible())
retval = TRUE;
- /* CTRL-E means completion is Ended, go back to the typed text. */
- if (c == Ctrl_E)
+ /* CTRL-E means completion is Ended, go back to the typed text.
+ * but only do this, if the Popup is still visible */
+ if (c == Ctrl_E && pum_visible())
{
ins_compl_delete();
if (compl_leader != NULL)