Search code examples
ipadiosuisplitviewcontrollermodalviewcontroller

How to use a UISplitViewController as a Modal View Controller?


I am trying to display a UISplitViewController presenting it as a Modal View Controller in my iPad app. I manage to have it display, but for some reason there is a gap to the left of the modal view the size of a Status Bar which is also preserved when the orientation is changed.

alt text

Does anybody know why this is happening? Or if this is even possible? Maybe I'm just digging myself a huge hole.


Solution

  • The stock UISplitViewController was designed for use as the root view controller only. Presenting one modally goes against the Apple Human Interface Guidelines and has a high probability of getting rejected by the App Review Team. In addition, you may receive the error:

    Application tried to present Split View Controllers modally