Presents the specified view controller as the primary view controller in the split view interface.
- iOS 8.0+
- tvOS 9.0+
The view controller to display in the primary (or master) location of the split view interface.
The object that made the request to show the view controller.
Whenever possible, use this method (instead of modifying the contents of the
viewproperty directly) to replace the primary view controller of your split view interface. This method displays the specified view controller in the best way possible given the current size class in effect.
Typically, you call this method from an action method when you want to replace the primary view controller with the one specified in
vc. This method calls the split view controller delegate’s
split method to give the delegate an opportunity to show the view controller. If the delegate does not show the view controller, the split view controller shows it using the following heuristics:
In a horizontally regular environment, the split view controller installs
vcas the primary view controller unless
vcis already a child of the primary view controller, in which case it installs
vcas the secondary view controller.
In a horizontally compact environment, the split view controller presents