Я использую этот код для перехода между подпредставлением и другим, но анимация прерывистая в моем iphone, но не в симуляторе!
Любая помощь приветствуется.
UIView * currentView =mysubview;
[currentView setHidden:TRUE];//hide previous view
PoemResults *view1=[[PoemResults alloc] initWithNibName:@"PoemResults" bundle:nil];
[currentView addSubview:view1.view];
[currentView setHidden:FALSE];
// set up an animation for the transition between the views
CATransition *animation = [CATransition animation];
[animation setDuration:0.5];
[animation setType:kCATransitionPush];
[animation setSubtype:kCATransitionFromRight];
animation.delegate = self;
[animation setTimingFunction:[CAMediaTimingFunction functionWithName:kCAMediaTimingFunctionEaseInEaseOut]];
[[mysubview layer] addAnimation:animation forKey:@"SwitchToView1w"];