I have an NSMutableArray of notifications, each time the view controller is opened, then NSMutableArray gets updated, how do I work out how many new items (notifications) have been added to the NSMutableArray?
NSMutableArray *arrItems;
[SharedDelegate.hnController loadDataOfType:GTUserNotifications cateId:self.strUserId curPage:curPage result:^(NSArray *results, GTControllerType type, BOOL success) {
if (!success)
{
[UIView animateWithDuration:0.5
delay:0.0
options:UIViewAnimationOptionLayoutSubviews | UIViewAnimationOptionAllowUserInteraction
animations:^{
[self.vNoNetWork setFrame:CGRectMake(0, 430, 320, 25)];
// animate here...
}
completion:^(BOOL finished){
}];
//[loading stopAnimating];
[refreshControl endRefreshing];
return;
}
[self.activityIndicatorView setHidden:YES];
[[self footerActivityIndicator] stopAnimating];
[arrItems addObjectsFromArray:results];
NSLog(@"ArrayItems: %@", arrItems);
[self.tblView reloadData];
}];
Thanks in advance
Aucun commentaire:
Enregistrer un commentaire