Unbalanced calls to begin/end appearance transitions for

前端 未结 25 1100
陌清茗
陌清茗 2020-12-02 06:31

I have this problem when I simulate my app, its not an error or a warning but it appears in my console, has anyone ever experienced this before?

25条回答
  •  失恋的感觉
    2020-12-02 07:03

    The situation can occur if you are adding a view with a modal view controller as a sub view. Best to use:

    -(void) viewDidAppear:(BOOL)animated {
        [self presentViewController:self.yourModalVC animated:YES completion:nil];
    }
    

    It is basically saying the view life cycle is not streamlined for those viewControllers you are trying to display then.

提交回复
热议问题