更新到Xcode 10.2之后,构建在testflight上显示黑屏

编程入门 行业动态 更新时间:2024-10-26 05:19:35
本文介绍了更新到Xcode 10.2之后,构建在testflight上显示黑屏的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

我的应用正常运行.我已经将Xcode更新到最新的10.2版本,并且发生了一些奇怪的事情(与任何更新一样,通常如此...)

I had my app working perfectly. I've updated the Xcode to the latest 10.2 version and something weird happened (as usual with any update...)

该应用程序在调试器上可以流畅运行.完全没有问题!

The app runs smoothly on the debugger. No issues at all!

当我将一个版本存档到testflight时,该版本会显示启动画面,然后进入黑屏(没有崩溃),只是停留在黑屏中……有人知道这里可能发生什么情况吗?

When I archive a version to testflight, that version shows the splashscreen then goes into black screen (without crashing) just stays in the black screen... does anyone know what might be happening here?

预先感谢

推荐答案

由于iOS 13及更高版本,应用程序启动与早期版本不同.使用最新的xCode-11,如果您在iOS 13上通过TestFlight运行或安装该应用程序,则该应用程序应能工作,但低于13的应用程序将显示黑屏或启动画面.实际上,UIApplicationMain期望AppDelegate中的窗口属性,该属性位于iOS-13中的SceneDelegate中.因此,只需在AppDelegate中添加此行代码(声明窗口属性)即可.

Because of iOS 13 and later, app launch different than earlier versions. Using the latest xCode-11, If you run or install the app from TestFlight on iOS 13 it should work but below 13 it will show black or splash screen. Actually UIApplicationMain expect a window property in AppDelegate which is in iOS-13 inside SceneDelegate. So simply add this line of code (declare window property) in your AppDelegate.

迅速:

var window: UIWindow?

Objective-C:

Objective-C:

@property (strong, nonatomic) UIWindow *window;

更多推荐

更新到Xcode 10.2之后,构建在testflight上显示黑屏

本文发布于:2023-11-26 15:17:34,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1634245.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:新到   黑屏   Xcode   testflight

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!