var AdfDomUtils={isVisible:function(a){return null==a?!1:"none"!=a.style.display},isInVisibleSubtree:function(a){if(null==a)return!1;for(;null!=a;){if(a.style&&"none"==a.style.display)return!1;a=a.parentNode}return!0},stripScripts:function(a){var b=a.childNodes;if(null!=b)for(var d=null,e=b.length-1;-1<e;e--)d=b[e],1==d.nodeType&&"SCRIPT"==d.tagName&&a.removeChild(d)},setVisible:function(a,b){AdfAssert.assert(null!=a);a.style.display="true"===b||!0===b?"":"none"},getOffsetSizeFromCssLength:function(a,
b){if(-1!=b.indexOf("px"))return parseInt(b,10);var d=a.ownerDocument.createElement("div");try{d.style.width=b}catch(f){AdfLogger.LOGGER.fine("Exception while trying to  style width to: "+b)}a.appendChild(d);var e=d.offsetWidth;a.removeChild(d);return e},isNodeInDocumentHierarchy:function(a,b){AdfAssert.assertDomNode(a);AdfAssert.assertDomNode(b);if(b==a)return!0;if(a==b.ownerDocument)for(;null!=b;)if(b=b.parentNode,b==a)return!0;return!1},isAncestor:function(a,b){if(null!=b)for(var d=b?b.parentNode:
null;d;){if(d==a)return!0;d=d.parentNode}return!1},isAncestorOrSelf:function(a,b){return b==a?!0:AdfDomUtils.isAncestor(a,b)},getNodeDistance:function(a,b){if(a==b)return 0;var d=0,e;if(AdfDomUtils.isAncestor(a,b))for(e=b.parentNode;e;){d++;if(e==a)return d;e=e.parentNode}else if(AdfDomUtils.isAncestor(b,a))for(e=a.parentNode;e;){d++;if(e==b)return d;e=e.parentNode}return(d=AdfDomUtils.getCommonAncestor(a,b))?AdfDomUtils.getNodeDistance(d,a)+AdfDomUtils.getNodeDistance(d,b):Number.POSITIVE_INFINITY},
getCommonAncestor:function(a,b){if(a==b)return a;for(var d=a;d;){if(AdfDomUtils.isAncestor(d,b))return d;d=d.parentNode}return null},getFormElement:function(a){AdfAssert.assertDomNode(a);for(var b=a.ownerDocument,d=AdfAgent.AGENT;a!=b;){if("FORM"==d.getNodeName(a))return a;a=a.parentNode;AdfAssert.assert(a,"Should never get this far with disconnected DOM")}return null},getInputFileForm:function(a){for(var b=a.getElementsByTagName("input"),d=b.length,e=null,f=0;f<d;++f){var g=b[f];if("file"==g.type&&
(g.value||"true"==g.getAttribute("_afrMultiFileUpload"))){e=a;break}}return e},isMultiPartForm:function(a){a=a.enctype;return null!=a&&"multipart/form-data"==a.toLowerCase()?!0:!1},getFormElementValue:function(a,b){for(var d=[],e=a.elements,f=0,g=e.length;f<g;++f)e[f].getAttribute("name")==b&&d.push(e[f]);if(0==d.length)return null;f=d[0];switch(f.tagName){case "TEXTAREA":return f.value;case "INPUT":switch(f.getAttribute("type")){case "radio":f=0;for(g=d.length;f<g;++f)if(d[f].checked)return d[f].value;
return null;case "checkbox":if(1==d.length)return f.checked?f.value:null;e=[];f=0;for(g=d.length;f<g;++f)d[f].checked&&e.push(d[f].value);return e;default:return f.value}case "SELECT":if(1==f.multiple){e=[];d=f.options;f=0;for(g=d.length;f<g;++f)d[f].selected&&e.push(d[f].value);return 0==e.length?null:e}return f.value;default:return null}},getFirstElementByTagName:function(a,b){if(null==a)return null;var d=a.getElementsByTagName(b);return d.length?d[0]:null},getLastElementByTagName:function(a,b){if(null==
a)return null;var d=a.getElementsByTagName(b);return d.length?d[d.length-1]:null},getFirstDescendentElement:function(a,b){return AdfDomUtils.getDescendentElement(a,b,0)},getDescendentElement:function(a,b,d){AdfAssert.assertDomElement(a);AdfAssert.assertString(b);AdfAssert.assertNumber(d);b=a.getElementsByTagName(b);AdfAssert.assert(b);var e=b.length;return e>d?(b[0]==a&&e>d+1&&d++,b[d]):null},getFirstChildElement:function(a){return AdfDomUtils.getFirstChildNodeByType(a,1)},getElement:function(a){if(null==
a)return null;for(;null!=a;a=a.parentNode)if(1==a.nodeType)return a;return null},getChildElements:function(a){a=a.childNodes;var b=[];if(a)for(var d=a.length,e=0;e<d;e++){var f=a[e];1==f.nodeType&&b.push(f)}return b},getLastChildElement:function(a){if(a=a.childNodes)for(var b=a.length-1;0<=b;b--){var d=a[b];if(1==d.nodeType)return d}return null},getNonWhitespaceChildCount:function(a){var b=0;if(a=a.childNodes)for(var d=a.length,e=0;e<d;e++){var f=a[e],g=f.nodeType;8!=g&&(3==g?0!=f.data.replace(/\s*/,
"").length&&++b:1==g&&(null!=f.style&&"none"==f.style.display||++b))}return b},getOnlyChildElement:function(a){var b=null;if(a=a.childNodes)for(var d=a.length,e=0;e<d;e++){childNode=a[e];var f=childNode.nodeType;if(8!=f)if(3==f){if(0<childNode.data.replace(/\s*/,"").length)return null}else if(1==f){if(null==childNode.style||"none"!=childNode.style.display){if(b)return null;b=childNode}}else return null}return b},getInputElementsInNode:function(a,b,d){var e=AdfAgent.AGENT.getDomDocument(),f=[];if(e.evaluate){var g=
".//input|.//select|.//textarea|.//button|.//a";if(d)for(var h=0;h<d.length;h++)g=g+"|.//"+d[h];a=e.evaluate(g,a,null,XPathResult.ANY_TYPE,null);for(d=a.iterateNext();d;)!b&&(d.disabled||-1==d.tabIndex)||"A"==d.nodeName&&!d.href||f.push(d),d=a.iterateNext()}else{a=a.getElementsByTagName("*");e=a.length;g="^INPUT|SELECT|BUTTON|^A\\b|TEXTAREA";if(d)for(var k,h=0;h<d.length;h++)k=d[h].toUpperCase(),g=g+"|"+k;g=new RegExp(g);for(h=0;h<e;h++)d=a[h],d.tagName.match(g)&&(b||!d.disabled&&-1!=d.tabIndex)&&
("A"!=d.nodeName||d.href)&&f.push(d)}return f},disableTabStop:function(a,b){for(var d=AdfDomUtils.getInputElementsInNode(a,!0,["ul"]),e=0;e<d.length;e++){var f=d[e];b?(void 0===f._afrTabIndex&&void 0!==f.tabIndex&&-1!==f.tabIndex&&(f._afrTabIndex=f.tabIndex,f.tabIndex=-1),void 0===f._afrOverflow&&"UL"==f.tagName&&AdfAgent.AGENT.getPlatform()==AdfAgent.GECKO_PLATFORM&&(f._afrOverflow=f.style.overflow,f.style.overflow="hidden")):(void 0!==f._afrTabIndex&&(f.tabIndex=f._afrTabIndex,delete f._afrTabIndex),
void 0!==f._afrOverflow&&(f.style.overflow=f._afrOverflow,delete f._afrOverflow))}},getNextElement:function(a){if(a)for(a=a.nextSibling;a;){if(1==a.nodeType)return a;a=a.nextSibling}},getPreviousElement:function(a){if(a)for(a=a.previousSibling;a;){if(1==a.nodeType)return a;a=a.previousSibling}},getFirstChildNodeByType:function(a,b){var d=a.childNodes;if(d)for(var e=d.length,f=0;f<e;f++){var g=d[f];if(g.nodeType==b)return g}return null},getRelativePosition:function(a){var b=a.offsetLeft,d=a.offsetTop,
e=AdfAgent.AGENT;for(a=a.offsetParent;a;){var f=e.getComputedStyle(a);if("static"!=f.position&&(e.getPlatform()!=AdfAgent.GECKO_PLATFORM||"TD"!=a.tagName||"relative"!=f.position))break;b+=a.offsetLeft;d+=a.offsetTop;a=a.offsetParent}return{x:b,y:d}},getElementPosition:function(a){var b=-1;if(a){var d=a;for(a=a.nodeType;d;)d.nodeType==a&&b++,d=d.previousSibling}return b},getChildElementByPosition:function(a,b,d){var e=null;if(a)for(var f=-1,e=a.firstChild;e&&f<d;)e.nodeType==b&&f++,f!=d&&(e=e.nextSibling);
return e},getElementDepth:function(a){AdfAssert.assertDomElement(a);var b=-1;do b++,a=a.parentNode;while(a);return b},getElementAtPoint:function(a,b,d,e,f){var g=AdfAgent.AGENT,h=0==a.offsetHeight;if(!(f&&f[a.localName]||!h&&!g.pointInElementBounds(a,b,d)))for(h||(e=a),a=a.firstChild;a;){if(1==a.nodeType&&(h=g.getComputedStyle(a),!h||"hidden"!=h.visibility&&"none"!=h.display)&&(h=AdfDomUtils.getElementAtPoint(a,b,d,e,f),h!=e))return h;a=a.nextSibling}return e},canScroll:function(a,b,d){return a.scrollWidth!=
b||a.scrollHeight!=d},getAutoScrollDeltas:function(a,b,d){var e=a.clientWidth,f=a.clientHeight,g=0,h=0,k=a.scrollTop,l=a.scrollLeft;b-=l;d-=k;l&&5>b?g=-Math.min(l,10):5>e-b&&(g=Math.min(a.scrollWidth-e,10));k&&5>d?h=-Math.min(k,10):5>f-d&&(h=Math.min(a.scrollHeight-f,10));return g||h?{x:g,y:h}:null},removeAllNodes:function(a){for(var b=a.childNodes,d=b.length-1;0<=d;d--)a.removeChild(b[d])},scrollRightBy:function(a,b){AdfDomUtils.setScrollLeft(a,a.scrollLeft+b)},setScrollLeft:function(a,b){b=Math.max(b,
0);a.scrollLeft=Math.min(b,a.scrollWidth-a.clientWidth)},scrollDownBy:function(a,b){AdfDomUtils.setScrollTop(a,a.scrollTop+b)},setScrollTop:function(a,b){b=Math.max(b,0);a.scrollTop=Math.min(b,a.scrollHeight-a.clientHeight)},scrollChildIntoViewY:function(a){var b=a.offsetTop,d=a.offsetHeight,e=a.offsetParent;for(a=a.parentNode;a&&a.scrollHeight<=a.offsetHeight;)a.offsetParent!=e&&(b+=a.offsetTop,e=a.offsetParent),a=a.parentNode;null!=a&&(b<a.scrollTop?a.scrollTop=b:b+d>a.scrollTop+a.clientHeight&&
(a.scrollTop=b+d-a.clientHeight))},getNodeInfo:function(a){var b="";a&&(b+=a.nodeName,a.id&&(b+=" id\x3d"+a.id),a._afrpeerid&&(b+=" peer id\x3d"+a._afrpeerid),a.className&&(b+=" class\x3d"+a.className));return b},suppressActionLinkBrowserContextMenu:function(a){var b=AdfAgent.AGENT,d=a.getNativeEvent(),e=AdfDomUtils.getElement(b.getEventTarget(d)),f=e.getAttribute("href",2);if(null==f||""==f)a=a.getSource().getPeer().getDomElement().parentNode,e=AdfDomUtils.getParentWithAttr(a,e,"href"),null!=e&&
(f=e.getAttribute("href",2));null!=f&&("#"!=f&&0!=f.indexOf("javascript:")||b.preventDefault(d))},swapIcon:function(a,b){var d=AdfPage.PAGE.getLookAndFeel().getRawIcon(b),e=AdfAgent.AGENT;null==d||e.isEqualIcon(a,d)||(e.getPlatform()==AdfAgent.IE_PLATFORM&&a.tagName==d.tagName&&"IMG"==d.tagName?(a.src=d.src,a.alt=d.alt,a.title=a.title,a.border=d.border):(d=d.cloneNode(!0),e.replaceNode(d,a)))},_getCSSClassNameIndex:function(a,b){if(a&&"string"===typeof a){if(b===a)return 0;var d=b.length,e=a.length;
if(!a.indexOf)return-1;var f=a.indexOf(b);if(0<=f){var g=0==f||" "==a.charAt(f-1),h=f+d,h=h==e||" "==a.charAt(h);if(g&&h)return f;var k=a.lastIndexOf(b);if(k!=f)return g=a.charAt(k-1),h=k+d,h=h==e||" "==a.charAt(h),g&&h?k:a.indexOf(" "+b+" ")}}return-1},addCSSClassName:function(a,b){AdfAssert.assertDomElement(a);var d=!1;if(null!=b){AdfAssert.assertString(b);var e=a.className;-1==AdfDomUtils._getCSSClassNameIndex(e,b)&&(a.className=e?b+" "+e:b,d=!0)}return d},removeCSSClassName:function(a,b){AdfAssert.assertDomElement(a);
var d=!1;if(null!=b){var e=a.className,f=AdfDomUtils._getCSSClassNameIndex(e,b);-1!=f&&(d=f+b.length,f=0==f?null:e.substring(0,f),e=d==e.length?null:e.substring(d+1),a.className=null==f?null==e?"":e:null==e?f:f+e,d=!0)}return d},addOrRemoveCSSClassName:function(a,b,d){return(a?AdfDomUtils.addCSSClassName:AdfDomUtils.removeCSSClassName)(b,d)},containsCSSClassName:function(a,b){return null!=b?-1!=AdfDomUtils._getCSSClassNameIndex(a.className,b):!1},addInlineStyle:function(a,b,d){if(null!=b){var e=a.style.cssText;
a.style.cssText=null==e||""==e?b:1==d?e+";"+b:b+";"+e}},fillEmptyCell:function(a){AdfAssert.assertDomElement(a,"TD");if(null==a.firstChild){var b=a.ownerDocument.createElement("div");a.appendChild(b)}},getElementsByClassName:function(a,b){null==a&&(a=AdfAgent.AGENT.getDomDocument().documentElement);for(var d=a.getElementsByTagName("*"),e=d.length,f=[],g,h=0;h<e;h++)g=d[h],AdfDomUtils.containsCSSClassName(g,b)&&f.push(g);return f},setAccessibleState:function(a,b){var d=AdfAgent.AGENT,e=AdfRichUIPeer.CreateSubId(a.getClientId(),
"state"),e=d.getElementById(e);AdfAssert.assertDomNode(e);null!=b?d.setTextContent(e," "+b+" "):d.setTextContent(e,"")},getFirstElementMatch:function(a,b,d,e){AdfAssert.assertFunction(d);AdfAssert.assertDomElement(a);if(!b&&d(a,e))return a;if(a.getElementsByTagName){a=a.getElementsByTagName("*");b=a.length;for(var f=0;f<b;f++){var g=a[f];if(d(g,e))return g}}return null},getNextElementMatch:function(a,b,d,e,f){AdfAssert.assertFunction(e);AdfAssert.assertDomElement(a);AdfAssert.assertDomElementOrNull(b);
var g=null;if(!d&&(g=AdfDomUtils.getFirstElementMatch(a,!0,e,f),null!=g))return g;for(;a&&a!=b;)if(a.nextSibling){if(a=a.nextSibling,1==a.nodeType&&(g=AdfDomUtils.getFirstElementMatch(a,!1,e,f),null!=g))return g}else a=a.parentNode;return null},getLastElementMatch:function(a,b,d,e){AdfAssert.assertFunction(d);AdfAssert.assertDomElement(a);if(a.getElementsByTagName)for(var f=a.getElementsByTagName("*"),g=f.length-1;0<=g;g--){var h=f[g];if(d(h,e))return h}return!b&&d(a,e)?a:null},getPreviousElementMatch:function(a,
b,d,e){AdfAssert.assertFunction(d);AdfAssert.assertDomElement(a);for(AdfAssert.assertDomElementOrNull(b);a&&a!=b;){for(var f=a.previousSibling;f&&1!=f.nodeType;)f=f.previousSibling;if(f){matchElement=AdfDomUtils.getLastElementMatch(f,!1,d,e);if(null!=matchElement)return matchElement;a=f}else if(a=a.parentNode,a!=b&&d(a,e))return a}return null},getFirstFilteredElement:function(a,b,d,e){AdfAssert.assertFunction(d);AdfAssert.assertDomElement(a);var f=d(a,e);return b||f!=AdfDomUtils.FILTER_ACCEPT?f==
AdfDomUtils.FILTER_REJECT?null:AdfDomUtils.depthFirstFilter(a,a,d,e):a},depthFirstFilter:function(a,b,d,e){if(null==a)return null;var f=d(a,e);a==b&&(f=AdfDomUtils.FILTER_SKIP);if(f==AdfDomUtils.FILTER_ACCEPT)return a;var g=null;if(f!=AdfDomUtils.FILTER_REJECT)for(a=a.firstChild;a&&!g;)g=AdfDomUtils.depthFirstFilter(a,b,d,e),a=a.nextSibling;return g},getNextFilteredElement:function(a,b,d,e,f){AdfAssert.assertFunction(e);AdfAssert.assertDomElement(a);AdfAssert.assertDomElementOrNull(b);var g=null;
if(!d&&(g=AdfDomUtils.getFirstFilteredElement(a,!1,e,f),null!=g))return g;for(;a&&a!=b;)if(a.nextSibling){if(a=a.nextSibling,1==a.nodeType&&(g=AdfDomUtils.getFirstFilteredElement(a,!1,e,f),null!=g))return g}else if((a=a.parentNode)&&a!=b&&1==a.nodeType&&e(a,f)==AdfDomUtils.FILTER_ACCEPT)return a;return null},reverseDepthFirstFilter:function(a,b,d,e){if(null==a)return null;var f=d(a,e),g=null;a==b&&(f=AdfDomUtils.FILTER_SKIP);if(f!=AdfDomUtils.FILTER_REJECT)for(var h=a.lastChild;h&&!g;)g=AdfDomUtils.reverseDepthFirstFilter(h,
b,d,e),h=h.previousSibling;g||f!=AdfDomUtils.FILTER_ACCEPT||(g=a);return g},getLastFilteredElement:function(a,b,d,e){AdfAssert.assertFunction(d);AdfAssert.assertDomElement(a);var f=AdfDomUtils.reverseDepthFirstFilter(a,a,d,e);return null!=f?f:b||d(a,e)!=AdfDomUtils.FILTER_ACCEPT?null:a},getPreviousFilteredElement:function(a,b,d,e){AdfAssert.assertFunction(d);AdfAssert.assertDomElement(a);AdfAssert.assertDomElementOrNull(b);for(var f=null;a&&a!=b;)if(a.previousSibling){if(a=a.previousSibling,1==a.nodeType&&
(f=AdfDomUtils.getLastFilteredElement(a,!1,d,e),null!=f))return f}else if((a=a.parentNode)&&a!=b&&1==a.nodeType&&d(a,e)==AdfDomUtils.FILTER_ACCEPT)return a;return null},getParentWithAttr:function(a,b,d){for(;b&&b!=a;){if(1==b.nodeType&&AdfAgent.AGENT.getAttribute(b,d))return b;b=b.parentNode}return null}};
AdfDomUtils.getFirstChildElementByAttributeValue=AdfDomUtils.getChildElementByAttributeValue=function(a,b,d,e){AdfAssert.assertNonEmptyString(b);AdfAssert.assertString(d);AdfAssert.assertDomElement(a);e||(e="*");a=a.getElementsByTagName(e);e=a.length;for(var f=0;f<e;f++)if(element=a[f],element.getAttribute(b)==d)return element;return null};
AdfDomUtils.getLastChildElementByAttributeValue=function(a,b,d,e){AdfAssert.assertNonEmptyString(b);AdfAssert.assertString(d);AdfAssert.assertDomElement(a);e||(e="*");a=a.getElementsByTagName(e);for(e=a.length-1;0<=e;e--)if(element=a[e],element.getAttribute(b)==d)return element;return null};
AdfDomUtils.getChildElementsByAttributeValue=function(a,b,d,e){AdfAssert.assertNonEmptyString(b);AdfAssert.assertNonEmptyString(d);AdfAssert.assertDomElement(a);e||(e="*");a=a.getElementsByTagName(e);e=a.length;for(var f=[],g=0;g<e;g++){var h=a[g];h.getAttribute(b)==d&&f.push(h)}return 0<f.length?f:null};
AdfDomUtils.getChildElementsByMatch=function(a,b,d,e){AdfAssert.assertDomElement(a);AdfAssert.assertFunction(b);d||(d="*");a=a.getElementsByTagName(d);d=a.length;for(var f=[],g=0;g<d;g++){var h=a[g];b(h,e)&&f.push(h)}return 0<f.length?f:null};AdfDomUtils.getChildElementsByMatch=function(a,b,d,e){AdfAssert.assertDomElement(a);AdfAssert.assertFunction(b);d||(d="*");a=a.getElementsByTagName(d);d=a.length;for(var f=[],g=0;g<d;g++){var h=a[g];b(h,e)&&f.push(h)}return 0<f.length?f:null};
AdfDomUtils.getChildElementByValueMap=function(a,b,d){AdfAssert.assertDomElement(a);AdfAssert.assertArray(b);AdfAssert.assert(2==b.length);d||(d="*");return AdfDomUtils.getChildElementByAttributeValue(a,b[0],b[1],d)};AdfDomUtils.getTabIndex=function(a){AdfAssert.assertDomElement(a);var b=AdfAgent.AGENT,d=a.attributes.tabIndex;return null!=d&&b.hasAttribute(a,d)?d.value:void 0};
AdfDomUtils.cleanHtml=function(a,b){var d=a.createElement("span");(d.innerHTML=b)&&0<=b.indexOf("\x3c")&&AdfDomUtils._cleanElementHtml(d);return d};
AdfDomUtils._cleanElementHtml=function(a){for(var b=AdfAgent.AGENT,d=a.childNodes,e=d.length-1;0<=e;){var f=d.item(e);if(1==f.nodeType)if(AdfDomUtils._LEGAL_ELEMENTS[f.nodeName]){for(var g=f.attributes,h=g.length-1;0<=h;h--){var k=g[h];b.hasAttribute(f,k)&&(AdfDomUtils._LEGAL_ATTRIBUTES[k.name]||f.removeAttribute(k.nodeName))}AdfDomUtils._cleanElementHtml(f)}else a.removeChild(f);e--}};
AdfDomUtils.findAccessKeyDom=function(a,b){if(null==b)return null;for(var d=a.childNodes,e=0;e<d.length;++e)if(AdfAgent.AGENT.getTextContent(d[e])==b)return d[e];return null};
AdfDomUtils.handleTextChangeWithAccessKey=function(a,b,d){if(null==b)return!1;var e=a.getPropertyValue("accessKey"),f=AdfDomUtils.findAccessKeyDom(b,e);if(null!=e){var g=a.getPeer().getDomDocument();return null!=f?(a=d.indexOf(e),-1==a?(AdfDomUtils._removeAccessKeyElement(b,f),AdfDomUtils._setTextContent(b,d)):(AdfDomUtils._removeSiblings(f),0<a&&b.insertBefore(g.createTextNode(d.substring(0,a)),f),AdfDomUtils._setTextContent(f,e),a+1<d.length&&b.appendChild(g.createTextNode(d.substr(a+1)))),!0):
AdfDomUtils._setTextAndAccessKeySpan(a,b,e,f,d)}null!=f&&AdfDomUtils._removeAccessKeyElement(f);AdfDomUtils._setTextContent(b,d);return!0};AdfDomUtils.launchHelpWindow=function(a){var b=AdfDomUtils._getHelpWindowName();null==b&&(b="RCFHelpWindow",AdfDomUtils._setHelpWindowName(b));window.open(a,b,"width\x3d650,height\x3d450,resizable\x3dyes,scrollbars\x3dyes,alwaysRaised").focus()};
AdfDomUtils.writeAttributesToElement=function(a,b){var d=AdfAgent.AGENT,e;for(e in b){var f=b[e];void 0!=f&&d.setAttribute(a,e,f)}};AdfDomUtils.copyAllAttributes=function(a,b){for(var d=0;d<a.attributes.length;d++){var e=a.attributes[d];b.setAttribute(e.nodeName,e.value)}};AdfDomUtils.getPopupAncestor=function(a){var b=null;try{b=a.getParent()}catch(d){}if(null==b)return null;for(;null!=b;){if(b instanceof AdfRichPopup)return b;try{b=b.getParent()}catch(d){return!1}if(null==b)return!1}};
AdfDomUtils.isInPopup=function(a){a=AdfDomUtils.getPopupAncestor(a);return null==a?null:0==a?!1:!0};AdfDomUtils._getHelpWindowName=function(){for(var a=AdfDomUtils._HELP_WINDOW_NAME_COOKIE+"\x3d",b=document.cookie.split(";"),d=b.length,e=0;e<d;e++){for(var f=b[e],g=0;" "==f.charAt(g);)g++;f=f.substring(g,f.length);if(0==f.indexOf(a))return f.substring(a.length,f.length)}return null};AdfDomUtils._setHelpWindowName=function(a){document.cookie=AdfDomUtils._HELP_WINDOW_NAME_COOKIE+"\x3d"+a+"; ; path\x3d/"};
AdfDomUtils._setTextAndAccessKeySpan=function(a,b,d,e,f){var g=AdfAgent.AGENT.getExpandoProperty(b,"_adfAccessKeyStyleClass",null);if(null==g)AdfDomUtils._setTextContent(b,f);else{var h=f.indexOf(d);if(0<=h){if(0<h)AdfAgent.AGENT.setTextContent(b,f.substring(0,h));else for(;null!=b.lastChild;)b.removeChild(b.lastChild);a=a.getPeer().getDomDocument();e=a.createElement("SPAN");e.className=g;AdfAgent.AGENT.setTextContent(e,d);b.appendChild(e);h+1<f.length&&b.appendChild(a.createTextNode(f.substr(h+1)))}else AdfAgent.AGENT.setTextContent(b,
f)}return!0};AdfDomUtils._removeSiblings=function(a){for(var b,d=a.parentNode;null!=(b=a.previousSibling);)d.removeChild(b);for(;null!=(b=a.nextSibling);)d.removeChild(b)};AdfDomUtils._setTextContent=function(a,b){"BUTTON"==a.tagName?AdfAgent.AGENT.setButtonTextContent(a,b):AdfAgent.AGENT.setTextContent(a,b)};AdfDomUtils._removeAccessKeyElement=function(a,b){AdfAgent.AGENT.setExpandoProperty(a,"_adfAccessKeyStyleClass",b.className);b.parentNode.removeChild(b)};
AdfDomUtils.__componentTextChanged=function(a,b,d,e){if(null!=e){e=AdfDomUtils.getFirstDescendentElement(b,"SPAN");var f=a.getPropertyValue("accessKey"),f=null==f?null:AdfDomUtils.findAccessKeyDom(b,f);return AdfDomUtils.handleTextChangeWithAccessKey(a,e&&e!=f?e:b,d)}return!1};
AdfDomUtils.componentShowRequiredChanged=function(a,b,d,e){a=AdfDomUtils.getFirstElementMatch(b,!0,AdfDomUtils._matchRequiredIconSpan);if(!a)return!1;d?(d=AdfPage.PAGE.getLookAndFeel().getIcon("AFRequiredIcon"),a.appendChild(d)):AdfDomUtils.removeAllNodes(a);return!0};AdfDomUtils._matchRequiredIconSpan=function(a){return"SPAN"==a.tagName&&AdfDomUtils.containsCSSClassName(a,AdfDomUtils._REQUIRED_ICON_PLACEHOLDER_STYLE_CLASS)?!0:!1};AdfDomUtils._REQUIRED_ICON_PLACEHOLDER_STYLE_CLASS="p_rqi";
AdfDomUtils._LEGAL_ELEMENTS={SPAN:1,B:1,A:1,I:1,EM:1,BR:1,HR:1,LI:1,OL:1,UL:1,P:1,TT:1,BIG:1,SMALL:1,PRE:1};AdfDomUtils._LEGAL_ATTRIBUTES={"class":1,style:1,href:1};AdfDomUtils._HELP_WINDOW_NAME_COOKIE="ORA_ADF_HELPWINDOWNAME";AdfDomUtils.FILTER_ACCEPT=1;AdfDomUtils.FILTER_REJECT=0;AdfDomUtils.FILTER_SKIP=-1;