mirror of
https://github.com/firestar5683/StarPilot.git
synced 2026-08-05 16:26:06 +08:00
odyss
This commit is contained in:
@@ -5,6 +5,7 @@
|
||||
#include <algorithm>
|
||||
#include <cmath>
|
||||
|
||||
#include "common/params.h"
|
||||
#include "common/swaglog.h"
|
||||
#include "selfdrive/ui/qt/util.h"
|
||||
|
||||
@@ -44,7 +45,8 @@ void AnnotatedCameraWidget::updateState(const UIState &s, const StarPilotUIState
|
||||
|
||||
const cereal::CarState::Reader &carState = sm["carState"].getCarState();
|
||||
|
||||
const bool hide_steering_wheel = starpilot_toggles.value("hide_steering_wheel").toBool();
|
||||
static Params params;
|
||||
const bool hide_steering_wheel = starpilot_toggles.value("hide_steering_wheel").toBool() || params.getBool("HideSteeringWheel");
|
||||
experimental_btn->setVisible(!hide_steering_wheel);
|
||||
|
||||
const QPoint experimental_button_position = hide_steering_wheel
|
||||
|
||||
@@ -174,6 +174,11 @@ StarPilotVisualsPanel::StarPilotVisualsPanel(StarPilotSettingsWindow *parent, bo
|
||||
QObject::connect(visualToggle, &AbstractControl::showDescriptionEvent, [this]() {
|
||||
update();
|
||||
});
|
||||
if (ToggleControl *toggle = qobject_cast<ToggleControl*>(visualToggle)) {
|
||||
QObject::connect(toggle, &ToggleControl::toggleFlipped, this, []() {
|
||||
updateStarPilotToggles();
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
QSet<QString> forceUpdateKeys = {"HideLeadMarker", "ShowSpeedLimits"};
|
||||
|
||||
Reference in New Issue
Block a user