1
0
mirror of https://github.com/SpaceVim/SpaceVim.git synced 2025-01-23 13:00:04 +08:00

fix(incsearch): use noautocmd to avoid incsearch_nohlsearch key

This commit is contained in:
wsdjeg 2022-05-02 16:31:29 +08:00
parent a44b1be345
commit 48dfd5d179

View File

@ -46,14 +46,16 @@ let s:protocol = ''
let s:chatting_commands = ['/set_protocol', '/set_channel']
let s:all_protocols = ['gitter']
function! chat#windows#open() abort
" "\<Plug>(_incsearch-nohlsearch)" will be send to vim on CursorMoved event,
" so use noautocmd to avoid this issue
if bufwinnr(s:name) < 0
if bufnr(s:name) != -1
exe 'silent! botright split ' . '+b' . bufnr(s:name)
exe 'silent! noautocmd botright split ' . '+b' . bufnr(s:name)
else
exe 'silent! botright split ' . s:name
exe 'silent! noautocmd botright split ' . s:name
endif
else
exec bufwinnr(s:name) . 'wincmd w'
noautocmd exec bufwinnr(s:name) . 'wincmd w'
endif
call s:windowsinit()
call s:init_hi()