0

enter image description here

as picture : when the white controller in popping out with a interactive pop gesture , the red controller (which make the status bar hide) will show, and during the animation : the navigation bar seems to move up , and the controller's view is still in its position (not move up with navigation bar) ,so the view seems divided into two pieces in the pop out animation . how to fix it ?

ximmyxiao
  • 2,622
  • 3
  • 20
  • 35

1 Answers1

0

In the first controller,add this code.

- (void)viewWillAppear:(BOOL)animated {
    [super viewWillAppear:animated];

    [self.navigationController setNavigationBarHidden:YES animated:YES];
}

- (void)viewWillDisappear:(BOOL)animated {
    [super viewWillDisappear:animated];

    [self.navigationController setNavigationBarHidden:NO animated:YES];
}
Henson Fang
  • 1,177
  • 7
  • 30
  • If that didn't help,comment here to let me know. – Henson Fang Mar 31 '17 at 10:06
  • ,thanks ,i 've already set the bar hide like you said as you can see the bar is hidden ,the weird thing is the status bar hide cause the the problem, and the problem seems it's somewhere in my project . i use the same code in a demo , everything works fine . and i dont know how to find the exactly place where cause the problem LOL~ – ximmyxiao Apr 06 '17 at 06:31
  • so how do you hide your status bar – Henson Fang Apr 06 '17 at 07:38
  • prefersStatusBarHidden – ximmyxiao Apr 06 '17 at 08:21