2012-04-12 2 views

답변

1
  1. iPad (전체 화면에는 UINavigationController를 사용하지 마십시오.)

당신은 이런 좋은 애니메이션을 전환 할 수 있습니다 : 당신이 // works only in app delegate와 주석 라인을 변경하지 않는 한 은 (앱 위임에서만 작동

UIViewController *ctrl = [[UIViewController alloc] initWithNibName:@"someXIBStuff" bundle:nil]; 


    CAKeyframeAnimation *theAnimation = [CAKeyframeAnimation animation]; 
    theAnimation.values = [NSArray arrayWithObjects: 
          [NSValue valueWithCATransform3D:CATransform3DMakeScale(1.12,1.12,1)], 
          [NSValue valueWithCATransform3D:CATransform3DMakeScale(1,1,1)], 
          nil]; 
    theAnimation.cumulative = YES; 
    theAnimation.duration = 0.3; 
    theAnimation.repeatCount = 0; 
    theAnimation.removedOnCompletion = YES; 


    theAnimation.timingFunctions = [NSArray arrayWithObjects:[CAMediaTimingFunction functionWithName:kCAMediaTimingFunctionEaseIn], 
            nil 
            ]; 

    [self.window.layer addAnimation:theAnimation forKey:@"transform"]; 

    CATransition *transition = [CATransition animation]; 
    transition.duration = 0.3; 
    transition.timingFunction = [CAMediaTimingFunction functionWithName:kCAMediaTimingFunctionEaseInEaseOut]; 
    transition.type = kCATransitionFade; 
    transition.delegate = self; 

    [self.window.layer addAnimation:transition forKey:nil]; 

    self.window.rootViewController = ctrl; // works only in app delegate 
    [ctrl release]; 
  1. 아이폰 :. 사용 UINavigationController (가능한 경우) 그렇지 않은 경우 위의 예를 사용할 수 있습니다.
관련 문제