function AdfIEAgentLegacy(a,b){this.Init(a,b);AdfIEAgentLegacy.assertBrowserMode(this)}AdfIEAgentLegacy.assertBrowserMode=function(a){AdfIEAgentLegacy._isIllegalBrowserDetected(a)&&("undefined"!=typeof checkBrowserMode&&null!=checkBrowserMode)&&("alert"==checkBrowserMode&&alert(AdfAgent._UNSUPPORTED_BROWSER_MODE_ALERT),window.setTimeout('try{AdfLogger.LOGGER.warning(unescape("'+escape(AdfAgent._UNSUPPORTED_BROWSER_MODE_ALERT)+'"));}catch(problem){}',1E3))};
AdfIEAgentLegacy._isIllegalBrowserDetected=function(a){var b=a.getVersion();a=document.documentMode;if(8>b)return 7>b?!0:null==a?!1:!0;if(8>a)return!0;b=Math.abs(b);a=Math.abs(a);return b!=a?!0:!1};AdfObject.createSubclass(AdfIEAgentLegacy,AdfAgent);AdfIEAgentLegacy._USERDATA_BEHAVIOR="url(#default#userData)";AdfIEAgentLegacy._USERDATA_ID="userDataState";AdfIEAgentLegacy._USERDATA_SEPARATOR="|";AdfIEAgentLegacy._USERDATA_ROOT_ELEMENT_ID="storageId";AdfIEAgentLegacy._USERDATA_WINDOW_ID="windowId";
AdfIEAgentLegacy._USERDATA_WINDOW_ELEMENT="window";AdfIEAgentLegacy._USERDATA_DATA_ELEMENT="data";AdfIEAgentLegacy._USERDATA_PROP_KEY="propKey";AdfIEAgentLegacy._USERDATA_PROP_VALUE="propValue";AdfIEAgentLegacy._DEFAULT_WINDOW_ID="userDataWindowId";AdfIEAgentLegacy._SESSION_WINDOW_DATA_TIMEOUT=1440;AdfIEAgentLegacy._CAPTURE_PANE_STYLE_CLASS="AFCapturePane";AdfIEAgentLegacy._IN_CAPTURE="_afrInCapture";
AdfIEAgentLegacy.__getAgentVersion=function(a){var b=null;(b=b=a.match(/trident\/(\d+[.]\d+)/))?(b=parseFloat(b[1]),b+=4):((b=a.match(/msie (\d+\.\d+);/))||(b=a.match(/msie (\d+\.\d+)b;/)),b=parseFloat(b[1]));return b};
AdfIEAgentLegacy.prototype.Init=function(a,b){AdfIEAgentLegacy.superclass.Init.call(this,AdfAgent.IE_PLATFORM,AdfAgent.guessOS(),a,b);this._imageURLs={};this._cursorURLsInited=!1;this._ID_TO_DOM_MAP={};this._EVENT_CAPTURES={_captureRefCount:0};this._scrollRecord=this._userDataStorageInstance=null};
AdfIEAgentLegacy.prototype.createXMLHttpRequest=function(){var a=AdfIEAgentLegacy.superclass.createXMLHttpRequest.call(this);if(!a&&window.ActiveXObject)try{a=new ActiveXObject("Msxml2.XMLHTTP")}catch(b){try{a=new ActiveXObject("Microsoft.XMLHTTP")}catch(d){}}return a};AdfIEAgentLegacy.prototype.getElementById=function(a){if(AdfAssert.DEBUG){var b=this._ID_TO_DOM_MAP[a],d=this.getDomDocument().getElementById(a);b!=d&&AdfAssert.assert(!1,"document.getElementById('"+a+"')\x3d\x3d"+d+" not "+b)}return this._ID_TO_DOM_MAP[a]};
AdfIEAgentLegacy.prototype.isSessionStorageEnabled=function(){if(void 0===this._isSessionStorageEnabled)try{this._setUserDataProperty("_adfTestKey","on",2),this._removeUserDataProperty("_adfTestKey"),this._isSessionStorageEnabled=!0}catch(a){AdfLogger.LOGGER.logErrorAsInfo(a,"userdata monitoring has been disabled because an error occurred accessing the UserData store. Please ensure that 'userdata persistence' is enabled in your IE browser."),this._isSessionStorageEnabled=!1}return this._isSessionStorageEnabled};
AdfIEAgentLegacy.prototype.getSessionStorageProperty=function(a,b){AdfAssert.assertString(a);var d=null;try{d=this._getUserDataProperty(a,b)}catch(e){throw AdfLogger.LOGGER.logErrorAsInfo(e,"An error occurred when retrieving the property from the UserData store. Please make sure your browser's userdata persistence feature is enabled."),e;}return d};
AdfIEAgentLegacy.prototype._getUserDataProperty=function(a,b){var d=null,e=this._loadUserDataFromStore(),f=this._getUserDataStorageDataNode(e.xmlDocument,a);f&&(d=f.getAttribute(AdfIEAgentLegacy._USERDATA_PROP_VALUE));f=this._getUserDataStorageId();this._setSessionStorageExpiration(e,f,b);return d};
AdfIEAgentLegacy.prototype.removeSessionStorageProperty=function(a){AdfAssert.assertString(a);try{this._removeUserDataProperty(a)}catch(b){throw AdfLogger.LOGGER.logErrorAsInfo(b,"An error occurred when removing a property from the UserData store. Please make sure your browser's userdata persistence feature is enabled."),b;}};
AdfIEAgentLegacy.prototype._removeUserDataProperty=function(a){AdfAssert.assertString(a);var b=this._loadUserDataFromStore(),d=this._getUserDataStorageId(),e=b.xmlDocument;(a=this._getUserDataStorageDataNode(e,a))&&e.documentElement.removeChild(a);this._saveUserDataToStore(b,d)};
AdfIEAgentLegacy.prototype.setSessionStorageProperty=function(a,b,d){AdfAssert.assertString(a);AdfAssert.assertString(b);try{this._setUserDataProperty(a,b,d)}catch(e){throw AdfLogger.LOGGER.logErrorAsInfo(e,"An error occurred when saving property value to the UserData store. Please make sure your browser's userdata persistence feature is enabled."),e;}};
AdfIEAgentLegacy.prototype._setUserDataProperty=function(a,b,d){AdfAssert.assertString(a);AdfAssert.assertString(b);var e=this._loadUserDataFromStore(),f=this._getUserDataStorageId();e.load(f);var g=e.xmlDocument,h=!1,k;e.getAttribute(AdfIEAgentLegacy._USERDATA_ROOT_ELEMENT_ID)?(k=this._getUserDataStorageDataNode(g,a))||(h=!0):(e.setAttribute(AdfIEAgentLegacy._USERDATA_ROOT_ELEMENT_ID,f),h=!0);h&&(k=this._createUserDataChildNode(g,AdfIEAgentLegacy._USERDATA_DATA_ELEMENT,AdfIEAgentLegacy._USERDATA_PROP_KEY,
a),g.documentElement.insertBefore(k,null));k.setAttribute(AdfIEAgentLegacy._USERDATA_PROP_VALUE,b);this._saveUserDataToStore(e,f);this._setSessionStorageExpiration(e,f,d)};AdfIEAgentLegacy.prototype._getUserDataStorageId=function(){var a=AdfPage.PAGE.getWindowId();a||(a=AdfIEAgentLegacy._DEFAULT_WINDOW_ID);return AdfIEAgentLegacy._userDataSessionToken+AdfIEAgentLegacy._USERDATA_SEPARATOR+a};
AdfIEAgentLegacy.prototype._loadUserDataFromStore=function(){var a=this._userDataStorageInstance;if(!a){var b=this.getDomDocument(),a=b.createElement("div");a.id=AdfIEAgentLegacy._USERDATA_ID;a.style.behavior=AdfIEAgentLegacy._USERDATA_BEHAVIOR;b.body.appendChild(a);this._userDataStorageInstance=a}b=this._getUserDataStorageId();try{a.load(b)}catch(d){throw AdfLogger.LOGGER.fine("Unable to load object participating in userData persistence from UserData store."),d;}return a};
AdfIEAgentLegacy.prototype._saveUserDataToStore=function(a,b){AdfAssert.assertString(b);AdfAssert.assertObject(a);try{a.save(b)}catch(d){throw AdfLogger.LOGGER.fine("Unable to save object participating in userData persistence to a UserData store."),d;}};
AdfIEAgentLegacy.prototype._setSessionStorageExpiration=function(a,b,d){AdfAssert.assertString(b);AdfAssert.assertObject(a);var e=new Date;d||(d=AdfIEAgentLegacy._SESSION_WINDOW_DATA_TIMEOUT);e.setMinutes(e.getMinutes()+d);d=e.toUTCString();a.expires=d;this._saveUserDataToStore(a,b)};
AdfIEAgentLegacy.prototype._getUserDataStorageDataNode=function(a,b){var d=a.getElementsByTagName(AdfIEAgentLegacy._USERDATA_DATA_ELEMENT),e=null;d&&0<d.length&&(e=this._getUserDataChildNode(d,AdfIEAgentLegacy._USERDATA_PROP_KEY,b));return e};AdfIEAgentLegacy.prototype._getUserDataChildNode=function(a,b,d){AdfAssert.assertString(b);AdfAssert.assertStringOrNull(d);if(!a)return null;for(var e=null,f=a.length,g=0;g<f;g++)if(a[g].getAttribute(b)==d){e=a[g];break}return e};
AdfIEAgentLegacy.prototype._createUserDataChildNode=function(a,b,d,e){AdfAssert.assertObject(a);AdfAssert.assertString(b);AdfAssert.assertString(d);AdfAssert.assertString(e);a=a.createNode(1,b,"");a.setAttribute(d,e);return a};AdfIEAgentLegacy.prototype.elementsRemoved=function(a){var b=this._ID_TO_DOM_MAP,d=a.id;null!=d&&delete b[d];a=a.all;for(var d=a.length,e=0;e<d;e++){var f=a(e);(f=this._getAttribute(f,"id"))&&delete b[f]}};
AdfIEAgentLegacy.prototype.allElementsRemoved=function(){this._ID_TO_DOM_MAP={};this.elementsAdded(this.getDomDocument())};AdfIEAgentLegacy.prototype.elementsAdded=function(a){var b=this._ID_TO_DOM_MAP,d=a.id;null!=d&&(b[d]=a);a=a.all;for(var d=a.length,e=0;e<d;e++){var f=a(e),g=this._getAttribute(f,"id");g&&(b[g]=f)}};AdfIEAgentLegacy.prototype._getAttribute=function(a,b){var d=a.getAttribute(b);if(d&&"string"!==typeof d)for(var d=a.attributes,e=d.length,f=0;f<e;f++){if(d[f].name==b)return d[f].value}else return d};
AdfIEAgentLegacy.prototype.getDescendantComponentsForNode=function(a,b){b||(b=[]);for(var d=a.all,e=d.length,f=AdfPage.PAGE,g=0;g<e;g++){var h=d(g).id;h&&(h=f.findComponent(h))&&b.push(h)}return b};AdfIEAgentLegacy.prototype.setTextContent=function(a,b){AdfAssert.assertDomNode(a);b||(b="");switch(a.nodeType){case 1:a.innerText=b;break;case 2:case 5:case 6:case 11:case 3:case 4:case 8:case 7:a.nodeValue=b}};
AdfIEAgentLegacy.prototype.getTextContent=function(a){AdfAssert.assertDomNode(a);switch(a.nodeType){case 1:var b=a.innerText;void 0==b&&(b=a.text);return b;case 2:case 5:case 6:case 11:case 3:case 4:case 8:case 7:return a.nodeValue;case 9:case 10:case 12:return null}};
AdfIEAgentLegacy.prototype.getCursor=function(a){if(!this._cursorURLsInited){this._cursorURLsInited=!0;var b=AdfIEAgentLegacy._CSS3_TO_IE_MAP,d=AdfPage.PAGE;b.alias="url('"+d.getResourceURL("/afr/alias.cur")+"'),"+b.alias;b.copy="url('"+d.getResourceURL("/afr/copy.cur")+"'),"+b.copy}return AdfIEAgentLegacy._CSS3_TO_IE_MAP[a]};AdfIEAgentLegacy.prototype.getWindowClientWidth=function(a){a=a.document;return("BackCompat"===a.compatMode?a.body:a.documentElement).clientWidth};
AdfIEAgentLegacy.prototype.getWindowClientHeight=function(a){a=a.document;return("BackCompat"===a.compatMode?a.body:a.documentElement).clientHeight};AdfIEAgentLegacy.prototype.getWindowScrollWidth=function(a){a=a.document;return("BackCompat"===a.compatMode?a.body:a.documentElement).scrollWidth};AdfIEAgentLegacy.prototype.getWindowScrollHeight=function(a){a=a.document;return("BackCompat"===a.compatMode?a.body:a.documentElement).scrollHeight};
AdfIEAgentLegacy.prototype.getBrowserViewportScrollLeft=function(){var a=AdfIEAgentLegacy.superclass.getBrowserViewportScrollLeft.call(this);if(AdfPage.PAGE.getLocaleContext().isRightToLeft())var b=this.getDomWindow(),a=a-(this.getWindowScrollWidth(b)-this.getWindowClientWidth(b));return a};
AdfIEAgentLegacy.prototype.getElementLeft=function(a){AdfAssert.assertDomElement(a);var b=a.getBoundingClientRect().left;a=a.ownerDocument.documentElement;var d=a.scrollLeft;AdfPage.PAGE.getLocaleContext().isRightToLeft()&&(d+=a.clientWidth-a.scrollWidth);return b-=a.clientLeft-d};AdfIEAgentLegacy.prototype.getElementTop=function(a){AdfAssert.assertDomElement(a);var b=a.getBoundingClientRect().top;a=a.ownerDocument.documentElement;return b-=a.clientTop-a.scrollTop};
AdfIEAgentLegacy.prototype.getElementPosition=function(a){AdfAssert.assertDomElement(a);var b=a.getBoundingClientRect(),d=b.top,b=b.left;a=a.ownerDocument.documentElement;var e=a.scrollLeft;AdfPage.PAGE.getLocaleContext().isRightToLeft()&&(e+=a.clientWidth-a.scrollWidth);b-=a.clientLeft-e;d-=a.clientTop-a.scrollTop;return{x:b,y:d}};
AdfIEAgentLegacy.prototype.getElementPageBounds=function(a){AdfAssert.assertDomElement(a);var b=a.getBoundingClientRect();a=a.ownerDocument.documentElement;var d=a.scrollLeft;AdfPage.PAGE.getLocaleContext().isRightToLeft()&&(d+=a.clientWidth-a.scrollWidth);deltaX=a.clientLeft-d;deltaY=a.clientTop-a.scrollTop;return{top:b.top-deltaY,left:b.left-deltaX,bottom:b.bottom-deltaY,right:b.right-deltaX}};
AdfIEAgentLegacy.prototype.pointInElementBounds=function(a,b,d){var e=a.getBoundingClientRect();a=a.ownerDocument.documentElement;b=b-a.scrollLeft-2;d=d-a.scrollTop-2;return d>=e.top&&d<=e.bottom&&b>=e.left&&b<=e.right};AdfIEAgentLegacy.prototype.pointInElementChrome=function(a,b,d){var e=a.ownerDocument.documentElement;return(a=a.componentFromPoint(b-e.scrollLeft,d-e.scrollTop))&&"outside"!=a};
AdfIEAgentLegacy.prototype.isChromeEvent=function(a){AdfAssert.assertObject(a);switch(a.type){case "mousedown":return this._handleInlineEditingMouseDown(a);case "mouseup":return this._handleInlineEditingMouseUp(a);case "mousemove":return this._handleInlineEditingMouseMove(a);case "click":return this._handleInlineEditingClick(a);default:return!1}};AdfIEAgentLegacy._handleScrollInterval=function(){var a=AdfAgent.AGENT._scrollRecord;a.currChromePart===a.draggedChromePart&&a.currTarget.doScroll(a.draggedChromePart)};
AdfIEAgentLegacy.prototype._getBlockingDiv=function(){return this.getDomDocument().body.firstChild};
AdfIEAgentLegacy.prototype._handleInlineEditingMouseDown=function(a){var b=this.getEventTarget(a),d=b.componentFromPoint(a.clientX,a.clientY),e=!1;if(d){var f={draggedChromePart:"",currChromePart:"",scrollTimer:0,currTarget:null,startDrag:0,startScroll:0,noClick:!1};switch(d){case "scrollbarPageDown":case "scrollbarPageUp":case "scrollbarPageLeft":case "scrollbarPageRight":case "scrollbarLeft":case "scrollbarRight":case "scrollbarUp":case "scrollbarDown":f.scrollTimer=window.setInterval(AdfIEAgentLegacy._handleScrollInterval,
50);case "scrollbarVThumb":case "scrollbarHThumb":"scrollbarVThumb"===d?(f.startDrag=a.clientY,f.startScroll=b.scrollTop):(f.startDrag=a.clientX,f.startScroll=b.scrollLeft),f.currTarget=b,f.draggedChromePart=d,this._getBlockingDiv().setCapture(!0),e=!0,this._scrollRecord=f}}return e};
AdfIEAgentLegacy.prototype._handleInlineEditingMouseUp=function(a){var b=this._scrollRecord;return b?(b.noClick?this._handleInlineEditingMouseMove(a):this._handleInlineEditingClick(a),this._getBlockingDiv().releaseCapture(),this._scrollRecord.scrollTimer&&window.clearInterval(this._scrollRecord.scrollTimer),this._scrollRecord=null,!0):!1};
AdfIEAgentLegacy.prototype._handleInlineEditingMouseMove=function(a){var b=this._scrollRecord;if(b){b.noClick=!0;var d=b.draggedChromePart;if(d){var e=this.getEventTarget(a);"scrollbarVThumb"===d||"scrollbarHThumb"===d?"scrollbarVThumb"===d?(a=AdfIEAgentLegacy._computeScrollDelta(b,e.clientHeight,e.scrollHeight,a.clientY-b.startDrag),e.scrollTop=b.startScroll+a):"scrollbarHThumb"===d&&(a=AdfIEAgentLegacy._computeScrollDelta(b,e.clientWidth,e.scrollWidth,a.clientX-b.startDrag),e.scrollLeft=b.startScroll+
a):b.currChromePart=e.componentFromPoint(a.clientX,a.clientY)}return!0}return!1};AdfIEAgentLegacy._computeScrollDelta=function(a,b,d,e){a=Math.max(b-39,0);var f=14<a?Math.max(Math.ceil(a*b/d),14):a;a-=f;return Math.ceil(e*(a?(d-b)/a:0))};AdfIEAgentLegacy.prototype._handleInlineEditingClick=function(a){var b=this.getEventTarget(a);return(a=b.componentFromPoint(a.clientX,a.clientY))?(b.doScroll(a),!0):!1};AdfIEAgentLegacy.prototype.getOverrideStyle=function(a){return a.runtimeStyle};
AdfIEAgentLegacy.prototype.getComputedStyle=function(a){return a.currentStyle};AdfIEAgentLegacy.prototype.getStyleProperty=function(a,b){return a[b]};AdfIEAgentLegacy.prototype.getLocalName=function(a){var b=a.nodeName;(a=a.prefix)&&(b=b.substring(a.length+1,b.length));return b};AdfIEAgentLegacy.prototype.getNodeName=function(a){var b;switch(a.nodeType){case 1:a.prefix?b=a.nodeName:(b=a.tagName,(a=a.scopeName)&&"HTML"!=a&&(b=a+":"+b));break;case 3:b="#text";break;case 8:b="#comment"}return b};
AdfIEAgentLegacy.prototype.getPrefix=function(a){var b=a.prefix;b||(b=a.scopeName);return b};AdfIEAgentLegacy.prototype.setCssFloat=function(a,b){a.style.styleFloat=b};AdfIEAgentLegacy.prototype.addBubbleEventListener=function(a,b,d){AdfAssert.assertString(b);AdfAssert.assertFunction(d);a.attachEvent("on"+b,d)};AdfIEAgentLegacy.prototype.removeBubbleEventListener=function(a,b,d){AdfAssert.assertString(b);AdfAssert.assertFunction(d);a.detachEvent("on"+b,d)};
AdfIEAgentLegacy.prototype.startDocumentKeyEventCapture=function(a,b){AdfAssert.assert(a);AdfAssert.assertDomElement(b);for(var d=AdfAgent.KEY_EVENTS,e=d.length,f=b.ownerDocument,g=f.body,h=0;h<e;h++){var k=d[h],l=a[k];l&&(AdfAssert.assertFunction(l),b.attachEvent("on"+k,l))}d=null;(f=f.activeElement)&&(d={activeElement:f,activeID:f.id});g.focus();return d};
AdfIEAgentLegacy.prototype.endDocumentKeyEventCapture=function(a,b,d){AdfAssert.assert(a);AdfAssert.assertDomElement(b);for(var e=AdfAgent.KEY_EVENTS,f=e.length,g=0;g<f;g++){var h=e[g],k=a[h];k&&(AdfAssert.assertFunction(k),b.detachEvent("on"+h,k))}if(d&&(a=d.activeElement))if(AdfAssert.assertDomElement(a),AdfDomUtils.isNodeInDocumentHierarchy(b.ownerDocument,a)||((b=d.activeID)?(AdfAssert.assert(ownderDoc==this.getDomDocument()),a=this.getElementById(b)):a=null),a)try{a.setActive()}catch(l){AdfLogger.LOGGER.fine("Could not restore focus to activeElement:",
a.id?a.id:"unknown")}else AdfLogger.LOGGER.fine("Could not restore focus")};AdfIEAgentLegacy.prototype.addEventBubbles=function(a,b){for(var d=AdfIEAgentLegacy._REDISTRIBUTE_EVENTS,e=d.length,f=0;f<e;f++)a[d[f]]=b};AdfIEAgentLegacy.prototype.removeEventBubbles=function(a,b){for(var d=AdfIEAgentLegacy._REDISTRIBUTE_EVENTS,e=d.length,f=0;f<e;f++)a[d[f]]=null};
AdfIEAgentLegacy.prototype.addEventCaptures=function(a,b){AdfAssert.assertDomNode(a);AdfAssert.assertFunction(b);var d=a.id;AdfAssert.assertString(d);var e=this._EVENT_CAPTURES,f=e[d];null==f&&(this._addCapturePane(d),f=[],e[d]=f);f.push(b);e._captureRefCount++};
AdfIEAgentLegacy.prototype.removeEventCaptures=function(a,b){AdfAssert.assertDomNode(a);AdfAssert.assertFunction(b);var d=a.id;AdfAssert.assertString(d);var e=this._EVENT_CAPTURES,f=e[d];if(null==f)AdfAssert.assert(!1,"no capture listeners registered on:"+a);else{var g=AdfCollections.removeArrayValue(f,b);AdfAssert.assert(-1!=g,"listener:"+b+" wasn't registered for capture on:"+a);0==f.length&&(this._removeCapturePane(d),delete e[d]);e._captureRefCount--}};
AdfIEAgentLegacy.prototype.getComponentEvent=function(a,b,d){var e=AdfIEAgentLegacy.superclass.getComponentEvent.apply(this,arguments),f=e.getType();f==AdfComponentEvent.CONTEXT_MENU_EVENT_TYPE&&(e=new AdfIEShowContextMenuEvent(e.getSource(),f,e.getNativeEvent()));return e};
AdfIEAgentLegacy.prototype._addCapturePane=function(a){var b=this.getDomDocument(),d=b.createElement("div");d.id=this._getCapturePaneId(a);d.className=AdfIEAgentLegacy._CAPTURE_PANE_STYLE_CLASS;var e=d.style;e.position="absolute";e.backgroundColor="red";e.filter="alpha(opacity\x3d0)";e.zIndex=1;e.setExpression("top","AdfAgent.AGENT.getElementTop(AdfAgent.AGENT.getElementById('"+a+"'))");e.setExpression("left","AdfAgent.AGENT.getElementLeft(AdfAgent.AGENT.getElementById('"+a+"'))");e.setExpression("width",
"AdfAgent.AGENT.getElementById('"+a+"').offsetWidth");e.setExpression("height","AdfAgent.AGENT.getElementById('"+a+"').offsetHeight");a=b.body;a.insertBefore(d,a.firstChild);this.addEventBubbles(d,AdfIEAgentLegacy._captureListenerStub)};AdfIEAgentLegacy.prototype._removeCapturePane=function(a){var b=this.getDomDocument();a=this._getCapturePaneId(a);b=b.getElementById(a);AdfAssert.assertDomElement(b);b.parentNode.removeChild(b)};
AdfIEAgentLegacy.prototype._getCapturePaneId=function(a){return AdfRichUIPeer.createSubId(a,"afrCapture")};AdfIEAgentLegacy._isCapturePane=function(a){AdfAssert.assertDomElement(a);return a.className==AdfIEAgentLegacy._CAPTURE_PANE_STYLE_CLASS};AdfIEAgentLegacy._captureListenerStub=function(){AdfAgent.AGENT._captureListener(window.event)};
AdfIEAgentLegacy.prototype._captureListener=function(a){AdfAssert.assertObject(a);var b,d=this._scrollRecord;if(d&&d.currTarget)b={},AdfCollections.copyInto(b,a),this.setEventTarget(b,d.currTarget),this.isChromeEvent(b),this.eatEvent(a);else{var d=this._EVENT_CAPTURES,e=this.getDomDocument().documentElement;b=e.scrollLeft+a.clientX+2;var f=e.scrollTop+a.clientY+2,e=a.type,g="mousemove"==e,h=d._lastTarget,k=d._lastPageX,l=d._lastPageY;if(!g||!(b==k&&f==l))d._lastPageX=b,d._lastPageY=f,f=this.elementFromPagePoint(b,
f,h,null,AdfIEAgentLegacy._isCapturePane),h==f&&g||("mouseout"==e?h&&(f=h,d._lastTarget=null):d._lastTarget=f,b={},AdfCollections.copyInto(b,a),this.setEventTarget(b,f),g&&(b.type="mouseover",h&&(g={},AdfCollections.copyInto(g,a),this.setEventTarget(g,h),g.type="mouseout",this._deliverEventToEventCaptures(d,g))),"mousedown"==e&&this.isChromeEvent(b)?this.eatEvent(a):this._deliverEventToEventCaptures(d,b))}};
AdfIEAgentLegacy.prototype._deliverEventToEventCaptures=function(a,b){for(var d=this.getEventTarget(b),e=a._captureRefCount,f=null;null!=d;){var g=d.id;if(null!=g){g=a[g];if(null!=g){var h=g.length;null==f?f=[g]:f.push(g)}e-=h;if(0==e)break}d=d.parentNode}if(null!=f)for(d=f.length-1;0<=d;d--){e=f[d];h=e.length;for(g=0;g<h;g++)try{if(e[g](b),b.cancelBubble)break}catch(k){AdfLogger.LOGGER.logErrorAsSevere(k,"Error delivering captured event on "+this.getEventTarget(b)+" to:",e[g])}if(b.cancelBubble)break}};
AdfIEAgentLegacy.prototype.addKeyEventListener=function(a,b){a.attachEvent("onkeydown",b)};AdfIEAgentLegacy.prototype.removeKeyEventListener=function(a,b){a.detachEvent("onkeydown",b)};delete AdfIEAgentLegacy.prototype._valueChangeHandler;AdfIEAgentLegacy.prototype.getEventTarget=function(a){return a.srcElement};AdfIEAgentLegacy.prototype.setEventTarget=function(a,b){a.srcElement=b};AdfIEAgentLegacy.prototype.getEventToElement=function(a){return a.toElement};
AdfIEAgentLegacy.prototype.getEventFromElement=function(a){return a.fromElement};AdfIEAgentLegacy.prototype.cloneEvent=function(a,b){var d=a.type,e=b?b:this.getEventTarget(a),f=e.ownerDocument,g=null,g=this.isKeyboardEvent(a);this.isMouseEvent(a);if(g){g=this._copyKeyboardEvent(a,d,b);this.addBubbleEventListener(f,d,this.stopPropagation);try{this.dispatchEvent(e,g)}finally{this.removeBubbleEventListener(f,d,this.stopPropagation)}}else g=e.ownerDocument.createEventObject(a);return g};
AdfIEAgentLegacy.prototype.copyEvent=function(a){return this.getEventTarget(a).ownerDocument.createEventObject(a)};AdfIEAgentLegacy.prototype._copyKeyboardEvent=function(a,b,d){return(d?d:a.target).ownerDocument.createEventObject(a)};
AdfIEAgentLegacy.prototype._copyMouseEvent=function(a,b){for(var d=b.ownerDocument.createEventObject(),e="altKey altLeft button clientX clientY ctrlKey ctrlLeft offsetX offsetY screenX screenY shiftKey shiftLeft type x y".split(" "),f=0,g=e.length;f<g;f++){var h=e[f];void 0!==a[h]&&(d[h]=a[h])}return d};AdfIEAgentLegacy.prototype.dispatchEvent=function(a,b){return a.fireEvent("on"+b.type,b)};AdfIEAgentLegacy.prototype.CreateUIInputEvent=function(a,b,d){return new AdfIEUIInputEvent(a,b,d)};
AdfIEAgentLegacy.prototype.elementFromPagePoint=function(a,b,d,e,f){return f?AdfIEAgentLegacy.superclass.elementFromPagePoint.call(this,a,b,d,e,f):this.getDomDocument().elementFromPoint(a,b)};AdfIEAgentLegacy._doNothing=function(){return AdfAgent.AGENT.getDomWindow().event.returnValue=!1};AdfIEAgentLegacy.prototype.disableUserSelect=function(a){AdfAssert.assertDomElement(a);a.attachEvent("onselectstart",AdfIEAgentLegacy._doNothing)};
AdfIEAgentLegacy.prototype.enableUserSelect=function(a){AdfAssert.assertDomElement(a);a.detachEvent("onselectstart",AdfIEAgentLegacy._doNothing)};AdfIEAgentLegacy.prototype.stopPropagation=function(a){a.cancelBubble=!0};AdfIEAgentLegacy.prototype.preventDefault=function(a){a.returnValue=!1;var b=a.keyCode;if(b&&17!=b&&16!=b&&"file"!=this.getEventTarget(a).type)try{a.keyCode=0}catch(d){AdfLogger.LOGGER.warning("Error slamming keycode:",AdfUIUtils.getPropertiesAsString(a))}};
AdfIEAgentLegacy.prototype.isDefaultPrevented=function(a){return!1===a.returnValue};AdfIEAgentLegacy.prototype.checkMouseOutEvent=function(a,b){for(var d=!1,e=b.toElement;null!=e;){if(e==a){d=!0;break}e=e.parentNode}return!d};AdfIEAgentLegacy.prototype.isLeftButton=function(a){return 1==this.getDomWindow().event.button};AdfIEAgentLegacy.prototype.getMousePosition=function(a){var b=this.getDomDocument().documentElement;return{x:a.clientX+b.scrollLeft-b.clientLeft,y:a.clientY+b.scrollTop-b.clientTop}};
AdfIEAgentLegacy.prototype.startMouseEventCapture=function(a){var b=this.getDomDocument().documentElement;AdfAssert.assert(!b[AdfIEAgentLegacy._IN_CAPTURE]);b[AdfIEAgentLegacy._IN_CAPTURE]=!0;b.setCapture();for(type in a)type in AdfAgent.KEY_EVENTS||b.attachEvent("on"+type,a[type])};
AdfIEAgentLegacy.prototype.stopMouseEventCapture=function(a){var b=this.getDomDocument().documentElement;AdfAssert.assert(b[AdfIEAgentLegacy._IN_CAPTURE]);b[AdfIEAgentLegacy._IN_CAPTURE]=!1;b.releaseCapture();for(type in a)type in AdfAgent.KEY_EVENTS||b.detachEvent("on"+type,a[type])};
AdfIEAgentLegacy.prototype.setCursor=function(a,b,d){AdfAssert.assertDomElement(a);AdfAssert.assertString(b);var e=a.ownerDocument.documentElement;if(e[AdfIEAgentLegacy._IN_CAPTURE]&&(void 0==d||!1==d))a.style.cursor=b,a=e;a.style.cursor=b};
AdfIEAgentLegacy.prototype.setImageSource=function(a,b){var d=this._imageURLs[b];if(d==AdfIEAgentLegacy._IMG_URL_LOADED)a.src=b;else if(d)d.push(a);else{var e=this._imageURLs,d=[];e[b]=d;d.push(a);e=new Image;e.onreadystatechange=AdfIEAgentLegacy._imageReadyCallback;d.image=e;e._src=b;e.src=b}};
AdfIEAgentLegacy.prototype.createXmlDocument=function(){if(window.ActiveXObject)try{return new ActiveXObject("Msxml2.DOMDocument")}catch(a){}var b=AdfPage.PAGE.getLookAndFeel().getTranslatedString("af_document.ACTIVEX_UNSUPPORTED");alert(b);return null};AdfIEAgentLegacy.prototype.getNodeXml=function(a){return a.xml};AdfIEAgentLegacy.prototype.getFormElement=function(a,b){for(var d=null,e=0;e<a.elements.length;e++){var f=a.elements[e];if(f.name==b){d=f;break}}return d};
AdfIEAgentLegacy.prototype.CreateNativeLogWriter=function(){var a=new AdfIELogWriter,b=this.getDomWindow(),d=b.console;return d&&d.log?new AdfIEConsoleLogWriter(b,a):a};AdfIEAgentLegacy.prototype.setOpacity=function(a,b){var d=a.getAttribute("filters"),d=d?d.alpha:null;null==d?100!=b&&(a.style.filter+="alpha(opacity\x3d"+b+")"):(d.opacity=b,d.enabled=100>b)};AdfIEAgentLegacy.prototype.execScript=function(a,b){b&&0<b.length&&a.execScript(b)};
AdfIEAgentLegacy.prototype.createStyle=function(a){var b=document.createElement("style");b.setAttribute("type","text/css");b.styleSheet.cssText=a;AdfDomUtils.getFirstDescendentElement(AdfAgent.AGENT.getDomDocument().documentElement,"HEAD").appendChild(b);return b};AdfIEAgentLegacy.prototype.getWindowHeight=function(){return this.getDomDocument().documentElement.clientHeight};AdfIEAgentLegacy.prototype.getWindowWidth=function(){return this.getDomDocument().documentElement.clientWidth};
AdfIEAgentLegacy.prototype.hasAttribute=function(a,b){return this.isAttributeSpecified(b)};AdfIEAgentLegacy.prototype.getIntAttribute=function(a,b,d){AdfAssert.assert(a);if(null==a.attributes)return d;a=a.getAttribute(b);if(void 0==a)return d;"string"==typeof a&&(a=parseInt(a));return a};AdfIEAgentLegacy.prototype.getBooleanAttribute=function(a,b,d){AdfAssert.assert(a);var e=a.getAttribute(b);return!0==e||!1==e?e:AdfIEAgentLegacy.superclass.getBooleanAttribute.call(this,a,b,d)};
AdfIEAgentLegacy.prototype.isFunctionKey=function(a){a=a.keyCode;return 112<=a&&123>=a};AdfIEAgentLegacy.prototype.isDisabledOptionSupported=function(){return!1};AdfIEAgentLegacy.prototype.isEqualIcon=function(a,b){var d=a.parentNode.innerHTML==b.parentNode.innerHTML;if(d)return!0;var e="IMG"==AdfAgent.AGENT.getNodeName(a),f="IMG"==AdfAgent.AGENT.getNodeName(b);return e&&f?(d=a.getAttribute("ALT"),e=b.getAttribute("ALT"),a.src!=b.src||d!=e?!1:!0):d};
AdfIEAgentLegacy.prototype.addOption=function(a,b,d,e,f,g,h){f||(f=this.getDomDocument().createElement("option"),a.options.add(f,h),null!=d&&(f.value=d),b&&AdfAgent.AGENT.setTextContent(f,b),f.selected=e,g&&(f.title=g))};AdfIEAgentLegacy.prototype.removeIdsFromDomSubTree=function(a){var b=a.id;null!=b&&""!=b&&(a.id="");a=a.all;for(var d=a.length,e=0;e<d;e++){var f=a(e),b=f.getAttribute("id");null!=b&&""!=b&&(f.id="")}};AdfIEAgentLegacy.prototype.removeStyleProperty=function(a,b){a.style.removeAttribute(b)};
AdfIEAgentLegacy._imageReadyCallback=function(){if("complete"==this.readyState){for(var a=AdfAgent.AGENT._imageURLs,b=this._src,d=a[b],e=d.length,f=0;f<e;f++)d[f].src=b;a[b]=AdfIEAgentLegacy._IMG_URL_LOADED;this._src=void 0;this.onreadystatechange=d.image=null}};
AdfIEAgentLegacy.prototype.setTableRowHeight=function(a,b){var d=0,e=0,f=a.cells[0];f&&(f=this.getComputedStyle(f),d=AdfAgent.getCSSLengthAsInt(f.paddingTop),e=AdfAgent.getCSSLengthAsInt(f.paddingBottom),borderTop=AdfAgent.getCSSLengthAsInt(f.borderTopWidth),borderBottom=AdfAgent.getCSSLengthAsInt(f.borderBottomWidth));a.style.height=b-d-e-borderTop-borderBottom+"px"};
AdfIEAgentLegacy.prototype.autoCompleteForm=function(a){AdfAssert.assertDomElement(a,"FORM");var b=this.getDomWindow().external;if(b&&"undefined"!=typeof b.AutoCompleteSaveForm)try{b.AutoCompleteSaveForm(a)}catch(d){AdfLogger.LOGGER.info("window.external autocomplete failed")}else AdfLogger.LOGGER.info("window.external property null, autocomplete disabled")};AdfIEAgentLegacy.prototype.GetCssToDomPropertyNameMap=function(){return AdfIEAgentLegacy._CSS_TO_DOM_MAP};
AdfIEAgentLegacy.prototype.getTableRowCells=function(a){var b=a.cells;if(!b.length&&a.firstChild){b=[];for(a=a.firstChild;a;)1==a.nodeType&&b.push(a),a=a.nextSibling}return b};AdfIEAgentLegacy.prototype.parseXML=function(a){var b=null;try{b=this.createXmlDocument(),b.loadXML(a)}catch(d){b=null}return b};AdfIEAgentLegacy.prototype.GetResizeEvents=function(){return AdfIEAgentLegacy._RESIZE_EVENTS};
AdfIEAgentLegacy.prototype.cloneNode=function(a){var b;try{b=a.cloneNode(!0)}catch(d){b=a.cloneNode(!1),b.innerHTML=a.innerHTML}return b};AdfIEAgentLegacy.prototype.clearSubtreeIds=function(a){a.id&&(a.id=void 0!=typeof a.uniqueID&&void 0!=a.uniqueID?a.uniqueID:"");a.name&&(a.name=void 0!=typeof a.uniqueID&&void 0!=a.uniqueID?a.name+a.uniqueID:"");for(a=a.firstChild;a;)1==a.nodeType&&this.clearSubtreeIds(a),a=a.nextSibling};AdfIEAgentLegacy.prototype.IsComputedWidthAuto=function(){return!0};
AdfIEAgentLegacy.prototype.supportsTransientStyleClasses=function(){return!1};AdfIEAgentLegacy.prototype.slice=function(a,b,d){if(!("undefined"===typeof Blob||"undefined"===typeof Blob.prototype.slice)){if(null==a)return null;if(a.slice)return a.slice(b,d)}};
AdfIEAgentLegacy.prototype.toISOString=function(a){AdfAssert.assert(null!=a);if(a.toISOString)return a.toISOString();var b=function(a){return 10>a?"0"+a:a};return a.getUTCFullYear()+"-"+b(a.getUTCMonth()+1)+"-"+b(a.getUTCDate())+"T"+b(a.getUTCHours())+":"+b(a.getUTCMinutes())+":"+b(a.getUTCSeconds())+"."+(a.getUTCMilliseconds()/1E3).toFixed(3).slice(2,5)+"Z"};AdfIEAgentLegacy._IMG_URL_LOADED={};AdfIEAgentLegacy._REDISTRIBUTE_EVENTS="onclick ondblclick onkeydown onkeyup onkeypress onmousedown onmousemove onmouseout onmouseover onmouseup onfocusin onfocusout oncontextmenu".split(" ");
AdfIEAgentLegacy._CSS3_TO_IE_MAP={auto:"auto","default":"default",none:"default","context-menu":"default",help:"help",pointer:"pointer",progress:"progress",wait:"wait",cell:"crosshair",crosshair:"crosshair",text:"text","vertical-text":"vertical-text",alias:"crosshair",copy:"crosshair",move:"move","no-drop":"no-drop","not-allowed":"not-allowed","e-resize":"e-resize","n-resize":"n-resize","ne-resize":"ne-resize","nw-resize":"nw-resize","s-resize":"s-resize","se-resize":"se-resize","sw-resize":"sw-resize",
"w-resize":"w-resize","ew-resize":"e-resize","ns-resize":"n-resize","nesw-resize":"move","col-resize":"col-resize","row-resize":"row-resize","all-scroll":"all-scroll",inherit:"auto"};AdfIEAgentLegacy._CSS_TO_DOM_MAP={"float":"styleFloat"};AdfIEAgentLegacy._RESIZE_EVENTS=["resize"];