From: hcj <1224667075@qq.com> Date: Tue, 11 Jun 2024 10:47:35 +0000 (+0800) Subject: 增加传输过程UI长亮 X-Git-Tag: release_V1.2.70_20241020_135402~1005^2^2~5 X-Git-Url: http://git.snicker.com.cn/css/static/gitweb.css?a=commitdiff_plain;h=bc2db41abbc4c94aa642e17a44c94717877ba3b1;p=mirrors%2FFD230.git 增加传输过程UI长亮 --- diff --git a/code/sdk/application/wearable/service/msg_center/src/notify/transmitting.cpp b/code/sdk/application/wearable/service/msg_center/src/notify/transmitting.cpp index b76cb6d03..ef774916f 100644 --- a/code/sdk/application/wearable/service/msg_center/src/notify/transmitting.cpp +++ b/code/sdk/application/wearable/service/msg_center/src/notify/transmitting.cpp @@ -12,7 +12,7 @@ #include "components/ui_slider.h" // #include "UiConfig.h" #include "bleEvent.h" - +#include "power_display_service.h" namespace OHOS { static UIImageView *imageCharge = nullptr; @@ -147,6 +147,14 @@ namespace OHOS } transmitting_timer = nullptr; } + + const power_display_svr_api_t *display_api = power_display_svr_get_api(); + if (display_api->get_screen_state() != SCREEN_ON) + { + display_api->turn_on_screen(); + } + display_api->set_auto_timeout_function(true); + RootView::GetInstance()->Remove(UIViewGroup_transmitting); @@ -548,6 +556,13 @@ namespace OHOS UIViewGroup_transmitting->SetOnClickListener(button1Click); UIViewGroup_transmitting->SetTouchable(true); + const power_display_svr_api_t *display_api = power_display_svr_get_api(); + if (display_api->get_screen_state() != SCREEN_ON) + { + display_api->turn_on_screen(); + } + display_api->set_auto_timeout_function(false); +