Several small optimizations, especially to _ASPendingState and other hot paths.

This commit is contained in:
Scott Goodson
2015-12-23 16:38:33 -08:00
parent dd6ddfc0a2
commit 928c440b4c
7 changed files with 48 additions and 28 deletions

View File

@@ -20,13 +20,14 @@
- (instancetype)init
{
_flowLayout = [[UICollectionViewFlowLayout alloc] init];
_flowLayout.scrollDirection = UICollectionViewScrollDirectionHorizontal;
_flowLayout.minimumInteritemSpacing = 0;
_flowLayout.minimumLineSpacing = 0;
UICollectionViewFlowLayout *flowLayout = [[UICollectionViewFlowLayout alloc] init];
flowLayout.scrollDirection = UICollectionViewScrollDirectionHorizontal;
flowLayout.minimumInteritemSpacing = 0;
flowLayout.minimumLineSpacing = 0;
self = [super initWithCollectionViewLayout:_flowLayout];
self = [super initWithCollectionViewLayout:flowLayout];
if (self != nil) {
_flowLayout = flowLayout;
}
return self;
}