Use CollectionView's layerId rather than guid in contentIndexForLayerId.

Previously, use of guid meant CollectionView's could not have a custom
layerId set.