From 28fb14cda0c26c559646e06af21e4456cf4b2c4a Mon Sep 17 00:00:00 2001 From: "snickersun@163.com" Date: Tue, 6 Aug 2024 10:18:47 +0000 Subject: [PATCH] Merge #651 into sdk602patch0626 from refs/changes/651/head MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit 添加DISABLE_AI_VALID_QUERY宏,控制是否需要查询AI服务器是否有效,默认开启查询。 * refs/changes/651/head: (1 commits squashed) - 添加DISABLE_AI_VALID_QUERY宏,控制是否需要查询AI服务器是否有效,默认开启查询。 Signed-off-by: snickersun@163.com Reviewed-by: snickersun@163.com Merged-by: snickersun@163.com CR-link: https://codeup.aliyun.com/64191456b9581d62e8f81ac0/FD230/change/651 --- .../fd230app/nativeui/aivoice/src/AiVoicePresenter.cpp | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) 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.两者连接都异常 { -- 2.17.1