Updated the LandingComplexItem recalculation logic to properly handle
waypoint approach items, fixing several issues with heading calculations
and when loading plans, such as the loiter radius being taken into
account despite the "Use loiter to altitude" option being disabled.
Refactored the relevant areas to unify the naming and logic between
waypoint and loiter-based approaches.
This replaces previous GUI-level workarounds (ddd97ad, e0f6a0a) that
partially fixed these heading calculation problems by manipulating the
loiter radius. This commit addresses the root cause instead, so it also
fixes the issues for VTOL landing sequences, where the GUI workarounds
hadn't yet been applied.
Key changes:
- Updated the coordinate recalculation logic to handle waypoint and
loiter approaches as distinct modes, rather than forcing the waypoint
approach through the loiter-based architecture.
- Added _recalcFromApproachModeChange method to properly handle
switching between loiter and waypoint approach items, instead of using
the generic coordinate change handler.
- Renamed "loiter tangent" to "slope start".
- Updated all UI components to remove some explicit approach
item-dependant logic which is no longer needed, and to use the new
naming.
MissionManager: Fix landing approach item handling
Description
Updated the LandingComplexItem recalculation logic to properly handle waypoint approach items, fixing several issues with heading calculations and when loading plans, such as the loiter radius being taken into account despite the "Use loiter to altitude" option being disabled. Refactored the relevant areas to unify the naming and logic between waypoint and loiter-based approaches.
This replaces previous GUI-level workarounds (ddd97ad, e0f6a0a) that partially fixed these heading calculation problems by manipulating the loiter radius. This commit addresses the root cause instead, so it also fixes the issues for VTOL landing sequences, where the GUI workarounds hadn't yet been applied.
Key changes:
Checklist:
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.