Fix SIMULATE_WEB_RESPONSE not imported (#450)

* fix SIMULATE_WEB_RESPONSE not imported (Reported in #449).

* changes per review

* Update license of ViewController.m
This commit is contained in:
Max Wang
2017-08-14 08:31:52 -07:00
committed by Huy Nguyen
parent 6b3e2ba4e0
commit a929950d2c

View File

@@ -16,7 +16,7 @@
//
#import "ViewController.h"
#import "AppDelegate.h"
#import <AsyncDisplayKit/AsyncDisplayKit.h>
#import "SupplementaryNode.h"
#import "ItemNode.h"
@@ -82,18 +82,18 @@
{
NSLog(@"ViewController is not nil");
strongSelf->_data = [[NSArray alloc] init];
[strongSelf->_collectionView performBatchUpdates:^{
[strongSelf->_collectionView insertSections:[[NSIndexSet alloc] initWithIndexesInRange:NSMakeRange(0, 100)]];
[strongSelf->_collectionNode performBatchUpdates:^{
[strongSelf->_collectionNode insertSections:[[NSIndexSet alloc] initWithIndexesInRange:NSMakeRange(0, 100)]];
} completion:nil];
NSLog(@"ViewController finished updating collectionView");
NSLog(@"ViewController finished updating collectionNode");
}
else {
NSLog(@"ViewController is nil - won't update collectionView");
NSLog(@"ViewController is nil - won't update collectionNode");
}
};
dispatch_after(dispatch_time(DISPATCH_TIME_NOW, (int64_t)(2 * NSEC_PER_SEC)), dispatch_get_main_queue(), mockWebService);
dispatch_after(dispatch_time(DISPATCH_TIME_NOW, (int64_t)(2 * NSEC_PER_SEC)), dispatch_get_main_queue(), ^{
dispatch_after(dispatch_time(DISPATCH_TIME_NOW, (int64_t)(4 * NSEC_PER_SEC)), dispatch_get_main_queue(), ^{
[self.navigationController popViewControllerAnimated:YES];
});
#endif