iphone ios 模式视图 model view切换

来源:互联网 发布:软件开发 成都 编辑:程序博客网 时间:2024/06/05 17:46

在iphone4的开发中,可以用

- (void)presentModalViewController:(UIViewController *)modalViewController animated:(BOOL)animated

[self presentModalViewController:<#(UIViewController *)modalViewController#> animated:<#(BOOL)animated#>]



方法来切换

- (void)dismissModalViewControllerAnimated:(BOOL)animated

[[self parentViewController]dismissModalViewControllerAnimated:<#(BOOL)animated#>]



网上有文章说,不要用在viewdidload函数里。


官方:http://developer.apple.com/library/ios/#documentation/UIKit/Reference/UIViewController_Class/Reference/Reference.html

原创粉丝点击