I have the custom UITableViewCell and this code to create the accessory
UIImage *indicatorImage = [UIImage imageNamed:@"Map.png"];
UIButton *button = [[UIButton alloc] init];
[button setImage:indicatorImage forState:UIControlStateNormal];
[button setFrame:CGRectMake(0, 0, 64, 64)];
cell.accessoryView = button;
and i have this two methods:
- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath
{
//[self performSegueWithIdentifier:@"goToDetail" sender:self];
NSLog(@"row");
}
-(void)tableView:(UITableView *)tableView accessoryButtonTappedForRowWithIndexPath:(NSIndexPath *)indexPath{
//[self performSegueWithIdentifier:@"goToMap" sender:self];
NSLog(@"accessory");
}
I would like to capture two different events: 1 for the row and one for the accessory, with the two methods that I put above I can only get the event for the row. How do I get the accessory?
help please