mirror of
https://github.com/junegunn/fzf.vim.git
synced 2026-10-08 21:15:19 +08:00
Say why CTRL-O did nothing on a refused address
The sinks name the tag; the Show callback returned without a word, so the key looked broken.
This commit is contained in:
1 file changed
+5
-2
@@ -776,7 +776,10 @@ function! s:goto_entry(winid, bufnr, dir, kind, entry) abort
|
|||||||
let path = relpath =~ (s:is_win ? '^[A-Z]:\' : '^/')
|
let path = relpath =~ (s:is_win ? '^[A-Z]:\' : '^/')
|
||||||
\ ? relpath : join([fnamemodify(parts[-1], ':h'), relpath], '/')
|
\ ? relpath : join([fnamemodify(parts[-1], ':h'), relpath], '/')
|
||||||
let path = expand(path, 1)
|
let path = expand(path, 1)
|
||||||
if empty(excmd) || !filereadable(path)
|
if empty(excmd)
|
||||||
|
return s:warn('Unsupported tag address: '.s:strip(parts[0]))
|
||||||
|
endif
|
||||||
|
if !filereadable(path)
|
||||||
return
|
return
|
||||||
endif
|
endif
|
||||||
let cmds = s:edit_cmds(a:winid, path)
|
let cmds = s:edit_cmds(a:winid, path)
|
||||||
@@ -788,7 +791,7 @@ function! s:goto_entry(winid, bufnr, dir, kind, entry) abort
|
|||||||
endif
|
endif
|
||||||
let excmd = s:tag_address(parts[2], 0)
|
let excmd = s:tag_address(parts[2], 0)
|
||||||
if empty(excmd)
|
if empty(excmd)
|
||||||
return
|
return s:warn('Unsupported tag address: '.s:strip(parts[0]))
|
||||||
endif
|
endif
|
||||||
let cmds = ['keepalt keepjumps hide buffer '.a:bufnr,
|
let cmds = ['keepalt keepjumps hide buffer '.a:bufnr,
|
||||||
\ s:sandboxed('keepjumps '.excmd), 'normal! zvzz']
|
\ s:sandboxed('keepjumps '.excmd), 'normal! zvzz']
|
||||||
|
|||||||
Reference in new issue
Block a user