mirror of
https://github.com/airblade/vim-gitgutter.git
synced 2025-11-08 11:33:48 -05:00
Fix closing floating preview window
When a floating window is closed, the cursor automatically goes back to the original window. There is no need to try to do this ourselves. Fixes #866.
This commit is contained in:
@@ -248,7 +248,9 @@ function! s:hunk_op(op, ...)
|
||||
|
||||
let hunk_diff = join(hunk_header + hunk_body, "\n")."\n"
|
||||
|
||||
call s:goto_original_window()
|
||||
if &previewwindow
|
||||
call s:goto_original_window()
|
||||
endif
|
||||
call gitgutter#hunk#close_hunk_preview_window()
|
||||
call s:stage(hunk_diff)
|
||||
endif
|
||||
|
||||
Reference in New Issue
Block a user