From c7314f6dc64c2459eb9590f566b2f7edf8c467bd Mon Sep 17 00:00:00 2001 From: Don Gagne Date: Tue, 27 Dec 2016 13:15:07 -0800 Subject: [PATCH] Correct UAVCAN settings --- src/AutoPilotPlugins/PX4/PowerComponent.qml | 19 +++++++++++-------- 1 file changed, 11 insertions(+), 8 deletions(-) diff --git a/src/AutoPilotPlugins/PX4/PowerComponent.qml b/src/AutoPilotPlugins/PX4/PowerComponent.qml index 1cc89d81c..8ccdc9270 100644 --- a/src/AutoPilotPlugins/PX4/PowerComponent.qml +++ b/src/AutoPilotPlugins/PX4/PowerComponent.qml @@ -398,7 +398,7 @@ SetupPage { QGCCheckBox { id: showUAVCAN text: qsTr("Show UAVCAN Settings") - visible: uavcanEnable !== -1 + checked: uavcanEnable.rawValue != 0 } QGCLabel { @@ -409,24 +409,27 @@ SetupPage { Rectangle { width: parent.width - height: uavCanConfigColumn.height + ScreenTools.defaultFontPixelHeight + height: uavCanConfigRow.height + ScreenTools.defaultFontPixelHeight color: qgcPal.windowShade visible: showUAVCAN.checked - Column { - id: uavCanConfigColumn + Row { + id: uavCanConfigRow anchors.margins: ScreenTools.defaultFontPixelHeight / 2 anchors.left: parent.left anchors.top: parent.top spacing: ScreenTools.defaultFontPixelWidth - FactCheckBox { + FactComboBox { id: uavcanEnabledCheckBox width: ScreenTools.defaultFontPixelWidth * 20 fact: uavcanEnable - checkedValue: 3 - uncheckedValue: 0 - text: qsTr("Enable UAVCAN as the default MAIN output bus (requires autopilot restart)") + indexModel: false + } + + QGCLabel { + anchors.verticalCenter: parent.verticalCenter + text: qsTr("Change required restart") } } } -- 2.22.0