|
29 | 29 | property var missionController
|
30 | 30 | property var confirmDialog
|
31 | 31 | property var guidedValueSlider
|
| 32 | + property var fwdFlightGotoMapCircle |
32 | 33 | property var orbitMapCircle
|
33 | 34 |
|
34 | 35 | readonly property string emergencyStopTitle: qsTr("EMERGENCY STOP")
|
|
48 | 49 | readonly property string pauseTitle: qsTr("Pause")
|
49 | 50 | readonly property string mvPauseTitle: qsTr("Pause (MV)")
|
50 | 51 | readonly property string changeAltTitle: qsTr("Change Altitude")
|
| 52 | + readonly property string changeLoiterRadiusTitle: qsTr("Change Loiter Radius") |
51 | 53 | readonly property string changeCruiseSpeedTitle: qsTr("Change Max Ground Speed")
|
52 | 54 | readonly property string changeAirspeedTitle: qsTr("Change Airspeed")
|
53 | 55 | readonly property string orbitTitle: qsTr("Orbit")
|
|
76 | 78 | readonly property string landMessage: qsTr("Land the vehicle at the current position.")
|
77 | 79 | readonly property string rtlMessage: qsTr("Return to the launch position of the vehicle.")
|
78 | 80 | readonly property string changeAltMessage: qsTr("Change the altitude of the vehicle up or down.")
|
| 81 | + readonly property string changeLoiterRadiusMessage: qsTr("Change the forward flight loiter radius.") |
79 | 82 | readonly property string changeCruiseSpeedMessage: qsTr("Change the maximum horizontal cruise speed.")
|
80 |
| - readonly property string changeAirspeedMessage: qsTr("Change the equivalent airspeed setpoint") |
| 83 | + readonly property string changeAirspeedMessage: qsTr("Change the equivalent airspeed setpoint.") |
81 | 84 | readonly property string gotoMessage: qsTr("Move the vehicle to the specified location.")
|
82 | 85 | property string setWaypointMessage: qsTr("Adjust current waypoint to %1.").arg(_actionData)
|
83 | 86 | readonly property string orbitMessage: qsTr("Orbit the vehicle around the specified location.")
|
@@ -123,6 +126,7 @@ Item {
|
123 | 126 | readonly property int actionChangeHeading: 30
|
124 | 127 | readonly property int actionMVArm: 31
|
125 | 128 | readonly property int actionMVDisarm: 32
|
| 129 | + readonly property int actionChangeLoiterRadius: 33 |
126 | 130 |
|
127 | 131 |
|
128 | 132 |
|
@@ -150,6 +154,7 @@ Item {
|
150 | 154 | property bool showContinueMission: _guidedActionsEnabled && _missionAvailable && !_missionActive && _vehicleArmed && _vehicleFlying && (_currentMissionIndex < _missionItemCount - 1)
|
151 | 155 | property bool showPause: _guidedActionsEnabled && _vehicleArmed && _activeVehicle.pauseVehicleSupported && _vehicleFlying && !_vehiclePaused && !_fixedWingOnApproach
|
152 | 156 | property bool showChangeAlt: _guidedActionsEnabled && _vehicleFlying && _activeVehicle.guidedModeSupported && _vehicleArmed && !_missionActive
|
| 157 | + property bool showChangeLoiterRadius: _guidedActionsEnabled && _vehicleFlying && _activeVehicle.guidedModeSupported && _vehicleArmed && !_missionActive && _vehicleInFwdFlight && fwdFlightGotoMapCircle.visible |
153 | 158 | property bool showChangeSpeed: _guidedActionsEnabled && _vehicleFlying && _activeVehicle.guidedModeSupported && _vehicleArmed && !_missionActive && _speedLimitsAvailable
|
154 | 159 | property bool showOrbit: _guidedActionsEnabled && _vehicleFlying && __orbitSupported && !_missionActive && _activeVehicle.homePosition.isValid && !isNaN(_activeVehicle.homePosition.altitude)
|
155 | 160 | property bool showROI: _guidedActionsEnabled && _vehicleFlying && __roiSupported
|
@@ -500,6 +505,13 @@ Item {
|
500 | 505 | confirmDialog.hideTrigger = Qt.binding(function() { return !showChangeAlt })
|
501 | 506 | guidedValueSlider.visible = true
|
502 | 507 | break;
|
| 508 | + case actionChangeLoiterRadius: |
| 509 | + confirmDialog.title = changeLoiterRadiusTitle |
| 510 | + confirmDialog.message = changeLoiterRadiusMessage |
| 511 | + confirmDialog.hideTrigger = Qt.binding(function() { return !showChangeLoiterRadius }) |
| 512 | + confirmDialog.mapIndicator = fwdFlightGotoMapCircle |
| 513 | + fwdFlightGotoMapCircle.startLoiterRadiusEdit() |
| 514 | + break |
503 | 515 | case actionGoto:
|
504 | 516 | confirmDialog.title = gotoTitle
|
505 | 517 | confirmDialog.message = gotoMessage
|
@@ -649,6 +661,12 @@ Item {
|
649 | 661 | var altitudeChangeInMeters = valueInMeters - _activeVehicle.altitudeRelative.rawValue
|
650 | 662 | _activeVehicle.guidedModeChangeAltitude(altitudeChangeInMeters, false /* pauseVehicle */)
|
651 | 663 | break
|
| 664 | + case actionChangeLoiterRadius: |
| 665 | + _activeVehicle.guidedModeGotoLocation( |
| 666 | + fwdFlightGotoMapCircle.coordinate, |
| 667 | + fwdFlightGotoMapCircle.radius.rawValue |
| 668 | + ) |
| 669 | + break |
652 | 670 | case actionGoto:
|
653 | 671 | _activeVehicle.guidedModeGotoLocation(
|
654 | 672 | actionData,
|
|
0 commit comments