I'm using Vim with tmux and I wanted to know if there was a signal or something to 'deactivate' the vim window (like when you switch between vim windows) but also when you switch between Vim and Tmux. I'm using vim-tmux-navigator and tried to modify it to have this effect.
vim-tmux-focus-events will send FocusGained and FocusLost events to vim.
This will enable Vim to reload a file that has changed on disk once you switch back to the Vim window.
I don't know airline but if it uses the same events it will work there as well.