I have multiple UIViewController
that have table views. I want these VCs to just handle UI stuff as they will all search the same database. I want to subclass UISearchDisplayController
so I can have this subclass handle all the data and search stuff.
The VC I am working with is a UIViewController
with a UITableView
and a UISearchDisplayController
. I have it set and can check to display the initial, or the searched data into the table view by using if/else statements like: if (tableView == self.searchDisplayController.searchResultsTableView) % else...
I want this custom subclass that I'm creating to handle the code that is executed in the self.searchDisplayController.searchResultsTableView
statement so I can have some abstraction and can use this custom class with other VCs.
Any ideas on how to continue with this? I think I need to override some methods in the UISearchDisplayController
.
EDIT:
Actually I may be coming into this wrong. I have it stepup the way I like right now, but there is no abstraction, so I can't really reuse this code in other parts of the app. My IB is setup like this:
Comments
Post a Comment