tags:

views:

415

answers:

5

Hello all,

I have a UITabBarController in my application. In the first view of this controller I have a UINavigatioController and user can navigate to multiple views through this NavigationController. In the rootview of this controller I have my frontview or main view of the application which have an info icon, which flips the screen to info page which is an another view in my appDelegate. So I use the following code from my appdelegate to switch to info page.

UIView * controllersView = [aboutUsViewController view];
[UIView beginAnimations:nil context:NULL];
[UIView setAnimationDuration:1];
[UIView setAnimationCurve:UIViewAnimationCurveEaseInOut];
[UIView setAnimationTransition:UIViewAnimationTransitionFlipFromRight forView:window cache:YES];
[self.window addSubview:controllersView];
//[aboutUsViewController animateView];
[self.tabBarController.view removeFromSuperview];
[UIView commitAnimations];

My problem is when I flip, I see a very small white bar at the top. This white bar is seen only while fliping from main view that is first screen to info page and not viceversa.

I am confused how to remove this bar since I have a UIImage covering my whole page on the mainview.

How to solve this.

A: 

I had the same problem. I think this is a bug in the 3.1 OS. File a bug with Apple. My current workaround was to use the standard slide up modal transition. Not the best solution, but at least it doesn't look weird.

casademora
http://bugreport.apple.com/
slf
A: 

Have you tried setting wantsFullScreenLayout on your view controller?

Frank Schmitt
+1  A: 

If the bar is only visible during a transition, then change the color of your main window to be the same as the view you are transitioning. Or you can make it totally translucent, which may do the same.

mahboudz
Well even if I change the color of main window, the background will change means the background while transiting. I am talking about the bar at the screen which is transition whereas window stays at the same place.
rkb
What are the dimensions of your two views? And you have a tabBar on the first views, and none on the info view, right? Do you have a status bar in either or both views?
mahboudz
A: 

I'm not sure if you are displaying the status bar or not, but you may want to check if your UIImage size completely goes to the top of your view - especially if you've added it in IB. Also, try setting the cache setting in your transition to NO to see if that makes a difference. It uses more resources, but I've had to do that to stop text fields from blanking out during a transition.

Mike W
Yes UIImage covers till top.
rkb
A: 

You probably shouldn't be doing all those animations yourself. I'm not exactly sure what your goal is, but it might be easier to use something called "pushModalViewController" and have a controller for your info page, along with a view. This may fix the problem, because it may just be something to do with animations.

Then, when you exit your info page, control returns to your navigation controller (which is what I think you want). I hope this helps.

gburgoon