Commit 15c8ff79 authored by justin's avatar justin

设置背景颜色,防止出现黑闪一下

parent 1301ef67
...@@ -137,6 +137,11 @@ public class FlutterActivityAndFragmentDelegate implements IFlutterViewContainer ...@@ -137,6 +137,11 @@ public class FlutterActivityAndFragmentDelegate implements IFlutterViewContainer
flutterSplashView = new FlutterSplashView(host.getContext()); flutterSplashView = new FlutterSplashView(host.getContext());
if(host.getTransparencyMode()==FlutterView.TransparencyMode.opaque){
flutterSplashView.setBackgroundColor(Color.WHITE);
}
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.JELLY_BEAN_MR1) { if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.JELLY_BEAN_MR1) {
flutterSplashView.setId(View.generateViewId()); flutterSplashView.setId(View.generateViewId());
} else { } else {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment