paulkinzett/toolbar — pull request #12 by mandx (2013-02-17 01:28:30+00:00)
Title: Better handling of the `hideOnClick` option

If having multiple toolbars on the same page, all with the option
`hideOnClick` enabled, opening a second toolbar doesn't hide the
first opened toolbar. And when clicking everywhere else, only the
last toolbar is hidden.

This commit fixes both issues by registering once to the $('html')
'click' event, and better checking of when to hide the toolbar.