Skip to content

Commit

Permalink
Update on command line changed
Browse files Browse the repository at this point in the history
This will allow us to immediately show changes to the command line
instead of relying on polling hacks.
  • Loading branch information
ardagnir committed Aug 4, 2019
1 parent 61f3ec7 commit 6b8e8cb
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions plugin/vimbed.vim
Expand Up @@ -223,6 +223,11 @@ function! Vimbed_SetupVimbed(path, dirname, options)
sil exec "autocmd InsertEnter * call <SID>WriteSlice(1)"
sil exec "autocmd InsertLeave * call <SID>WriteSlice(0)"
sil exec "autocmd InsertChange * call <SID>WriteSlice(1)"
if v:version>=801 || (v:version==800 && has("patch1445"))
sil exec "autocmd CmdlineChanged * call <SID>WriteSlice(0)"
sil exec "autocmd CmdlineEnter * call <SID>WriteSlice(0)"
sil exec "autocmd CmdlineLeave * call <SID>WriteSlice(0)"
endif
sil exec "autocmd VimLeave * call <SID>VimLeave('".s:sliceFile."')"
else
sil exec "sil autocmd TextChanged * call <SID>WriteFile()"
Expand All @@ -235,6 +240,11 @@ function! Vimbed_SetupVimbed(path, dirname, options)
sil exec "autocmd InsertEnter * call <SID>WriteMetaFile(1)"
sil exec "autocmd InsertLeave * call <SID>WriteMetaFile(0)"
sil exec "autocmd InsertChange * call <SID>WriteMetaFile(1)"
if v:version>=801 || (v:version==800 && has("patch1445"))
sil exec "autocmd CmdlineChanged * call <SID>WriteMetaFile(0)"
sil exec "autocmd CmdlineEnter * call <SID>WriteSlice(0)"
sil exec "autocmd CmdlineLeave * call <SID>WriteSlice(0)"
endif
sil exec "autocmd VimLeave * call <SID>VimLeave('".s:metaFile."')"
endif

Expand Down

0 comments on commit 6b8e8cb

Please sign in to comment.