首页 > 其他 > 详细

presentModalViewController方法,present一个透明的viewController,带动画效果

时间:2014-02-28 09:02:58      阅读:392      评论:0      收藏:0      [点我收藏+]

 

bubuko.com,布布扣
//假设需要被present的控制器实例为controller
UIViewController * rootcontroller = self.view.window.rootViewController; rootcontroller.modalPresentationStyle = UIModalPresentationCurrentContext;//进入的动画失效
[rootcontroller presentViewController:controller animated:NO completion:
^{ rootcontroller.modalPresentationStyle = UIModalPresentationFullScreen; }]; controller.view.transform = CGAffineTransformMakeTranslation(0, controller.view.frame.size.height); [UIView animateWithDuration:0.35 animations:^{ controller.view.transform = CGAffineTransformMakeTranslation(0, 0); }];
bubuko.com,布布扣

presentModalViewController方法,present一个透明的viewController,带动画效果,布布扣,bubuko.com

presentModalViewController方法,present一个透明的viewController,带动画效果

原文:http://www.cnblogs.com/benbenzhu/p/3571629.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!