Fix Pager Node Issues (#3028)

* Fix pager node and deprecate zeroContentInsets flag

* Do it with the visible state callback

* There we are

* Put viewController in node debug description
This commit is contained in:
Adlai Holler
2017-02-14 14:10:51 -08:00
committed by GitHub
parent aecd36a4df
commit fab98b32ef
14 changed files with 271 additions and 67 deletions

View File

@@ -21,9 +21,9 @@
@implementation PageNode
- (ASLayout *)calculateLayoutThatFits:(ASSizeRange)constrainedSize
- (CGSize)calculateSizeThatFits:(CGSize)constrainedSize
{
return [ASLayout layoutWithLayoutElement:self size:constrainedSize.max];
return constrainedSize;
}
- (void)fetchData

View File

@@ -46,7 +46,7 @@ static UIColor *randomColor() {
self.navigationItem.rightBarButtonItem = [[UIBarButtonItem alloc] initWithTitle:@"Next" style:UIBarButtonItemStylePlain target:self action:@selector(scrollToNextPage:)];
self.navigationItem.leftBarButtonItem = [[UIBarButtonItem alloc] initWithTitle:@"Previous" style:UIBarButtonItemStylePlain target:self action:@selector(scrollToPreviousPage:)];
self.automaticallyAdjustsScrollViewInsets = NO;
return self;
}