Skip to content

Instantly share code, notes, and snippets.

@nalitzis
Created October 13, 2012 16:21
Show Gist options
  • Save nalitzis/3885208 to your computer and use it in GitHub Desktop.
Save nalitzis/3885208 to your computer and use it in GitHub Desktop.
-(NSArray *)findAfterViewsAfter:(ContentView *)contentView{
int viewIndex = contentView.tag;
NSMutableArray *afterViews = [NSMutableArray array];
BOOL isBefore = YES;
for(int i=0; i < _views.count; i++){
ContentView *currentView = [_views objectAtIndex:i];
if(currentView.tag == viewIndex){
isBefore = NO;
continue;
}
if(!isBefore)
[afterViews addObject:currentView];
}
return afterViews;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment