var $AdfDhtmlSelectManyListboxPeer$$ = $AdfRichUIPeer$$.$createPeerClass$($AdfDhtmlSelectManyPeer$$, "AdfDhtmlSelectManyListboxPeer");
$goog$exportSymbol$$("AdfDhtmlSelectManyListboxPeer", $AdfDhtmlSelectManyListboxPeer$$);
$AdfDhtmlSelectManyListboxPeer$$.$InitSubclass$ = function $$AdfDhtmlSelectManyListboxPeer$$$$InitSubclass$$() {
  $AdfRichUIPeer$$.$addComponentPropertyGetters$(this, AdfUIEditableValue.SUBMITTED_VALUE, AdfUISelectMany.$SELECT_ITEMS$, AdfRichSelectManyListbox.LABEL);
  $AdfRichUIPeer$$.$addComponentPropertyChanges$(this, AdfRichSelectManyListbox.LABEL);
  $AdfRichUIPeer$$.$addComponentEventHandlers$(this, $AdfUIInputEvent$$.$CLICK_EVENT_TYPE$, $AdfUIInputEvent$$.$FOCUS_EVENT_TYPE$, $AdfUIInputEvent$$.$BLUR_EVENT_TYPE$, $AdfUIInputEvent$$.$MOUSE_DOWN_EVENT_TYPE$, $AdfUIInputEvent$$.$KEY_DOWN_EVENT_TYPE$);
  this.$_ALL_ID$ = "all";
  this.$_DISABLED$ = "disabled";
  this.$_TABINDEX$ = "tabIndex"
};
$goog$exportSymbol$$("AdfDhtmlSelectManyListboxPeer.InitSubclass", $AdfDhtmlSelectManyListboxPeer$$.$InitSubclass$);
$AdfDhtmlSelectManyListboxPeer$$.prototype.$HandleComponentMouseDown$ = function $$AdfDhtmlSelectManyListboxPeer$$$$$HandleComponentMouseDown$$($componentEvent$$366$$) {
  var $checkbox$$6$$ = $componentEvent$$366$$.$getNativeEventTarget$();
  "LABEL" == $checkbox$$6$$.tagName ? $checkbox$$6$$ = $AdfDomUtils$$.$getFirstChildElement$($checkbox$$6$$) : "LI" == $checkbox$$6$$.tagName && ($checkbox$$6$$ = $AdfDomUtils$$.$getFirstChildElement$($checkbox$$6$$)) && ($checkbox$$6$$ = $AdfDomUtils$$.$getFirstChildElement$($checkbox$$6$$));
  if($checkbox$$6$$ && "INPUT" == $checkbox$$6$$.tagName && !$checkbox$$6$$.disabled) {
    var $domElement$$399$$ = this.$getDomElement$(), $evt$$131$$ = $componentEvent$$366$$.$getNativeEvent$();
    this.$_setCurrentTabStop$($domElement$$399$$, $checkbox$$6$$, $evt$$131$$.shiftKey);
    $evt$$131$$.shiftKey && $componentEvent$$366$$.cancel()
  }
};
$AdfObject$$.$exportPrototypeSymbol$("AdfDhtmlSelectManyListboxPeer.prototype.HandleComponentMouseDown", {$HandleComponentMouseDown$:$AdfDhtmlSelectManyListboxPeer$$.prototype.$HandleComponentMouseDown$});
$AdfDhtmlSelectManyListboxPeer$$.prototype.$HandleComponentClick$ = function $$AdfDhtmlSelectManyListboxPeer$$$$$HandleComponentClick$$($componentEvent$$367_value$$183$$) {
  $AdfDhtmlSelectManyListboxPeer$$.$superclass$.$HandleComponentClick$.call(this, $componentEvent$$367_value$$183$$);
  var $checkbox$$7$$ = $componentEvent$$367_value$$183$$.$getNativeEventTarget$();
  if(($checkbox$$7$$ = this.$GetCheckboxByEventTarget$($checkbox$$7$$, $componentEvent$$367_value$$183$$)) && "INPUT" == $checkbox$$7$$.tagName) {
    var $isAllBox$$1$$ = $checkbox$$7$$.getAttribute("id"), $component$$1508$$ = this.$getComponent$(), $domElement$$400$$ = this.$getDomElement$();
    $isAllBox$$1$$ == $AdfRichUIPeer$$.$CreateSubId$($component$$1508$$.$getClientId$(), $AdfDhtmlSelectManyPeer$$.$_SELECT_ALL_ID$) ? this.$UpdateAll$($component$$1508$$, $domElement$$400$$, $checkbox$$7$$.checked, $JSCompiler_alias_TRUE$$) : ($componentEvent$$367_value$$183$$.$getNativeEvent$().shiftKey && ($checkbox$$7$$.checked = $JSCompiler_alias_TRUE$$), this.$UpdateSelectedStyle$($checkbox$$7$$), $componentEvent$$367_value$$183$$ = this.$GetComponentSubmittedValue$($component$$1508$$, $domElement$$400$$), 
    this.$Validate$($component$$1508$$, $componentEvent$$367_value$$183$$))
  }
};
$AdfObject$$.$exportPrototypeSymbol$("AdfDhtmlSelectManyListboxPeer.prototype.HandleComponentClick", {$HandleComponentClick$:$AdfDhtmlSelectManyListboxPeer$$.prototype.$HandleComponentClick$});
$AdfDhtmlSelectManyListboxPeer$$.prototype.$Validate$ = function $$AdfDhtmlSelectManyListboxPeer$$$$$Validate$$($component$$1509$$, $submittedValue$$22$$) {
  $AdfDhtmlSelectManyListboxPeer$$.$superclass$.$Validate$.call(this, $component$$1509$$, $submittedValue$$22$$);
  if($component$$1509$$.getRequired()) {
    var $boxes$$6_cb$$4$$ = this.$GetCheckboxes$($component$$1509$$, this.$getDomElement$());
    if($boxes$$6_cb$$4$$ && 1 == $boxes$$6_cb$$4$$.length) {
      var $boxes$$6_cb$$4$$ = $boxes$$6_cb$$4$$[0], $selectAllCheckbox$$3$$ = this.$GetSelectAllCheckbox$($component$$1509$$);
      $selectAllCheckbox$$3$$ != $JSCompiler_alias_NULL$$ && ($selectAllCheckbox$$3$$.checked = $boxes$$6_cb$$4$$.checked, this.$UpdateSelectedStyle$($selectAllCheckbox$$3$$))
    }
  }
};
$AdfObject$$.$exportPrototypeSymbol$("AdfDhtmlSelectManyListboxPeer.prototype.Validate", {$Validate$:$AdfDhtmlSelectManyListboxPeer$$.prototype.$Validate$});
$AdfDhtmlSelectManyListboxPeer$$.prototype.$HandleComponentFocus$ = function $$AdfDhtmlSelectManyListboxPeer$$$$$HandleComponentFocus$$($componentEvent$$368_rootElement$$128_tabStop$$) {
  $AdfDhtmlSelectManyListboxPeer$$.$superclass$.$HandleComponentFocus$.call(this, $componentEvent$$368_rootElement$$128_tabStop$$);
  $componentEvent$$368_rootElement$$128_tabStop$$ = this.$getDomElement$();
  ($componentEvent$$368_rootElement$$128_tabStop$$ = $AdfFocusUtils$$.$getFirstTabStop$($componentEvent$$368_rootElement$$128_tabStop$$)) && !$AdfDomUtils$$.$containsCSSClassName$($componentEvent$$368_rootElement$$128_tabStop$$, $AdfDhtmlSelectManyPeer$$.$HIGHLIGHTED_STYLE$) && $AdfDomUtils$$.$addCSSClassName$($componentEvent$$368_rootElement$$128_tabStop$$.parentNode.parentNode, $AdfDhtmlSelectManyPeer$$.$HIGHLIGHTED_STYLE$)
};
$AdfObject$$.$exportPrototypeSymbol$("AdfDhtmlSelectManyListboxPeer.prototype.HandleComponentFocus", {$HandleComponentFocus$:$AdfDhtmlSelectManyListboxPeer$$.prototype.$HandleComponentFocus$});
$AdfDhtmlSelectManyListboxPeer$$.prototype.$HandleComponentBlur$ = function $$AdfDhtmlSelectManyListboxPeer$$$$$HandleComponentBlur$$() {
  var $rootElement$$129_tabStop$$1$$ = this.$getDomElement$();
  ($rootElement$$129_tabStop$$1$$ = $AdfFocusUtils$$.$getFirstTabStop$($rootElement$$129_tabStop$$1$$)) && $AdfDomUtils$$.$removeCSSClassName$($rootElement$$129_tabStop$$1$$.parentNode.parentNode, $AdfDhtmlSelectManyPeer$$.$HIGHLIGHTED_STYLE$)
};
$AdfObject$$.$exportPrototypeSymbol$("AdfDhtmlSelectManyListboxPeer.prototype.HandleComponentBlur", {$HandleComponentBlur$:$AdfDhtmlSelectManyListboxPeer$$.prototype.$HandleComponentBlur$});
$AdfDhtmlSelectManyListboxPeer$$.prototype.$HandleComponentKeyDown$ = function $$AdfDhtmlSelectManyListboxPeer$$$$$HandleComponentKeyDown$$($componentEvent$$370$$) {
  var $endItem$$1_eventTarget$$60_oldTabStop$$ = $componentEvent$$370$$.$getNativeEventTarget$(), $evt$$133$$ = $componentEvent$$370$$.$getNativeEvent$(), $keyCode$$81$$ = $AdfAgent$$.$AGENT$.$getKeyCode$($evt$$133$$), $component$$1510$$ = $componentEvent$$370$$.getSource(), $domElement$$401$$ = this.$getDomElement$();
  if("INPUT" == $endItem$$1_eventTarget$$60_oldTabStop$$.tagName) {
    switch($keyCode$$81$$) {
      case $AdfKeyStroke$$.$ARROWUP_KEY$:
      ;
      case $AdfKeyStroke$$.$ARROWDOWN_KEY$:
        var $endItem$$1_eventTarget$$60_oldTabStop$$ = $AdfFocusUtils$$.$getFirstTabStop$($domElement$$401$$), $newTabStop$$;
        if(($newTabStop$$ = $keyCode$$81$$ == $AdfKeyStroke$$.$ARROWUP_KEY$ ? this.$GetPreviousItem$($component$$1510$$, $domElement$$401$$, $endItem$$1_eventTarget$$60_oldTabStop$$) : this.$GetNextItem$($component$$1510$$, $domElement$$401$$, $endItem$$1_eventTarget$$60_oldTabStop$$)) && $newTabStop$$ != $endItem$$1_eventTarget$$60_oldTabStop$$) {
          this.$_setCurrentTabStop$($domElement$$401$$, $newTabStop$$, $evt$$133$$.shiftKey), $evt$$133$$.shiftKey && this.$Validate$($component$$1510$$, this.$GetComponentSubmittedValue$($component$$1510$$, $domElement$$401$$)), $newTabStop$$.focus()
        }
        $componentEvent$$370$$.cancel();
        break;
      case $AdfKeyStroke$$.$HOME_KEY$:
      ;
      case $AdfKeyStroke$$.$END_KEY$:
        $evt$$133$$.shiftKey && ($endItem$$1_eventTarget$$60_oldTabStop$$ = $keyCode$$81$$ == $AdfKeyStroke$$.$HOME_KEY$ ? this.$GetNextItem$($component$$1510$$, $domElement$$401$$, $JSCompiler_alias_NULL$$) : this.$GetPreviousItem$($component$$1510$$, $domElement$$401$$, $JSCompiler_alias_NULL$$, $JSCompiler_alias_TRUE$$), this.$_setCurrentTabStop$($domElement$$401$$, $endItem$$1_eventTarget$$60_oldTabStop$$, $JSCompiler_alias_TRUE$$), $endItem$$1_eventTarget$$60_oldTabStop$$.focus(), this.$Validate$($component$$1510$$, 
        this.$GetComponentSubmittedValue$($component$$1510$$, $domElement$$401$$)))
    }
  }
  switch($keyCode$$81$$) {
    case $AdfKeyStroke$$.$A_KEY$:
      $evt$$133$$.ctrlKey && (this.$UpdateAll$($component$$1510$$, $domElement$$401$$, $JSCompiler_alias_TRUE$$, $JSCompiler_alias_TRUE$$), $componentEvent$$370$$.cancel())
  }
};
$AdfObject$$.$exportPrototypeSymbol$("AdfDhtmlSelectManyListboxPeer.prototype.HandleComponentKeyDown", {$HandleComponentKeyDown$:$AdfDhtmlSelectManyListboxPeer$$.prototype.$HandleComponentKeyDown$});
$AdfDhtmlSelectManyListboxPeer$$.prototype.$SetDisplayValue$ = function $$AdfDhtmlSelectManyListboxPeer$$$$$SetDisplayValue$$($component$$1511_selectAllCheckbox$$4$$, $domElement$$402_selectAll$$1$$, $newValue$$121$$) {
  $AdfAssert$$.$assertDomElement$($domElement$$402_selectAll$$1$$);
  $AdfAssert$$.$assertArray$($newValue$$121$$);
  if($component$$1511_selectAllCheckbox$$4$$.getReadOnly()) {
    return $JSCompiler_alias_FALSE$$
  }
  var $boxes$$7$$ = this.$GetCheckboxes$($component$$1511_selectAllCheckbox$$4$$, $domElement$$402_selectAll$$1$$);
  if($boxes$$7$$) {
    $domElement$$402_selectAll$$1$$ = $JSCompiler_alias_TRUE$$;
    for(var $i$$423$$ = 0;$i$$423$$ < $boxes$$7$$.length;$i$$423$$++) {
      var $cb$$5$$ = $boxes$$7$$[$i$$423$$], $index$$138$$ = $AdfCollections$$.indexOf($newValue$$121$$, $cb$$5$$.value);
      $cb$$5$$.checked = 0 <= $index$$138$$;
      this.$UpdateSelectedStyle$($cb$$5$$);
      $cb$$5$$.checked || $cb$$5$$.disabled || ($domElement$$402_selectAll$$1$$ = $JSCompiler_alias_FALSE$$)
    }
    $component$$1511_selectAllCheckbox$$4$$ = this.$GetSelectAllCheckbox$($component$$1511_selectAllCheckbox$$4$$);
    $component$$1511_selectAllCheckbox$$4$$ != $JSCompiler_alias_NULL$$ && ($component$$1511_selectAllCheckbox$$4$$.checked = $domElement$$402_selectAll$$1$$, this.$UpdateSelectedStyle$($component$$1511_selectAllCheckbox$$4$$))
  }
};
$AdfObject$$.$exportPrototypeSymbol$("AdfDhtmlSelectManyListboxPeer.prototype.SetDisplayValue", {$SetDisplayValue$:$AdfDhtmlSelectManyListboxPeer$$.prototype.$SetDisplayValue$});
$AdfDhtmlSelectManyListboxPeer$$.prototype.$GetInlineEditor$ = function $$AdfDhtmlSelectManyListboxPeer$$$$$GetInlineEditor$$() {
  return $AdfDhtmlSimpleLabelEditor$$.$getInlineEditor$()
};
$AdfObject$$.$exportPrototypeSymbol$("AdfDhtmlSelectManyListboxPeer.prototype.GetInlineEditor", {$GetInlineEditor$:$AdfDhtmlSelectManyListboxPeer$$.prototype.$GetInlineEditor$});
$AdfDhtmlSelectManyListboxPeer$$.prototype.$_setCurrentTabStop$ = function $$AdfDhtmlSelectManyListboxPeer$$$$$_setCurrentTabStop$$($rootElement$$130$$, $newTabStop$$1$$, $component$$1512_select$$1$$) {
  var $curTabStop$$ = $AdfFocusUtils$$.$getFirstTabStop$($rootElement$$130$$);
  $curTabStop$$ != $newTabStop$$1$$ && ($component$$1512_select$$1$$ && ($component$$1512_select$$1$$ = this.$getComponent$(), this.$SelectRange$($component$$1512_select$$1$$, $rootElement$$130$$, $curTabStop$$, $newTabStop$$1$$)), $curTabStop$$ && ($curTabStop$$.setAttribute($AdfDhtmlSelectManyListboxPeer$$.$_TABINDEX$, "-1"), $AdfDomUtils$$.$removeCSSClassName$($curTabStop$$.parentNode.parentNode, $AdfDhtmlSelectManyPeer$$.$HIGHLIGHTED_STYLE$)), $newTabStop$$1$$.setAttribute($AdfDhtmlSelectManyListboxPeer$$.$_TABINDEX$, 
  "0"))
};
