(UITableViewCell *) tableView: (UITableView *) tableView cellForRowAtIndexPath: (NSIndexPath *) indexPath {identifiant sélection de bouton de chaque ligne dans TableView?
UIButton *btn = [UIButton buttonWithType:UIButtonTypeRoundedRect]; btn.frame = CGRectMake(230.0f, 4.0f, 60.0f, 36.0f); [btn setTitle:@"OK" forState:UIControlStateNormal]; [btn setTitle:@"OK" forState:UIControlStateSelected]; [btn addTarget:self action:@selector(onClickRename:) forControlEvents:UIControlEventTouchUpInside]; [cell addSubview:btn]; return cell;
}
mais si l'utilisateur sélectionne le bouton de ligne particulière, Je peux changer cette image par onClickRename ... mais puis-je obtenir dans quelle image de la ligne a été touchée
- (vide) tableView: (UITableView ) tableView didSelectRowAtIndexPath: (NSIndexPath) indexPath?