Fix example code for the NERDTreeAddKeyMap function. (#1116)

* Fix example code for the NERDTreeAddKeyMap function.

The quickhelpText didn't match what the statement in the callback
function actually did.

* Update version number in change log.
This commit is contained in:
Phil Runninger
2020-05-03 01:21:34 -04:00
committed by GitHub
parent 29a321d061
commit 5e77fb2fef
2 changed files with 4 additions and 3 deletions

View File

@@ -1353,12 +1353,12 @@ NERDTreeAddKeyMap({options}) *NERDTreeAddKeyMap()*
Example: >
call NERDTreeAddKeyMap({
\ 'key': 'foo',
\ 'callback': 'NERDTreeCDHandler',
\ 'callback': 'NERDTreeEchoPathHandler',
\ 'quickhelpText': 'echo full path of current node',
\ 'scope': 'DirNode' })
function! NERDTreeCDHandler(dirnode)
call a:dirnode.changeToDir()
function! NERDTreeEchoPathHandler(dirnode)
echo a:dirnode.path.str()
endfunction
<
This code should sit in a file like ~/.vim/nerdtree_plugin/mymapping.vim.