Do we need to use 2 Storyboard for a Universal app?

前端 未结 6 1738
星月不相逢
星月不相逢 2021-02-06 12:01

I have a project for iPhone and iPad. The iPad needs a split view controller. Do we create two separate storyboards? One for iPhone (using autolayout we can support all devices)

6条回答
  •  梦毁少年i
    2021-02-06 12:52

    For iOS 7 and before, yes, use two storyboards and two completely different interfaces, since there is no split view controller on the iPhone.

    For iOS 8, use one storyboard, and use the UISplitViewController on both the iPad and the iPhone. Make a new project from the Universal version of the Xcode 6 Master-Detail app template to see all about how it works! It is automatically a split view controller on the iPad and a navigation interface on the iPhone.

提交回复
热议问题