update quickhelp for custom mappings

dont display quickhelp for a mapping if there is no text to display -
this prevents all the default mappings from being displayed under the
"custom mappings" section.
This commit is contained in:
Martin Grenfell
2012-01-03 16:08:10 +00:00
parent 73e2d8ca7e
commit 0c12f6fe10

View File

@@ -3091,13 +3091,13 @@ function! s:dumpHelp()
let @h=@h."\" ". g:NERDTreeMapToggleBookmarks .": bookmarks (" . (b:NERDTreeShowBookmarks ? "on" : "off") . ")\n"
"add quickhelp entries for each custom key map
if len(s:KeyMap.All())
let @h=@h."\"\n\" ----------------------------\n"
let @h=@h."\" Custom mappings~\n"
for i in s:KeyMap.All()
if !empty(i.quickhelpText)
let @h=@h."\" ". i.key .": ". i.quickhelpText ."\n"
endfor
endif
endfor
let @h=@h."\"\n\" ----------------------------\n"
let @h=@h."\" Other mappings~\n"