点击索引不起作用

时间:2013-10-18 13:29:32

标签: objective-c ios7 uitableview

我使用segue进行推送单元格和详细信息披露按钮。 我无法点击索引,因为详细信息披露按钮"截取"触摸而不是。

enter image description here

代码:

- (void)prepareForSegue:(UIStoryboardSegue *)segue
                 sender:(id)sender {
    NSIndexPath *indexPath = [self.tableView indexPathForCell:sender];
    if ([segue.identifier isEqualToString:@"Dossier Segue"]) {
        Person *person = [[self fetchedResultsController] objectAtIndexPath:indexPath];
        DSRevealViewController *vc = (DSRevealViewController *)segue.destinationViewController;
        vc.person = person;
        vc.transitioningDelegate = self;
    }
    else if ([segue.identifier isEqualToString:@"Info"]) {
        Person *person = [[self fetchedResultsController] objectAtIndexPath:indexPath];
        NSAssert(person, @"Person is nil");
        PersonInfoViewController *vc = (PersonInfoViewController *)segue.destinationViewController;
        vc.person = person;
    }
}

P.S。我检查了我的其他应用程序,我使用表视图委托方法而不是segues,它运行良好。

0 个答案:

没有答案