iOS6中UIViewController被弃用的方法(: first deprecated in iOS 6.0)

deprecated  表示已不被建议使用,可能随时取消它;建议采用新的来替代。


1:

"modalViewController" 属性 is deprecated : first deprecated in iOS 6.0

采用 presentedViewController

 2:

"dismissModalViewControllerAnimated" is deprecated : first deprecated in iOS 6.0

采用

dismissViewControllerAnimated:(BOOL) completion:^(void)completion

如:[self dismissViewControllerAnimated:YES completion:nil];

 3:

"presentModalViewController: animated:" is deprecated : first deprecated in iOS 6.0

采用

presentViewController:(UIViewController *) animated:(BOOL) completion:^(void)completion

如:[self.viewController presentViewController:controller animated:YES completion:nil];

 4:

"automaticallyForwardAppearanceAndRotationMethodsToChildViewControllers" is deprecated : first deprecated in iOS 6.0

采用

shouldAutomaticallyForwardRotationMethods 和 shouldAutomaticallyForwardAppearanceMethods

 5:

"shouldAutorotateToInterfaceOrientation:" is deprecated : first deprecated in iOS 6.0

采用

重载 supportedInterfaceOrientationspreferredInterfaceOrientationForPresentation 方法

 

 "viewDidUnload"和"viewWillUnload" 在iOS 6.0从不调用。


你可能感兴趣的:(ios,ios,in,iOS6,deprecated,6.)