This commit is contained in:
xkeyC 2023-10-28 20:37:45 +08:00
parent 8e4fb2fd18
commit 6edda9bdc4
2 changed files with 4 additions and 2 deletions

View File

@ -81,6 +81,8 @@ class HomeUIModel extends BaseUIModel {
appPlacardData = r; appPlacardData = r;
} }
} }
updateSCServerStatus();
notifyListeners();
appWebLocalizationVersionsData = AppWebLocalizationVersionsData.fromJson( appWebLocalizationVersionsData = AppWebLocalizationVersionsData.fromJson(
(await Api.dio.get("${AppConf.webTranslateHomeUrl}/versions.json", (await Api.dio.get("${AppConf.webTranslateHomeUrl}/versions.json",
options: Options(responseType: ResponseType.json))) options: Options(responseType: ResponseType.json)))
@ -89,7 +91,6 @@ class HomeUIModel extends BaseUIModel {
dPrint(e); dPrint(e);
} }
notifyListeners(); notifyListeners();
updateSCServerStatus();
} }
@override @override
@ -449,7 +450,6 @@ class HomeUIModel extends BaseUIModel {
isFixingString = ""; isFixingString = "";
isFixing = false; isFixing = false;
} }
await webViewModel.initWebView( await webViewModel.initWebView(
title: title, title: title,
); );
@ -467,6 +467,7 @@ class HomeUIModel extends BaseUIModel {
}); });
} }
await Future.delayed(const Duration(milliseconds: 500));
await webViewModel.launch(url); await webViewModel.launch(url);
notifyListeners(); notifyListeners();
} }

View File

@ -129,6 +129,7 @@ class LoginDialogModel extends BaseUIModel {
.initLocalization(homeUIModel.appWebLocalizationVersionsData!); .initLocalization(homeUIModel.appWebLocalizationVersionsData!);
} catch (_) {} } catch (_) {}
} }
await Future.delayed(const Duration(milliseconds: 500));
await webViewModel.initWebView( await webViewModel.initWebView(
title: title, title: title,
); );