我有一个视图控制器,它的打开UIViewController
方式UIViewPicker
如下:
-(void)operationClicked:(id)sender {
ChoseOperationViewController *picker = [[ChoseOperationViewController alloc] initWithNibName:@"ChoseOperationViewController" bundle:[NSBundle mainBundle]];
[self.view addSubview:picker.view];
[picker animateSlideOut];
}
ChoseOperationViewController 是自定义的 UiViewController 类,其 nib 持有UiViewPicker
和UINavigationBar
我已将“Anuluj”(取消)按钮连接到操作,如下图所示:
当我点击按钮时,我得到了-[ChoseOperationViewController performSelector:withObject:withObject:]: message sent to deallocated instance 0x7569fd0
并且 cancelClicked 方法没有被调用。这是为什么?