Provide a context object

A context object can either be a high-level project, language or
translation project or a directory or a store if the current view is
drilling down in the file/dir browser.
Reuse existing code
Fixed search form action URL

This didn't generate proper URLs when the user was in a context of the
file/dir browser.
Simplified code, handle the situation with no args
Added support for all sorts of directories
Added convenience `get_translate_url` methods
Use `get_path_obj`
Added manager method to retrieve units below a given path

Works for any `pootle_path` and does permission checking for the user
attached to the given `profile`.
Use `get_for_path` to support arbitrary paths
No need to retrieve a `path_obj` that won't be used
Differentiate between `Directory` and other objects

Also removed the IndexError check since the decorator is meant to be used
along with `get_path_obj`.
Reordered import
Improved readability
Implemented global search

This commit adds the pieces for having translation editors at the root of
the server, at projects across languages, and at languages across
projects.

Fixes bug 2719
Cleanup: removed cruft
Group by `pootle_path` for uniqueness

Units from different stores could be grouped together otherwise.
Display file delimiter rows in the editor

Fixes bug 2946.
Take into account current resource's path

Fixes #6
Fix href’s in project and language tabs

The URLs were relative to the current tab, so in Translate tab, for
example, you end with wrong URLs like:

  projects/terminology/translate/notices
  projects/terminology/translate/admin.html
Fix translate-table margins in Chrome

-1.5em is way too much, apparently Firefox contains the table to its
parent element(s) so only a -0.4em was effective, but not in Chrome
resulting in the boy encroaching upon the tabs.

Why this wasn’t happening before, I don’t know.