我添加了这些代码以将内容滚动到滚动视图中,但我的滚动视图框架不是内容而是从右向左移动,并且分别从右向左移动。我的代码在这里..
-(IBAction)leftbtnclick:(id)sender
{
NSLog(@"left clicked");
CGRect basketTopFrame = nameContainerScrollView.frame;
basketTopFrame.origin.x = 115;
[UIView animateWithDuration:0.3 delay:0.0 options:UIViewAnimationOptionCurveEaseIn animations:^{ nameContainerScrollView.frame = basketTopFrame; } completion:^(BOOL finished){ }];
}
-(IBAction)rightbtnclick:(id)sender
{
NSLog(@"right clicked");
CGRect napkinBottomFrame = nameContainerScrollView.frame;
napkinBottomFrame.origin.x = 0;
[UIView animateWithDuration:0.3 delay:0.0 options: UIViewAnimationOptionCurveEaseOut animations:^{ nameContainerScrollView.frame = napkinBottomFrame; } completion:^(BOOL finished){/*done*/}];
}