增加运动中自动拒接电话
authorhcj <1224667075@qq.com>
Mon, 9 Sep 2024 08:13:38 +0000 (16:13 +0800)
committerhcj <1224667075@qq.com>
Mon, 9 Sep 2024 08:13:38 +0000 (16:13 +0800)
code/sdk/application/wearable/fd230app/nativeui/phoneservice/src/PhoneService.cpp
code/sdk/application/wearable/service/msg_center/src/msg_center_customer.cpp
code/sdk/application/wearable/service/msg_center/src/notify/makephone_notification.cpp

index 6c2915c..27c118e 100644 (file)
@@ -1458,8 +1458,8 @@ static void CallStateChanged(const bd_addr_t *bdAddr, const hfp_hf_calls_info_t
         }
     }
 
-    if(OHOS::CallerLogModel::GetInstance()->GetCallSource() == OHOS::CallerLogModel::CallSourceCat1
-    && OHOS::NotificationManager::GetInstance()->GetWatchCallStatus())
+    if((OHOS::CallerLogModel::GetInstance()->GetCallSource() == OHOS::CallerLogModel::CallSourceCat1
+    && OHOS::NotificationManager::GetInstance()->GetWatchCallStatus())||uapi_dev_runtime_get_train_status() )
     {
         {
              WEARABLE_LOGE(WEARABLE_LOG_MODULE_APP, "4G 电话中");
index 3163c01..61fed1c 100644 (file)
@@ -803,6 +803,15 @@ void MsgCenterNotifyCatIncomingCallProc(const Topic topic, Request* req)
     // When the incoming call view is displayed, the calling number is not set in CallerLogModel.
         //uapi_hfp_disconnect();
 
+        if(uapi_dev_runtime_get_train_status())
+        {
+            CallerLogModel::GetInstance()->SetoperateNumber(call_data,req->len);
+            cat1_call_hungup();
+            free(call_data);
+            
+            return;
+        }
+
         if(NotificationManager::GetInstance()->GetWatchCallStatus() &&
         (CallerLogModel::GetInstance()->GetCallSource()==CallerLogModel::CallSourcePhone))
         {
index 9d9d9cf..f36c093 100755 (executable)
@@ -348,15 +348,15 @@ UIViewGroup* CALL_INCOMING_HINT(void)
     Hint_UILabel->SetStyle(STYLE_BACKGROUND_COLOR, 0xffAAAAAA);
     Hint_UILabel->SetStyle(STYLE_BACKGROUND_OPA, 0xff);
     Hint_UILabel->SetStyle(STYLE_BORDER_RADIUS, 27);
-    Hint_UILabel->SetStyle(STYLE_TEXT_FONT, 33);
+    Hint_UILabel->SetStyle(STYLE_TEXT_FONT, 40);
     Hint_UILabel->SetStyle(STYLE_LINE_SPACE, 0);
 
     // Set additional property
-    Hint_UILabel->SetText("æ\89\8bæ\9cºæ\96°æ\9d¥ç\94µ");
+    Hint_UILabel->SetText("新来电");
     Hint_UILabel->SetLineBreakMode(UILabel::LINE_BREAK_WRAP);
     Hint_UILabel->SetAlign(TEXT_ALIGNMENT_CENTER, TEXT_ALIGNMENT_CENTER);
     Hint_UILabel->SetRollSpeed(0);
-    Hint_UILabel->SetFont(DEFAULT_VECTOR_FONT_FILENAME, 33);
+    Hint_UILabel->SetFont(DEFAULT_VECTOR_FONT_FILENAME, 40);
 
     HintView->Add(Hint_UILabel);
     Hint_UILabel->SetVisible(true);
@@ -590,6 +590,7 @@ static void WatchFinishHandle(void)
     {
         if(get_falg_SOS())
         {
+            addcalllog();
             sos_falg_add();
         }
         else
@@ -597,6 +598,12 @@ static void WatchFinishHandle(void)
             if(CallerLogModel::GetInstance()->GetCallSource()==CallerLogModel::CallSourcePhone)
             {
                
+            }
+            else if(uapi_dev_runtime_get_train_status())
+            {
+                calllog_info_init();
+                call_stat=2;
+                addcalllog();
             }
             else
             {