mirror of
https://github.com/dragonpilot/dragonpilot.git
synced 2026-11-03 04:54:37 +08:00
bugfix: on_off_road btn
This commit is contained in:
@@ -131,4 +131,5 @@ inline static std::unordered_map<std::string, ParamKeyAttributes> keys = {
|
||||
{"Version", {PERSISTENT, STRING}},
|
||||
{"dp_dev_last_log", {CLEAR_ON_ONROAD_TRANSITION, STRING}},
|
||||
{"dp_dev_reset_conf", {CLEAR_ON_MANAGER_START, BOOL, "0"}},
|
||||
{"dp_dev_go_off_road", {CLEAR_ON_MANAGER_START, BOOL, "0"}},
|
||||
};
|
||||
|
||||
@@ -280,5 +280,5 @@ class DeviceLayout(Widget):
|
||||
|
||||
self._dp_on_off_road_btn.action_item.set_text(tr("Go Onroad") if not val else tr("Go Offroad"))
|
||||
|
||||
dialog = ConfirmDialog(tr("Are you sure you want to switch?"), tr("CONFIRM"))
|
||||
gui_app.set_modal_overlay(dialog, callback=on_off_road)
|
||||
dialog = ConfirmDialog(tr("Are you sure you want to switch?"), tr("CONFIRM"), callback=on_off_road)
|
||||
gui_app.push_widget(dialog)
|
||||
|
||||
Reference in New Issue
Block a user