<Gauge Name="B-5C_Autopilot" Version="1.0">
<Image Name="B5C_Background.bmp"/>
<Element>
<Position X="214" Y="339" />
<Image Name="Gear_AmberLight_On.bmp" ImageSizes="20,20"/>
</Element>
<Element>
<!-- Autopilot OFF -->
<Element>
<Position X="23" Y="47"/> <!--x=68 Y=96 -->
<Image Name="Off Button.bmp" Bright="Yes"/>
</Element>
<!-- ======================= Man Hold Switch =================== -->
<Element>
<Position X="95" Y="47"/>
<Image Name="MAN Button.bmp" Bright="yes"/>
</Element>
<!-- ======================= Hdg Hold Switch =================== -->
<Element>
<Position X="165" Y="47"/>
<Image Name="HDG Button.bmp" Bright="yes"/>
</Element>
<!-- ======================= Nav Hold Switch =================== -->
<Element>
<Position X="237" Y="47"/>
<Image Name="CAP Button.bmp" Bright="Yes"/>
</Element>
<!-- ==================== Localizer Hold Switch ============== -->
<Element>
<Position X="385" Y="47"/>
<Image Name="LOC Button.bmp" Bright="Yes"/>
</Element>
<!-- ===================== Approach Hold Switch ================ -->
<Element>
<Position X="312" Y="47"/>
<Image Name="TRK Button.bmp" Bright="Yes"/>
</Element>
<!-- ======================= Alt Hold Switch =================== -->
<Element>
<Position X="350" Y="188"/>
<Image Name="ALT Button.bmp" Bright="Yes"/>
</Element>
<!-- ======================= Turn Knob A =================== -->
<Element>
<Visible> (L:Turn Knob Position,number) -1 == </Visible>
<Position X="45" Y="190"/>
<Image Name="Turn Knob left.bmp" />
</Element>
<Element>
<Visible> (L:Turn Knob Position,number) 0 == </Visible>
<Position X="40" Y="185"/>
<Image Name="Turn Knob up.bmp" />
</Element>
<Element>
<Visible> (L:Turn Knob Position,number) 1 == </Visible>
<Position X="40" Y="200"/>
<Image Name="Turn Knob right.bmp" />
</Element>
<!-- ======================= Turn Knob B =================== -->
<!--
<Element>
<Position X="85" Y="250"/>
<Image Name="Turn Knob up.bmp" PointsTo="East">\n
<Axis X="50" Y="66"/>
</Image>
<Rotate>
<Value Minimum="-1" Maximum="+1">(L:Turn Knob Position,number) </Value>
<Nonlinearity>
<Item Value="-1" Degrees="290"/>
<Item Value="0" Degrees="0"/>
<Item Value="+1" Degrees="70"/>
</Nonlinearity>
</Rotate>
</Element>
-->
</Element>
<Mouse>
<!-- =========================== Mouse Stuff ========================= -->
<!-- AP on/off button -->
<Area Left="36" Top="48" Right="91" Bottom="147">
<Tooltip ID="TOOLTIPTEXT_AUTOPILOT_MASTER"/>
<Cursor Type="Hand"/>
<Click>(A:Autopilot master, bool) if{
(>K:AP_HDG_HOLD_OFF)
(>K:AP_ALT_HOLD_OFF)
(>K:AP_NAV1_HOLD_OFF)
(>K:AUTOPILOT_OFF) }
els{ (>K:AUTOPILOT_ON) }
</Click>
</Area>
<!-- MAN button -->
<Area Left="102" Top="48" Right="166" Bottom="147">
<Tooltip ID="TOOLTIPTEXT_MAN"/>
<Cursor Type="Hand"/>
<Click>
</Click>
</Area>
<!-- Heading button -->
<Area Left="173" Top="48" Right="236" Bottom="147">
<Tooltip>Heading hold, press 2 secs to sync </Tooltip>
<Cursor Type="Hand"/>
<Click Kind="LeftSingle+LeftRelease" Repeat = "no" >
(M:Event) 'LeftSingle' scmp 0 == if{
(P:Local time, seconds) 1 + (>G:Var3) }
(M:Event) 'LeftRelease' scmp 0 == if{
(P:Local time, seconds) (G:Var3) > if{ (>K:AP_HDG_HOLD)
(A:AUTOPILOT HEADING LOCK,bool) if{ (>K:AP_HDG_HOLD) } }
els{ (A:AUTOPILOT HEADING LOCK,bool) if{
(>K:AP_HDG_HOLD_OFF) } els{
(>K:AP_HDG_HOLD_ON)
(>K:AP_WING_LEVELER_OFF)
(>K:AUTOPILOT_ON) }
0 (>G:Var3) }
</Click>
</Area>
<!-- Localizer button -->
<Area Left="386" Top="48" Right="447" Bottom="147">
<Tooltip ID="TOOLTIPTEXT_AUTOPILOT_LOC_HOLD"/>
<Cursor Type="Hand"/>
<Click> (A:Autopilot localizer hold, bool) if{
(>K:AP_LOC_HOLD_OFF) (>K:AP_APR_HOLD_OFF) }
els{
(>K:AP__HOLD_ON) }
</Click>
</Area>
<!-- Altitude button -->
<Area Left="359" Top="199" Right="422" Bottom="297">
<Tooltip>Altitude hold, press 2 secs to sync </Tooltip>
<Cursor Type="Hand"/>
<Click Kind="LeftSingle+LeftRelease" Repeat = "no" >
(M:Event) 'LeftSingle' scmp 0 == if{
(P:Local time, seconds) 1 + (>G:Var3) }
(M:Event) 'LeftRelease' scmp 0 == if{
(P:Local time, seconds) (G:Var3) > if{ (>K:AP_ALT_HOLD)
(A:AUTOPILOT ALTITUDE LOCK,bool) if{ (>K:AP_ALT_HOLD) } }
els{ (>K:AP_PANEL_ALTITUDE_HOLD) }
0 (>G:Var3) }
</Click>
</Area>
<!-- Nav1 button ASSUMED as TRK Button-->
<Area Left="314" Top="48" Right="378" Bottom="147">
<Tooltip>Nav1 Hold (%((A:AUTOPILOT NAV1 LOCK,bool))%{if}on%{else}off%{end}) </Tooltip>
<Cursor Type="Hand"/>
<Click> (A:AUTOPILOT NAV1 LOCK,bool) if{
(>K:AP_NAV1_HOLD_OFF) } els{
(>K:AP_NAV1_HOLD_ON) }
</Click>
</Area>
<!-- Approach button ASSUMED as CAP Button -->
<Area Left="242" Top="48" Right="305" Bottom="147">
<Tooltip ID="TOOLTIPTEXT_AUTOPILOT_APP_HOLD"/>
<Cursor Type="Hand"/>
<Click> (A:Autopilot approach hold, bool) if{
(>K:AP_APR_HOLD_OFF) } els{
(>K:AP_APR_HOLD_ON) (>K:AUTOPILOT_ON) }
</Click>
</Area>
<!-- Turn button -->
<Area Left="30" Top="225" Right="140" Bottom="335">
<Cursor Type="Hand"/>
<Click Kind="WheelUp+WheelDown">
(M:Event) 'WheelUp' scmp 0 ==
if{ (L:Turn Knob Position,number) 1 <
if{ (L:Turn Knob Position,number) ++ (>L:Turn Knob Position,number) } }
(M:Event) 'WheelDown' scmp 0 ==
if{ (L:Turn Knob Position,number) -1 >
if{ (L:Turn Knob Position,number) -- (>L:Turn Knob Position,number) } }
(L:Turn Knob Position,number) -1 == if{ +10000 (>K:AILERON_SET) }
(L:Turn Knob Position,number) 0 == if{ 0 (>K:AILERON_SET) }
(L:Turn Knob Position,number) +1 == if{ -10000 (>K:AILERON_SET) }
</Click>
</Area>
</Mouse>
</Gauge>