Dismissing Popover After Selecting Row


#1

This isn’t in the book, but in case anyone was interested in getting rid of the popover after selecting a row, this post was helpful in getting it implemented:

http://stackoverflow.com/questions/5721583/uisplitviewcontroller-in-portrait-how-to-hide-master-popover-programatically#=

I created and set the UIPopoverController variable in WebViewController (see link), and then put the dismiss call at the end of ListViewController’s didSelectRowAtIndexPath: method.

if ([self splitViewController]) [[webViewController popverController] dismissPopoverAnimated:YES];