几次触发presentViewController

时间:2014-02-07 02:39:53

标签: objective-c storyboard modalviewcontroller viewcontroller viewdidappear

-(void) viewDidAppear:(BOOL)animated {
if (!self.hasPresentedModalMenuView) {

    NSLog(@"Firing");
UIStoryboard *storyboard = [UIStoryboard storyboardWithName:@"highScoresStory" bundle:nil];
UIViewController *vc = [storyboard instantiateViewControllerWithIdentifier:@"highScores"];
[vc setModalPresentationStyle:UIModalPresentationFullScreen];
[self presentViewController:vc animated:YES completion:nil];


} }

这一遍又一遍地重复着。我已经取出了“Firing”下面的代码,如果我这样做,它只会触发一次。为什么这会继续射击?谢谢你的帮助。

0 个答案:

没有答案