protected virtual void CacheCellAttributes(NSIndexPath indexPath, CGSize size) { if (!ItemsSource.IsIndexPathValid(indexPath)) { // The upate might be coming from a cell that's being removed; don't cache it. return; } var item = ItemsSource[indexPath]; if (item != null) { ItemsViewLayout.CacheCellSize(item, size); } }