Question

iOS 7, while pop a viewController, the left-to-right animation of View's contents disappear. but the title-change animation of NavigationBar still exists.

I use this code to pop:

[self.navigationController popViewControllerAnimated:YES];

some times this case will happen, sometimes not

I would like to know :

  1. is this only about iOS 7?
  2. what I do will absolutely trigger this animation problem happen.
  3. how to solve this.

appreciate your answers.

Was it helpful?

Solution

Question ended, This is the answer: Link of Answer

The Answer of Miha Hribar can solve my problem.

my solution detail:

the animation has problem, so finally, the reason is about UINavigationController, not it's viewControllers(at very first, I think the bug is caused by calling viewController's lifecycle method forcelly, like below:

[viewController viewWillAppear:YES]

so I solve this question by remove the following code:

// these codes are deleted
UINavigationController *nav = self.navigationController;
[nav viewWillAppear:YES];
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top