<?xml version="1.0" encoding="iso-8859-1"?>

<PropertyList>
    <!-- If you put the dialog file in the Aircraft/aircraftname/gui/dialog the dialog box is loaded -->
  <name>flightmode</name>
  <modal type="bool">false</modal>
  <layout>vbox</layout>

  <group>
    <layout>hbox</layout>
    <empty>
      <stretch>1</stretch>
    </empty>

    <text>
      <label>Options</label>
    </text>

    <empty>
      <stretch>1</stretch>
    </empty>

    <button>
      <pref-width>16</pref-width>
      <pref-height>16</pref-height>
      <legend />

      <default>1</default>
      <keynum>27</keynum>
      <border>2</border>
      <binding>
        <command>dialog-close</command>
      </binding>
      <binding>
        <command>dialog-apply</command>
      </binding>
    </button>
  </group>

  <hrule />

  <group>
    <layout>hbox</layout>
    <text><label>TO</label></text>
    <checkbox>
      <property>/instrumentation/flightmode/to</property>
      <live>false</live>
      <binding>
        <command>property-toggle</command>
        <property>/instrumentation/flightmode/to</property>
      </binding>
      <binding>
        <command>nasal</command>
        <script>
          setprop("/instrumentation/flightmode/app",0);
          setprop("/instrumentation/flightmode/nav",0);
          setprop("/instrumentation/flightmode/arm",0);
          mirage2000.flightmode();
          </script>
      </binding>
    </checkbox>
  </group>
  
  <group>
    <layout>hbox</layout>
    <text><label>APP</label></text>
    <checkbox>
      <property>/instrumentation/flightmode/app</property>
      <live>false</live>
      <binding>
        <command>property-toggle</command>
        <property>/instrumentation/flightmode/app</property>
      </binding>
      <binding>
        <command>nasal</command>
        <script>
          setprop("/instrumentation/flightmode/to",0);
          setprop("/instrumentation/flightmode/nav",0);
          setprop("/instrumentation/flightmode/arm",0);
          mirage2000.flightmode();
          </script>
      </binding>
    </checkbox>
  </group>
  
    
  <group>
    <layout>hbox</layout>
    <text><label>NAV</label></text>
    <checkbox>
      <property>/instrumentation/flightmode/nav</property>
      <live>false</live>
      <binding>
        <command>property-toggle</command>
        <property>/instrumentation/flightmode/nav</property>
      </binding>
      <binding>
        <command>nasal</command>
        <script>
          setprop("/instrumentation/flightmode/app",0);
          setprop("/instrumentation/flightmode/to",0);
          setprop("/instrumentation/flightmode/arm",0);          
          mirage2000.flightmode();
          </script>
      </binding>
    </checkbox>
  </group>

  <group>
    <layout>hbox</layout>
    <text><label>ARM</label></text>
    <checkbox>
      <property>/instrumentation/flightmode/arm</property>
      <live>false</live>
      <binding>
        <command>property-toggle</command>
        <property>/instrumentation/flightmode/arm</property>
      </binding>
      <binding>
        <command>nasal</command>
        <script>
          setprop("/instrumentation/flightmode/app",0);
          setprop("/instrumentation/flightmode/nav",0);
          setprop("/instrumentation/flightmode/to",0);          
          mirage2000.flightmode();
          </script>
      </binding>
    </checkbox>
  </group>


</PropertyList>
