if(idc.isWebFeatureRequired("idcRounded")){idc.Rounded=function idc_Rounded(elmtId,corners,cornerPattern){this.elmtId=elmtId;
this.elmt=document.getElementById(elmtId);this.cornerPattern=(typeof cornerPattern!=="undefined")?cornerPattern:"small";this.roundTL=false;
this.roundTR=false;this.roundBL=false;this.roundBR=false;this.backgroundColor=null;this.backgroundImage=null;this.backgroundRepeat=null;
this.borderColor=null;this.borderStyle=null;this.borderTopWidth=null;this.borderBottomWidth=null;this.borderLeftWidth=null;
this.borderRightWidth=null;this.stdShimElmt=null;this.topGroupElmt=null;this.bottomGroupElmt=null;this.groupHeight=0;corners=(typeof corners!=="undefined")?corners.toLowerCase():"all";
this.setCornerFlags(corners);this.getStyleValues();this.createStdShimElmt();window[elmtId]=this};idc.Rounded._VERSION="1.0";
idc.Rounded._NAME="idc.Rounded";idc.Rounded.prototype={roundCorners:function idc_Rounded_roundCorners(){var i,childElmt;if(this.elmt){this.elmt.style.backgroundColor="transparent";
this.elmt.style.backgroundImage="none";if(this.borderStyle==="solid"){this.elmt.style.borderLeftStyle="none";this.elmt.style.borderRightStyle="none";
if(this.roundTL||this.roundTR){this.elmt.style.borderTopStyle="none"}if(this.roundBL||this.roundBR){this.elmt.style.borderBottomStyle="none"
}}for(i=0;i<this.elmt.childNodes.length;i++){childElmt=this.elmt.childNodes[i];if(childElmt.nodeType===1){childElmt.style.backgroundColor=this.backgroundColor;
childElmt.style.backgroundImage=this.backgroundImage;childElmt.style.backgroundRepeat=this.backgroundRepeat;childElmt.style.backgroundPosition="0px -"+this.groupHeight+"px";
if(this.borderStyle==="solid"){childElmt.style.borderLeft=this.borderLeftWidth+" solid "+this.borderColor;childElmt.style.borderRight=this.borderLeftWidth+" solid "+this.borderColor
}}}if(this.roundTL||this.roundTR){this.topGroupElmt=document.createElement("div");this.topGroupElmt.style.display="block";
this.topGroupElmt.style.background="transparent";this.createShims(this.topGroupElmt);this.elmt.insertBefore(this.topGroupElmt,this.elmt.firstChild)
}if(this.roundBL||this.roundBR){this.bottomGroupElmt=document.createElement("div");this.bottomGroupElmt.style.display="block";
this.bottomGroupElmt.style.background="transparent";this.createShims(this.bottomGroupElmt);this.elmt.appendChild(this.bottomGroupElmt)
}}},patterns:{small:[{margin:"2px",height:"1px",borderWidth:null},{margin:"1px",height:"1px",borderWidth:"1px"}],large:[{margin:"5px",height:"1px",borderWidth:null},{margin:"3px",height:"1px",borderWidth:"2px"},{margin:"2px",height:"1px",borderWidth:"1px"},{margin:"1px",height:"2px",borderWidth:"1px"}],xLarge:[{margin:"15px",height:"1px",borderWidth:null},{margin:"12px",height:"1px",borderWidth:"3px"},{margin:"10px",height:"1px",borderWidth:"2px"},{margin:"8px",height:"1px",borderWidth:"2px"},{margin:"7px",height:"1px",borderWidth:"1px"},{margin:"6px",height:"1px",borderWidth:"1px"},{margin:"5px",height:"1px",borderWidth:"1px"},{margin:"4px",height:"1px",borderWidth:"1px"},{margin:"3px",height:"2px",borderWidth:"1px"},{margin:"2px",height:"2px",borderWidth:"1px"},{margin:"1px",height:"3px",borderWidth:"1px"}]},createShims:function idc_Rounded_createShims(groupElmt){var pattern,group,roundLeft,roundRight,accumulatedShimHeight,i,shim,backgroundLeftAdjust,bWidth;
pattern=this.patterns[this.cornerPattern];group=(groupElmt===this.topGroupElmt)?"top":"bottom";roundLeft=((group==="top"&&this.roundTL)||(group==="bottom"&&this.roundBL));
roundRight=((group==="top"&&this.roundTR)||(group==="bottom"&&this.roundBR));accumulatedShimHeight=0;for(i=0;i<pattern.length;
i++){shim=this.stdShimElmt.cloneNode(false);backgroundLeftAdjust=0;shim.className=(i===0)?"outerShim":"innerShim";shim.style.height=pattern[i].height;
if(roundLeft){shim.style.marginLeft=pattern[i].margin}if(roundRight){shim.style.marginRight=pattern[i].margin}bWidth;if(this.borderStyle==="solid"){bWidth=(roundLeft)?pattern[i].borderWidth:this.borderLeftWidth;
if(bWidth&&this.borderLeftWidth!=="0px"){shim.style.borderLeft=bWidth+" solid "+this.borderColor;if(this.backgroundImage!=="none"&&group==="top"){backgroundLeftAdjust+=parseInt(bWidth,10)-parseInt(this.borderLeftWidth,10)
}}bWidth=(roundRight)?pattern[i].borderWidth:this.borderRightWidth;if(bWidth&&this.borderRightWidth!=="0px"){shim.style.borderRight=bWidth+" solid "+this.borderColor
}if(shim.className==="outerShim"){if((group==="top"&&this.borderTopWidth!=="0px")||(group==="bottom"&&this.borderBottomWidth!=="0px")){shim.style.backgroundColor=this.borderColor
}shim.style.backgroundImage="none"}}if(this.backgroundImage!=="none"){if(group==="top"){backgroundLeftAdjust+=parseInt(shim.style.marginLeft,10);
shim.style.backgroundPosition="-"+backgroundLeftAdjust+"px -"+accumulatedShimHeight+"px"}else{shim.style.backgroundImage="none"
}}if(shim.className==="outerShim"&&this.borderStyle==="solid"){}else{accumulatedShimHeight+=parseInt(pattern[i].height,10)
}if(group==="top"||i===0){groupElmt.appendChild(shim)}else{groupElmt.insertBefore(shim,groupElmt.firstChild)}}this.groupHeight=accumulatedShimHeight
},setCornerFlags:function idc_Rounded_setCornerFlags(corners){if(corners.indexOf("all")>-1||corners===""){this.roundTL=true;
this.roundTR=true;this.roundBL=true;this.roundBR=true}else{if(corners.indexOf("top")>-1||corners.indexOf("tl")>-1){this.roundTL=true
}if(corners.indexOf("top")>-1||corners.indexOf("tr")>-1){this.roundTR=true}if(corners.indexOf("bottom")>-1||corners.indexOf("bl")>-1){this.roundBL=true
}if(corners.indexOf("bottom")>-1||corners.indexOf("br")>-1){this.roundBR=true}}},getStyleValues:function idc_Rounded_getStyleValues(){var elmtStyle;
if(this.elmt){if(this.elmt.currentStyle){elmtStyle=this.elmt.currentStyle;this.borderColor=elmtStyle.borderColor;this.borderStyle=elmtStyle.borderStyle
}else{if(document.defaultView&&document.defaultView.getComputedStyle){elmtStyle=document.defaultView.getComputedStyle(this.elmt,null);
this.borderColor=elmtStyle.borderTopColor;this.borderStyle=elmtStyle.borderTopStyle}else{return}}this.backgroundColor=elmtStyle.backgroundColor;
this.backgroundImage=elmtStyle.backgroundImage;this.backgroundRepeat=elmtStyle.backgroundRepeat;this.borderTopWidth=elmtStyle.borderTopWidth;
this.borderBottomWidth=elmtStyle.borderBottomWidth;this.borderLeftWidth=elmtStyle.borderLeftWidth;this.borderRightWidth=elmtStyle.borderRightWidth;
if(this.backgroundColor.indexOf("rgb")>-1){this.backgroundColor=idc.Rounded.rgbStringToHex(this.backgroundColor)}if(this.borderColor.indexOf("rgb")>-1){this.borderColor=idc.Rounded.rgbStringToHex(this.borderColor)
}}},createStdShimElmt:function idc_Rounded_createStdShimElmt(){var nbsp;this.stdShimElmt=document.createElement("div");this.stdShimElmt.style.display="block";
this.stdShimElmt.style.height="1px";this.stdShimElmt.style.fontSize="1px";this.stdShimElmt.style.margin="0px";this.stdShimElmt.style.backgroundColor=this.backgroundColor;
if(this.backgroundImage!=="none"){this.stdShimElmt.style.backgroundImage=this.backgroundImage;this.stdShimElmt.style.backgroundRepeat=this.backgroundRepeat
}this.stdShimElmt.style.overflow="hidden";nbsp=document.createTextNode("&nbsp;");this.stdShimElmt.appendChild(nbsp)},idcVersionInfo:"releaseInfo=dev,releaseRevision=$Rev: 75244 $"};
idc.Rounded.rgbStringToHex=function idc_Rounded_rgbStringToHex(rgbValueStr){var parsedRgbStr,hexStr,i;parsedRgbStr="";hexStr="#";
for(i=0;i<rgbValueStr.length-1;i++){if(!isNaN(parseInt(rgbValueStr.charAt(i),10))||rgbValueStr.charAt(i)===","){parsedRgbStr+=rgbValueStr.charAt(i)
}}rgbArray=parsedRgbStr.split(",");for(i=0;i<rgbArray.length;i++){rgbArray[i]=parseInt(rgbArray[i],10).toString(16);if(rgbArray[i].length===1){rgbArray[i]="0"+rgbArray[i]
}hexStr+=rgbArray[i]}return hexStr}};
