From 23356479571ef24406320c7a3f96de43b432d195 Mon Sep 17 00:00:00 2001 From: wolfplus Date: Sun, 23 Feb 2025 21:21:19 +0000 Subject: [PATCH] add --- android/app/build.gradle.kts | 6 + android/app/src/main/AndroidManifest.xml | 27 +- ios/Runner/Info.plist | 30 +- lib/core/bindings/initial_binding.dart | 22 +- lib/core/controllers/app_controller.dart | 6 + lib/data/services/audio_service.dart | 96 ++--- .../services/background_agent_service.dart | 95 +++++ lib/data/services/my_audio_handler.dart | 91 +++-- lib/data/services/notification_service.dart | 147 ++++++++ lib/data/services/volcano_tts_service.dart | 56 +-- lib/modules/chat/bindings/chat_binding.dart | 20 +- .../chat/controllers/chat_controller.dart | 343 ++++++++++++------ lib/modules/explore/views/explore_view.dart | 28 +- pubspec.yaml | 5 +- 14 files changed, 695 insertions(+), 277 deletions(-) create mode 100644 lib/data/services/background_agent_service.dart create mode 100644 lib/data/services/notification_service.dart diff --git a/android/app/build.gradle.kts b/android/app/build.gradle.kts index 1cf8cc89f..431857519 100644 --- a/android/app/build.gradle.kts +++ b/android/app/build.gradle.kts @@ -13,6 +13,7 @@ android { compileOptions { sourceCompatibility = JavaVersion.VERSION_11 targetCompatibility = JavaVersion.VERSION_11 + isCoreLibraryDesugaringEnabled = true } kotlinOptions { @@ -28,6 +29,7 @@ android { targetSdk = flutter.targetSdkVersion versionCode = flutter.versionCode versionName = flutter.versionName + multiDexEnabled = true } buildTypes { @@ -42,3 +44,7 @@ android { flutter { source = "../.." } + +dependencies { + coreLibraryDesugaring("com.android.tools:desugar_jdk_libs:2.0.4") +} diff --git a/android/app/src/main/AndroidManifest.xml b/android/app/src/main/AndroidManifest.xml index 481af1c19..9c6e2260c 100644 --- a/android/app/src/main/AndroidManifest.xml +++ b/android/app/src/main/AndroidManifest.xml @@ -9,10 +9,14 @@ + + + + @@ -44,7 +48,9 @@ android:theme="@style/LaunchTheme" android:configChanges="orientation|keyboardHidden|keyboard|screenSize|smallestScreenSize|locale|layoutDirection|fontScale|screenLayout|density|uiMode" android:hardwareAccelerated="true" - android:windowSoftInputMode="adjustResize"> + android:windowSoftInputMode="adjustResize" + android:showWhenLocked="true" + android:turnScreenOn="true"> + + + + + + + + + + +