wip
This commit is contained in:
@@ -96,7 +96,6 @@ void OnroadWindow::updateState(const UIState &s) {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
Alert alert = Alert::get(*(s.sm), s.scene.started_frame);
|
Alert alert = Alert::get(*(s.sm), s.scene.started_frame);
|
||||||
alerts->updateAlert(alert);
|
alerts->updateAlert(alert);
|
||||||
|
|
||||||
@@ -115,6 +114,7 @@ void OnroadWindow::updateState(const UIState &s) {
|
|||||||
|
|
||||||
if (bg != bgColor) {
|
if (bg != bgColor) {
|
||||||
bg = bgColor;
|
bg = bgColor;
|
||||||
|
CameraWidget->updateLaneEdgeColor(bg);
|
||||||
update();
|
update();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -636,20 +636,16 @@ void AnnotatedCameraWidget::updateState(const UIState &s) {
|
|||||||
map_settings_btn->setVisible(!hideBottomIcons && compass && !scene.hide_map_icon);
|
map_settings_btn->setVisible(!hideBottomIcons && compass && !scene.hide_map_icon);
|
||||||
main_layout->setAlignment(map_settings_btn, (rightHandDM ? Qt::AlignLeft : Qt::AlignRight) | Qt::AlignTop);
|
main_layout->setAlignment(map_settings_btn, (rightHandDM ? Qt::AlignLeft : Qt::AlignRight) | Qt::AlignTop);
|
||||||
}
|
}
|
||||||
|
|
||||||
QColor bgColor = bg_colors[s.status];
|
|
||||||
if (paramsMemory.getInt("no_lat_lane_change") == 1) {
|
|
||||||
bgColor = bg_colors[STATUS_DISENGAGED];
|
|
||||||
}
|
|
||||||
|
|
||||||
if (bg != bgColor) {
|
|
||||||
bg = bgColor;
|
|
||||||
update();
|
|
||||||
}
|
|
||||||
|
|
||||||
updateFrogPilotWidgets();
|
updateFrogPilotWidgets();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void AnnotatedCameraWidget::updateLaneEdgeColor(QColor &bgColor) {
|
||||||
|
if (bg != bgColor) {
|
||||||
|
bg = bgColor;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
void AnnotatedCameraWidget::drawHud(QPainter &p) {
|
void AnnotatedCameraWidget::drawHud(QPainter &p) {
|
||||||
p.save();
|
p.save();
|
||||||
|
|
||||||
|
|||||||
@@ -168,6 +168,7 @@ class AnnotatedCameraWidget : public CameraWidget {
|
|||||||
public:
|
public:
|
||||||
explicit AnnotatedCameraWidget(VisionStreamType type, QWidget* parent = 0);
|
explicit AnnotatedCameraWidget(VisionStreamType type, QWidget* parent = 0);
|
||||||
void updateState(const UIState &s);
|
void updateState(const UIState &s);
|
||||||
|
void updateLaneEdgeColor(QColor &bgColor);
|
||||||
|
|
||||||
MapSettingsButton *map_settings_btn;
|
MapSettingsButton *map_settings_btn;
|
||||||
MapSettingsButton *map_settings_btn_bottom;
|
MapSettingsButton *map_settings_btn_bottom;
|
||||||
|
|||||||
Reference in New Issue
Block a user