次のデリゲートにリンクされたA->B->Cコントローラーがあります:
@protocol ViewControllerDelegate <NSObject>
- (void)onResult:(ControllerDelegateObject *)delegateObject;
@end
およびCI呼び出し:
- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath{
ControllerDelegateObject *object = [[ControllerDelegateObject alloc]init];
object.model = indexPath.row;
[delegate onResult:object];
[ self.navigationController popViewControllerAnimated:YES ];
}
私がBに入るより:
-(void)onResult:(ControllerDelegateObject *)delegateObject{
delegateObject.brand = self.chosenBrand;
[delegate onResult:delegateObject];
[ self.navigationController popViewControllerAnimated:YES ]; **//doesn't work**
NSLog(@"TEST2");
}
デリゲートコールバックで[self.navigationControllerpopViewControllerAnimated:YES]が2回呼び出されないのはなぜですか?