From: luozheng <1732036298@qq.com> Date: Wed, 5 Nov 2025 10:36:49 +0000 (+0800) Subject: 解决ota界面文本显示异常问题,ota界面50%下载,修改为30%下载 X-Git-Tag: V1.0.9_20251128_194606_LN~107^2~2 X-Git-Url: http://git.snicker.com.cn/css/static/gitweb.css?a=commitdiff_plain;h=refs%2Fchanges%2F2689%2Fhead;p=mirrors%2FFD230.git 解决ota界面文本显示异常问题,ota界面50%下载,修改为30%下载 --- diff --git a/code/sdk/application/wearable/ln/nativeapp/nativeui/ota/include/OtaModel.h b/code/sdk/application/wearable/ln/nativeapp/nativeui/ota/include/OtaModel.h index 6a034274a..5f971e676 100644 --- a/code/sdk/application/wearable/ln/nativeapp/nativeui/ota/include/OtaModel.h +++ b/code/sdk/application/wearable/ln/nativeapp/nativeui/ota/include/OtaModel.h @@ -73,7 +73,7 @@ namespace OHOS void HandleDownloadEta(int seconds); void HandleDownloadFail(int type); - void SetUpgradeDescription(const std::string& description); + void SetUpgradeDescription(const std::string description); std::string GetUpgradeDescription() const; private: OtaModel(); diff --git a/code/sdk/application/wearable/ln/nativeapp/nativeui/ota/src/OtaLowBatteryView.cpp b/code/sdk/application/wearable/ln/nativeapp/nativeui/ota/src/OtaLowBatteryView.cpp index 651c249fa..833d4fbe9 100644 --- a/code/sdk/application/wearable/ln/nativeapp/nativeui/ota/src/OtaLowBatteryView.cpp +++ b/code/sdk/application/wearable/ln/nativeapp/nativeui/ota/src/OtaLowBatteryView.cpp @@ -65,7 +65,7 @@ namespace OHOS LittleTextLabel->SetAlign(TEXT_ALIGNMENT_CENTER, TEXT_ALIGNMENT_CENTER); LittleTextLabel->SetFont(DEFAULT_VECTOR_FONT_FILENAME, 18); LittleTextLabel->SetStyle(STYLE_TEXT_COLOR, 0xffcccccc); - LittleTextLabel->SetText("请至少充至50%电量哦"); + LittleTextLabel->SetText("请至少充至30%电量哦"); LittleTextLabel->SetVisible(true); group->Add(LittleTextLabel); } diff --git a/code/sdk/application/wearable/ln/nativeapp/nativeui/ota/src/OtaModel.cpp b/code/sdk/application/wearable/ln/nativeapp/nativeui/ota/src/OtaModel.cpp index c0a8bccff..9ccc15e45 100644 --- a/code/sdk/application/wearable/ln/nativeapp/nativeui/ota/src/OtaModel.cpp +++ b/code/sdk/application/wearable/ln/nativeapp/nativeui/ota/src/OtaModel.cpp @@ -498,9 +498,10 @@ namespace OHOS WEARABLE_LOGD(WEARABLE_LOG_MODULE_APP, "OtaModel: Night update status cleared from KV storage"); } - void OtaModel::SetUpgradeDescription(const std::string& description) + void OtaModel::SetUpgradeDescription(const std::string description) { m_upgradeDescription = description; + WEARABLE_LOGE(WEARABLE_LOG_MODULE_APP, "SetUpgradeDescription:%s",m_upgradeDescription.c_str()); } std::string OtaModel::GetUpgradeDescription() const