<!DOCTYPE template>
<!--
  Description:
    An effect unit widget.
  Variables:
    group: The group for the controls.
    FxRack
    FxUnit
-->
<Template>
  <SetVariable name="FxRack_FxUnit">EffectRack<Variable name="FxRack"/>_EffectUnit<Variable name="FxUnit"/></SetVariable>

  <WidgetGroup>
    <ObjectName>EffectUnit<Variable name="FxUnit"/></ObjectName>
    <Layout>horizontal</Layout>
    <SizePolicy>me,max</SizePolicy>
    <Children>

      <WidgetGroup><!-- No parameters -->
        <ObjectName>EffectRows</ObjectName>
        <SizePolicy>me,min</SizePolicy>
        <Layout>horizontal</Layout>
        <BackPath>style/background_tile.png</BackPath>
        <Children>

          <WidgetGroup><Size>0min,1me</Size></WidgetGroup>

          <WidgetGroup>
            <Layout>horizontal</Layout>
            <SizePolicy>me,min</SizePolicy>
            <MaximumSize>220,-1</MaximumSize>
            <Children>
              <Template src="skin:fx_slot.xml">
                <SetVariable name="FxNum">1</SetVariable>
              </Template>
            </Children>
          </WidgetGroup>

          <WidgetGroup><ObjectName>Spacer58</ObjectName><Size>1f,1me</Size></WidgetGroup>

          <WidgetGroup>
            <Layout>horizontal</Layout>
            <SizePolicy>me,min</SizePolicy>
            <MaximumSize>220,-1</MaximumSize>
            <Children>
              <Template src="skin:fx_slot.xml">
                <SetVariable name="FxNum">2</SetVariable>
              </Template>
            </Children>
          </WidgetGroup>

          <WidgetGroup><ObjectName>Spacer58</ObjectName><Size>1f,1me</Size></WidgetGroup>

          <WidgetGroup>
            <Layout>horizontal</Layout>
            <SizePolicy>me,min</SizePolicy>
            <MaximumSize>220,-1</MaximumSize>
            <Children>
              <Template src="skin:fx_slot.xml">
                <SetVariable name="FxNum">3</SetVariable>
              </Template>
            </Children>
          </WidgetGroup>
        </Children>
      </WidgetGroup><!-- /No parameters -->

      <WidgetGroup><!-- Mix / Super -->
        <ObjectName>EffectUnitControls</ObjectName>
        <Layout>horizontal</Layout>
        <SizePolicy>max,min</SizePolicy>
        <Children>

          <WidgetGroup><Size>5f,</Size></WidgetGroup>

          <WidgetGroup><!-- Super knob, optional -->
            <Layout>horizontal</Layout>
            <SizePolicy>max,max</SizePolicy>
            <Children>
              <SingletonContainer>
                <ObjectName>FxUnit<Variable name="FxUnit"/>_SuperKnob</ObjectName>
              </SingletonContainer>

              <WidgetGroup><Size>5f,</Size></WidgetGroup>
            </Children>
            <Connection>
              <ConfigKey persist="true">[Master],show_superknobs</ConfigKey>
              <BindProperty>visible</BindProperty>
            </Connection>
          </WidgetGroup>

          <SingletonContainer>
            <ObjectName>FxUnit<Variable name="FxUnit"/>_DryWetKnob</ObjectName>
          </SingletonContainer>

          <WidgetGroup><Size>3f,</Size></WidgetGroup>

          <WidgetGroup><!-- Super knob, optional -->
            <Layout>vertical</Layout>
            <SizePolicy>max,me</SizePolicy>
            <Children>
              <WidgetGroup><Size>1min,7f</Size></WidgetGroup>

				      <SingletonContainer>
				        <ObjectName>FxUnit<Variable name="FxUnit"/>_PflButton</ObjectName>
				      </SingletonContainer>
              <WidgetGroup><Size>1min,1me</Size></WidgetGroup>
            </Children>
          </WidgetGroup>

          <WidgetGroup><!-- No parameters -->
            <SizePolicy>me,max</SizePolicy>
            <Layout>vertical</Layout>
            <Children>
              <SingletonContainer>
                <ObjectName>FxUnit<Variable name="FxUnit"/>_ExpandCollapseButton</ObjectName>
              </SingletonContainer>

              <SingletonContainer>
                <ObjectName>FxUnit<Variable name="FxUnit"/>_MixModeButton</ObjectName>
              </SingletonContainer>
            </Children>
          </WidgetGroup>
        </Children>
      </WidgetGroup><!-- /Mix / Super -->

    </Children>
  </WidgetGroup>
</Template>
