Helpful Information
Home
Categories
Contact us
Category: iPhone SDK Development
Flip Animation
I am trying to use a "Flip" transition/animation. On both sides I want to have 2 separate UITables.
The following code that I am trying to do this with works fine, but it obviously "Flips" with the same view:
CGContextRef context = UIGraphicsGetCurrentContext();
[UIView beginAnimations:nil context:context];
[UIView setAnimationTransition: UIViewAnimationTransitionFlipFromLeft forView:self.view cache:YES];
[UIView setAnimationCurve:UIViewAnimationCurveEaseInOut];
[UIView setAnimationDuration:1.0];
[self.view exchangeSubviewAtIndex:0 withSubviewAtIndex:1];
[UIView commitAnimations];
I don't know where I would include the second UITable for the backside?
I have the following code now that is working.
The problem I am running into now though is that the UINavigationController is flipping too:
DetailViewControllerLatestElectionPolls *controller = [[DetailViewControllerLatestElectionPolls alloc] initWithNibName:@"DetailView" bundle:nil];
UINavigationController *navController = [[UINavigationController alloc] initWithRootViewController:controller];
[controller release];
navController.modalTransitionStyle = UIModalTransitionStyleFlipHorizontal;
[self presentModalViewController:navController animated:YES];
[navController release];
Id say the problem is:
[self presentModalViewController:navController animated:YES];
try removing that line.
privacy (GDPR)