I have pagination scrolling. Each page has a viewcontroller (buttonViewController) that controls the button grid. If you click one of the buttons, buttonViewController will add another view controller (detailViewController).
The problem is that when I reject the modal view controller, the visible buttonView control moves down about 20 pixels. It is strange that only the visible page is shifted. If I go to another loaded page, it is still in the correct position.
My question is basically the same as rejecting the modalViewController moves the main view buttons around the iphone
However, the accepted answer to this question suggests that the status bar is hidden. I do not hide the status bar in my application.
Any other ideas?
One more note: the shift only occurs when the modal controller is first started. If I continue to open and close the modal view controller, everything remains the same.
One more note: if I add the following code:
CGRect frame = self.view.frame; frame.origin.y=0; self.view.frame = frame;
after I reject the modal view controller, I can work around the problem. It seems the frame moves 20 pixels in y. I still don't know what causes the movement.
It turns out this was due to: ModalViewController not showing during animation when scrolling scroll scroll
view, .
460 , - 480 . - 20 evertime, . 460 , .
, , , viewController ( UIWindow), , , , , , subview (0,0) , , , , . , , , , . , , , , UIWindows , , , . , CGRectMake (0,0,320,460) , . , , . , .