开发者社区 问答 正文

有关Aviary SDK的问题

在ios中使用Aviary SDK,我按照教程中的步骤进行,但是在调用Viewdidload中的方法:

- (void)displayEditorForImage:(UIImage *)imageToEdit
{
    AFPhotoEditorController *editorController = [[AFPhotoEditorController alloc] initWithImage:imageToEdit];
    [editorController setDelegate:self];
    [self presentViewController:editorController animated:YES completion:nil];
}

报出了如下警告:

Warning: Attempt to present <AFSDKViewController: 0x7e1aeb0> on <ViewController: 0x7934af0> whose view is not in the window hierarchy!

展开
收起
爵霸 2016-03-26 08:42:12 2094 分享 版权
1 条回答
写回答
取消 提交回答
  • 如果你Modal View ControllerViewDidLoad 中,出现这样的错误是由于view还没有加载到窗体框架中。你可以在viewDidAppear中调用那个方法。

    但是如果每次view显示都如此就会调用displayEditorForImagemethod

    2019-07-17 19:15:07
    赞同 展开评论
问答分类:
问答地址: