diff options
author | Marco Hinz <mh.codebro@gmail.com> | 2015-11-23 13:19:00 +0100 |
---|---|---|
committer | Marco Hinz <mh.codebro@gmail.com> | 2015-11-23 13:19:00 +0100 |
commit | 97cee2c2e39888b33a546ba5ffe37c510740c3a5 (patch) | |
tree | d57b9ccf05ca0f910f6af2fbcc95d04e5e523caf /src/nvim/ex_getln.c | |
parent | 321db59ca1dc304feb3e00c10ca3e89c1de616e7 (diff) | |
parent | 6329fd420eec1f1325be2131726e82e23da3e90b (diff) | |
download | rneovim-97cee2c2e39888b33a546ba5ffe37c510740c3a5.tar.gz rneovim-97cee2c2e39888b33a546ba5ffe37c510740c3a5.tar.bz2 rneovim-97cee2c2e39888b33a546ba5ffe37c510740c3a5.zip |
Merge PR #3715 'Enable focus events in cmdline and terminal modes'
Diffstat (limited to 'src/nvim/ex_getln.c')
-rw-r--r-- | src/nvim/ex_getln.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/nvim/ex_getln.c b/src/nvim/ex_getln.c index 52292128d8..cbaf15e38d 100644 --- a/src/nvim/ex_getln.c +++ b/src/nvim/ex_getln.c @@ -1448,6 +1448,14 @@ static int command_line_handle_key(CommandLineState *s) } return command_line_not_changed(s); + case K_FOCUSGAINED: // Neovim has been given focus + apply_autocmds(EVENT_FOCUSGAINED, NULL, NULL, false, curbuf); + return command_line_not_changed(s); + + case K_FOCUSLOST: // Neovim has lost focus + apply_autocmds(EVENT_FOCUSLOST, NULL, NULL, false, curbuf); + return command_line_not_changed(s); + default: // Normal character with no special meaning. Just set mod_mask // to 0x0 so that typing Shift-Space in the GUI doesn't enter |