views:

34

answers:

1

I am building a book where I will use the page curl animation to flip the pages, something like this:

[UIView beginAnimations:nil context:NULL];
[UIView setAnimationDuration:0.45f];
[UIView setAnimationTransition:UIViewAnimationTransitionCurlUp forView:self.view cache:NO];
[UIView commitAnimations];

I will use curl down or up, according to the page being increased or decreased.

At some point the user can click on the chapter button and go a menu where he can choose the chapter. This menu is on a separate view, called using an animation like this

[UIView setAnimationTransition:UIViewAnimationTransitionFlipFromRight forView:self.view cache:NO];

After the user chooses a chapter, I close the chapters choosing view using

[UIView setAnimationTransition:UIViewAnimationTransitionFlipFromLeft forView:self.view cache:NO];

and after this transition finishes, I call a method that will show the first page of the chosen chapter. This page will be shown using a page curl animation.

This is almost working fine, but this is the problem.

If I press the "choose a chapter" button again, instead of seeing a flip from right animation and see the "choose a chapter menu" I will see a page curl, that will review the same page I am already seeing and then, suddenly, the "choose a chapter menu" will appear, with no transition.

Is this something related to the animation being cached? Even if I declared the cache property as NO? How do I solve that?

thanks

+1  A: 

Set some breakpoints. It sounds more like the "page curl" animation is being called spuriously.

tc.
thankssssssssssss!!!!!!!!!!!!
Digital Robot