Replace UITableView Delete Button with Segmented Button
I have an UITableView in my application that lets the user quit apps on a remote computer. I would like to let the user to choose from Force Quit or 开发者_开发知识库regular Quit, using the regular 'delete' button. Here's a quick mock-up of what I mean:
First of all, is this even possible? Secondly, how would I go about implementing this? I'm guessing something like an UISegmentedControl with the same red tint. I'd love to know that tint too ;)
The first thing I thought is the following: Set the "editing" property of every row to NO, then add an UISwipeGestureRecognizer to the cell and attach to it a selector that spawns your segmented control in the cell. I suggest to create a subclass of the UITableViewCell and override the initWithFrame method.
精彩评论