我正在使用 Flutter 中构建的 Android 应用程序片段来扩展我们现有的 Swift iOS 应用程序。它工作正常,但是当我转向 FlutterViewController 时,启动画面在加载时闪烁(大概是 flutter 启动画面)。有没有办法在后台执行加载/segue,并且仅在页面加载后才进行segue?
使用: swift 4.0, flutter
最佳答案
也许将FlutterViewController的splashScreenView设置为nil可以工作。
Specifies the view to use as a splash screen. Flutter’s rendering is asynchronous, so the first frame rendered by the Flutter application might not immediately appear when theFlutter view is initially placed in the view hierarchy. The splash screen view will be used as a replacement until the first frame is rendered.
The view used should be appropriate for multiple sizes; an autoresizing mask to have a flexible width and height will be applied automatically.
Declaration
@property (readwrite, strong, nonatomic) UIView *splashScreenView;
关于swift - 在现有 native 应用程序中使用 FlutterViewController 时关闭启动屏幕,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/49763336/