March 2014
Intermediate to advanced
672 pages
40h 11m
English
The table displays remove controls with a single call: [self.tableView setEditing:YES animated:YES]. This updates the table’s editing property and presents the round remove controls shown in Figure 9-5 on each cell. The animation is optional but recommended. As a rule, use animations in your iOS interfaces to lead your users from one state to the next so that they’re prepared for the mode changes that happen onscreen.
Recipe 9-3 uses a system-supplied Edit/Done button (self.editButtonItem) and implements setEditing:animated: to move the table into and out of an editing state. When a user taps the Edit or Done button (it toggles back and forth), this method updates the edit state and the navigation bar’s buttons.
Read now
Unlock full access