Actually support the url_name parameter in NavigationBarHook.

The docstring for this hook claimed that you could initialize it with a URL
name, and have it do the reverse lookup. This was a lie. I've implemented this
functionality.

Testing done:
- Used this in an extension I've been working on.
- Ran unit tests.

Reviewed at http://reviews.reviewboard.org/r/4186/
Merge branch 'release-1.7.x'