mirror of
https://github.com/firestar5683/StarPilot.git
synced 2026-07-04 21:12:07 +08:00
UI: don't disable toggles onroad
old-commit-hash: d3af76842c82c3f5bc19be7623264c739b21c740
This commit is contained in:
@@ -89,9 +89,6 @@ TogglesPanel::TogglesPanel(SettingsWindow *parent) : ListWidget(parent) {
|
||||
auto toggle = new ParamControl(param, title, desc, icon, this);
|
||||
bool locked = params.getBool((param + "Lock").toStdString());
|
||||
toggle->setEnabled(!locked);
|
||||
if (!locked) {
|
||||
connect(uiState(), &UIState::offroadTransition, toggle, &ParamControl::setEnabled);
|
||||
}
|
||||
addItem(toggle);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user