Когда я нажимаю кнопку детализации моего tableView ... я могу получить номер секции, номер строки и даже саму ячейку ... но почему фактическая "кнопка детализации" недоступна? (NSLog всегда отображает «(ноль)» для кнопки.)
- (void) tableView:(UITableView *)tableView accessoryButtonTappedForRowWithIndexPath:(NSIndexPath *)indexPath
{
int section = indexPath.section;
int row = indexPath.row;
UITableViewCell *aCell = [tableView cellForRowAtIndexPath:indexPath];
UIButton *detailButton = (UIButton *)[aCell accessoryView];
// Why is detailButton null?
NSLog(@"accessory button tapped for row with index path %d x %d \n cell=(%@) \n button=(%@)", section, row, aCell, detailButton);
}