Add User autocommand for Theme changing

fixes #1226
This commit is contained in:
Christian Brabandt 2016-08-24 21:27:49 +02:00
parent d00f7b35d2
commit 7612aaf701
2 changed files with 3 additions and 0 deletions

View File

@ -65,6 +65,8 @@ function! airline#switch_theme(name)
let w:airline_lastmode = ''
call airline#load_theme()
silent doautocmd User AirlineAfterTheme
" this is required to prevent clobbering the startup info message, i don't know why...
call airline#check_mode(winnr())
endfunction

View File

@ -168,6 +168,7 @@ Airline comes with some user-defined autocommands.
|AirlineAfterInit| after plugin is initialized, but before the statusline
is replaced
|AirlineAfterTheme| after theme of the statusline has been changed
|AirlineToggledOn| after airline is activated and replaced the statusline
|AirlineToggledOff| after airline is deactivated and the statusline is
restored to the original