Scale down avatar images to save memory.

This gets the maximal display size of avatars from the style specification
and downsamples the loaded avatar images to be close to that size, with no
(to me) visible degradation of quality. Bonus: you actually see the rounded
corners of the images now.

Before this patch, each loaded avatar image occupied 850k of RAM, causing
the app to OOM after longer usage. With this patch, one image occupies
50k of RAM, preventing OOMs (device: Moto X).

Fixes #513
Might be a fix for #509
Add Gradle support
Add possibility to fork a repository, refs #106
Open the new repository after a fork.

This behaviour is consistent with the website and solves the issue of
forking an already forked repository.
Merge pull request #611 from jonanp/gradle-2

Add Gradle support
Merge pull request #612 from jonanp/fork

Add forking support
Revert "Add forking support"
Merge pull request #614 from github/revert-612-fork

Revert "Add forking support"
Update Travis CI configuration for Gradle

Revise build tools to 21.1.2

Add the equivalent Maven build command

Add gradle check command
Merge pull request #615 from fadils/master

Update Travis CI configuration for Gradle
Merge pull request #535 from Blei/less-memory-usage

Scale down avatar images to save memory.
Update README.md
Merge pull request #616 from fadils/master

Update README.md