From: hcj <1224667075@qq.com> Date: Tue, 15 Jul 2025 04:06:05 +0000 (+0800) Subject: 修改紧急号码拨打限制 X-Git-Url: http://git.snicker.com.cn/css/static/gitweb.css?a=commitdiff_plain;h=refs%2Fchanges%2F1966%2Fhead;p=mirrors%2FFD230.git 修改紧急号码拨打限制 --- diff --git a/code/sdk/application/wearable/fd230app/nativeui/phone/src/DialingMethodPresenter.cpp b/code/sdk/application/wearable/fd230app/nativeui/phone/src/DialingMethodPresenter.cpp index 2ee861d0e..78d26fa1d 100644 --- a/code/sdk/application/wearable/fd230app/nativeui/phone/src/DialingMethodPresenter.cpp +++ b/code/sdk/application/wearable/fd230app/nativeui/phone/src/DialingMethodPresenter.cpp @@ -70,20 +70,29 @@ namespace OHOS if(get_address_number()) { - if(uapi_cat1_get_power_stat()==0 || uapi_dev_runtime_get_cat1_simstat()==0) + if((uapi_cat1_get_power_stat()==0 || uapi_dev_runtime_get_cat1_simstat()==0 ) + && (strcmp(get_address_number(),"110")!=0 + && strcmp(get_address_number(),"112")!=0 + && strcmp(get_address_number(),"120")!=0 + && strcmp(get_address_number(),"119")!=0 + && strcmp(get_address_number(),"122")!=0) ) { DialingMethodView::GetInstance()->fail_Dial_show(0); } else - calldial_event_sendmsg_toUI(get_address_number()); + { + calldial_event_sendmsg_toUI(get_address_number()); + } + + } else { - if(uapi_cat1_get_power_stat()==0 || uapi_dev_runtime_get_cat1_simstat()==0) - { - DialingMethodView::GetInstance()->fail_Dial_show(0); - }else + // if(uapi_cat1_get_power_stat()==0 || uapi_dev_runtime_get_cat1_simstat()==0) + // { + // DialingMethodView::GetInstance()->fail_Dial_show(0); + // }else { WEARABLE_LOGE(WEARABLE_LOG_MODULE_APP, "uapi_cat1_get_power_stat"); NativeAbility::GetInstance().EnterSlice(VIEW_PHONECALL);