From f2751e77d974df0074edf68fee1806da350d6036 Mon Sep 17 00:00:00 2001 From: Michael Bleuez Date: Wed, 6 Oct 2021 23:28:21 +0200 Subject: [PATCH] fix close on notification close bug that was as well present for floating windows and terminal --- lua/sniprun.lua | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/lua/sniprun.lua b/lua/sniprun.lua index 9c523264..9bf1fd2e 100644 --- a/lua/sniprun.lua +++ b/lua/sniprun.lua @@ -141,7 +141,8 @@ function M.setup_autocommands() vim.cmd("augroup sniprun_fw_close") vim.cmd("autocmd!") - vim.cmd("autocmd CursorMoved,BufWinLeave * call Sniprun_fw_close_wrapper()") + -- vim.cmd("autocmd CursorMoved,BufWinLeave * call Sniprun_fw_close_wrapper()") + vim.cmd("autocmd CursorMoved * call Sniprun_fw_close_wrapper()") vim.cmd("augroup END") vim.cmd("function! Sniprun_clear_vt_on_leave()\n lua require'sniprun.display'.clear_virtual_text()\n endfunction") @@ -153,7 +154,8 @@ function M.setup_autocommands() vim.cmd("function! Sniprun_close_term_on_leave()\n lua require'sniprun.display'.term_close()\n endfunction") vim.cmd("augroup sniprun_close_term") vim.cmd("autocmd!") - vim.cmd("autocmd VimLeave,QuitPre,BufWinLeave * call Sniprun_close_term_on_leave()") + -- vim.cmd("autocmd VimLeave,QuitPre,BufWinLeave * call Sniprun_close_term_on_leave()") + vim.cmd("autocmd VimLeave,QuitPre * call Sniprun_close_term_on_leave()") vim.cmd("augroup END") end