[stagingView] Store IFile/IContainer for entries
Instead of calculating the resource on each access, calculate them once
and store them in a field. With 4000 unstaged changes in a test
repository, this brought down the time to expand all elements from 3
seconds to 500-800 ms.
Maybe getting the resources could be made faster by not using
findFilesForLocationURI/findContainersForLocationURI, but instead going
through the projects of the repository and using getFile/getFolder and
only falling back to the above in case nothing is found.
Bug: 420825
Change-Id: I86f0e09fad54d63e7e76ae3541178ae80c867144
Signed-off-by: Robin Stocker <robin@nibor.org>
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>