Restore GPS functionality :)
This commit is contained in:
parent
71bf5b042c
commit
67987829f5
1 changed files with 16 additions and 16 deletions
|
@ -1149,16 +1149,16 @@ var canvas_MCDU_base = {
|
||||||
me["INITA_InitRequest"].hide();
|
me["INITA_InitRequest"].hide();
|
||||||
me["Simple_L4"].setText("----.-");
|
me["Simple_L4"].setText("----.-");
|
||||||
me["Simple_R4"].setText("-----.--");
|
me["Simple_R4"].setText("-----.--");
|
||||||
# if (getprop("autopilot/route-manager/route/wp[0]/latitude-deg") > 0) {
|
if (getprop("FMGC/flightplan[2]/wp[0]/lat") > 0) {
|
||||||
# me["Simple_L4"].setText(sprintf("%6.2fN", getprop("autopilot/route-manager/route/wp[0]/latitude-deg")));
|
me["Simple_L4"].setText(sprintf("%6.2fN", getprop("FMGC/flightplan[2]/wp[0]/lat")));
|
||||||
# } else {
|
} else {
|
||||||
# me["Simple_L4"].setText(sprintf("%6.2fS", getprop("autopilot/route-manager/route/wp[0]/latitude-deg") * -1));
|
me["Simple_L4"].setText(sprintf("%6.2fS", getprop("FMGC/flightplan[2]/wp[0]/lat") * -1));
|
||||||
# }
|
}
|
||||||
# if (getprop("autopilot/route-manager/route/wp[0]/longitude-deg") > 0) {
|
if (getprop("FMGC/flightplan[2]/wp[0]/lon") > 0) {
|
||||||
# me["Simple_R4"].setText(sprintf("%7.2fE", getprop("autopilot/route-manager/route/wp[0]/longitude-deg")));
|
me["Simple_R4"].setText(sprintf("%7.2fE", getprop("FMGC/flightplan[2]/wp[0]/lon")));
|
||||||
# } else {
|
} else {
|
||||||
# me["Simple_R4"].setText(sprintf("%7.2fW", getprop("autopilot/route-manager/route/wp[0]/longitude-deg") * -1));
|
me["Simple_R4"].setText(sprintf("%7.2fW", getprop("FMGC/flightplan[2]/wp[0]/lon") * -1));
|
||||||
# }
|
}
|
||||||
} else {
|
} else {
|
||||||
me["INITA_CoRoute"].show();
|
me["INITA_CoRoute"].show();
|
||||||
me["INITA_FromTo"].show();
|
me["INITA_FromTo"].show();
|
||||||
|
@ -1258,15 +1258,15 @@ var canvas_MCDU_base = {
|
||||||
|
|
||||||
if (toFromSet.getValue() == 1) {
|
if (toFromSet.getValue() == 1) {
|
||||||
#need to convert lat/long format
|
#need to convert lat/long format
|
||||||
if (getprop("autopilot/route-manager/route/wp[0]/latitude-deg") > 0) {
|
if (getprop("FMGC/flightplan[2]/wp[0]/lat") > 0) {
|
||||||
me["Simple_L1"].setText(sprintf("%6.2fN", getprop("autopilot/route-manager/route/wp[0]/latitude-deg")));
|
me["Simple_L1"].setText(sprintf("%6.2fN", getprop("FMGC/flightplan[2]/wp[0]/lat")));
|
||||||
} else {
|
} else {
|
||||||
me["Simple_L1"].setText(sprintf("%6.2fS", getprop("autopilot/route-manager/route/wp[0]/latitude-deg") * -1));
|
me["Simple_L1"].setText(sprintf("%6.2fS", getprop("FMGC/flightplan[2]/wp[0]/lat") * -1));
|
||||||
}
|
}
|
||||||
if (getprop("autopilot/route-manager/route/wp[0]/longitude-deg") > 0) {
|
if (getprop("FMGC/flightplan[2]/wp[0]/lon") > 0) {
|
||||||
me["Simple_R1"].setText(sprintf("%7.2fE", getprop("autopilot/route-manager/route/wp[0]/longitude-deg")));
|
me["Simple_R1"].setText(sprintf("%7.2fE", getprop("FMGC/flightplan[2]/wp[0]/lon")));
|
||||||
} else {
|
} else {
|
||||||
me["Simple_R1"].setText(sprintf("%7.2fW", getprop("autopilot/route-manager/route/wp[0]/longitude-deg") * -1));
|
me["Simple_R1"].setText(sprintf("%7.2fW", getprop("FMGC/flightplan[2]/wp[0]/lon") * -1));
|
||||||
}
|
}
|
||||||
me["Simple_C1"].setText(sprintf("%s", depArpt.getValue()));
|
me["Simple_C1"].setText(sprintf("%s", depArpt.getValue()));
|
||||||
} else {
|
} else {
|
||||||
|
|
Loading…
Reference in a new issue