diff options
author | Bram Moolenaar <Bram@vim.org> | 2018-02-10 18:15:19 +0100 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2018-02-10 18:15:19 +0100 |
commit | 5a093437199001a0d60d8e18e2b9539b99a7757c (patch) | |
tree | 4897a21d58c38ac3adc0c3b309381a58f4bbde45 /src/main.c | |
parent | 9b56a57cdae31f7a2c85d440392bf63d3253a158 (diff) | |
download | vim-git-5a093437199001a0d60d8e18e2b9539b99a7757c.tar.gz |
patch 8.0.1494: no autocmd triggered in Insert mode with visible popup menuv8.0.1494
Problem: No autocmd triggered in Insert mode with visible popup menu.
Solution: Add TextChangedP. (Prabir Shrestha, Christian Brabandt,
closes #2372, closes #1691)
Fix that the TextChanged autocommands are not always triggered
when sourcing a script.
Diffstat (limited to 'src/main.c')
-rw-r--r-- | src/main.c | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/src/main.c b/src/main.c index 9f443aef2..971590aab 100644 --- a/src/main.c +++ b/src/main.c @@ -1201,13 +1201,10 @@ main_loop( #ifdef FEAT_AUTOCMD /* Trigger TextChanged if b:changedtick differs. */ if (!finish_op && has_textchanged() - && last_changedtick != CHANGEDTICK(curbuf)) + && curbuf->b_last_changedtick != CHANGEDTICK(curbuf)) { - if (last_changedtick_buf == curbuf) - apply_autocmds(EVENT_TEXTCHANGED, NULL, NULL, - FALSE, curbuf); - last_changedtick_buf = curbuf; - last_changedtick = CHANGEDTICK(curbuf); + apply_autocmds(EVENT_TEXTCHANGED, NULL, NULL, FALSE, curbuf); + curbuf->b_last_changedtick = CHANGEDTICK(curbuf); } #endif |