Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,14 @@ - (NSArray *)layoutAttributesForElementsInRect:(CGRect)rect {
}

- (UICollectionViewLayoutAttributes *)layoutAttributesForItemAtIndexPath:(NSIndexPath *)indexPath {
UICollectionViewLayoutAttributes* currentItemAttributes = [[super layoutAttributesForItemAtIndexPath:indexPath] copy];
UICollectionViewLayoutAttributes* currentItemAttributes;

if (@available(iOS 10, *)) {
currentItemAttributes = [[super layoutAttributesForItemAtIndexPath:indexPath] copy];
} else {
currentItemAttributes = [super layoutAttributesForItemAtIndexPath:indexPath];
}

UIEdgeInsets sectionInset = [self evaluatedSectionInsetForItemAtIndex:indexPath.section];

BOOL isFirstItemInSection = indexPath.item == 0;
Expand Down