FIX:display correct humidity

jira:[fix]

Change-Id: I27aae54a8355911b5d88ed45be320d3c9178081c
This commit is contained in:
tao wang 2024-03-04 20:25:58 +08:00 committed by Lane.Wei
parent 9b3d7c36ff
commit 9e39016837

View File

@ -1576,11 +1576,14 @@ void AMSRoad::doRender(wxDC &dc)
if (m_amsinfo.ams_humidity >= 1 && m_amsinfo.ams_humidity <= 5) {
int hum_index = m_amsinfo.ams_humidity - 1;
int hum_index = 6 - m_amsinfo.ams_humidity - 1;
if (wxGetApp().dark_mode()) {
hum_index += 5;
}
dc.DrawBitmap(ams_humidity_img[hum_index].bmp(), wxPoint(size.x - FromDIP(33), size.y - FromDIP(33)));
if (hum_index >= 0) {
dc.DrawBitmap(ams_humidity_img[hum_index].bmp(), wxPoint(size.x - FromDIP(33), size.y - FromDIP(33)));
}
}
else {
//to do ...