From 7cab33f06ceb7d27087093813e02415b7efc5ce9 Mon Sep 17 00:00:00 2001 From: root Date: Sun, 3 Mar 2024 13:56:25 +0800 Subject: [PATCH] =?utf8?q?cat1=E7=94=B5=E8=AF=9D?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- .../fd230app/nativeui/phoneservice/include/PhoneService.h | 1 - .../fd230app/nativeui/phoneservice/src/PhoneService.cpp | 8 +------- .../msg_center/src/notify/makephone_notification.cpp | 6 +++++- 3 files changed, 6 insertions(+), 9 deletions(-) diff --git a/code/sdk/application/wearable/fd230app/nativeui/phoneservice/include/PhoneService.h b/code/sdk/application/wearable/fd230app/nativeui/phoneservice/include/PhoneService.h index 23f4c1447..a3de0f919 100644 --- a/code/sdk/application/wearable/fd230app/nativeui/phoneservice/include/PhoneService.h +++ b/code/sdk/application/wearable/fd230app/nativeui/phoneservice/include/PhoneService.h @@ -117,7 +117,6 @@ int AcceptIncomingCall(void); void CallChangeIncomePro(const hfp_hf_calls_info_t *call); -int AcceptIncomingCall_cat1(void); /** * @brief 手表拒接呼入来电 * diff --git a/code/sdk/application/wearable/fd230app/nativeui/phoneservice/src/PhoneService.cpp b/code/sdk/application/wearable/fd230app/nativeui/phoneservice/src/PhoneService.cpp index 4227c38c8..c0abf996e 100644 --- a/code/sdk/application/wearable/fd230app/nativeui/phoneservice/src/PhoneService.cpp +++ b/code/sdk/application/wearable/fd230app/nativeui/phoneservice/src/PhoneService.cpp @@ -1709,13 +1709,7 @@ int AcceptIncomingCall(void) return OHOS_SUCCESS; } -int AcceptIncomingCall_cat1(void) -{ - WEARABLE_LOGD(WEARABLE_LOG_MODULE_APP, "[AcceptIncomingCall] start"); - int ret, i; - incomedcall_event_sendmsg_toUI("10086"); - return OHOS_SUCCESS; -} + // 手表拒接呼入来电,成功:0,失败:错误码 int RejectIncomingCall(void) { diff --git a/code/sdk/application/wearable/service/msg_center/src/notify/makephone_notification.cpp b/code/sdk/application/wearable/service/msg_center/src/notify/makephone_notification.cpp index 738a4a7df..17bb1b98e 100755 --- a/code/sdk/application/wearable/service/msg_center/src/notify/makephone_notification.cpp +++ b/code/sdk/application/wearable/service/msg_center/src/notify/makephone_notification.cpp @@ -27,6 +27,7 @@ #define NOTIFY_ONE_MINUTE 60000 #define NOTOFY_NO_OPERATE_TIME 35000 +#include "cat1_server_hal.h" #include "NativeAbility.h" namespace OHOS { int changeImage = 0; @@ -524,7 +525,10 @@ bool CallViewEventListener::OnClick(UIView& view, const ClickEvent& event) WEARABLE_LOGD(WEARABLE_LOG_MODULE_APP, "MakephoneNotify 11111111 "); //#ifdef SUPPORT_CAT1_SERVICE - AcceptIncomingCall_cat1(); + WEARABLE_LOGD(WEARABLE_LOG_MODULE_APP, "[AcceptIncomingCall] start"); + + incomedcall_event_sendmsg_toUI("10086"); + cat1_call_answer(); //#endif -- 2.17.1