I use TTTableSubtitleItem to crete the cells for a table. I then use didSelectObject to sent an object to the detail view controller. To prevent the message being sent twice I have to set the TTTableSubtitleItem URL to nil. Because of this the Disclosure Button will not display?
[TTTableSubtitleItem itemWithText:[chunks objectAtIndex: 0]
subtitle:@"Link To Website"
imageURL:@""
defaultImage:[UIImage imageNamed:@"map.png"]
URL:nil
accessoryURL:@"http://www.google.com"];
I had this same issue and the way I got around it was by subclassing the item cell (so for you it’d be
TTTableSubtitleItemCelland overriding thesetObjectmethod to manually include the disclosure button as follow:I also used this method to allow myself to have the selection style still be blue even though I wasn’t handling the URL in the expected way. This would happen by also just adding
right after the other call.
Note you’ll also need to add the mapping between the items you care about and this new custom item cell in your data source. This requires overriding one method in a custom data source. If you want all of your
TTTableSubtitleItems to have the disclosure button, you can mapTTTableSubtitleItemto your new custom item cell. Otherwise just create a custom subclass ofTTTableSubtitleItemas well that doesn’t make any changes to it. Assuming your two new subclasses areCustomItemandCustomItemCellyour data source would override the following method to look like so:Hope this helps