- Fixed for abbr.

This commit is contained in:
Shougo Matsushita 2012-11-02 14:57:17 +09:00
parent e367cd6330
commit 343925a5c8
2 changed files with 4 additions and 4 deletions

View File

@ -83,10 +83,10 @@ function! s:keyword_filter(snippets, cur_keyword_str)"{{{
let dict = {}
if len(a:cur_keyword_str) > 1
" Use partial match by abbr.
" Use partial match by filter_str.
let list = filter(values(a:snippets),
\ printf('v:val.abbr =~ %s',
\ string(neocomplcache#keyword_escape(a:cur_keyword_str))))
\ printf('v:val.filter_str =~ %s',
\ string(neocomplcache#keyword_escape(a:cur_keyword_str))))
else
" Use default filter.
let list = neocomplcache#keyword_filter(

View File

@ -214,7 +214,7 @@ function! s:initialize_snippet(dict, path, line, pattern, name)"{{{
let dict = {
\ 'word' : a:dict.name, 'snip' : a:dict.word,
\ 'abbr' : a:dict.abbr,
\ 'filter_str' : a:dict.abbr,
\ 'description' : a:dict.word,
\ 'menu' : menu_pattern . abbr,
\ 'options' : a:dict.options,