Update location from application states

With this PR the URL in the address bar is updated as the application states change. It works in modern browsers, as well as in IE 9. In IE 9, Angular redirects to a "hashbang" URL. In modern browsers, Angular redirects to a regular URL.

Note that for this to work, the page should include an appropriate `<base>` tag. This is explained in http://docs.angularjs.org/guide/dev_guide.services.$location.

Please review.