[PATCH 20/21] vim: check compose is done on delete
Felipe Contreras
felipe.contreras at gmail.com
Sat Nov 2 06:55:53 PDT 2013
Not on unload, which happens when we switch buffers.
Signed-off-by: Felipe Contreras <felipe.contreras at gmail.com>
---
vim/notmuch.vim | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/vim/notmuch.vim b/vim/notmuch.vim
index 9109470..d7b310c 100644
--- a/vim/notmuch.vim
+++ b/vim/notmuch.vim
@@ -67,7 +67,7 @@ function! s:new_file_buffer(type, fname)
ruby $curbuf.init(VIM::evaluate('a:type'))
endfunction
-function! s:compose_unload()
+function! s:on_compose_delete()
if b:compose_done
return
endif
@@ -126,7 +126,7 @@ function! s:show_reply()
ruby open_reply get_message.mail
let b:compose_done = 0
call s:set_map(g:notmuch_compose_maps)
- autocmd BufUnload <buffer> call s:compose_unload()
+ autocmd BufDelete <buffer> call s:on_compose_delete()
startinsert!
endfunction
@@ -134,7 +134,7 @@ function! s:compose()
ruby open_compose
let b:compose_done = 0
call s:set_map(g:notmuch_compose_maps)
- autocmd BufUnload <buffer> call s:compose_unload()
+ autocmd BufDelete <buffer> call s:on_compose_delete()
startinsert!
endfunction
--
1.8.4.2+fc1
More information about the notmuch
mailing list