<!-- normal header container used on all screens except the match screen -->
<panel>

  <layout class="stick_to_sides_attachment" alignment="all" inset="0" layout_children="true"/>

  <!-- coloured title bar image -->
  <widget class="picture" id="colb" file="interface/header/titlebar" rthr="68">
    <!-- set the colour of the image to the team background colour -->
    <record id="object_property">
      <integer id="get_property" value="tbcl" />
      <integer id="set_property" value="colr" />
    </record>
  </widget>

  <container>
    <layout class="stick_to_sides_attachment" alignment="vertical" inset="0"/>
    <layout class="arrange_horizontal_attachment" layout="0, 300, -1" offset="0" gap="0" />
      <container/>
        <widget class="picture" id="lftB" auto_size="all">
	  <layout class="stick_to_sides_attachment" alignment="vertical" inset="0"/>
	  <record id="object_property">
	    <integer id="get_property" value="mbpc"/>
	    <integer id="set_property" value="file"/>
	  </record>	
        </widget>
      <container/>	
  </container>

  <container>
    <layout class="stick_to_sides_attachment" alignment="vertical" inset="0"/>
    <layout class="arrange_horizontal_attachment" layout="-1, 300, 0" offset="0" gap="0" />
      <container/>
        <widget class="picture" id="rigB" auto_size="all">
	  <layout class="stick_to_sides_attachment" alignment="vertical" inset="0"/>
	  <record id="object_property">
	    <integer id="get_property" value="sbpc"/>
	    <integer id="set_property" value="file"/>
	  </record>	
        </widget>
      <container/>	
  </container>

  <!-- battery indicator, only shows up for laptops -->
  <container>
    <layout class="arrange_horizontal_attachment" alignment="right" gap="0" offset="3"/>
    <layout class="stick_to_sides_attachment" alignment="top" inset="0" layout_children="true" />
    <layout class="stick_to_sides_attachment" alignment="top, right" inset="0"/>

    <layout class="fit_children_attachment" alignment="vertical"/>
    <layout class="fit_children_attachment" alignment="horizontal, fill" offset="3"/>

    <widget class="battery_power_indicator" width="20" height="20"/>
  </container>

  <!-- main logos container -->
  <container id="MnLg">
    <layout class="arrange_horizontal_attachment" layout="107,-1" offset="0" gap="0" />
    <layout class="stick_to_sides_attachment" alignment="vertical" inset="0" layout_children="true"/>

    <!--left sided main logo and quick flicks-->
    <container id="flik">
      <layout class="arrange_horizontal_attachment" layout="-1,22" gap="0" inset="0"/>

      <!-- Primary Logo -->
      <widget class="picture" id="lgtF" scale_picture="true" keep_aspect_ratio="true" image_alignment="centre" >
        <layout class="stick_to_sides_attachment" alignment="vertical" inset="10"/>

        <attachment class="test_setting_attachment" get_setting="show_badges" default_value="true" set_property="hidn">
          <boolean id="value" value="false"/>
        </attachment>

        <!-- tells the picture to listen to the 'main picture' global property being set, and set its own file property from it -->
        <record id="object_property">
          <integer id="get_property" value="mnpc" />
          <integer id="set_property" value="file" />
        </record>
      </widget>

      <container id="trST">
        <layout class="stick_to_sides_attachment" alignment="vertical" inset="0"/>

        <widget class="quick_flick_button" id="flkl" auto_size="all" appearance="button/custom/quickflicks/left/button" cached="true" step="-1">
          <layout class="stick_to_sides_attachment" alignment="left" inset="0"/>
          <layout class="stick_to_sides_attachment" alignment="top" inset="18"/>

          <attachment class="get_global_attachment" get_property="stPQ" set_property="clke"/>
        </widget>

        <widget class="quick_flick_button" id="flkr" auto_size="all" appearance="button/custom/quickflicks/right/button" cached="true" step="1">
          <layout class="stick_to_sides_attachment" alignment="left" inset="0"/>
          <layout class="stick_to_sides_attachment" alignment="top" inset="38"/>

          <attachment class="get_global_attachment" get_property="stNQ" set_property="clke"/>
        </widget>

      </container>

    </container>

    <!-- club/nation/team names -->
    <container>
      <layout class="arrange_horizontal_attachment" alignment="left" offset="0" gap="0"/>
      <layout class="stick_to_sides_attachment" alignment="vertical" inset="18" layout_children="true"/>

      <!--team container stuff-->
      <widget class="button" id="tcon" auto_size="horizontal" appearance="button/team titlebar/club/button" size="10"/>
      <widget class="popup_button" id="tcpo" fixed="true" width="21" appearance="menu/team titlebar/club"/>

      <!--team popup-->
      <widget class="button" id="team" auto_size="horizontal" appearance="button/team titlebar/button" size="10"/>
      <widget class="popup_button" id="tepo" fixed="true" width="21" appearance="menu/team titlebar"/>

      <!--spacer -->
      <container width="5"/>

            <!-- Context Menu -->
      <widget class="popup_button" id="CntM" auto_size="all" appearance="button/custom/quickflicks/right" fixed="true">
        <layout class="stick_to_sides_attachment" alignment="top" inset="32"/>
        <attachment class="get_global_attachment" get_property="lnks" set_property="itms" />
        <attachment class="test_global_attachment" get_property="lnks" set_property="hidn">
          <list id="value">
            <integer value="0" />
          </list>
        </attachment>
      </widget>

      <!--division info-->
      <widget class="text" id="divt" multiline="false" auto_size="all" alignment="left,centre_y">
        <layout class="stick_to_sides_attachment" alignment="top" inset="28"/>
        <record id="object_property">
          <list id="get_properties">
            <record>
              <integer id="get_property" value="subt"/>
              <integer id="set_property" value="text"/>
            </record>
            <record>
              <integer id="get_property" value="ttcl"/>
              <integer id="set_property" value="colr"/>
            </record>
          </list>
        </record>
      </widget>
    </container>

  </container>

</panel>
