8

我知道还有其他问题可以解决此错误,但这些答案对我没有任何帮助。我想知道是否有人知道确切原因,如果没有人知道,这里是代码:

-(void) imagePickerController : (UIImagePickerController *) picker
        didFinishPickingImage : (UIImage *) image
                  editingInfo : (NSDictionary *) editingInfo {

    self.imageView.image = image;
    [picker dismissModalViewControllerAnimated:YES];
    [picker release];
    //[self myNextResponder];
}

此错误:wait_fences: failed to receive reply: 10004003,在此方法退出后立即出现。我已经用谷歌搜索了所有内容,但无法弄清楚。

4

3 回答 3

4

看来您使用选择器对象作为 present/dismissModalViewController 的调用者。该文档建议使用“父”视图控制器。

对于“父母”,我使用了 self.navigationController (因为它不会去任何地方)

我的选择器委托的取消方法的实现看起来像这样......

- (void)imagePickerControllerDidCancel:(UIImagePickerController *)picker
{
    // make sure the picker doesn't try to access the soon to die delegate
    picker.delegate = nil;

    [self.navigationController dismissModalViewControllerAnimated:YES];
    [self.navigationController popViewControllerAnimated:YES];
}
于 2009-12-08T16:22:56.087 回答
1

只需注释该行

//[选择器释放];

并尝试

于 2009-10-05T10:30:58.617 回答
0

确保屏幕上没有显示任何键盘。如果有,请使用 [yourTextFieldOrTextView resignFirstResponder]。谢谢

于 2009-09-29T12:29:43.940 回答