Commit 6efac729 authored by Lorenz Meier's avatar Lorenz Meier

Vehicle: Fix joystick enabled state checkbox

parent e93d3d1d
......@@ -838,6 +838,7 @@ void Vehicle::setJoystickEnabled(bool enabled)
_joystickEnabled = enabled;
_startJoystick(_joystickEnabled);
_saveSettings();
emit joystickEnabledChanged(_joystickEnabled);
}
void Vehicle::_startJoystick(bool start)
......
......@@ -355,12 +355,10 @@ QGCView {
QGCCheckBox {
enabled: allowEnableDisable
enabled: _activeJoystick.calibrated
text: _activeJoystick.calibrated ? "Enable joystick input" : "Enable/Disable not allowed (Calibrate First)"
checked: _activeVehicle.joystickEnabled
property bool allowEnableDisable: _activeJoystick.calibrated
onClicked: _activeVehicle.joystickEnabled = checked
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment