From: luozheng <1732036298@qq.com> Date: Thu, 28 Nov 2024 02:30:17 +0000 (+0800) Subject: 修复闹钟弹窗不亮屏bug X-Git-Tag: fd230_release_V1.3.102~7^2~9 X-Git-Url: http://git.snicker.com.cn/css/static/gitweb.css?a=commitdiff_plain;h=2af07f29fa8e0427eda1daa42f3a0f058e8792b3;p=mirrors%2FFD230.git 修复闹钟弹窗不亮屏bug --- diff --git a/code/sdk/application/wearable/service/msg_center/src/notify/alarm_notification.cpp b/code/sdk/application/wearable/service/msg_center/src/notify/alarm_notification.cpp index 0abbaf0f8..b24132c0f 100755 --- a/code/sdk/application/wearable/service/msg_center/src/notify/alarm_notification.cpp +++ b/code/sdk/application/wearable/service/msg_center/src/notify/alarm_notification.cpp @@ -19,6 +19,7 @@ #include "ConfigModel.h" #include #include "../../../../../../drivers/peripheral/vibrator/service/vibrator_service.h" +#include namespace OHOS { static constexpr const char *RING_AGAIN = "响铃将在十分钟后再次响起"; @@ -503,6 +504,7 @@ namespace OHOS g_alarmView->Add(g_StopBtn); /* -------------------------------------------------------------------------- */ StartAlarmTimer(AlarmTimerType::NOTIFY_ALARM_RING, NOTIFY_ONE_SECOND); + ScreenAlwaysOnCtr(OPEN_SCREEN_ALWAYS_ON); } NotificationManager::GetInstance()->RegisterNotifyCleanupFunction(FreeAlarmView); return g_alarmView; @@ -542,6 +544,7 @@ namespace OHOS RootView::GetInstance()->Remove(g_alarmView); delete g_alarmView; g_alarmView = nullptr; + ScreenAlwaysOnCtr(CANCEL_SCREEN_ALWAYS_ON); WEARABLE_LOGD(WEARABLE_LOG_MODULE_APP, "FreeAlarmView over!!"); } }