瀏覽代碼

1.优化启动页,在宣染完第一帧后再去掉启动屏

tags/0.0.4+3
“yanghuaxuan” 3 年之前
父節點
當前提交
50fdfb49b7
共有 1 個文件被更改,包括 4 次插入3 次删除
  1. +4
    -3
      lib/pages/home_page/home_page.dart

+ 4
- 3
lib/pages/home_page/home_page.dart 查看文件

@@ -51,9 +51,6 @@ class _HomePageState extends State<HomePage> with WidgetsBindingObserver, Ticker

@override
void initState() {
Timer(Duration(milliseconds: 0), () {
NativeUtil.notifyInitSuccess();
});

///初始化一些数据
initAsync();
@@ -65,6 +62,10 @@ class _HomePageState extends State<HomePage> with WidgetsBindingObserver, Ticker
initAsync() async {
try {
WidgetsBinding.instance.addObserver(this);
///渲染完第一帧后调用
WidgetsBinding.instance.addPostFrameCallback((timeStamp) {
NativeUtil.notifyInitSuccess();
});
String data = BaseSettingModel.setting.tab['data'];
try {
List list = convert.jsonDecode(data);


Loading…
取消
儲存