AdfRichUIPeer.createPeerClass(AdfDhtmlSelectManyPeer,"AdfDhtmlSelectManyShuttleBasePeer");
AdfDhtmlSelectManyShuttleBasePeer.InitSubclass=function(){AdfRichUIPeer.addComponentEventHandlers(this,AdfUIInputEvent.CLICK_EVENT_TYPE,AdfUIInputEvent.DOUBLE_CLICK_EVENT_TYPE,AdfUIInputEvent.FOCUS_EVENT_TYPE,AdfUIInputEvent.KEY_DOWN_EVENT_TYPE);AdfRichUIPeer.addComponentPropertyGetters(this,AdfUIEditableValue.SUBMITTED_VALUE,AdfUISelectMany.SELECT_ITEMS);AdfObject.ensureClassInitialization(AdfRichSelectManyShuttle);AdfRichUIPeer.addComponentPropertyChanges(this,AdfRichSelectManyShuttle.LABEL);AdfRichUIPeer.addComponentPropertyChanges(this,
AdfRichSelectOrderShuttle.SELECTION);this._BUTCON_KEYS={};this._MOVE_ID_ATTR_NAME="_adfMove";this._BUTCON_KEYS[this._MOVE_ID_ATTR_NAME]="move";this._MOVEALL_ID_ATTR_NAME="_adfMoveall";this._BUTCON_KEYS[this._MOVEALL_ID_ATTR_NAME]="moveall";this._REMOVE_ID_ATTR_NAME="_adfRemove";this._BUTCON_KEYS[this._REMOVE_ID_ATTR_NAME]="remove";this._REMOVEALL_ID_ATTR_NAME="_adfRemoveall";this._BUTCON_KEYS[this._REMOVEALL_ID_ATTR_NAME]="removeall";this._TOP_ID_ATTR_NAME="_adfTop";this._BUTCON_KEYS[this._TOP_ID_ATTR_NAME]=
"move-top";this._UP_ID_ATTR_NAME="_adfUp";this._BUTCON_KEYS[this._UP_ID_ATTR_NAME]="move-up";this._DOWN_ID_ATTR_NAME="_adfDown";this._BUTCON_KEYS[this._DOWN_ID_ATTR_NAME]="move-down";this._BOTTOM_ID_ATTR_NAME="_adfBottom";this._BUTCON_KEYS[this._BOTTOM_ID_ATTR_NAME]="move-bottom";this._DISABLED_STYLE_CLASS="p_AFDisabled";this._TABINDEX="tabIndex";this._HREF="href";this._ONCLICK="onclick";this._RETURN_FALSE="return false;";this._MOVE_ID="move";this._MOVEALL_ID="moveall";this._REMOVE_ID="remove";this._REMOVEALL_ID=
"removeall";this._TOP_ID="move-top";this._UP_ID="move-up";this._DOWN_ID="move-down";this._BOTTOM_ID="move-bottom";this._LAZY_ATTR="_adfLazy";this._SELECT_VALUES="_adfSelectValues";this._LEAD_ALL_ID="leadAllId";this._LEAD_DESC="ldDesc";this._TRAIL_DESC="trDesc";this._LEAD_UL="leadUl";this._TRAIL_UL="trailUl";this._TRAIL_ITEMS="trailItems";this._REORDER_DIV="reorderDiv";this._MOVE_DIV="moveDiv";this._LEAD_UL_ID_EXPANDO="_adfLeadULId";this._TRAIL_UL_ID_EXPANDO="_adfTrailULId";this._TRAIL_ITEMS_ID_EXPANDO=
"_adfTrailItems";this._REORDER_DIV_ID_EXPANDO="_adfReorderDivId";this._MOVE_DIV_ID_EXPANDO="_adfMoveDivId"};
AdfDhtmlSelectManyShuttleBasePeer.prototype.LazyInitialize=function(a,b){var d=a.getClientId(),e=AdfAgent.AGENT,f=AdfRichUIPeer.CreateSubId(d,AdfDhtmlSelectManyShuttleBasePeer._TRAIL_ITEMS);b.setAttribute(AdfDhtmlSelectManyShuttleBasePeer._TRAIL_ITEMS_ID_EXPANDO,f);AdfDhtmlSelectManyShuttleBasePeer.superclass.LazyInitialize.call(this,a,b);var f=AdfRichUIPeer.CreateSubId(d,AdfDhtmlSelectManyShuttleBasePeer._LEAD_UL),g=AdfRichUIPeer.CreateSubId(d,AdfDhtmlSelectManyShuttleBasePeer._TRAIL_UL),h=AdfRichUIPeer.CreateSubId(d,
AdfDhtmlSelectManyShuttleBasePeer._REORDER_DIV),d=AdfRichUIPeer.CreateSubId(d,AdfDhtmlSelectManyShuttleBasePeer._MOVE_DIV);b.setAttribute(AdfDhtmlSelectManyShuttleBasePeer._LEAD_UL_ID_EXPANDO,f);b.setAttribute(AdfDhtmlSelectManyShuttleBasePeer._TRAIL_UL_ID_EXPANDO,g);b.setAttribute(AdfDhtmlSelectManyShuttleBasePeer._REORDER_DIV_ID_EXPANDO,h);b.setAttribute(AdfDhtmlSelectManyShuttleBasePeer._MOVE_DIV_ID_EXPANDO,d);this._initLazyLoad(b);1!=a.getReadOnly()&&b.setAttribute(AdfDhtmlSelectManyShuttleBasePeer._SELECT_VALUES,
this._saveValuesOnElement(b));e.getPlatform()==AdfAgent.IE_PLATFORM&&(d=this._getContainer(null,AdfDhtmlSelectManyShuttleBasePeer._LEAD_UL_ID_EXPANDO),f=this._getContainer(null,AdfDhtmlSelectManyShuttleBasePeer._TRAIL_UL_ID_EXPANDO),d&&e.disableUserSelect(d),f&&e.disableUserSelect(f));if(e.getPlatform()==AdfAgent.IE_PLATFORM||e.getPlatform()==AdfAgent.GECKO_PLATFORM)this._updateSizeAndPositionAriaAttributes(AdfDhtmlSelectManyShuttleBasePeer._LEAD_UL_ID_EXPANDO),this._updateSizeAndPositionAriaAttributes(AdfDhtmlSelectManyShuttleBasePeer._TRAIL_UL_ID_EXPANDO)};
AdfDhtmlSelectManyShuttleBasePeer.prototype.Focus=function(){var a=this.getDomElement(),b=this.getComponent(),a=AdfDhtmlEditableValuePeer.getContentNode(b,a),a=AdfFocusUtils.getFirstTabStop(a);null!=a&&AdfFocusUtils.focusElement(a)};
AdfDhtmlSelectManyShuttleBasePeer.prototype.HandleComponentFocus=function(a){var b=a.getNativeEventTarget();AdfDhtmlSelectManyShuttleBasePeer.superclass.HandleComponentFocus.call(this,a);"LI"==b.tagName&&(a=b.getElementsByTagName("input")[0],"none"!=AdfAgent.AGENT.getComputedStyle(a).display&&(b=this._getParentContainer(this.getDomElement(),a),this._setCurrentTabStop(b,a,null),a.focus()))};
AdfDhtmlSelectManyShuttleBasePeer.prototype._handleComponentMouseDownOrTouchStart=function(a,b){var d=a.getNativeEventTarget();if("LABEL"==d.tagName||"LI"==d.tagName)d=d.getElementsByTagName("input")[0];if(d&&"INPUT"==d.tagName&&!d.disabled){var e=this.getDomElement(),e=this._getParentContainer(e,d),f=a.getNativeEvent();this._setCurrentTabStop(e,d,f.shiftKey);b||a.cancel()}};
AdfDhtmlSelectManyShuttleBasePeer.prototype.HandleComponentKeyDown=function(a){var b=a.getNativeEventTarget();if("INPUT"==b.tagName||"LI"==b.tagName){var d=a.getNativeEvent(),e=AdfAgent.AGENT.getKeyCode(d),f=this.getDomElement(),g=this._getParentContainer(f,b),h;-1!=g.id.indexOf(AdfDhtmlSelectManyShuttleBasePeer._LEAD_UL)?h=AdfDhtmlSelectManyShuttleBasePeer._LEAD_UL_ID_EXPANDO:-1!=g.id.indexOf(AdfDhtmlSelectManyShuttleBasePeer._TRAIL_UL)&&(h=AdfDhtmlSelectManyShuttleBasePeer._TRAIL_UL_ID_EXPANDO);
switch(e){case AdfKeyStroke.ARROWUP_KEY:case AdfKeyStroke.ARROWDOWN_KEY:var k=AdfFocusUtils.getFirstTabStop(g);"LI"==k.tagName&&(k=k.getElementsByTagName("input")[0]);(e=e==AdfKeyStroke.ARROWUP_KEY?this.GetPreviousItem(null,f,k,!0,h):this.GetNextItem(null,f,k,h))&&e!=k&&(this._setCurrentTabStop(g,e,d.shiftKey),"none"==AdfAgent.AGENT.getComputedStyle(e).display?e.parentNode.parentNode.focus():e.focus(),d.shiftKey&&this._updateClickedCheckbox(b,a));a.cancel();break;case AdfKeyStroke.SPACE_KEY:"LI"==
b.tagName&&(this._updateClickedCheckbox(b,a),a.cancel())}}else if("A"==b.tagName)switch(d=a.getNativeEvent(),e=AdfAgent.AGENT.getKeyCode(d),f=this.getDomElement(),g=this._getButconParentContainer(f,b),e){case AdfKeyStroke.ARROWUP_KEY:case AdfKeyStroke.ARROWDOWN_KEY:case AdfKeyStroke.ARROWLEFT_KEY:case AdfKeyStroke.ARROWRIGHT_KEY:var k=AdfFocusUtils.getFirstTabStop(g),l,m=AdfKeyStroke.ARROWUP_KEY,n=AdfKeyStroke.ARROWDOWN_KEY,q=!1;1<b.parentNode.parentNode.parentNode.getElementsByTagName("TD").length&&
-1==g.id.indexOf(AdfDhtmlSelectManyShuttleBasePeer._REORDER_DIV)&&(AdfPage.PAGE.getLocaleContext().isRightToLeft()?(m=AdfKeyStroke.ARROWRIGHT_KEY,n=AdfKeyStroke.ARROWLEFT_KEY):(m=AdfKeyStroke.ARROWLEFT_KEY,n=AdfKeyStroke.ARROWRIGHT_KEY));e==m?(-1!=g.id.indexOf(AdfDhtmlSelectManyShuttleBasePeer._REORDER_DIV)?h=AdfDhtmlSelectManyShuttleBasePeer._REORDER_DIV_ID_EXPANDO:-1!=g.id.indexOf(AdfDhtmlSelectManyShuttleBasePeer._MOVE_DIV)&&(h=AdfDhtmlSelectManyShuttleBasePeer._MOVE_DIV_ID_EXPANDO),l=this._getPreviousButcon(f,
h,k),q=!0):e==n&&(-1!=g.id.indexOf(AdfDhtmlSelectManyShuttleBasePeer._REORDER_DIV)?h=AdfDhtmlSelectManyShuttleBasePeer._REORDER_DIV_ID_EXPANDO:-1!=g.id.indexOf(AdfDhtmlSelectManyShuttleBasePeer._MOVE_DIV)&&(h=AdfDhtmlSelectManyShuttleBasePeer._MOVE_DIV_ID_EXPANDO),l=this._getNextButcon(f,h,k),q=!0);q&&(l&&l!=k&&(this._setCurrentTabStop(g,l,d.shiftKey),l.focus()),a.cancel());break;case AdfKeyStroke.SPACE_KEY:if("A"==b.tagName){d=AdfAgent.AGENT;if(b=this._checkTask(b))-1==b.toLowerCase().indexOf("-")?
this._smartMove(b):(this._reorder(b),this._manageReorderButtons()),d.preventDefault(a.getNativeEvent()),(g=AdfFocusUtils.getFirstTabStop(g))&&AdfFocusUtils.focusElement(g);a.cancel()}}};
AdfDhtmlSelectManyShuttleBasePeer.prototype.HandleComponentClick=function(a){AdfDhtmlSelectManyShuttleBasePeer.superclass.HandleComponentClick.call(this,a);var b=this.getComponent();if(!b.getDisabled()&&a.isLeftButtonPressed()){var d=a.getNativeEventTarget(),e=AdfAgent.AGENT,f=this._checkTask(d);if(f)-1==f.toLowerCase().indexOf("-")?this._smartMove(f):(this._reorder(f),this._manageReorderButtons()),e.preventDefault(a.getNativeEvent()),f=this.getDomElement(),f=this._getButconParentContainer(f,d),(a=
AdfFocusUtils.getFirstTabStop(f))&&AdfFocusUtils.focusElement(a);else if(f=this.getDomElement(),f=this._getParentContainer(f,d),AdfDomUtils.isAncestor(f,d)){if(d)if(b=a.getNativeEvent(),e.getPlatform()!=AdfAgent.GECKO_PLATFORM){if("LABEL"==d.nodeName){a=b.pointerType;""!=a&&void 0!=a&&(b=this.getComponent(),b.setProperty(AdfRichSelectManyShuttle.POINTERTYPE,a));return}}else if(!AdfAgent.AGENT.isSelectionToggle(b)&&!b.shiftKey&&"LABEL"==d.nodeName)return;this._updateClickedCheckbox(d,a);(a=AdfFocusUtils.getFirstTabStop(f))&&
AdfFocusUtils.focusElement(a)}else this.focus(b)}};
AdfDhtmlSelectManyShuttleBasePeer.prototype.HandleComponentDblClick=function(a){if(!this.getComponent().getDisabled()&&a.isLeftButtonPressed()){var b=a.getNativeEventTarget();checkbox=this.GetCheckboxByEventTarget(b,a);if(this.IsCheckbox(checkbox)&&!checkbox.disabled&&!this._isReorderOnly()){a=null;var d=this.getDomElement(),b=this._getParentContainer(d,b).id;"none"==AdfAgent.AGENT.getComputedStyle(checkbox).display&&(checkbox.checked=!0);-1!=b.indexOf(AdfDhtmlSelectManyShuttleBasePeer._LEAD_UL)?a=
"move":-1!=b.indexOf(AdfDhtmlSelectManyShuttleBasePeer._TRAIL_UL)&&(a="remove");null!=a&&this._smartMove(a)}}};AdfDhtmlSelectManyShuttleBasePeer.prototype.Validate=function(a,b){AdfDhtmlSelectManyShuttleBasePeer.superclass.Validate.call(this,a,b);this._disableButtons(this.getDomElement())};
AdfDhtmlSelectManyShuttleBasePeer.prototype.SetDisplayValue=function(a,b,d){AdfAssert.assertDomElement(b);AdfAssert.assertArrayOrNull(d);if(!this._isReorderOnly()){boxes=this.GetCheckboxes(a,null,AdfDhtmlSelectManyShuttleBasePeer._TRAIL_UL_ID_EXPANDO);var e=this._getContainer(null,AdfDhtmlSelectManyShuttleBasePeer._LEAD_UL_ID_EXPANDO);a=this._getContainer(null,AdfDhtmlSelectManyShuttleBasePeer._TRAIL_UL_ID_EXPANDO);for(var f=a.scrollTop,g=0;g<boxes.length;g++){var h=this._getElementFromContainerByValue(AdfDhtmlSelectManyShuttleBasePeer._TRAIL_UL_ID_EXPANDO,
boxes[g].value);e.appendChild(h)}if(d!=AdfCollections.EMPTY_ARRAY)for(e=0;e<d.length;e++)(h=this._getElementFromContainerByValue(AdfDhtmlSelectManyShuttleBasePeer._LEAD_UL_ID_EXPANDO,d[e]))&&a.appendChild(h);a.scrollTop=f;this._initLazyLoad(b);this._disableButtons(b);this._setCurrentTabStop(this._getContainer(null,AdfDhtmlSelectManyShuttleBasePeer._LEAD_UL_ID_EXPANDO),this._getFirstEnabledCheckbox(AdfDhtmlSelectManyShuttleBasePeer._LEAD_UL_ID_EXPANDO),!1);this._setCurrentTabStop(this._getContainer(null,
AdfDhtmlSelectManyShuttleBasePeer._TRAIL_UL_ID_EXPANDO),this._getFirstEnabledCheckbox(AdfDhtmlSelectManyShuttleBasePeer._TRAIL_UL_ID_EXPANDO),!1)}this._createSubmitValueArray(!1);b=AdfAgent.AGENT;if(b.getPlatform()==AdfAgent.IE_PLATFORM||b.getPlatform()==AdfAgent.GECKO_PLATFORM)this._updateSizeAndPositionAriaAttributes(AdfDhtmlSelectManyShuttleBasePeer._LEAD_UL_ID_EXPANDO),this._updateSizeAndPositionAriaAttributes(AdfDhtmlSelectManyShuttleBasePeer._TRAIL_UL_ID_EXPANDO)};
AdfDhtmlSelectManyShuttleBasePeer.prototype.GetSubmittedValue=function(a,b){AdfAssert.assertDomElement(b);var d=a.getReadOnly(),e=a.getDisabled();if(d||e)return d=AdfDhtmlEditableValuePeer.getContentNode(a,b).getAttribute(AdfDhtmlSelectManyPeer._ITEM_VALUE_EXPANDO),eval(d);d=this._getHiddenField();e=[];if(d)return e=d.value.split(";"),""!=e?e:null};
AdfDhtmlSelectManyShuttleBasePeer.prototype.GetComponentSelectItems=function(a,b){AdfAssert.assertDomElement(b);var d=[],e=this.GetCheckboxes(a,null,AdfDhtmlSelectManyShuttleBasePeer._LEAD_UL_ID_EXPANDO),f;for(f=0;f<e.length;f++)d[f]=new AdfSelectItem,d[f].setValue(e[f].value),d[f].setLabel(AdfDhtmlEditableValuePeer.GetLabelElement(e[f]).textContent),d[f].setDisabled(e[f].disabled);for(var e=this.GetCheckboxes(a,null,AdfDhtmlSelectManyShuttleBasePeer._TRAIL_UL_ID_EXPANDO),g=0;g<e.length;g++,f++)d[f]=
new AdfSelectItem,d[f].setValue(e[g].value),d[f].setLabel(AdfDhtmlEditableValuePeer.GetLabelElement(e[g]).textContent),d[f].setDisabled(e[g].disabled);return d};AdfDhtmlSelectManyShuttleBasePeer.prototype.GetCheckboxes=function(a,b,d){AdfAssert.assertDomElementOrNull(b);AdfAssert.assertString(d);a=[];var e=[];if(b=this._getContainer(b,d))e=b.childNodes;for(i=0;i<e.length;i++)1==e[i].nodeType&&(b=e[i].getElementsByTagName("input")[0])&&a.push(b);return a};
AdfDhtmlSelectManyShuttleBasePeer.prototype.GetInlineEditor=function(a){return AdfDhtmlSimpleLabelEditor.getInlineEditor()};AdfDhtmlSelectManyShuttleBasePeer.prototype.GetNoteWindowAlignmentNode=function(a,b){return this._getContainer(b,AdfDhtmlSelectManyShuttleBasePeer._TRAIL_UL_ID_EXPANDO)};
AdfDhtmlSelectManyShuttleBasePeer.prototype.GetCheckboxByEventTarget=function(a,b){var d=this._getParentContainer(this.getDomElement(),a);return AdfDomUtils.isAncestor(d,a)&&0<d.getElementsByTagName("li").length?AdfDhtmlSelectManyShuttleBasePeer.superclass.GetCheckboxByEventTarget.call(this,a,b):a};
AdfDhtmlSelectManyShuttleBasePeer.prototype._updateClickedCheckbox=function(a,b){a=this.GetCheckboxByEventTarget(a,b);if(this.IsCheckbox(a)&&!a.disabled){var d=a;this._showDesc(d);var e=this._isReorderOnly(),f=b.getNativeEvent(),g=AdfAgent.AGENT.getComputedStyle(d),h;if(AdfAgent.AGENT.getPlatform()==AdfAgent.GECKO_PLATFORM)b.Event.mozInputSource==b.Event.MOZ_SOURCE_MOUSE&&(h="mouse"),b.Event.mozInputSource==b.Event.MOZ_SOURCE_TOUCH&&(h="touch");else if(h=f.pointerType,""==h||void 0==h){var k=this.getComponent();
h=k.getProperty(AdfRichSelectManyShuttle.POINTERTYPE);k.setProperty(AdfRichSelectManyShuttle.POINTERTYPE,"")}f.shiftKey?d.checked=!0:(k=AdfAgent.AGENT.getCapabilities()[AdfAgent.CAP_TOUCH_SCREEN],"none"!=g.display||AdfAgent.AGENT.isSelectionToggle(f)||k&&k!=AdfAgent.CAP_TOUCH_SCREEN_NONE&&"mouse"!=h||(f=this._getParentContainer(this.getDomElement(),d),this._unselectAll(f),d.checked=!0));this.UpdateSelectedStyle(d);e?(this._manageReorderButtons(),d=this._getCheckedItemValues(AdfDhtmlSelectManyShuttleBasePeer._TRAIL_UL_ID_EXPANDO)):
(this._manageMoveButtons(d),d=this._getCheckedItemValues(AdfDhtmlSelectManyShuttleBasePeer._LEAD_UL_ID_EXPANDO),e=this._getCheckedItemValues(AdfDhtmlSelectManyShuttleBasePeer._TRAIL_UL_ID_EXPANDO),d=d.concat(e));k=this.getComponent();k.setProperty(AdfRichSelectManyShuttle.SELECTION,d)}};
AdfDhtmlSelectManyShuttleBasePeer.prototype.ComponentSelectionChanged=function(a,b,d,e){e=this._isReorderOnly();var f=AdfAgent.AGENT;b=this.getDomElement();var g;e||(g=b.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._LEAD_UL_ID_EXPANDO),g=f.getElementById(g),this._unselectAll(g),g=this.GetCheckboxes(null,null,AdfDhtmlSelectManyShuttleBasePeer._LEAD_UL_ID_EXPANDO));b=b.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._TRAIL_UL_ID_EXPANDO);b=f.getElementById(b);this._unselectAll(b);b=this.GetCheckboxes(null,
null,AdfDhtmlSelectManyShuttleBasePeer._TRAIL_UL_ID_EXPANDO);g=g?g.concat(b):b;for(i=0;i<d.length;i++){b=!1;for(j=0;j<g.length;j++)if(g[j].value==d[i]){b=!0;g[j].disabled||g[j].checked?(d.splice(i,1),i--):(g[j].checked=!0,this.UpdateSelectedStyle(g[j]));break}b||(d.splice(i,1),i--)}e||this._manageAllMoveButtons();a.getReorderOnly&&this._manageReorderButtons()};
AdfDhtmlSelectManyShuttleBasePeer.prototype._getDescSide=function(a){var b=AdfAgent.AGENT,d=this.getDomElement(),e,f;this._isReorderOnly()||(e=d.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._LEAD_UL_ID_EXPANDO),e=b.getElementById(e));d=d.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._TRAIL_UL_ID_EXPANDO);b=b.getElementById(d);e&&AdfDomUtils.isAncestor(e,a)?f=AdfDhtmlSelectManyShuttleBasePeer._LEAD_DESC:AdfDomUtils.isAncestor(b,a)&&(f=AdfDhtmlSelectManyShuttleBasePeer._TRAIL_DESC);return f};
AdfDhtmlSelectManyShuttleBasePeer.prototype._manageReorderButtons=function(){var a=this.getDomElement(),b=this._getContainer(a,AdfDhtmlSelectManyShuttleBasePeer._TRAIL_UL_ID_EXPANDO),d=this._getSelectItemCount(b)[0],e=!1,f=!1;if(0<d){var g=this._getSelectedIndices(b),h=b.getElementsByTagName("li").length;if(1==d&&0==g[0])e=!0;else if(1<d&&0==g[0]){for(b=0;g[b]==b;)b++;b==d&&(e=!0)}if(1==d&&g[0]==h-1)f=!0;else if(1<d&&g[g.length-1]==h-1){b=h-1;for(h=1;g[g.length-h]==b;)b--,h++;h>d&&(f=!0)}}this._disableButton(f||
!(0<d),a.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._BOTTOM_ID_ATTR_NAME),AdfDhtmlSelectManyShuttleBasePeer._BOTTOM_ID_ATTR_NAME,!1,!1);this._disableButton(f||!(0<d),a.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._DOWN_ID_ATTR_NAME),AdfDhtmlSelectManyShuttleBasePeer._DOWN_ID_ATTR_NAME,!1,!1);this._disableButton(e||!(0<d),a.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._UP_ID_ATTR_NAME),AdfDhtmlSelectManyShuttleBasePeer._UP_ID_ATTR_NAME,!1,!1);this._disableButton(e||!(0<d),a.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._TOP_ID_ATTR_NAME),
AdfDhtmlSelectManyShuttleBasePeer._TOP_ID_ATTR_NAME,!1,!1)};
AdfDhtmlSelectManyShuttleBasePeer.prototype._manageMoveButtons=function(a){var b,d,e,f,g=this.getDomElement();a=this._getParentContainer(g,a);var h=this._getSelectItemCount(a),k=h[0],h=h[1];-1!=a.id.indexOf(AdfDhtmlSelectManyShuttleBasePeer._LEAD_UL)?(b=g.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._MOVE_ID_ATTR_NAME),e=AdfDhtmlSelectManyShuttleBasePeer._MOVE_ID_ATTR_NAME,d=g.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._MOVEALL_ID_ATTR_NAME),f=AdfDhtmlSelectManyShuttleBasePeer._MOVEALL_ID_ATTR_NAME):
-1!=a.id.indexOf(AdfDhtmlSelectManyShuttleBasePeer._TRAIL_UL)&&(b=g.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._REMOVE_ID_ATTR_NAME),e=AdfDhtmlSelectManyShuttleBasePeer._REMOVE_ID_ATTR_NAME,d=g.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._REMOVEALL_ID_ATTR_NAME),f=AdfDhtmlSelectManyShuttleBasePeer._REMOVEALL_ID_ATTR_NAME);this._disableButton(!(0<h),d,f,!0,!0);this._disableButton(!(0<k),b,e,!0,!0);this.getComponent().getReorderOnly&&this._manageReorderButtons()};
AdfDhtmlSelectManyShuttleBasePeer.prototype._manageAllMoveButtons=function(){var a=this.getDomElement(),b=AdfAgent.AGENT,d=a.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._LEAD_UL_ID_EXPANDO),e=b.getElementById(d),d=a.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._TRAIL_UL_ID_EXPANDO),d=b.getElementById(d),e=this._getSelectItemCount(e),b=e[0],e=e[1],d=this._getSelectItemCount(d),f=d[0];this._disableButton(!(0<d[1]),a.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._REMOVEALL_ID_ATTR_NAME),AdfDhtmlSelectManyShuttleBasePeer._REMOVEALL_ID_ATTR_NAME,
!0,!0);this._disableButton(!(0<f),a.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._REMOVE_ID_ATTR_NAME),AdfDhtmlSelectManyShuttleBasePeer._REMOVE_ID_ATTR_NAME,!0,!0);this._disableButton(!(0<e),a.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._MOVEALL_ID_ATTR_NAME),AdfDhtmlSelectManyShuttleBasePeer._MOVEALL_ID_ATTR_NAME,!0,!0);this._disableButton(!(0<b),a.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._MOVE_ID_ATTR_NAME),AdfDhtmlSelectManyShuttleBasePeer._MOVE_ID_ATTR_NAME,!0,!0)};
AdfDhtmlSelectManyShuttleBasePeer.prototype._disableButton=function(a,b,d,e,f){AdfAssert.assertBoolean(a);if(b){b=AdfAgent.AGENT.getElementById(b);var g=AdfDomUtils.getFirstChildElement(b);AdfDomUtils.addOrRemoveCSSClassName(a,b,AdfDhtmlSelectManyShuttleBasePeer._DISABLED_STYLE_CLASS);b.setAttribute("aria-disabled",a.toString());AdfDomUtils.addOrRemoveCSSClassName(a,b.parentNode,AdfRichUIPeer.DISABLED_STYLECLASS);g&&(d=this.getComponent().getReorderOnly?"af|selectOrderShuttle::"+AdfDhtmlSelectManyShuttleBasePeer._BUTCON_KEYS[d]:
"af|selectManyShuttle::"+AdfDhtmlSelectManyShuttleBasePeer._BUTCON_KEYS[d],e&&(e=this.getComponent().getLayout(),d="vertical"==e?d+"-vertical":d+"-horizontal"),a&&(d+="-disabled"),d+="-icon",f&&AdfPage.PAGE.getLocaleContext().isRightToLeft()&&(d+=":rtl"),AdfDomUtils.swapIcon(g,d));a?(b.setAttribute(AdfDhtmlSelectManyShuttleBasePeer._TABINDEX,"-1"),b.removeAttribute(AdfDhtmlSelectManyShuttleBasePeer._HREF,0)):(a=this.getDomElement(),a=this._getButconParentContainer(a,b),null!=a&&this._setCurrentTabStop(a,
b,!1),b.setAttribute(AdfDhtmlSelectManyShuttleBasePeer._HREF,"#"),b.setAttribute(AdfDhtmlSelectManyShuttleBasePeer._ONCLICK,AdfDhtmlSelectManyShuttleBasePeer._RETURN_FALSE))}};AdfDhtmlSelectManyShuttleBasePeer.prototype._getSelectItemCount=function(a,b){AdfAssert.assertBoolean(b);var d=0,e=a.getElementsByTagName("input");for(i=0;i<e.length;i++)e[i]&&!e[i].disabled&&(b?e[i].checked&&d++:d++);return d};
AdfDhtmlSelectManyShuttleBasePeer.prototype._getSelectItemCount=function(a){var b=0,d=0;a=a.getElementsByTagName("input");for(i=0;i<a.length;i++)a[i]&&!a[i].disabled&&(a[i].checked&&b++,d++);return[b,d]};AdfDhtmlSelectManyShuttleBasePeer.prototype._unselectAll=function(a){a=a.getElementsByTagName("input");for(i=0;i<a.length;i++)a[i]&&!a[i].disabled&&(a[i].checked=!1,this.UpdateSelectedStyle(a[i]))};
AdfDhtmlSelectManyShuttleBasePeer.prototype._showDesc=function(a){var b,d=this._getDescSide(a);d&&(b=this._getDescBox(d));b&&(a=a.parentNode.title,null==a&&(a=""),b.value=a)};AdfDhtmlSelectManyShuttleBasePeer.prototype._clearDescs=function(){this._clearDesc(AdfDhtmlSelectManyShuttleBasePeer._LEAD_DESC);this._clearDesc(AdfDhtmlSelectManyShuttleBasePeer._TRAIL_DESC)};AdfDhtmlSelectManyShuttleBasePeer.prototype._clearDesc=function(a){if(a=this._getDescBox(a))a.value=""};
AdfDhtmlSelectManyShuttleBasePeer.prototype._getDescBox=function(a){var b=this.getComponent().getClientId();a=AdfRichUIPeer.CreateSubId(b,a);return AdfAgent.AGENT.getElementById(a)};
AdfDhtmlSelectManyShuttleBasePeer.prototype._getContainer=function(a,b){AdfAssert.assertDomElementOrNull(a);AdfAssert.assertString(b);var d,e=AdfAgent.AGENT;d=null==a?this.getDomElement().getAttribute(b):a.getAttribute(b);d=e.getElementById(d);var f;if(d&&d.getAttribute("_adfFieldset"))for(d=d.childNodes,i=0;i<d.length;i++)1==d[i].nodeType&&"FIELDSET"==e.getNodeName(d[i])&&(f=d[i]);else f=d;return f};
AdfDhtmlSelectManyShuttleBasePeer.prototype._setCurrentTabStop=function(a,b,d){if(a){b&&"none"==AdfAgent.AGENT.getComputedStyle(b).display&&(b=b.parentNode.parentNode);var e=AdfFocusUtils.getFirstTabStop(a);if(e!=b){if(d&&"INPUT"==AdfAgent.AGENT.getNodeName(b)|"LI"==AdfAgent.AGENT.getNodeName(b)){d=this.getDomElement();var f=this.getComponent(),g=e,h=AdfDhtmlSelectManyShuttleBasePeer._LEAD_UL_ID_EXPANDO;a.id!=d.getAttribute(h)&&(h=AdfDhtmlSelectManyShuttleBasePeer._TRAIL_UL_ID_EXPANDO);e||(g=this._getFirstEnabledCheckbox(h));
a=g;var k=b;"LI"==AdfAgent.AGENT.getNodeName(g)&&(a=g.getElementsByTagName("input")[0]);"LI"==AdfAgent.AGENT.getNodeName(b)&&(k=b.getElementsByTagName("input")[0]);this.SelectRange(f,d,a,k,h)}e&&e.setAttribute(AdfDhtmlSelectManyShuttleBasePeer._TABINDEX,"-1");b.setAttribute(AdfDhtmlSelectManyShuttleBasePeer._TABINDEX,"0")}}};
AdfDhtmlSelectManyShuttleBasePeer.prototype._saveValuesOnElement=function(a){AdfAssert.assertDomElement(a);var b=[],d=this.GetCheckboxes(null,a,AdfDhtmlSelectManyShuttleBasePeer._LEAD_UL_ID_EXPANDO);a=this.GetCheckboxes(null,a,AdfDhtmlSelectManyShuttleBasePeer._TRAIL_UL_ID_EXPANDO);if(d)for(var e=0;e<d.length;e++)d[e]&&b.push(d[e].value);if(a)for(e=0;e<a.length;e++)a[e]&&b.push(a[e].value);return b.join(";")};
AdfDhtmlSelectManyShuttleBasePeer.prototype._getClearContainer=function(a){AdfAssert.assertString(a);a=this._getContainer(null,a);var b=a.childNodes;for(i=0;i<b.length;i++)"LEGEND"!=AdfAgent.AGENT.getNodeName(b[i])&&(a.removeChild(b[i]),--i);return a};
AdfDhtmlSelectManyShuttleBasePeer.prototype._getElementFromContainerByValue=function(a,b){AdfAssert.assertString(a);var d=[],e=this._getContainer(null,a),f=null;e&&(d=e.childNodes);for(i=0;i<d.length;i++)if(1==d[i].nodeType&&(e=d[i].getElementsByTagName("input")[0],e.value&&e.value==b)){f=d[i];break}return f};
AdfDhtmlSelectManyShuttleBasePeer.prototype._smartMove=function(a){var b=-1!=a.indexOf("all"),d=null,e=null,f=AdfDhtmlSelectManyShuttleBasePeer._TRAIL_UL_ID_EXPANDO;if("move"==a||"moveall"==a)d=this._getContainer(null,AdfDhtmlSelectManyShuttleBasePeer._LEAD_UL_ID_EXPANDO),e=this._getContainer(null,f);if("remove"==a||"removeall"==a)f=AdfDhtmlSelectManyShuttleBasePeer._LEAD_UL_ID_EXPANDO,d=this._getContainer(null,AdfDhtmlSelectManyShuttleBasePeer._TRAIL_UL_ID_EXPANDO),e=this._getContainer(null,f);this._move(d,
e,b);this.getComponent().setProperty(AdfRichSelectManyShuttle.SELECTION,this._getCheckedItemValues(f))};
AdfDhtmlSelectManyShuttleBasePeer.prototype._move=function(a,b,d){AdfAssert.assertBoolean(d);a=a.getElementsByTagName("li");for(i=0;i<a.length;i++){var e=a[i].getElementsByTagName("input")[0],f=!1;1==d?e.disabled||(f=!0,e.checked=!1,this.UpdateSelectedStyle(e)):!e.disabled&&e.checked&&(f=!0,e.checked=!1,this.UpdateSelectedStyle(e));1==f&&(e.parentElement.parentElement.setAttribute(AdfDhtmlSelectManyShuttleBasePeer._TABINDEX,"-1"),b.appendChild(a[i]),--i)}b.scrollTop=b.scrollHeight;this._createSubmitValueArray(!0);
this._clearDescs()};AdfDhtmlSelectManyShuttleBasePeer.prototype._updateSizeAndPositionAriaAttributes=function(a){if(a=this._getContainer(null,a)){a=a.getElementsByTagName("li");for(var b=a.length,d=0;d<b;d++)a[d].setAttribute("aria-setsize",b),a[d].setAttribute("aria-posinset",d+1)}};AdfDhtmlSelectManyShuttleBasePeer.prototype._getFirstEnabledCheckbox=function(a){a=this.GetCheckboxes(null,null,a);for(i=0;i<a.length;i++)if(a[i]&&!a[i].disabled)return a[i]};
AdfDhtmlSelectManyShuttleBasePeer.prototype._createSubmitValueArray=function(a){var b=[],d=this.GetCheckboxes(null,null,AdfDhtmlSelectManyShuttleBasePeer._TRAIL_UL_ID_EXPANDO);for(i=0;i<d.length;i++)d[i]&&b.push(d[i].value);if(d=this._getHiddenField())d.value=b.join(";"),a&&this.Validate(this.getComponent(),b)};AdfDhtmlSelectManyShuttleBasePeer.prototype._getHiddenField=function(){return AdfAgent.AGENT.getElementsByName(this.getDomElement().getAttribute(AdfDhtmlSelectManyShuttleBasePeer._TRAIL_ITEMS_ID_EXPANDO))[0]};
AdfDhtmlSelectManyShuttleBasePeer.prototype._getSelectedIndices=function(a){var b=[];a=a.getElementsByTagName("input");for(i=0;i<a.length;i++){var d=a[i];!d.disabled&&d.checked&&b.push(i)}return b};AdfDhtmlSelectManyShuttleBasePeer.prototype._getCheckedItemValues=function(a){var b=[];a=this.GetCheckboxes(null,null,a);for(i=0;i<a.length;i++)a[i].checked&&!a[i].disabled&&b.push(a[i].value);return b};
AdfDhtmlSelectManyShuttleBasePeer.prototype._reorder=function(a){AdfAssert.assertString(a);var b=this._getContainer(null,AdfDhtmlSelectManyShuttleBasePeer._TRAIL_UL_ID_EXPANDO),d=this._getSelectedIndices(b),e=b.getElementsByTagName("li"),f=null;if("move-top"==a){for(j=0;j<d.length;j++)a=e[d[j]],b.insertBefore(a,e[j]);b.scrollTop=0}else if("move-up"==a){if(1<d.length&&0==d[0])for(a=0;d[0]==a;)AdfCollections.removeArrayValue(d,d[0]),a++;for(j=0;j<d.length;j++){var g=d[j];0<g&&(a=e[g],null==f&&(f=a),
b.insertBefore(a,e[g-1]))}AdfDomUtils.scrollChildIntoViewY(f)}else if("move-down"==a){if(1<d.length&&(a=e.length,d[d.length-1]==a-1))for(--a;d[d.length-1]==a;)AdfCollections.removeArrayValue(d,d[d.length-1]),a--;for(j=d.length-1;0<=j;j--)g=d[j],g<e.length&&(a=e[g],g+=2,null==f&&(f=a),g!=e.length?b.insertBefore(a,e[g]):b.appendChild(a));AdfDomUtils.scrollChildIntoViewY(f)}else if("move-bottom"==a){for(j=0;j<d.length;j++)a=e[d[j]-j],b.appendChild(a);b.scrollTop=b.scrollHeight}this._createSubmitValueArray(!0);
this._clearDescs()};AdfDhtmlSelectManyShuttleBasePeer.prototype._isReorderOnly=function(){var a=this.getComponent();return a.getReorderOnly&&a.getReorderOnly()};
AdfDhtmlSelectManyShuttleBasePeer.prototype._disableButtons=function(a){var b=this.getComponent();if(!b.getDisabled()&&!b.getReadOnly()){var d=this._getContainer(a,AdfDhtmlSelectManyShuttleBasePeer._LEAD_UL_ID_EXPANDO);if(d){var e=this._getContainer(a,AdfDhtmlSelectManyShuttleBasePeer._TRAIL_UL_ID_EXPANDO),d=this._getSelectItemCount(d),e=this._getSelectItemCount(e),f=d[0],g=e[0],d=0==d[1];this._disableButton(0==e[1],a.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._REMOVEALL_ID_ATTR_NAME),AdfDhtmlSelectManyShuttleBasePeer._REMOVEALL_ID_ATTR_NAME,
!0,!0);this._disableButton(!(0<g),a.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._REMOVE_ID_ATTR_NAME),AdfDhtmlSelectManyShuttleBasePeer._REMOVE_ID_ATTR_NAME,!0,!0);this._disableButton(d,a.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._MOVEALL_ID_ATTR_NAME),AdfDhtmlSelectManyShuttleBasePeer._MOVEALL_ID_ATTR_NAME,!0,!0);this._disableButton(!(0<f),a.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._MOVE_ID_ATTR_NAME),AdfDhtmlSelectManyShuttleBasePeer._MOVE_ID_ATTR_NAME,!0,!0)}b.getReorderOnly&&this._manageReorderButtons()}};
AdfDhtmlSelectManyShuttleBasePeer.prototype._checkTask=function(a){if(a=this._getAnchor(a)){a=a.id;if(this._endsWith(a,"::move"))return"move";if(this._endsWith(a,"::moveall"))return"moveall";if(this._endsWith(a,"::remove"))return"remove";if(this._endsWith(a,"::removeall"))return"removeall";if(this._endsWith(a,"move-top"))return"move-top";if(this._endsWith(a,"move-up"))return"move-up";if(this._endsWith(a,"move-down"))return"move-down";if(this._endsWith(a,"move-bottom"))return"move-bottom"}};
AdfDhtmlSelectManyShuttleBasePeer.prototype._getParentContainer=function(a,b){AdfAssert.assertDomElement(a);var d=AdfAgent.AGENT,e=d.getElementById(a.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._LEAD_UL_ID_EXPANDO));AdfDomUtils.isAncestor(e,b)||(e=d.getElementById(a.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._TRAIL_UL_ID_EXPANDO)));return e};
AdfDhtmlSelectManyShuttleBasePeer.prototype._getButconParentContainer=function(a,b){AdfAssert.assertDomElement(a);var d=AdfAgent.AGENT,e=d.getElementById(a.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._REORDER_DIV_ID_EXPANDO));AdfDomUtils.isAncestor(e,b)||(e=d.getElementById(a.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._MOVE_DIV_ID_EXPANDO)));return e};
AdfDhtmlSelectManyShuttleBasePeer.prototype._getPreviousButcon=function(a,b,d){AdfAssert.assertString(b);var e=this._getAnchor(d);if(null==e)return d;d=e.id;var f=e;b==AdfDhtmlSelectManyShuttleBasePeer._REORDER_DIV_ID_EXPANDO?this._endsWith(d,"move-top")||this._endsWith(d,"move-up")?(a=[a.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._TOP_ID_ATTR_NAME)],f=this._getFirstEnabledButcon(a,0,e)):this._endsWith(d,"move-down")?(a=[a.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._UP_ID_ATTR_NAME),a.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._TOP_ID_ATTR_NAME)],
f=this._getFirstEnabledButcon(a,0,e)):this._endsWith(d,"move-bottom")&&(a=[a.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._DOWN_ID_ATTR_NAME),a.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._UP_ID_ATTR_NAME),a.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._TOP_ID_ATTR_NAME)],f=this._getFirstEnabledButcon(a,0,e)):b==AdfDhtmlSelectManyShuttleBasePeer._MOVE_DIV_ID_EXPANDO&&(this._endsWith(d,"::move")||this._endsWith(d,"::moveall")?(a=[a.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._MOVE_ID_ATTR_NAME)],
f=this._getFirstEnabledButcon(a,0,e)):this._endsWith(d,"::remove")?(a=[a.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._MOVEALL_ID_ATTR_NAME),a.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._MOVE_ID_ATTR_NAME)],f=this._getFirstEnabledButcon(a,0,e)):this._endsWith(d,"::removeall")&&(a=[a.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._REMOVE_ID_ATTR_NAME),a.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._MOVEALL_ID_ATTR_NAME),a.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._MOVE_ID_ATTR_NAME)],
f=this._getFirstEnabledButcon(a,0,e)));return f};
AdfDhtmlSelectManyShuttleBasePeer.prototype._getNextButcon=function(a,b,d){AdfAssert.assertString(b);var e=this._getAnchor(d);if(null==e)return d;d=e.id;var f=e;if(b==AdfDhtmlSelectManyShuttleBasePeer._REORDER_DIV_ID_EXPANDO)if(this._endsWith(d,"move-top"))a=[a.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._UP_ID_ATTR_NAME),a.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._DOWN_ID_ATTR_NAME),a.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._BOTTOM_ID_ATTR_NAME)],f=this._getFirstEnabledButcon(a,0,
e);else if(this._endsWith(d,"move-up"))a=[a.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._DOWN_ID_ATTR_NAME),a.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._BOTTOM_ID_ATTR_NAME)],f=this._getFirstEnabledButcon(a,0,e);else{if(this._endsWith(d,"move-down")||this._endsWith(d,"move-bottom"))a=[a.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._BOTTOM_ID_ATTR_NAME)],f=this._getFirstEnabledButcon(a,0,e)}else if(b==AdfDhtmlSelectManyShuttleBasePeer._MOVE_DIV_ID_EXPANDO)if(this._endsWith(d,"::move"))a=
[a.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._MOVEALL_ID_ATTR_NAME),a.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._REMOVE_ID_ATTR_NAME),a.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._REMOVEALL_ID_ATTR_NAME)],f=this._getFirstEnabledButcon(a,0,e);else if(this._endsWith(d,"::moveall"))a=[a.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._REMOVE_ID_ATTR_NAME),a.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._REMOVEALL_ID_ATTR_NAME)],f=this._getFirstEnabledButcon(a,0,e);else if(this._endsWith(d,
"::remove")||this._endsWith(d,"::removeall"))a=[a.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._REMOVEALL_ID_ATTR_NAME)],f=this._getFirstEnabledButcon(a,0,e);return f};AdfDhtmlSelectManyShuttleBasePeer.prototype._getFirstEnabledButcon=function(a,b,d){var e=a[b];return this._checkButconDisabledClassName(e)?b<a.length-1?this._getFirstEnabledButcon(a,b+1):d:AdfAgent.AGENT.getElementById(e)};
AdfDhtmlSelectManyShuttleBasePeer.prototype._checkButconDisabledClassName=function(a){return(a=AdfAgent.AGENT.getElementById(a))&&-1==a.className.indexOf(AdfDhtmlSelectManyShuttleBasePeer._DISABLED_STYLE_CLASS)?!1:!0};AdfDhtmlSelectManyShuttleBasePeer.prototype._getAnchor=function(a){var b=AdfAgent.AGENT,d=a.getElementsByTagName("A");if(1==d.length)return d[0];for(;a;){if("INPUT"==b.getNodeName(a)||"LABEL"==b.getNodeName(a))return null;if("A"==b.getNodeName(a))return a;a=a.parentNode}};
AdfDhtmlSelectManyShuttleBasePeer.prototype._endsWith=function(a,b){AdfAssert.assertString(a);AdfAssert.assertString(b);var d=a.length-b.length;return 0>d?!1:a.lastIndexOf(b,d)==d};AdfDhtmlSelectManyShuttleBasePeer.prototype._initLazyLoad=function(a){AdfAssert.assertDomElement(a);a.getAttribute(AdfDhtmlSelectManyShuttleBasePeer._LAZY_ATTR)||this._lazyInitButtons()};
AdfDhtmlSelectManyShuttleBasePeer.prototype._lazyInitButtons=function(){var a=this.getComponent().getClientId(),b=AdfRichUIPeer.CreateSubId(a,AdfDhtmlSelectManyShuttleBasePeer._MOVE_ID),d=AdfRichUIPeer.CreateSubId(a,AdfDhtmlSelectManyShuttleBasePeer._MOVEALL_ID),e=AdfRichUIPeer.CreateSubId(a,AdfDhtmlSelectManyShuttleBasePeer._REMOVE_ID),f=AdfRichUIPeer.CreateSubId(a,AdfDhtmlSelectManyShuttleBasePeer._REMOVEALL_ID),g=AdfRichUIPeer.CreateSubId(a,AdfDhtmlSelectManyShuttleBasePeer._TOP_ID),h=AdfRichUIPeer.CreateSubId(a,
AdfDhtmlSelectManyShuttleBasePeer._UP_ID),k=AdfRichUIPeer.CreateSubId(a,AdfDhtmlSelectManyShuttleBasePeer._DOWN_ID),a=AdfRichUIPeer.CreateSubId(a,AdfDhtmlSelectManyShuttleBasePeer._BOTTOM_ID),l=this.getDomElement();l.setAttribute(AdfDhtmlSelectManyShuttleBasePeer._MOVE_ID_ATTR_NAME,b);l.setAttribute(AdfDhtmlSelectManyShuttleBasePeer._MOVEALL_ID_ATTR_NAME,d);l.setAttribute(AdfDhtmlSelectManyShuttleBasePeer._REMOVE_ID_ATTR_NAME,e);l.setAttribute(AdfDhtmlSelectManyShuttleBasePeer._REMOVEALL_ID_ATTR_NAME,
f);l.setAttribute(AdfDhtmlSelectManyShuttleBasePeer._TOP_ID_ATTR_NAME,g);l.setAttribute(AdfDhtmlSelectManyShuttleBasePeer._UP_ID_ATTR_NAME,h);l.setAttribute(AdfDhtmlSelectManyShuttleBasePeer._DOWN_ID_ATTR_NAME,k);l.setAttribute(AdfDhtmlSelectManyShuttleBasePeer._BOTTOM_ID_ATTR_NAME,a);l.setAttribute(AdfDhtmlSelectManyShuttleBasePeer._LAZY_ATTR,"true")};