Skip to content

Instantly share code, notes, and snippets.

@srahim
Created January 17, 2012 01:08
Show Gist options
  • Save srahim/1623941 to your computer and use it in GitHub Desktop.
Save srahim/1623941 to your computer and use it in GitHub Desktop.
setContentoffset
-(void)setContentOffset_:(id)value withObject:(id)animated_
{
CGPoint newOffset = [TiUtils pointValue:value];
BOOL animated;
if ([animated_ objectForKey:@"animated"] != nil ) {
animated = [TiUtils boolValue:[animated_ objectForKey:@"animated"]];
}
else{
animated = scrollView != nil;
}
[[self scrollView] setContentOffset:newOffset animated:animated];
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment