-
Notifications
You must be signed in to change notification settings - Fork 16
Open
Description
I've an issue when using the sticky header feature in combination with cell deletion. The section header doesn't stick. See this screen video:
To reproduce the issue, just add this method to StickyHeadersCollectionViewController.m:
- (void)collectionView:(UICollectionView *)collectionView didSelectItemAtIndexPath:(NSIndexPath *)indexPath {
[collectionView performBatchUpdates:^{
TLIndexPathSectionInfo *section = [self.indexPathController.dataModel sectionInfoForSection:indexPath.section];
NSMutableArray *filtered = [section.objects mutableCopy];
[filtered removeObjectAtIndex:indexPath.row];
section = [[TLIndexPathSectionInfo alloc] initWithItems:filtered name:section.name];
NSMutableArray *sectionInfos = [self.indexPathController.dataModel.sections mutableCopy];
sectionInfos[indexPath.section] = section;
self.indexPathController.dataModel = [[TLIndexPathDataModel alloc] initWithSectionInfos:sectionInfos identifierKeyPath:nil];
} completion:nil];
}
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels