presentModalViewController在iOS6 [英] presentModalViewController in iOS6
问题描述
在我的应用程序的代码中,我仍然以presentModalViewController模式地呈现viewcontrollers。这在iOS 6中已被弃用。这是否意味着此方法对运行iOS 6的设备没有影响?
In my app's code I am still presenting viewcontrollers modally with presentModalViewController. This is deprecated in iOS 6. Does that mean this method has no effect on devices running iOS 6?
如果是,我如何使我的应用程序在iOS 6?
If yes, how can I make my app present viewcontrollers modally on iOS 6? My Xcode version does not support iOS 6, so all new methods in iOS 6 are unavailable to me.
推荐答案
不推荐使用的方法是:您可以使用我的Xcode版本不支持iOS 6,因此iOS 6中的所有新方法都无法使用。不应再使用此方法。
Deprecated means that you shouldn't use this method anymore. It still works, but it might be completely removed in one of the next updates.
为了以模态方式显示视图控制器,您可以使用新的 -
。
解除新方法的方法是 -dismissViewControllerAnimated:completion:
。presentViewController:animated:completion:
For displaying view controllers modally, you can use the new -presentViewController:animated:completion:
method introduced in iOS 5.0.
For dismissing the new method is -dismissViewControllerAnimated:completion:
.
这篇关于presentModalViewController在iOS6的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!