From 11b7fb91e152258c59b0bb0526c3fb04469cf38c Mon Sep 17 00:00:00 2001 From: Junegunn Choi Date: Wed, 6 Dec 2017 12:29:44 +0900 Subject: [PATCH] Decorate Vim 8 statusline We used to decorate statusline only on Neovim, but we can do the same for Vim 8. --- plugin/fzf.vim | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/plugin/fzf.vim b/plugin/fzf.vim index 79e3d9d..bd6c836 100644 --- a/plugin/fzf.vim +++ b/plugin/fzf.vim @@ -77,7 +77,7 @@ function! fzf#complete(...) return call('fzf#vim#complete', a:000) endfunction -if has('nvim') && get(g:, 'fzf_nvim_statusline', 1) +if (has('nvim') || has('terminal') && has('patch-8.0.995')) && (get(g:, 'fzf_statusline', 1) || get(g:, 'fzf_nvim_statusline', 1)) function! s:fzf_restore_colors() if exists('#User#FzfStatusLine') doautocmd User FzfStatusLine @@ -95,7 +95,7 @@ if has('nvim') && get(g:, 'fzf_nvim_statusline', 1) endif endfunction - function! s:fzf_nvim_term() + function! s:fzf_vim_term() if get(w:, 'airline_active', 0) let w:airline_disabled = 1 autocmd BufWinLeave let w:airline_disabled = 0 @@ -108,7 +108,7 @@ if has('nvim') && get(g:, 'fzf_nvim_statusline', 1) augroup _fzf_statusline autocmd! - autocmd FileType fzf call s:fzf_nvim_term() + autocmd FileType fzf call s:fzf_vim_term() augroup END endif