From: SnickerSun Date: Tue, 6 Aug 2024 10:17:26 +0000 (+0800) Subject: 添加DISABLE_AI_VALID_QUERY宏,控制是否需要查询AI服务器是否有效,默认开启查询。 X-Git-Tag: release_V1.2.70_20241020_135402~694^2^2~5 X-Git-Url: http://git.snicker.com.cn/css/static/gitweb.css?a=commitdiff_plain;h=refs%2Fchanges%2F651%2F1;p=mirrors%2FFD230.git 添加DISABLE_AI_VALID_QUERY宏,控制是否需要查询AI服务器是否有效,默认开启查询。 --- diff --git a/code/sdk/application/wearable/fd230app/nativeui/aivoice/src/AiVoicePresenter.cpp b/code/sdk/application/wearable/fd230app/nativeui/aivoice/src/AiVoicePresenter.cpp index 9b1b97a66..6a61319c9 100644 --- a/code/sdk/application/wearable/fd230app/nativeui/aivoice/src/AiVoicePresenter.cpp +++ b/code/sdk/application/wearable/fd230app/nativeui/aivoice/src/AiVoicePresenter.cpp @@ -1,8 +1,8 @@ /* * @Author: luozheng 1732036298@qq.com * @Date: 2024-06-20 15:11:17 - * @LastEditors: luozheng 1732036298@qq.com - * @LastEditTime: 2024-08-03 17:48:50 + * @LastEditors: SnickerSun snickersun@163.com + * @LastEditTime: 2024-08-06 17:40:32 * @FilePath: /FD230/code/sdk/application/wearable/fd230app/nativeui/aivoice/src/AiVoicePresenter.cpp */ #include "AppViewIDs.h" @@ -269,7 +269,12 @@ namespace OHOS else if (appBluetoothConnectState) // 3.只有与APP蓝牙连接正常 { // 通过蓝牙连接APP调用大模型 +#ifdef DISABLE_AI_VALID_QUERY + ChangeViewAndLogicOperator(AIVOICE_STARTCHAT_VIEWID, AIVOICE_LISTENING_VIEWID); + model->SetAiVoiceConnectStatus(true); +#else ChangeViewAndLogicOperator(AIVOICE_STARTCHAT_VIEWID, AIVOICE_AIMODE_CONNECTING); // LOADING +#endif } else // 4.两者连接都异常 {