Adding App Section Navigation

The CarValet app has three main sections: Cars, Images, and About. The iPhone uses a tab view for navigation between sections. You could use the same controller on an iPad, but it would not look very good. Tabs are designed for a small screen space. On iPad, each tab would be extremely wide, giving the screen a strange look.

This is one of the reasons the split view controller was created. It allows the same kind of section navigation but fits better in the larger screen. You already have a table view for navigation; the next step is adding the cells for each section.

The top-level menu stays the same, so you don’t need to dynamically generate the cells. Instead, you can use a feature of UITableViewController for ...

Get Learning iOS Development: A Hands-on Guide to the Fundamentals of iOS Programming now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.