presentModalViewController在iOS6 [英] presentModalViewController in iOS6

查看:98
本文介绍了presentModalViewController在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:.

http://developer.apple.com/library/ios/#documentation/uikit/reference/UIViewController_Class/Reference/Reference.html

这篇关于presentModalViewController在iOS6的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆