mirror of
https://github.com/vim-airline/vim-airline.git
synced 2024-11-22 14:05:04 +08:00
Add a separate function for returning all available themes
This commit is contained in:
parent
49671d0a11
commit
b20e181bc8
|
@ -124,3 +124,8 @@ endfunction
|
|||
function! airline#util#doautocmd(event)
|
||||
exe printf("silent doautocmd %s User %s", s:nomodeline, a:event)
|
||||
endfunction
|
||||
|
||||
function! airline#util#themes(match)
|
||||
let files = split(globpath(&rtp, 'autoload/airline/themes/'.a:match.'*'), "\n")
|
||||
return map(files, 'fnamemodify(v:val, ":t:r")')
|
||||
endfunction
|
||||
|
|
|
@ -146,8 +146,7 @@ function! s:airline_toggle()
|
|||
endfunction
|
||||
|
||||
function! s:get_airline_themes(a, l, p)
|
||||
let files = split(globpath(&rtp, 'autoload/airline/themes/'.a:a.'*'), "\n")
|
||||
return map(files, 'fnamemodify(v:val, ":t:r")')
|
||||
return airline#util#themes(a:a)
|
||||
endfunction
|
||||
|
||||
function! s:airline_theme(...)
|
||||
|
|
Loading…
Reference in New Issue
Block a user