From c9f70140347ec9729e84eb783ec45e5fa7675f3e Mon Sep 17 00:00:00 2001 From: Jason Franklin Date: Sat, 11 Nov 2017 12:10:08 -0500 Subject: [PATCH] Fix handlers for "t" and "T" on bookmarks The "t" and "T" mappings didn't work on bookmarks. This commit fixes this problem by making the callbacks more general. Fixes #565. --- autoload/nerdtree/ui_glue.vim | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/autoload/nerdtree/ui_glue.vim b/autoload/nerdtree/ui_glue.vim index a2921f9..f5b4726 100644 --- a/autoload/nerdtree/ui_glue.vim +++ b/autoload/nerdtree/ui_glue.vim @@ -494,12 +494,14 @@ endfunction " FUNCTION: s:openInNewTab(target) {{{1 function! s:openInNewTab(target) - call a:target.open({'where': 't'}) + let l:opener = g:NERDTreeOpener.New(a:target.path, {'where': 't'}) + call l:opener.open(a:target) endfunction " FUNCTION: s:openInNewTabSilent(target) {{{1 function! s:openInNewTabSilent(target) - call a:target.open({'where': 't', 'stay': 1}) + let l:opener = g:NERDTreeOpener.New(a:target.path, {'where': 't', 'stay': 1}) + call l:opener.open(a:target) endfunction " FUNCTION: s:openNodeRecursively(node) {{{1