views:

79

answers:

2

I have a uitableview within a navigation controller shown within a popover. When you press a bar button from within the popover (on a detail view), it shows a modal view. If you rotate the iPad with the popover visible and the modal view on top of that, the popover's content changes to a seemingly random orientation as shown below.

Any idea what's going on here?

alt text

UPDATE: I'm trying to implement a solution, maybe there's a better way. When the modal view is dismissed, I send an NSNotification from - (void)mailComposeController:(MFMailComposeViewController *)controller didFinishWithResult:(MFMailComposeResult)result error:(NSError *)error to the popover's owner. When I press cancel, the button is visibly pressed but nothing happens after that and the screen becomes unresponsive. However, rotation still occurs properly.

It would seem that I'm dismissing the popover before the modal view is dismissed. I don't really know any other way of doing this, you're continued help is appreciated.

A: 

Have you tried to dismiss the popover and then redisplay it? The UIPopoverController documentation is straightforward in saying that it will often fail to rotate a popover, and suggests redisplaying it as the only solution. I suspect that since your modal view is on top of the view from which the popover was displayed, the popover's controller is not updating its position & orientation.

Tim Isganitis
Redisplaying makes no change. I cannot for the life of my determine why. Maybe this has something to do with it: I am creating and showing the modal view from a view which has been pushed from another view inside a nav controler inside a uipopover.
DysonApps
+2  A: 

I had to completely reload the popover and its view controllers. This is the only way I could mask the problem, not solve it, because this seems to be a bug in iOS 3.2.

DysonApps