From 7bc406c2158defff9b87b6c9282469bb692e4d91 Mon Sep 17 00:00:00 2001 From: "J. A. Messias" Date: Tue, 22 Oct 2024 17:25:33 -0300 Subject: [PATCH] =?UTF-8?q?otimiza=C3=A7=C3=A3o=20o=20desempenho=20do=20ap?= =?UTF-8?q?p=20por=20causa=20da=20solu=C3=A7=C3=A3o=20anterior?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- android/app/build.gradle | 4 ++-- lib/main.dart | 3 ++- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/android/app/build.gradle b/android/app/build.gradle index 62e36bbf..af88cf55 100644 --- a/android/app/build.gradle +++ b/android/app/build.gradle @@ -57,8 +57,8 @@ android { compileOptions { coreLibraryDesugaringEnabled true - sourceCompatibility JavaVersion.VERSION_11 - targetCompatibility JavaVersion.VERSION_11 + sourceCompatibility JavaVersion.VERSION_18 + targetCompatibility JavaVersion.VERSION_18 } kotlinOptions { diff --git a/lib/main.dart b/lib/main.dart index 842cf756..a4358e0e 100644 --- a/lib/main.dart +++ b/lib/main.dart @@ -288,7 +288,8 @@ class _AppState extends State with WidgetsBindingObserver { @override void didChangeAppLifecycleState(AppLifecycleState state) async { if (state == AppLifecycleState.resumed) await StorageUtil().ensureInitialization(); - LocalizationService.processLocals(context); + if (state == AppLifecycleState.resumed) LocalizationService.processLocals(context); + else LocalizationService.processData(context); } @override Widget build(BuildContext context) {