// Licensed Materials - Property of IBM // IBM Cognos Products: cchl // (C) Copyright IBM Corp. 2003, 2016. // US Government Users Restricted Rights - Use, duplication or disclosure restricted by GSA ADP Schedule Contract with IBM Corp. function C_PromptPublicControl(_cBB, _cTM, _cCB1, _c9O){this.F_ConstructBaseClass(_cTM, _cCB1);this._cCB=_cBB;this._cCB._cJN=this;this._c8O=_c9O;this._cW1={};this._cW1[ "valid" ]=null;this._cW1[ "hasValue" ]=null;this._cAB=null;if(this._cCB&&this._cCB.getAttribute("specname")){var _cIT=G_ReportSpec.F_GetReportNode().getAttribute("useStyleVersion");if(_cIT&&+_cIT>11){this._cCB.classList.add(C_PromptControl.M_sPromptClass);this._cSQ=true;var _c0S1, _cMP1=["range", "multiSelect"];for(var _c6U1=0; _c6U1<_cMP1.length; _c6U1++){_c0S1=_cMP1[_c6U1];if(_cTM.getAttribute(_c0S1)=="true"){_cBB.setAttribute("_" + _c0S1, "true");}}}}};C_PromptPublicControl.F_Extends(C_PromptControl);C_PromptPublicControl.prototype.F_Detach=function(){delete this._cDB1;this._cAB.F_Detach();delete this._cAB;if(this._cE31){this._cE31.F_Detach();}this._cX3=null;this._cY3=null;this._cAY=null;this._cQ81=null;delete this._cEO1;delete this._cP7;delete this._cW1;delete this._c63;this._cCB._cJN=null;if(this._cCB.firstChild){this._cCB.removeChild(this._cCB.firstChild);}};C_PromptPublicControl.prototype._cBT1=function(_cDB){this._cCB.setAttribute( "border", "0" );this._cCB.setAttribute( "cellPadding", "0" );this._cCB.setAttribute( "cellSpacing", "0" );var _cF2=this._cCB;if(this._cHX){var _cCE=this._cCB.insertRow(0);var _cDE=_cCE.insertCell(0);_cF2=this._cT(_cDE, _cDB);var _c56=_cCE.insertCell(1);this._cH1(_c56);var _cVD1=_cCE.insertCell(2);this._cEB(_cVD1);if(this._cSQ){_cDE.setAttribute(C_PromptControl.M_sAttrRole, C_PromptControl.M_sAttrRoleControl);_cVD1.setAttribute(C_PromptControl.M_sAttrRole, C_PromptControl.M_sAttrRoleChoice);}}if(this._cHX){this._cWM.setAttribute( "required", "false" );}return _cF2;};C_PromptPublicControl.prototype._cT=function(_cDE,_cDB){_cDE.style.verticalAlign="top";var _cQ7=_cDE.appendChild(document.createElement("table"));U_Accessibility.F_SetRoleForLayoutTable(_cQ7);if(this._cSQ){_cQ7.classList.add(C_PromptControl.M_sPromptClass);_cQ7.style.width=_cQ7.style.height="100%";}var _cI9;if(this._c0P1||_cDB){_cI9=_cQ7;}else{_cQ7.setAttribute( "border", "0" );_cQ7.setAttribute( "cellPadding", "0" );_cQ7.setAttribute( "cellSpacing", "0" );var _cMV1=_cQ7.insertRow(0);var _cNV1=_cMV1.insertCell(0);_cNV1.className=this._cSQ?"pc":"clsDialogText";_cNV1.innerText=G_ResManager.F_GetString("IDS_CCHL_PRMT_VALUE");var _c8V1=_cQ7.insertRow(1);var _c6V1=_c8V1.insertCell(0);_cI9=_c6V1.appendChild(document.createElement("table"));if(this._cCB.id){_cI9.id=this._cCB.id+"_tblPromptControl";}_cI9.style.padding="0px";U_Accessibility.F_SetRoleForLayoutTable(_cI9);if(this._cSQ){_cI9.classList.add(C_PromptControl.M_sPromptClass);_cI9.style.width=_cI9.style.height="100%";_cMV1.setAttribute(C_PromptControl.M_sAttrRole, C_PromptControl.M_sAttrRoleLabel);_c8V1.style.height="100%";}if(G_HAL.M_oLibraries["hal"]["enableAccessibility"]){_cI9.setAttribute( "HAL_idsAriaLabel", "IDS_CCHL_PRMT_VALUE" );}}_cI9.setAttribute( "border", "0" );_cI9.setAttribute( "cellPadding", "0" );_cI9.setAttribute( "cellSpacing", "0" );return _cI9;};C_PromptPublicControl.prototype._cH1=function(_c56){_c56.style.verticalAlign="top";var _cW4=_c56.appendChild(document.createElement("table"));_cW4.setAttribute( "border", "0" );_cW4.setAttribute( "cellPadding", "0" );_cW4.setAttribute( "cellSpacing", "0" );_cW4.style.width="40px";U_Accessibility.F_SetRoleForLayoutTable(_cW4);var _c1U1=false;if(this._cSQ){_cW4.classList.add(C_PromptControl.M_sPromptClass);_c1U1=C_PromptControl.F_IsDirectionRtl(_cW4);}var _cBY=_cW4.insertRow(0);var _cCY=_cBY.insertCell(0);if(this._cSQ){_cCY.className="pc";_cCY.style.visibility="hidden";}else{_cCY.className="clsDialogText";}_cCY.innerHTML=" ";var _cAO=_cW4.insertRow(1);var _cBO=_cAO.insertCell(0);_cBO.setAttribute( "align", "center" );this._cY3=this._cX1(_cBO, true, _c1U1);var _cCO=_cW4.insertRow(2);var _cDO=_cCO.insertCell(0);_cDO.setAttribute( "align", "center" );this._cX3=this._cX1(_cDO, false, _c1U1);U_DOM.F_SetButtonEnabled( this._cX3.uniqueID, false, (this._cSQ?"cchl/images/next-left_24":"hal/images/btn_arrow_left"), (this._cSQ?".svg":null) );};C_PromptPublicControl.prototype._cX1=function(_c56,_c5M1,_c1U1){var _cNP1=_c56.appendChild(document.createElement("button"));if(this._cCB.id){_cNP1.setAttribute("id", (_c5M1?"btn_insert_":"btn_remove_") + this._cCB.id);}_cNP1.hideFocus=true;G_HAL.F_VerifyDependencies("U_CoolButton");U_CoolButton.F_InitCoolButton(_cNP1);if(!this._cSQ){_cNP1.onmouseover=C_PromptPublicControl._c73;_cNP1.onmouseout=C_PromptPublicControl._cZ3;}_cNP1.onclick=_c5M1?C_PromptPublicControl._c66:C_PromptPublicControl._c76;var _c4V1=_cNP1.appendChild(document.createElement("img"));if(this._cSQ){_c4V1.src=G_HAL.F_GetImageURL( "cchl/images/next-" + ( _c5M1?"right":"left" ) + "_24.svg" );if(_c1U1){_c4V1.setAttribute("dir", "rtl");}}else{_c4V1.src=G_HAL.F_GetImageURL( "cchl/images/btn_arrow_" + ( _c5M1?"right":"left" ) + ".gif" );}_c4V1.className="clsImg16x16";_cNP1.title=_c5M1?G_ResManager.F_GetString( "IDS_CCHL_PRMT_INSERTTIP" ):G_ResManager.F_GetString( "IDS_CCHL_PRMT_REMOVETIP" );return _cNP1;};C_PromptPublicControl.prototype._cEB=function(_cVD1){_cVD1.style.verticalAlign="top";var _cR81=_cVD1.appendChild(document.createElement("table"));_cR81.setAttribute( "border", "0" );_cR81.setAttribute( "cellPadding", "0" );_cR81.setAttribute( "cellSpacing", "0" );U_Accessibility.F_SetRoleForLayoutTable(_cR81);if(this._cSQ){_cR81.classList.add(C_PromptControl.M_sPromptClass);_cR81.style.width=_cR81.style.height="100%";this._cQ81=_cR81;}var _cEO=_cR81.insertRow(0);var _cFO=_cEO.insertCell(0);_cFO.className=this._cSQ?"pc":"clsDialogText";if(this._cWC1&&!this._cUJ){var _cA31=this._cU5(_cFO);_cA31.style.marginRight="2px";}var _cDY=this._cWM.getAttribute("choicesText");_cFO.appendChild(document.createTextNode(_cDY||G_ResManager.F_GetString("IDS_CCHL_PRMT_SELECTIONS")));if(this._cSQ&&C_PromptControl.F_IsDirectionRtl(_cFO)){_cFO.style["text-align"] = "right";}var _cEY=_cR81.insertRow(1);this._cAY=_cEY.insertCell(0);this._cAY.style.verticalAlign="top";var _cF31=this._cAY.appendChild(document.createElement("div"));if(this._cSQ){_cEY.style.height="100%";_cF31.setAttribute(C_PromptControl.M_sAttrRole, C_PromptControl.M_sAttrRoleContainer);_cF31.style.position="relative";_cF31.style.width=_cF31.style.height="100%";_cF31.className="pv";_cF31=_cF31.appendChild(document.createElement("div"));_cF31.style.position="absolute";_cF31.style.top=_cF31.style.left="0";_cF31.style.width=_cF31.style.height="100%";if(C_PromptControl.F_IsDirectionRtl(_cF31)){_cF31.style.textAlign="right";}}else{_cF31.style.width="205px";_cF31.style.height="120px";}_cF31.className="clsListView";if(G_HAL.M_oLibraries["hal"]["enableAccessibility"]){_cF31.setAttribute("aria-labelledby", _cFO.uniqueID);}this._cEO1=U_XML.F_CreateDocument();var _cPA1=this._cEO1.createElement("listView");_cPA1.setAttribute( "multiSelect", "true" );this._cP7=_cPA1.appendChild(this._cEO1.createElement("listItems"));this._c63=[];for(var i=0;this._c8O&&(i0);U_DOM.F_SetButtonEnabled( this._cX3.uniqueID, _cKG1, (this._cSQ?"cchl/images/next-left_24":"hal/images/btn_arrow_left"), (this._cSQ?".svg":null) );};C_PromptPublicControl.prototype.F_PromptControl_OnValidUserInput=function(_c5M){this._cW1[ "valid" ]=true;this._c14();if(this._c9B===true){return;}if(!this._cWC1||this._cWC1&&!this._cHX){this._c04();}};C_PromptPublicControl.prototype.F_PromptControl_OnInvalidUserInput=function(_c5M){this._cW1[ "valid" ]=false;this._c14();if(this._c9B===false){return;}if(!this._cWC1||this._cWC1&&!this._cHX){this._cG2();}};C_PromptPublicControl.prototype.F_PromptControl_HasInput=function(){this._cW1[ "hasValue" ]=true;this._c14();};C_PromptPublicControl.prototype.F_PromptControl_EmptyInput=function(){this._cW1[ "hasValue" ]=false;this._c14();};C_PromptPublicControl.prototype._c14=function(){if(this._cY3){var _cKG1=( this._cW1[ "hasValue" ]&&this._cW1[ "valid" ] );U_DOM.F_SetButtonEnabled( this._cY3.uniqueID, _cKG1, (this._cSQ?"cchl/images/next-right_24":"hal/images/btn_arrow_right"), (this._cSQ?".svg":null) );}};C_PromptPublicControl.prototype._c04=function(){this._c9B=true;if(this._cDB1&&this._cDB1.F_PromptControl_OnOverallValidState){this._cDB1.F_PromptControl_OnOverallValidState(this);}};C_PromptPublicControl.prototype._cG2=function(){this._c9B=false;if(this._cDB1&&this._cDB1.F_PromptControl_OnOverallInvalidState){this._cDB1.F_PromptControl_OnOverallInvalidState(this);}};C_PromptPublicControl.prototype.F_GetParameterValues=function(){if(this._cHX){return this._c63;}else{return [ this._cAB.F_GetParameterValue()];}};C_PromptPublicControl.prototype._c24=function(){var _cA61=[];for(var i=0;i0){var _c6U1, _c6M1, _cHY, _c9O=this._c8O=[];for(_c6U1=0; _c6U1<_cGO.length; _c6U1++){_c6M1=_cGO[_c6U1];_c9O.push(_cHY=this.F_CreateSimpleValue());var _cWB1=_c6M1.getAttribute("useValue");if(this._c0P1){if(_cWB1){var a=_cWB1.split(":");if(a[0]){_cHY.F_SetUseValue(a[0], C_ParameterValue._cUC1);}if(a[1]){_cHY.F_SetUseValue(a[1], C_ParameterValue._cZB1);}}else{var n=_c6M1.selectSingleNode("start");if(n){_cHY.F_SetUseValue(n.getAttribute("useValue"), C_ParameterValue._cUC1);}var n=_c6M1.selectSingleNode("end");if(n){_cHY.F_SetUseValue(n.getAttribute("useValue"), C_ParameterValue._cZB1);}}}else {_cHY.F_SetUseValue(_cWB1);}}}};C_PromptPublicControl.prototype.F_UpdateInnnerControlStyle=function(_cWD1,_cCI1){for(var _c7U1=0; _c7U1<_cCI1.length; _c7U1++){var _c8U1=_cWD1.getElementsByClassName(_cCI1[_c7U1]);for(var _c6U1=0; _c6U1<_c8U1.length; _c6U1++){this.F_UpdateControlStyle(_c8U1[_c6U1], "", true);}}};C_PromptPublicControl.F_CreateParentTable=function(_cNG){var _cCD1=_cNG.insertRow(0);var _cDD1=_cCD1.insertCell(0);_cDD1.style.verticalAlign="top";var _cIY=_cDD1.appendChild(document.createElement("table"));_cIY.setAttribute("border", "0");_cIY.setAttribute("cellPadding", "0");_cIY.setAttribute("cellSpacing", "0");return _cIY;};C_PromptPublicControl.prototype.F_ClearParameterValues=function(){if(this._cHX){this._c86();}else{this._cAB.F_ClearParameterValue();}};C_PromptPublicControl.prototype.F_AddValues=function(_cRL1){if(this._cHX){if(_cRL1){var _cHY, _cYO1, _cOA1;var _cLT=[];for(var _c6U1=0; _c6U1<_cRL1.length; _c6U1++){_cYO1=_cRL1[_c6U1];_cHY=new C_SimpleValue(this._c0P1);if(_cHY.F_IsRange()){_cHY.F_SetUseValue(_cYO1["start"]["use"], C_ParameterValue._cUC1);_cHY.F_SetUseValue(_cYO1["end"]["use"], C_ParameterValue._cZB1);}else{_cHY.F_SetUseValue(_cYO1["use"]);}_cLT.push(_cHY);}this._cEE(_cLT);}}else{this._cAB.F_SetParameterValue((_cRL1&&_cRL1.length>0)?_cRL1[0]:null);}};C_PromptPublicControl.prototype._cX4=function(_cRL1){if(this._c231){return(!this._cWC1||this._c231(this.F_GetValues()));}else{return(!this._cWC1||this._cP7.hasChildNodes());}};C_PromptPublicControl.prototype.F_SetValidator=function(_cN21){if(this._cHX){C_PromptPublicControl.superClass.F_SetValidator.call(this, _cN21);}else{this._cAB.F_SetValidator(_cN21);}};