mirror of
https://github.com/preservim/nerdtree.git
synced 2025-11-09 11:53:48 -05:00
make marks global instead of tab based
This commit is contained in:
@@ -1372,7 +1372,7 @@ endfunction " >>>
|
|||||||
"FUNCTION: s:ClearAllMarks() {{{2
|
"FUNCTION: s:ClearAllMarks() {{{2
|
||||||
"delete all marks
|
"delete all marks
|
||||||
function! s:ClearAllMarks()
|
function! s:ClearAllMarks()
|
||||||
let t:NERDTreeMarks = {}
|
let g:NERDTreeMarks = {}
|
||||||
endfunction
|
endfunction
|
||||||
"FUNCTION: s:GetNodeForMark(name, searchFromAbsoluteRoot) {{{2
|
"FUNCTION: s:GetNodeForMark(name, searchFromAbsoluteRoot) {{{2
|
||||||
"get the treenode for the mark with the given name
|
"get the treenode for the mark with the given name
|
||||||
@@ -1428,8 +1428,6 @@ function! s:InitNerdTree(dir)
|
|||||||
unlet t:NERDTreeRoot
|
unlet t:NERDTreeRoot
|
||||||
endif
|
endif
|
||||||
|
|
||||||
call s:ClearAllMarks()
|
|
||||||
|
|
||||||
let t:NERDTreeRoot = s:oTreeDirNode.New(path)
|
let t:NERDTreeRoot = s:oTreeDirNode.New(path)
|
||||||
call t:NERDTreeRoot.Open()
|
call t:NERDTreeRoot.Open()
|
||||||
|
|
||||||
@@ -1810,12 +1808,12 @@ function! s:FindRootNodeLineNumber()
|
|||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
" FUNCTION: s:GetMarks(name) {{{2
|
" FUNCTION: s:GetMarks(name) {{{2
|
||||||
" getter/lazy initializer for the t:NERDTreeMarks hash
|
" getter/lazy initializer for the g:NERDTreeMarks hash
|
||||||
function! s:GetMarks()
|
function! s:GetMarks()
|
||||||
if !exists("t:NERDTreeMarks")
|
if !exists("g:NERDTreeMarks")
|
||||||
let t:NERDTreeMarks = {}
|
let g:NERDTreeMarks = {}
|
||||||
endif
|
endif
|
||||||
return t:NERDTreeMarks
|
return g:NERDTreeMarks
|
||||||
endfunction
|
endfunction
|
||||||
"FUNCTION: s:GetPath(ln) {{{2
|
"FUNCTION: s:GetPath(ln) {{{2
|
||||||
"Gets the full path to the node that is rendered on the given line number
|
"Gets the full path to the node that is rendered on the given line number
|
||||||
|
|||||||
Reference in New Issue
Block a user