Rewrite the toggle logic with bug fixed
Rewrite the toggle logic with bug fixed

There is a bug in the previous version. After the location buffer closed
by hit <Enter> on the selected item in its list, the open/close key mapping
will not work anymore. The same thing happens on quickfix buffer.
This version use a different way to implement the toggle logic while the
bug was fixed.

jkglasbrenner/dotfiles,jkglasbrenner/dotfiles,jkglasbrenner/dotfiles,jkglasbrenner/dotfiles,jkglasbrenner/dotfiles,jkglasbrenner/dotfiles