* Pre-compute name, formatted sizes and speeds.
* Handle name edge-cases such as no-path and no-uris better.
* Unroll getCtx.
* Improve performance of mergeMap.
* Delay the search filter.
As indicated by Chrome/Gecko profilers.
This will improve the performance a lot. First load performance may
suffer a bit, though.
Also, the leading "./" is skipped now, as this causes additional string
ops, which turn out to be particularly harmful in some cases (slots vs
heaps aka. shortstrings in spidermonkey, allocation overhead). And the
leading "./" is not really required anymore.
Angular uses dirty-checking for data-bindings. This is OK for POD types,
but when it comes to objects, incl. arrays, just stuffing in the new
array without checking for changed content will make angular think
something has changed and update the DOM when there really was no change
at all. So do not blindly copy over objects and arrays anymore.
Also, since webui-aria2 does not use all `bittorrent` and `file` fields,
there is no point in keeping all fields around, causing unnecessary
angular invalidations.
With this commit, the update code runs in about 1/10th of the time it
did before on my system (Chrome/Firefox) when using displaying many
torrent downloads with many files.