1
0
mirror of https://github.com/gryf/tagbar.git synced 2025-12-17 11:30:28 +01:00

Work around a statusline bug in Vim < 7.1.097

This commit is contained in:
Jan Larres
2011-11-25 19:50:48 +13:00
parent 4bc7555b80
commit 5c50b77a5a

View File

@@ -1461,7 +1461,12 @@ function! s:InitWindow(autoclose)
setlocal foldmethod&
setlocal foldexpr&
setlocal statusline=%!TagbarGenerateStatusline()
" Earlier versions have a bug in local, evaluated statuslines
if v:version > 701 || (v:version == 701 && has('patch097'))
setlocal statusline=%!TagbarGenerateStatusline()
else
setlocal statusline=Tagbar
endif
" Script-local variable needed since compare functions can't
" take extra arguments