【iOS】设置 rootViewController
2016-07-05 21:17
405 查看
iOS 开发中,rootViewController 经常用到,示例代码如下:
self.window = [[UIWindow alloc] initWithFrame:[UIScreen mainScreen].bounds]; self.window.backgroundColor = [UIColor whiteColor]; // 设置相应的 ViewController ViewController *vc = [[ViewController alloc] init]; self.window.rootViewController = vc; [self.window makeKeyAndVisible];
相关文章推荐
- iOS进阶5--使用Jenkins搭建持续集成打包平台
- iOS直播点赞动画,iOS直播心型点赞动画
- 第十一章:推送机制
- iOS开发便捷工具
- iOS视图导航
- iOS开发拓展篇——如何把项目托管到GitHub
- iOS调试常见错误 如:symbol(s) not found for architecture x86_64
- 充电-ios(未完更新中...
- IOS图像拉伸解决方案
- iOS一些提高开发效率的宏(收集)
- iOS相机 相册 麦克风 定位等权限是否拥有
- iOS 右滑手势返回上一级
- ios9模拟器上下出现黑边
- 分析iOS Crash文件:符号化iOS Crash文件的3种方法
- 读书笔记--关于Cocoa框架中的类
- [IOS]JSPatch
- iOS 为什么选择了OC
- iOS Core Data
- 使用workSpace 安装出现updating local specs repositories
- iOS如何清除xcode缓存和生成文件