From 72b04a114b0d780ee11a140660e0b26c262be98c Mon Sep 17 00:00:00 2001 From: tanlongsheng <252620078@qq.com> Date: Wed, 2 Apr 2025 12:57:54 +0800 Subject: [PATCH 1/3] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E9=80=89=E6=8B=A9?= =?UTF-8?q?=E4=BD=8D=E7=BD=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- lib/core/widgets/select_location_map.dart | 15 ++++++++ .../meeting/views/meeting_record_view.dart | 36 +++++++++++-------- 2 files changed, 36 insertions(+), 15 deletions(-) create mode 100644 lib/core/widgets/select_location_map.dart diff --git a/lib/core/widgets/select_location_map.dart b/lib/core/widgets/select_location_map.dart new file mode 100644 index 000000000..c783901ed --- /dev/null +++ b/lib/core/widgets/select_location_map.dart @@ -0,0 +1,15 @@ +import 'package:flutter/material.dart'; + +class SelectLocationMap extends StatefulWidget { + const SelectLocationMap({super.key}); + + @override + State createState() => _SelectLocationMapState(); +} + +class _SelectLocationMapState extends State { + @override + Widget build(BuildContext context) { + return const Placeholder(); + } +} diff --git a/lib/modules/meeting/views/meeting_record_view.dart b/lib/modules/meeting/views/meeting_record_view.dart index 7aa297e24..726a1b2e1 100644 --- a/lib/modules/meeting/views/meeting_record_view.dart +++ b/lib/modules/meeting/views/meeting_record_view.dart @@ -5,6 +5,7 @@ import 'package:get/get.dart'; import 'package:lottie/lottie.dart'; import '../../../core/theme/app_colors.dart'; +import '../../../core/widgets/select_location_map.dart'; import '../controllers/meeting_record_controller.dart'; class MeetingRecordView extends GetView { @@ -121,23 +122,28 @@ class MeetingRecordView extends GetView { ], ), ), - Padding( - padding: EdgeInsets.symmetric(horizontal: 12.w, vertical: 5.w), - child: Row( - children: [ - Icon( - Icons.location_on, - size: 16.w, - color: isDarkMode ? Colors.grey[400] : Colors.grey[500], - ), - Text( - controller.address.value, - style: TextStyle( + GestureDetector( + onTap: () { + Get.to(() => const SelectLocationMap()); + }, + child: Padding( + padding: EdgeInsets.symmetric(horizontal: 12.w, vertical: 5.w), + child: Row( + children: [ + Icon( + Icons.location_on, + size: 16.w, color: isDarkMode ? Colors.grey[400] : Colors.grey[500], - fontSize: 14.sp, ), - ), - ], + Text( + controller.address.value, + style: TextStyle( + color: isDarkMode ? Colors.grey[400] : Colors.grey[500], + fontSize: 14.sp, + ), + ), + ], + ), ), ), _recordContent(isDarkMode), From bd09d6e820cb7bc4fe3c8459662dad5b140f8045 Mon Sep 17 00:00:00 2001 From: wolfplus Date: Thu, 3 Apr 2025 11:23:45 +0100 Subject: [PATCH 2/3] add --- android/app/build.gradle.kts | 6 +----- ios/Runner/AudioSessionManager.swift | 6 +++++- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/android/app/build.gradle.kts b/android/app/build.gradle.kts index 5f45a8a3f..ad5eafd7b 100644 --- a/android/app/build.gradle.kts +++ b/android/app/build.gradle.kts @@ -1,8 +1,6 @@ repositories { google() mavenCentral() - maven { url = uri("https://artifact.bytedance.com/repository/Volcengine/") } - maven { url = uri("https://oss.sonatype.org/content/repositories/snapshots/") } } plugins { @@ -49,9 +47,7 @@ android { } dependencies { - // WebRTC依赖已移除 - // implementation("io.antmedia:webrtc-android-framework:2.8.0-SNAPSHOT") - + // 添加OkHttp依赖 implementation("com.squareup.okhttp3:okhttp:4.9.3") diff --git a/ios/Runner/AudioSessionManager.swift b/ios/Runner/AudioSessionManager.swift index feaeee830..d41d2fbf5 100644 --- a/ios/Runner/AudioSessionManager.swift +++ b/ios/Runner/AudioSessionManager.swift @@ -206,7 +206,7 @@ import UIKit // 重新激活会话 try audioSession.setActive(true, options: .notifyOthersOnDeactivation) isActive = true - + // 切换到扬声器 // 记录当前配置 currentCategory = category currentMode = mode @@ -319,6 +319,8 @@ import UIKit ], force: false // 是否强制重新配置 ) + try audioSession.overrideOutputAudioPort(.speaker) + } @@ -516,6 +518,8 @@ import UIKit force: force // 是否强制重新配置 ) + try audioSession.overrideOutputAudioPort(.speaker) + // 额外的优化配置 if configureAdditionalSettings { // 获取当前是否使用耳机 From 46f832695bce24ced6e921b61eccfa8f5f316c4a Mon Sep 17 00:00:00 2001 From: wolfplus Date: Thu, 3 Apr 2025 13:51:28 +0100 Subject: [PATCH 3/3] add --- android/app/build.gradle.kts | 2 +- .../kotlin/com/example/deep_voice/MainActivity.kt | 12 ++++++++++-- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/android/app/build.gradle.kts b/android/app/build.gradle.kts index 06c4dbe30..542cf24d8 100644 --- a/android/app/build.gradle.kts +++ b/android/app/build.gradle.kts @@ -40,7 +40,7 @@ android { // You can update the following values to match your application needs. // For more information, see: https://flutter.dev/to/review-gradle-config. minSdk = 24 // Updated to meet azure_speech_recognition_null_safety requirements - targetSdk = 33 // 设置为 Android 13 (API 33),以匹配 FOREGROUND_SERVICE_MEDIA_PLAYBACK 权限的要求 + targetSdk = 34 // 设置为 Android 13 (API 33),以匹配 FOREGROUND_SERVICE_MEDIA_PLAYBACK 权限的要求 versionCode = flutter.versionCode versionName = flutter.versionName } diff --git a/android/app/src/main/kotlin/com/example/deep_voice/MainActivity.kt b/android/app/src/main/kotlin/com/example/deep_voice/MainActivity.kt index d60a43c22..49fd8fdf6 100644 --- a/android/app/src/main/kotlin/com/example/deep_voice/MainActivity.kt +++ b/android/app/src/main/kotlin/com/example/deep_voice/MainActivity.kt @@ -267,7 +267,11 @@ class MainActivity: FlutterActivity() { addAction(VoiceInteractionService.ACTION_RECOGNITION_STARTED) addAction(VoiceInteractionService.ACTION_CHAT_HISTORY_UPDATED) } - registerReceiver(voiceInteractionReceiver, voiceInteractionFilter) + if (android.os.Build.VERSION.SDK_INT >= android.os.Build.VERSION_CODES.UPSIDE_DOWN_CAKE) { + registerReceiver(voiceInteractionReceiver, voiceInteractionFilter, Context.RECEIVER_NOT_EXPORTED) + } else { + registerReceiver(voiceInteractionReceiver, voiceInteractionFilter) + } // 注册蓝牙状态变化广播接收器 val bluetoothFilter = IntentFilter().apply { @@ -275,7 +279,11 @@ class MainActivity: FlutterActivity() { addAction(BluetoothDevice.ACTION_ACL_DISCONNECTED) addAction(BluetoothAdapter.ACTION_STATE_CHANGED) } - registerReceiver(bluetoothStateReceiver, bluetoothFilter) + if (android.os.Build.VERSION.SDK_INT >= android.os.Build.VERSION_CODES.UPSIDE_DOWN_CAKE) { + registerReceiver(bluetoothStateReceiver, bluetoothFilter, Context.RECEIVER_NOT_EXPORTED) + } else { + registerReceiver(bluetoothStateReceiver, bluetoothFilter) + } } override fun configureFlutterEngine(flutterEngine: FlutterEngine) {