Fixes #4702: Only include selected repositories in UI when filtering for...

... content view.
This method and `ContentViewAvailableRepositories.addRepositories()` are quite similar, can we factor out the common parts?