<Gauge Name="Pky_AutoBrake" Version="1.3">
<copyright>(c)2008 Hiroshi Igami, updated 2009 Jakob Klein</copyright>

<Image Name="posky_Autobrake.bmp"/>

<Size X="80" Y="80"/>

<Element>
  <Position X="16" Y="16"/>
  <Select>
    <Value>(L:PkyAutoBrake, enum)</Value>
    <Case Value="0">
      <Image Name="PKY_AB_SW_OFF.bmp"/>
    </Case>
    <Case Value="1">
      <Image Name="PKY_AB_SW_1.bmp"/>
    </Case>
    <Case Value="2">
      <Image Name="PKY_AB_SW_2.bmp"/>
    </Case>
    <Case Value="3">
      <Image Name="PKY_AB_SW_3.bmp"/>
    </Case>
    <Case Value="4">
      <Image Name="PKY_AB_SW_4.bmp"/>
    </Case>
    <Case Value="-1">
      <Image Name="PKY_AB_SW_RTO.bmp"/>
    </Case>
  </Select>
</Element>
  
<Element>
  <Position X="4" Y="64"/>
  <Visible>(L:PkyAutoBrakeActive, bool)</Visible>
  <Image Name="PKY_AB_Light.bmp"/>
</Element>
  
<Mouse>

  <Area Left="0" Top="0" Width="40" Height="80">
    <Tooltip>Minus</Tooltip>
    <Cursor Type="DownArrow"/>
    <Click>
      (L:PkyAutoBrake,enum) 1 - -1 max
      (&gt;L:PkyAutoBrake,enum) 
    </Click>
  </Area>

  <Area Left="40" Top="0" Width="40" Height="80">
    <Tooltip>Plus</Tooltip>
      <Cursor Type="UpArrow"/>
      <Click>
      (L:PkyAutoBrake,enum) 1 + 4 min
      (&gt;L:PkyAutoBrake,enum) 
      
      </Click>
  </Area>
    
</Mouse>
  
<Keys>
  <On Event="SPOILERS_ARM_TOGGLE">
    (A:SIM ON GROUND, bool) 1 == if{
      (L:PkyAutoBrake,enum) 0 == if{
        -1 (&gt;L:PkyAutoBrake,enum)
      } els{
        0 (&gt;L:PkyAutoBrake,enum)
      }
    } els{
      (L:PkyAutoBrake,enum) 0 == if{
        2 (&gt;L:PkyAutoBrake,enum)
      } els{
        0 (&gt;L:PkyAutoBrake,enum)
      }
    }
    
    (&gt;K:SPOILERS_ARM_OFF)

    <!--
    (A:SPOILERS ARMED, bool) 1 == if{
      (&gt;K:SPOILERS_ARM_OFF)
    }-->
  </On>
</Keys>  
  
</Gauge>
 