From b2b15e6e137d7be2b01bf2174791f36bd12981bd Mon Sep 17 00:00:00 2001 From: "Justin M. Keyes" Date: Sat, 11 Mar 2017 16:00:26 +0100 Subject: win/package: nvim-qt v0.2.6 (#6258) --- runtime/plugin/gui_shim.vim | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'runtime/plugin') diff --git a/runtime/plugin/gui_shim.vim b/runtime/plugin/gui_shim.vim index 28d82eb1c7..575b826b5e 100644 --- a/runtime/plugin/gui_shim.vim +++ b/runtime/plugin/gui_shim.vim @@ -4,6 +4,14 @@ if !has('win32') || !has('nvim') || exists('g:GuiLoaded') endif let g:GuiLoaded = 1 +" Close the GUI +function! GuiClose() abort + call rpcnotify(0, 'Gui', 'Close') +endfunction + +" Notify the GUI when exiting Neovim +autocmd VimLeave * call GuiClose() + " A replacement for foreground() function! GuiForeground() abort call rpcnotify(0, 'Gui', 'Foreground') -- cgit