diff --git a/src/FlightDisplay/FlightDisplayView.qml b/src/FlightDisplay/FlightDisplayView.qml index dac62fee0f33eefced7b08a49f4a5e5faa1172ab..41668ee9109be9f7c6cdf51695cdf6c70512a1df 100644 --- a/src/FlightDisplay/FlightDisplayView.qml +++ b/src/FlightDisplay/FlightDisplayView.qml @@ -148,7 +148,10 @@ QGCView { } } else { if (promptForMissionRemove && (_missionController.containsItems || _geoFenceController.containsItems || _rallyPointController.containsItems)) { - root.showDialog(missionCompleteDialogComponent, qsTr("Flight Plan complete"), showDialogDefaultWidth, StandardButton.Close) + // ArduPilot has a strange bug which prevents mission clear from working at certain times, so we can't show this dialog + if (!_activeVehicle.apmFirmware) { + root.showDialog(missionCompleteDialogComponent, qsTr("Flight Plan complete"), showDialogDefaultWidth, StandardButton.Close) + } } promptForMissionRemove = false } @@ -168,7 +171,7 @@ QGCView { anchors.fill: parent contentHeight: column.height - Column { + ColumnLayout { id: column anchors.margins: _margins anchors.left: parent.left @@ -176,19 +179,27 @@ QGCView { spacing: ScreenTools.defaultFontPixelHeight QGCLabel { - text: qsTr("%1 Images Taken").arg(_activeVehicle.cameraTriggerPoints.count) - anchors.horizontalCenter: parent.horizontalCenter - visible: _activeVehicle.cameraTriggerPoints.count != 0 + Layout.fillWidth: true + text: qsTr("%1 Images Taken").arg(_activeVehicle.cameraTriggerPoints.count) + horizontalAlignment: Text.AlignHCenter + visible: _activeVehicle.cameraTriggerPoints.count != 0 } QGCButton { - text: qsTr("Remove plan from vehicle") - anchors.horizontalCenter: parent.horizontalCenter + Layout.fillWidth: true + text: qsTr("Remove plan from vehicle") onClicked: { _planMasterController.removeAllFromVehicle() hideDialog() } } + + QGCButton { + Layout.fillWidth: true + text: qsTr("Leave plan on vehicle") + anchors.horizontalCenter: parent.horizontalCenter + onClicked: hideDialog() + } } } }