Browse Source

fix(translation): 仅在蓝牙设备已连接时启用面对面翻译模式

newdev_shunjiawei
lxm 1 year ago
parent
commit
dc2195582b
  1. 6
      lib/modules/translation/views/translation_view.dart

6
lib/modules/translation/views/translation_view.dart

@ -1102,11 +1102,13 @@ class TranslationView extends GetView<TranslationController> {
'faceToFaceTranslation'.tr, 'faceToFaceTranslation'.tr,
Icons.people, Icons.people,
Colors.green, Colors.green,
onTap: () async { onTap: controller.bluetoothManager.currentDevice != null
? () async {
Get.back(); Get.back();
await controller.changeTranslationMode('faceToFace'); await controller.changeTranslationMode('faceToFace');
controller.startRecognition(); controller.startRecognition();
}, }
: null,
), ),
_buildModeItem( _buildModeItem(
context, context,

Loading…
Cancel
Save