xcode6 建立 empty application

1.新建一个single view application
2.打开 Info.plist,删除里面的  Launch screen interface file....以及 Main storyboard file base name...
3.删除Main.storyboard以及LaunchScreen.xib
4.打开工程项目属性文件,点击Target下面的第一项,再选择General选项卡,向下找到Use Asset Catalog按钮。点击它。弹出对话框,点击Migrate即可。这样,应用尺寸就能根据屏幕大小进行调整了。
5.在AppDelegate.m修改如下(其中MainViewController是自己新建的 viewController) - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions { // Override point for customization after application launch. self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds] ]; self.window.rootViewController = [[MainViewController alloc]init]; [self.window makeKeyAndVisible]; return YES; }

 

posted @ 2014-12-19 14:51  菜鸟程序猿  阅读(150)  评论(0编辑  收藏  举报