UI: fix wrong background on controls unresponsive alert

old-commit-hash: 0e35db7c05172b154c70216d2b1b9ed8c9c7b163
This commit is contained in:
Adeeb Shihadeh
2021-11-16 13:16:56 -08:00
parent d1eacc4619
commit 50f00cf617
+3 -3
View File
@@ -43,11 +43,11 @@ void OnroadWindow::updateState(const UIState &s) {
QColor bgColor = bg_colors[s.status];
Alert alert = Alert::get(*(s.sm), s.scene.started_frame);
if (s.sm->updated("controlsState") || !alert.equal({})) {
if (alert.type == "controlsUnresponsive") {
bgColor = bg_colors[STATUS_ALERT];
}
alerts->updateAlert(alert, bgColor);
}
if (alert.type == "controlsUnresponsive") {
bgColor = bg_colors[STATUS_ALERT];
}
if (bg != bgColor) {
// repaint border
bg = bgColor;