mirror a tree which tab already closed

This commit is contained in:
momo 2017-09-24 18:04:29 +08:00
parent 5782b228e4
commit cb5ce66398

View File

@ -134,6 +134,13 @@ function! s:Creator.createMirror()
call add(treeBufNames, nextName)
endif
endfor
for i in range(1, bufnr('$'))
let nextName = bufname(i)
if bufexists(i) && getbufvar(i, '&filetype') == 'nerdtree' && (!exists("t:NERDTreeBufName") || nextName != t:NERDTreeBufName)
call add(treeBufNames, nextName)
endif
endfor
let treeBufNames = self._uniq(treeBufNames)
"map the option names (that the user will be prompted with) to the nerd