Skip to Content
Beginning iOS 5 Application Development
book

Beginning iOS 5 Application Development

by Wei-Meng Lee
January 2012
Beginner content levelBeginner
655 pages
16h 35m
English
Wrox
Content preview from Beginning iOS 5 Application Development

CHAPTER 8 EXERCISE SOLUTIONS

Answer to Question 1

The two protocols are UITableViewDataSource and UITableViewDelegate.

The UITableViewDataSource protocol contains events that you can implement to populate the Table view with the various items.

The UITableViewDelegate protocol contains events that you can implement to handle the selection of rows in a Table view.

Answer to Question 2

To add an index list to your Table view, you need to implement the sectionIndexTitlesForTableView: method.

Answer to Question 3

The three disclosure and checkmark accessories are as follows:

  • UITableViewCellAccessoryDetailDisclosureButton
  • UITableViewCellAccessoryCheckmark
  • UITableViewCellAccessoryDisclosureIndicator

The UITableViewCellAccessoryDetailDisclosureButton image handles a user's tap event. The event name is tableView:accessoryButtonTappedForRowWithIndexPath:.

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Mastering iOS 12 Programming - Third Edition

Mastering iOS 12 Programming - Third Edition

Donny Wals
What Successful Project Managers Do

What Successful Project Managers Do

W. Scott Cameron, Jeffrey S. Russell, Edward J. Hoffman, Alexander Laufer

Publisher Resources

ISBN: 9781118144251Purchase book