builder: don't call add_separtor twice
This commit is contained in:
parent
f08078d683
commit
a993ae5d42
@ -142,7 +142,6 @@ endfunction
|
|||||||
|
|
||||||
function! s:get_transitioned_seperator(self, prev_group, group, side)
|
function! s:get_transitioned_seperator(self, prev_group, group, side)
|
||||||
let line = ''
|
let line = ''
|
||||||
call airline#highlighter#add_separator(a:prev_group, a:group, a:side)
|
|
||||||
if get(a:self._context, 'tabline', 0) && get(g:, 'airline#extensions#tabline#alt_sep', 0) && a:group ==# 'airline_tabsel' && a:side
|
if get(a:self._context, 'tabline', 0) && get(g:, 'airline#extensions#tabline#alt_sep', 0) && a:group ==# 'airline_tabsel' && a:side
|
||||||
call airline#highlighter#add_separator(a:prev_group, a:group, 0)
|
call airline#highlighter#add_separator(a:prev_group, a:group, 0)
|
||||||
let line .= '%#'.a:prev_group.'_to_'.a:group.'#'
|
let line .= '%#'.a:prev_group.'_to_'.a:group.'#'
|
||||||
@ -166,6 +165,7 @@ endfunction
|
|||||||
|
|
||||||
function! s:get_accented_line(self, group, contents)
|
function! s:get_accented_line(self, group, contents)
|
||||||
if a:self._context.active
|
if a:self._context.active
|
||||||
|
" active window
|
||||||
let contents = []
|
let contents = []
|
||||||
let content_parts = split(a:contents, '__accent')
|
let content_parts = split(a:contents, '__accent')
|
||||||
for cpart in content_parts
|
for cpart in content_parts
|
||||||
@ -175,6 +175,7 @@ function! s:get_accented_line(self, group, contents)
|
|||||||
let line = join(contents, a:group)
|
let line = join(contents, a:group)
|
||||||
let line = substitute(line, '__restore__', a:group, 'g')
|
let line = substitute(line, '__restore__', a:group, 'g')
|
||||||
else
|
else
|
||||||
|
" inactive window
|
||||||
let line = substitute(a:contents, '%#__accent[^#]*#', '', 'g')
|
let line = substitute(a:contents, '%#__accent[^#]*#', '', 'g')
|
||||||
let line = substitute(line, '%#__restore__#', '', 'g')
|
let line = substitute(line, '%#__restore__#', '', 'g')
|
||||||
endif
|
endif
|
||||||
|
Loading…
Reference in New Issue
Block a user