ui: display current driving model in software settings (#127)

This commit is contained in:
Jason Wen
2023-06-10 22:04:38 -04:00
committed by GitHub
parent 3dc9ffb9bb
commit f6335f1f7b
4 changed files with 7 additions and 0 deletions
+1
View File
@@ -0,0 +1 @@
#define CURRENT_MODEL "Nicki Minaj (May 22, 2023)"
+1
View File
@@ -162,6 +162,7 @@ selfdrive/mapd/README.md
common/SConscript
common/version.h
common/model.h
common/prefix.h
common/swaglog.h
+1
View File
@@ -89,6 +89,7 @@ private:
QLabel *onroadLbl;
QLabel *osmUpdateLbl;
LabelControl *currentModelLbl;
LabelControl *versionLbl;
ButtonControl *installBtn;
ButtonControl *downloadBtn;
@@ -9,6 +9,7 @@
#include "common/params.h"
#include "common/util.h"
#include "common/model.h"
#include "selfdrive/ui/ui.h"
#include "selfdrive/ui/qt/util.h"
#include "selfdrive/ui/qt/widgets/controls.h"
@@ -21,6 +22,9 @@ void SoftwarePanel::checkForUpdates() {
}
SoftwarePanel::SoftwarePanel(QWidget* parent) : ListWidget(parent) {
currentModelLbl = new LabelControl(tr("Current Driving Model"), CURRENT_MODEL);
addItem(currentModelLbl);
onroadLbl = new QLabel(tr("Updates are only downloaded while the car is off."));
onroadLbl->setStyleSheet("font-size: 50px; font-weight: 400; text-align: left; padding-top: 30px; padding-bottom: 30px;");
addItem(onroadLbl);