<!DOCTYPE ui:UiBinder SYSTEM "http://dl.google.com/gwt/DTD/xhtml.ent">
<ui:UiBinder xmlns:ui="urn:ui:com.google.gwt.uibinder"
             xmlns:g="urn:import:com.google.gwt.user.client.ui"
             xmlns:b="urn:import:org.gwtbootstrap3.client.ui"
             xmlns:bts="urn:import:org.gwtbootstrap3.extras.toggleswitch.client.ui"
             xmlns:attributes="urn:import:org.dashbuilder.client.widgets.dataset.editor.attributes">

  <ui:with field="i18n" type="org.dashbuilder.client.widgets.resources.i18n.DataSetEditorConstants"/>

  <ui:style>
    .inlineText {
      margin-left: 10px;
    }
    .refreshOnStaleDataRow {
      margin-top: 10px;
    }
  </ui:style>

  <b:Container fluid="true">
    <b:Row>

      <!-- Refresh enabled. -->
      <b:Column size="MD_3">
        <g:HorizontalPanel verticalAlignment="ALIGN_MIDDLE">
          <bts:ToggleSwitch ui:field="refreshEnabled" size="MINI" animate="true"/>
          <g:HTML text="{i18n.refreshEvery}" addStyleNames="{style.inlineText}"/>
        </g:HorizontalPanel>
      </b:Column>

      <!-- Refresh time. -->
      <b:Column size="MD_9">
        <attributes:DataSetDefRefreshIntervalEditor.View ui:field="refreshTimeView"/>
      </b:Column>
      
    </b:Row>
    
    <b:Row addStyleNames="{style.refreshOnStaleDataRow}">
      <!-- Refresh on stale data. -->
      <b:Column offset="MD_3" size="MD_9">
        <g:HorizontalPanel verticalAlignment="ALIGN_MIDDLE">
          <g:IsWidget ui:field="refreshOnStaleDataView"/>
          <g:HTML text="{i18n.refreshOnStaleData}" addStyleNames="{style.inlineText}"/>
        </g:HorizontalPanel>
      </b:Column>
    </b:Row>
    
  </b:Container>
  
</ui:UiBinder>