I have several UITableViews with ready delegate and dataSource methods. How to add the same second action/handler for these tables using subclassing but without of editing their didSelectRowAtIndexPath methods manually?
If I use UIButtons instead of tables then the solution is:
inside the child class of UIButton:
- (void)defaultInit {
[self addTarget:[PCFlurryManager manager] action:@selector(...) forControlEvents:UIControlEventTouchUpInside];
}
- (void)dealloc {
[self removeTarget:[PCFlurryManager manager] action:@selector(...) forControlEvents:UIControlEventTouchUpInside];
[super dealloc];
}
So I can use addTarget for the same event as much times as I want. But how to realize the similar for a table?