Temporary fix - sync current WP after temporary flightplan sequencing
This commit is contained in:
parent
1bbf9e43ac
commit
ebfbb4b037
1 changed files with 10 additions and 0 deletions
|
@ -77,6 +77,7 @@ var flightPlanController = {
|
||||||
me.arrivalIndex[n] = 0; # reset arrival index calculations
|
me.arrivalIndex[n] = 0; # reset arrival index calculations
|
||||||
},
|
},
|
||||||
|
|
||||||
|
oldCurrentWp: 0,
|
||||||
createTemporaryFlightPlan: func(n) {
|
createTemporaryFlightPlan: func(n) {
|
||||||
me.resetFlightplan(n);
|
me.resetFlightplan(n);
|
||||||
me.flightplans[n] = me.flightplans[2].clone();
|
me.flightplans[n] = me.flightplans[2].clone();
|
||||||
|
@ -91,6 +92,9 @@ var flightPlanController = {
|
||||||
canvas_mcdu.myAirways[n].updateTmpy();
|
canvas_mcdu.myAirways[n].updateTmpy();
|
||||||
}
|
}
|
||||||
fmgc.windController.createTemporaryWinds(n);
|
fmgc.windController.createTemporaryWinds(n);
|
||||||
|
|
||||||
|
me.oldCurrentWp = FPLN.currentWP.getValue();
|
||||||
|
|
||||||
me.flightPlanChanged(n);
|
me.flightPlanChanged(n);
|
||||||
},
|
},
|
||||||
|
|
||||||
|
@ -161,6 +165,12 @@ var flightPlanController = {
|
||||||
}
|
}
|
||||||
|
|
||||||
fmgc.windController.destroyTemporaryWinds(n, a);
|
fmgc.windController.destroyTemporaryWinds(n, a);
|
||||||
|
|
||||||
|
# TODO - handle changed wpt order
|
||||||
|
if (FPLN.currentWP.getValue() != me.oldCurrentWp) {
|
||||||
|
FPLN.currentWP.setValue(me.oldCurrentWp);
|
||||||
|
}
|
||||||
|
|
||||||
me.flightPlanChanged(n);
|
me.flightPlanChanged(n);
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue