Update vital-over: including fix #177
This commit is contained in:
parent
0ae51b2ddc
commit
60cb17b87f
@ -35,7 +35,7 @@ endfunction
|
|||||||
|
|
||||||
|
|
||||||
function! s:make_plain()
|
function! s:make_plain()
|
||||||
return deepcpy(s:base)
|
return deepcopy(s:base)
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
|
|
||||||
@ -396,6 +396,9 @@ function! s:base._main(...)
|
|||||||
" call self._input(s:_getchar(0))
|
" call self._input(s:_getchar(0))
|
||||||
" call self.draw()
|
" call self.draw()
|
||||||
call self._input(s:_getchar())
|
call self._input(s:_getchar())
|
||||||
|
if self._is_exit()
|
||||||
|
break
|
||||||
|
endif
|
||||||
call self.draw()
|
call self.draw()
|
||||||
catch
|
catch
|
||||||
call self.callevent("on_exception")
|
call self.callevent("on_exception")
|
||||||
@ -466,8 +469,13 @@ endfunction
|
|||||||
|
|
||||||
|
|
||||||
function! s:_getchar(...)
|
function! s:_getchar(...)
|
||||||
let char = call("getchar", a:000)
|
while 1
|
||||||
return type(char) == type(0) ? nr2char(char) : char
|
let char = call("getchar", a:000)
|
||||||
|
" Workaround for the <expr> mappings
|
||||||
|
if char !=# "\x80\xfd`"
|
||||||
|
return type(char) == type(0) ? nr2char(char) : char
|
||||||
|
endif
|
||||||
|
endwhile
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
|
|
||||||
|
@ -3,15 +3,11 @@ let s:save_cpo = &cpo
|
|||||||
set cpo&vim
|
set cpo&vim
|
||||||
|
|
||||||
|
|
||||||
augroup vital-over-commandline-doautocmd-dummy
|
|
||||||
autocmd!
|
|
||||||
augroup END
|
|
||||||
|
|
||||||
|
|
||||||
let s:cache_command = {}
|
let s:cache_command = {}
|
||||||
function! s:doautocmd_user(command)
|
function! s:doautocmd_user(prefix, command)
|
||||||
|
let group = a:prefix . "-vital-over-commandline-doautocmd-dummy"
|
||||||
if !has_key(s:cache_command, a:command)
|
if !has_key(s:cache_command, a:command)
|
||||||
execute "autocmd vital-over-commandline-doautocmd-dummy"
|
execute "autocmd " . group
|
||||||
\ . " User " . a:command." silent! execute ''"
|
\ . " User " . a:command." silent! execute ''"
|
||||||
|
|
||||||
if v:version > 703 || v:version == 703 && has("patch438")
|
if v:version > 703 || v:version == 703 && has("patch438")
|
||||||
@ -57,15 +53,19 @@ let s:module = {
|
|||||||
|
|
||||||
|
|
||||||
for s:i in range(len(s:hooks))
|
for s:i in range(len(s:hooks))
|
||||||
execute join([
|
execute join([
|
||||||
\ "function! s:module.on_" . s:hooks[s:i] . "(...)",
|
\ "function! s:module.on_" . s:hooks[s:i] . "(...)",
|
||||||
\ " call s:doautocmd_user(self.prefix . " . string(s:hooks_camel[s:i]) . ")",
|
\ " call s:doautocmd_user(self.prefix, self.prefix . " . string(s:hooks_camel[s:i]) . ")",
|
||||||
\ "endfunction",
|
\ "endfunction",
|
||||||
\ ], "\n")
|
\ ], "\n")
|
||||||
endfor
|
endfor
|
||||||
|
|
||||||
|
|
||||||
function! s:make(prefix)
|
function! s:make(prefix)
|
||||||
|
execute "augroup " a:prefix . "-vital-over-commandline-doautocmd-dummy"
|
||||||
|
autocmd!
|
||||||
|
augroup END
|
||||||
|
|
||||||
let module = deepcopy(s:module)
|
let module = deepcopy(s:module)
|
||||||
let module.prefix = a:prefix
|
let module.prefix = a:prefix
|
||||||
return module
|
return module
|
||||||
|
@ -37,7 +37,11 @@ endfunction
|
|||||||
|
|
||||||
function! s:module.redraw(cmdline)
|
function! s:module.redraw(cmdline)
|
||||||
redraw
|
redraw
|
||||||
normal! :
|
" Workaround for the :set cedit=<C-c>
|
||||||
|
" https://github.com/osyo-manga/vital-over/issues/52
|
||||||
|
if &cedit != "<C-c>"
|
||||||
|
normal! :
|
||||||
|
endif
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
function! s:make()
|
function! s:make()
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
easymotion
|
easymotion
|
||||||
95279f3
|
d5563d1
|
||||||
|
|
||||||
Over.Commandline.Base
|
Over.Commandline.Base
|
||||||
Over.Commandline.Modules.Cancel
|
Over.Commandline.Modules.Cancel
|
||||||
|
Loading…
x
Reference in New Issue
Block a user