Route-manager: UI for cruise and alternate
Revise the UI for specifying cruise now the route-manager properties are hooked up.
This commit is contained in:
parent
0ad592783a
commit
4320f8403a
1 changed files with 112 additions and 18 deletions
|
@ -33,6 +33,11 @@ command interface /autopilot/route-manager/input:
|
||||||
var dep = routem.getNode("departure", 1);
|
var dep = routem.getNode("departure", 1);
|
||||||
var dest = routem.getNode("destination", 1);
|
var dest = routem.getNode("destination", 1);
|
||||||
|
|
||||||
|
var isMach = dlg.getNode("cruise-is-mach", 1);
|
||||||
|
isMach.setBoolValue(routem.getNode('cruise/mach').getValue() > 0.0);
|
||||||
|
var isFL = dlg.getNode("cruise-is-flight-level", 1);
|
||||||
|
isFL.setBoolValue(routem.getNode('cruise/flight-level').getValue() > 0);
|
||||||
|
|
||||||
var sel_index = func {
|
var sel_index = func {
|
||||||
return int(selection.getValue());
|
return int(selection.getValue());
|
||||||
}
|
}
|
||||||
|
@ -252,8 +257,6 @@ command interface /autopilot/route-manager/input:
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
# we're on the ground, find the nearest airport to start from
|
# we're on the ground, find the nearest airport to start from
|
||||||
if (fp.departure == nil) {
|
if (fp.departure == nil) {
|
||||||
var apts = findAirportsWithinRange(25.0);
|
var apts = findAirportsWithinRange(25.0);
|
||||||
|
@ -412,7 +415,11 @@ command interface /autopilot/route-manager/input:
|
||||||
</binding>
|
</binding>
|
||||||
<binding>
|
<binding>
|
||||||
<command>nasal</command>
|
<command>nasal</command>
|
||||||
<script>updateRunways();</script>
|
<script>
|
||||||
|
updateRunways();
|
||||||
|
updateSTARs();
|
||||||
|
updateApproaches();
|
||||||
|
</script>
|
||||||
</binding>
|
</binding>
|
||||||
</input>
|
</input>
|
||||||
<text>
|
<text>
|
||||||
|
@ -498,36 +505,56 @@ command interface /autopilot/route-manager/input:
|
||||||
<object-name>star</object-name>
|
<object-name>star</object-name>
|
||||||
</binding>
|
</binding>
|
||||||
</combo>
|
</combo>
|
||||||
</group>
|
|
||||||
<!--
|
|
||||||
<group>
|
|
||||||
<layout>hbox</layout>
|
|
||||||
<text>
|
<text>
|
||||||
|
<row>2</row>
|
||||||
|
<col>0</col>
|
||||||
|
<halign>right</halign>
|
||||||
<label>Alternate:</label>
|
<label>Alternate:</label>
|
||||||
<pref-width>80</pref-width>
|
|
||||||
</text>
|
</text>
|
||||||
<input>
|
<input>
|
||||||
<name>alt-airport</name>
|
<row>2</row>
|
||||||
<halign>fill</halign>
|
<col>1</col>
|
||||||
<stretch>true</stretch>
|
<halign>left</halign>
|
||||||
<pref-width>150</pref-width>
|
<name>alternate-airport</name>
|
||||||
|
<pref-width>70</pref-width>
|
||||||
<property>/autopilot/route-manager/alternate/airport</property>
|
<property>/autopilot/route-manager/alternate/airport</property>
|
||||||
|
<live>true</live>
|
||||||
|
<binding>
|
||||||
|
<command>dialog-apply</command>
|
||||||
|
<object-name>alternate-airport</object-name>
|
||||||
|
</binding>
|
||||||
</input>
|
</input>
|
||||||
|
|
||||||
|
<text>
|
||||||
|
<row>2</row>
|
||||||
|
<col>2</col>
|
||||||
|
<format>%s</format>
|
||||||
|
<property>/autopilot/route-manager/alternate/name</property>
|
||||||
|
<live>true</live>
|
||||||
|
<stretch>true</stretch>
|
||||||
|
<halign>fill</halign>
|
||||||
|
</text>
|
||||||
</group>
|
</group>
|
||||||
-->
|
|
||||||
<group>
|
<group>
|
||||||
<layout>hbox</layout>
|
<layout>table</layout>
|
||||||
<text>
|
<text>
|
||||||
<halign>right</halign>
|
<halign>right</halign>
|
||||||
<label> Cruise Speed (kts):</label>
|
<label>Cruise Speed:</label>
|
||||||
|
<col>0</col>
|
||||||
</text>
|
</text>
|
||||||
<input>
|
<input>
|
||||||
<name>cruise-speed</name>
|
<name>cruise-speed</name>
|
||||||
<live>true</live>
|
<live>true</live>
|
||||||
|
<label>(kts)</label>
|
||||||
<halign>left</halign>
|
<halign>left</halign>
|
||||||
<stretch>true</stretch>
|
<pref-width>50</pref-width>
|
||||||
<pref-width>100</pref-width>
|
<col>1</col>
|
||||||
|
<visible>
|
||||||
|
<not><property>/sim/gui/dialogs/route-manager/cruise-is-mach</property></not>
|
||||||
|
</visible>
|
||||||
|
|
||||||
<property>/autopilot/route-manager/cruise/speed-kts</property>
|
<property>/autopilot/route-manager/cruise/speed-kts</property>
|
||||||
<binding>
|
<binding>
|
||||||
<command>dialog-apply</command>
|
<command>dialog-apply</command>
|
||||||
|
@ -535,13 +562,45 @@ command interface /autopilot/route-manager/input:
|
||||||
</binding>
|
</binding>
|
||||||
</input>
|
</input>
|
||||||
|
|
||||||
|
<input>
|
||||||
|
<name>cruise-speed-mach</name>
|
||||||
|
<live>true</live>
|
||||||
|
<label>(M)</label>
|
||||||
|
<halign>left</halign>
|
||||||
|
<pref-width>50</pref-width>
|
||||||
|
<property>/autopilot/route-manager/cruise/mach</property>
|
||||||
|
<binding>
|
||||||
|
<command>dialog-apply</command>
|
||||||
|
<object-name>cruise-speed-mach</object-name>
|
||||||
|
</binding>
|
||||||
|
<visible>
|
||||||
|
<property>/sim/gui/dialogs/route-manager/cruise-is-mach</property>
|
||||||
|
</visible>
|
||||||
|
<col>1</col>
|
||||||
|
</input>
|
||||||
|
|
||||||
|
<checkbox>
|
||||||
|
<name>cruise-speed-type-check</name>
|
||||||
|
<halign>left</halign>
|
||||||
|
<label>use Mach</label>
|
||||||
|
<property>/sim/gui/dialogs/route-manager/cruise-is-mach</property>
|
||||||
|
<binding>
|
||||||
|
<command>dialog-apply</command>
|
||||||
|
<object-name>cruise-speed-type-check</object-name>
|
||||||
|
</binding>
|
||||||
|
<col>2</col>
|
||||||
|
</checkbox>
|
||||||
|
|
||||||
|
|
||||||
<text>
|
<text>
|
||||||
<label>Cruise Altitude (ft/FL):</label>
|
<label>Cruise Altitude:</label>
|
||||||
<halign>right</halign>
|
<halign>right</halign>
|
||||||
|
<col>3</col>
|
||||||
</text>
|
</text>
|
||||||
<input>
|
<input>
|
||||||
<name>cruise-alt</name>
|
<name>cruise-alt</name>
|
||||||
<live>true</live>
|
<live>true</live>
|
||||||
|
<label>(ft)</label>
|
||||||
<halign>left</halign>
|
<halign>left</halign>
|
||||||
<stretch>true</stretch>
|
<stretch>true</stretch>
|
||||||
<pref-width>100</pref-width>
|
<pref-width>100</pref-width>
|
||||||
|
@ -550,7 +609,42 @@ command interface /autopilot/route-manager/input:
|
||||||
<command>dialog-apply</command>
|
<command>dialog-apply</command>
|
||||||
<object-name>cruise-alt</object-name>
|
<object-name>cruise-alt</object-name>
|
||||||
</binding>
|
</binding>
|
||||||
|
<visible>
|
||||||
|
<not><property>/sim/gui/dialogs/route-manager/cruise-is-flight-level</property></not>
|
||||||
|
</visible>
|
||||||
|
<col>4</col>
|
||||||
</input>
|
</input>
|
||||||
|
|
||||||
|
<input>
|
||||||
|
<name>cruise-alt-fl</name>
|
||||||
|
<live>true</live>
|
||||||
|
<label>(FL)</label>
|
||||||
|
<halign>left</halign>
|
||||||
|
<stretch>true</stretch>
|
||||||
|
<pref-width>100</pref-width>
|
||||||
|
<property>/autopilot/route-manager/cruise/flight-level</property>
|
||||||
|
<binding>
|
||||||
|
<command>dialog-apply</command>
|
||||||
|
<object-name>cruise-alt-fl</object-name>
|
||||||
|
</binding>
|
||||||
|
<visible>
|
||||||
|
<property>/sim/gui/dialogs/route-manager/cruise-is-flight-level</property>
|
||||||
|
</visible>
|
||||||
|
<col>4</col>
|
||||||
|
</input>
|
||||||
|
|
||||||
|
<checkbox>
|
||||||
|
<name>cruise-alt-type-check</name>
|
||||||
|
<halign>left</halign>
|
||||||
|
<label>use Flight-level</label>
|
||||||
|
<property>/sim/gui/dialogs/route-manager/cruise-is-flight-level</property>
|
||||||
|
<binding>
|
||||||
|
<command>dialog-apply</command>
|
||||||
|
<object-name>cruise-alt-type-check</object-name>
|
||||||
|
</binding>
|
||||||
|
<col>5</col>
|
||||||
|
</checkbox>
|
||||||
|
|
||||||
</group>
|
</group>
|
||||||
|
|
||||||
<hrule/>
|
<hrule/>
|
||||||
|
|
Loading…
Add table
Reference in a new issue