diff options
author | Shougo Matsushita <Shougo.Matsu@gmail.com> | 2017-05-17 09:03:19 +0900 |
---|---|---|
committer | Shougo Matsushita <Shougo.Matsu@gmail.com> | 2017-05-17 09:03:19 +0900 |
commit | eeda83b2234844bea5027d22a3e3d1804f50f758 (patch) | |
tree | e0ebdbb865b5c231fbda2846711b15a61d6e39fd | |
parent | cb095ecf89cbc7a98345424328be9fe13f75762a (diff) | |
download | deoplete.nvim-eeda83b2234844bea5027d22a3e3d1804f50f758.zip |
Fix CompleteDone problem
-rw-r--r-- | autoload/deoplete/handler.vim | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/autoload/deoplete/handler.vim b/autoload/deoplete/handler.vim index b4c0a02..6c41deb 100644 --- a/autoload/deoplete/handler.vim +++ b/autoload/deoplete/handler.vim @@ -117,6 +117,7 @@ function! s:completion_begin(event) abort let context = deoplete#init#_context(a:event, []) if s:is_skip(a:event, context) call deoplete#mapping#_restore_completeopt() + let g:deoplete#_context.candidates = [] return endif @@ -165,7 +166,7 @@ function! s:is_skip_text(event) abort if has_key(context, 'input') \ && a:event !=# 'Manual' \ && a:event !=# 'Async' - \ && input ==# context['input'] + \ && input ==# context.input return 1 endif @@ -206,6 +207,12 @@ function! s:complete_done() abort let g:deoplete#_rank[word] += 1 endif endif + + " Skip the next completion + let input = deoplete#util#get_input('CompleteDone') + if input[-1:] !=# '/' + let g:deoplete#_context.input = input + endif endfunction function! s:on_insert_char_pre() abort |