FIX: update the time shown; keep the val update while popup

jira: [STUDIO-9268]
Change-Id: I0b743ddb0ae479f9baad6239f68861a199681cda
(cherry picked from commit e1bc737d1cbc1dcf79ceecf9ed301a4a02590d5a)
This commit is contained in:
xin.zhang
2025-02-27 16:37:01 +08:00
committed by Noisyfox
parent 179f403ee3
commit 385c8a36a1
2 changed files with 20 additions and 1 deletions

View File

@@ -1063,7 +1063,25 @@ void AMSControl::UpdateAms(std::vector<AMSinfo> ams_info, std::vector<AMSinfo>ex
}*/
}
/*update humidity popup*/
if (m_percent_humidity_dry_popup->IsShown())
{
string target_id = m_percent_humidity_dry_popup->get_owner_ams_id();
for (const auto& the_info : ams_info)
{
if (target_id == the_info.ams_id)
{
uiAmsHumidityInfo humidity_info;
humidity_info.ams_id = the_info.ams_id;
humidity_info.humidity_level = the_info.ams_humidity;
humidity_info.humidity_percent = the_info.humidity_raw;
humidity_info.left_dry_time = the_info.left_dray_time;
humidity_info.current_temperature = the_info.current_temperature;
m_percent_humidity_dry_popup->Update(&humidity_info);
break;
}
}
}
}
void AMSControl::AddAmsPreview(AMSinfo info, AMSModel type)