Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>I was having the same issue and I believe this to be an Apple bug (I filed it a month ago with no response from them.) For me, it was specifically the "detail" view that was blank when the app started at orientation UIInterfaceOrientationLandscapeRight (3). It would look like this: <a href="http://d.pr/cGcU" rel="nofollow">http://d.pr/cGcU</a>. This would occur when I restricted one of the two view controllers (say, the RootViewController) to landscape-only:</p> <pre><code>- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation { return UIInterfaceOrientationIsLandscape(interfaceOrientation); } </code></pre> <p>With this in place, the following would occur during the detail view's initialization:</p> <pre><code>2010-11-15 20:17:47.792 MultipleDetailViews[96250:207] firstDetailViewController willAnimateRotationToInterfaceOrientation: 3 (landscape) 2010-11-15 20:17:47.792 MultipleDetailViews[96250:207] self.view.hidden is: 0 2010-11-15 20:17:47.799 MultipleDetailViews[96250:207] rotating... 2010-11-15 20:17:47.848 MultipleDetailViews[96250:207] firstDetailViewController didRotateFromInterfaceOrientation 2010-11-15 20:17:47.849 MultipleDetailViews[96250:207] self.view.hidden is: 1 </code></pre> <p>For some reason the detail view would mysteriously become hidden during rotation to orientation 3. Until Apple fixes this bug (it doesn't occur in 3.2), my workaround is currently to override the following method in the detail view controller, re-displaying the view after rotation has completed:</p> <pre><code>- (void)didRotateFromInterfaceOrientation:(UIInterfaceOrientation)fromInterfaceOrientation { self.view.hidden = NO; } </code></pre> <p><strong>EDIT</strong>: If your detail view isn't a direct subview of <code>splitViewController.view</code> (e.g. you are using a <code>UINavigationController</code>), you will need to set <code>hidden</code> on the topmost view on the detail side within the <code>UISplitViewController</code>:</p> <pre><code>- (void)didRotateFromInterfaceOrientation:(UIInterfaceOrientation)fromInterfaceOrientation { // Make sure you set splitViewController via an outlet or get it via your AppDelegate for (UIView *splitViewChild in splitViewController.view.subviews) splitViewChild.hidden = NO; } </code></pre>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload