Undo when LiveEasyAlign is cancelled via CTRL-C

This commit is contained in:
Junegunn Choi
2016-01-26 00:57:25 +09:00
parent 4fb4c1056c
commit d1b68f9dd0

View File

@@ -657,7 +657,11 @@ function! s:interactive(range, modes, n, d, opts, rules, vis, bvis)
let check = 0
let warn = ''
try
let c = getchar()
catch /^Vim:Interrupt$/
let c = 27
endtry
let ch = nr2char(c)
if c == 3 || c == 27 " CTRL-C / ESC
if undo