steipete/PSTCollectionView — pull request #179 by tyrone-sudeium (2013-01-23 10:49:34+00:00)
Title: Behaviour when layoutAttributesForElementsInRect is nil

I'm not 100% exactly what the behaviour is with UICollectionView here, but it's much more lazy than what PSTCollectionView does. I'm sure this small hack isn't the way UICollectionView does it, but it certainly gets the behaviour a lot closer.

Without this hack, if your custom layout returns nil for a given rect, the collection view will go ahead and remove *every* cell immediately; UICollectionView by comparison, just doesn't update anything. This is an attempt to replicate that behaviour by cutting it off early.

Sorry about the pull request spam.