新版xcode新建项目 删除Scenedelegate

1: 到info.plist删除Application Scene Manifest选项;

2: 删掉Scenedelegate.h和Scenedelegate.m这两个文件;

3: AppDelegate里删掉

- (void)application:(UIApplication *)application didDiscardSceneSessions:(NSSet *)sceneSessions {}

- (UISceneConfiguration *)application:(UIApplication *)application configurationForConnectingSceneSession:(UISceneSession *)connectingSceneSession options:(UISceneConnectionOptions *)options {}

4: 在APPdelegate.h里面添加window属性

@property (strong, nonatomic) UIWindow * window;

运行

你可能感兴趣的:(新版xcode新建项目 删除Scenedelegate)