mirror of
https://github.com/dcs-liberation/dcs_liberation.git
synced 2025-11-10 14:22:26 +00:00
Don't send the selected flight plan to the back.
We want the selected flight plan to show on top of all the other flight plans, and because we can't properly z-order with the other elements of the map (see the code comment), this is probably the best we can do. This means that the selected flight will be drawn on top of the front line again, and will in some cases intercept mouse clicks meant for the front line, but it's much less of a problem than when all the paths were drawn on top. Fixes https://github.com/dcs-liberation/dcs_liberation/issues/3305.
This commit is contained in:
parent
167cea08f6
commit
ef69275f34
@ -46,7 +46,9 @@ function FlightPlanPath(props: FlightPlanProps) {
|
|||||||
// behind everything than was added before them. Anything added after always
|
// behind everything than was added before them. Anything added after always
|
||||||
// goes on top.
|
// goes on top.
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
|
if (!props.selected) {
|
||||||
polylineRef.current?.bringToBack();
|
polylineRef.current?.bringToBack();
|
||||||
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
if (waypoints == null) {
|
if (waypoints == null) {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user