123 |
- // Copyright (C) 2008 Cognos ULC, an IBM Company. All Rights Reserved.
- // Cognos and the Cognos logo are trademarks of Cognos ULC (formerly Cognos Incorporated) in the United States and/or other countries. IBM and the IBM logo are trademarks of International Business Machines Corporation in the United States, or other countries, or both. Other company, product, or service names may be trademarks or service marks of others.
- var Debug=new Object();Debug._sj=false;Debug.SetDebugEnabled=function(_Ub){Debug._sj=_Ub;};Debug.IsEnabled=function(){return Debug._sj;};Debug.ShowConsole=function(){/*@if(@bering_debug)@*/if(this._sj){try{if((!this.m_win||this.m_win.closed)&&!this.m_win_loading){this.m_win_loading=true;var _are="edge:sunken; dialogWidth:700px; dialogHeight:250px; resizable:yes; status:no; dialogTop:"+String(window.screen.availHeight-250)+"; dialogLeft:"+String(window.screen.availWidth-700);this.m_win=window.showModelessDialog("localhost",document,_are);this.m_win.document.open();this.m_win.document.write('<html><body id="ConsoleBody" style="white-space:nowrap;background-color:black;color:silver;padding:5px;font-size:10pt;"></body></html>');this.m_win.document.close();this.m_win_loading=false;this.m_win_body=this.m_win.document.getElementById("ConsoleBody");}}catch(e){}}/*@end@*/};Debug.Print=function(s,_SY){/*@if(@bering_debug)@*/if(this._sj){try{_SY=_SY||new Date();if(this.m_win_loading){_OM=Utilities.GenerateCallback(Debug.Print,[s,_SY]);setTimeout(_OM,5);}else{Debug.ShowConsole();if(this.m_win&&!this.m_win.closed){s=String(s);s=s.replace(/&/g,"&");s=s.replace(/</g,"<");s=s.replace(/>/g,">");s=s.replace(/\n/g,"<br>");s=s.replace(/\t/g," ");var _82=this.m_win.document.createElement("div");_82.innerHTML="<tt>"+_SY.toLocaleTimeString()+": "+s+"</tt>";var _0A=this.m_win_body.firstChild;if(_0A){this.m_win_body.insertBefore(_82,_0A);}else{this.m_win_body.appendChild(_82);}}}}catch(e){alert("Debug.Print EXCEPTION");}}/*@end@*/};Debug.Alert=function(s){/*@if(@bering_debug)@*/try{if(Debug._sj){window.alert(s);}}catch(e){}/*@end@*/};Debug.Popup=function(_Ku){/*@if(@bering_debug)@*/if(this._sj){if(!this.m_divPopup){var _2W=document.createElement("DIV");_2W.style.fontFamily="Arial";_2W.style.fontWeight="bold";_2W.style.fontSize="65%";_2W.style.padding="5px";_2W.style.backgroundColor="red";_2W.style.color="white";_2W.style.border="solid black 1px";_2W.style.position="absolute";_2W.style.top=(document.body.offsetHeight/3)+'px';_2W.style.left=(document.body.offsetWidth/3)+'px';_2W.style.width=((document.body.offsetWidth/2)-20)+'px';_2W.style.height=((document.body.offsetHeight/2)-20)+'px';_2W.style.overflow='auto';_2W.ondblclick=function(){_2W.style.display='none';};document.body.appendChild(_2W);this.m_divPopup=_2W;Dom.EnableTextSelection(this.m_divPopup);}this.m_divPopup.style.display='block';this.m_divPopup.innerText=_Ku;}/*@end@*/};Debug.Assert=function(_MQ,_Th){/*@if(@bering_debug)@*/if(this._sj){if(this.m_win&&!this.m_win.closed){if(!(_MQ)){if(this.m_win.confirm("Debug assertion failed!\r\n\r\nView function source?")){this.m_win.alert(Debug.Assert.caller);}}}else if(!(_MQ)){var _TL="Assert Failure";if(Debug.Assert.caller){_TL="Assert Failure occured in \r\n"+Debug.Assert.caller;}Utilities.DisplaySimpleWindow(_TL,'Debug Assertion: '+_Th);throw new COTException("Assert Failed");}}/*@end@*/};Debug.Call=function(_Pr,_GB,_UA){/*@if(!@bering_debug)@*/if(Debug.IsEnabled()&&window[_Pr]){Utilities.GenerateCallback(window[_Pr][_GB],_UA)();}/*@end@*/};Debug.kUnitHooks="ieUnitHooks";Debug.kUnitHelper="ieUnitHelper";Debug.kStartTimer="startTimer";Debug.kStopTimer="stopTimer";Debug.kAddTimingInfo="addTimingInfo";Debug.kStartRequest="startRequest";Debug.kStopRequest="stopRequest";Debug.kStartBufferedTimer="startBufferedTimer";Debug.kStopBufferedTimer="stopBufferedTimer";Debug.RowCount="RowCount";Debug.RowDepth="RowDepth";Debug.ColCount="ColCount";Debug.ColDepth="ColDepth";Debug.CellCount="CellCount";Debug.VisibleCells="VisibleCells";Debug.VisibleRows="VisibleRows";Debug.VisibleCols="VisibleCols";function CookieJar(){};CookieJar.SetCookie=function(_Vj,_FT,_L9,_Az,_AD,_MH){var _33=_Vj+"="+escape(_FT);if(_L9){_33+="; expires="+_L9.toUTCString();}if(_Az){_33+="; path="+_Az;}if(_AD){_33+="; domain="+_AD;}if(_MH){_33+="; secure";}document.cookie=_33;};CookieJar.DeleteCookie=function(_Vj,_Az,_AD){var _33=_Vj+"=";if(_Az){_33+="; path="+_Az;}if(_AD){_33+="; domain="+_AD;}_33+="; expires=Thu, 1 Jan 1970 00:00:01 UTC";document.cookie=_33;};CookieJar.GetCookie=function(_Vj){var _BA=document;var _aGX=_Vj+"=";for(var i=0;i<_BA.cookie.length;i++){var j=i+_aGX.length;if(_BA.cookie.substring(i,j)==_aGX){return CookieJar.getCookieVal(j);}i=_BA.cookie.indexOf(" ",i);if(i<=0){break;}}return null;};CookieJar.getCookieVal=function(_J1){var _Yx=document.cookie.indexOf(";",_J1);if(_Yx==-1){_Yx=document.cookie.length;}return decodeURIComponent(document.cookie.substring(_J1,_Yx));return null;};String.prototype.IsCharAtUpperCase=function(_Re){if(this.charCodeAt(_Re)>=65&&this.charCodeAt(_Re)<=96){return true;}};function Utilities(){};Utilities._eC=new Object();Utilities.bAutoAnalysisDrillEnabled=false;Utilities.bSingleMemExpandEnabled=false;Utilities.bShowRepeatBlkSelector=true;Utilities.bShowBlkSelectorOnce=false;Utilities.bShowVBlkSelector=true;Utilities.bCalcSlicerEnabled=false;Utilities.bCalcCentroidEnabled=false;Utilities.bCharBasedTruncation=false;Utilities.bUnlimitedCalcEnabled=true;Utilities.bMultiParentCalcEnabled=true;Utilities.bBlackSeaRemainderPrototype=false;Utilities.bEnableInnerHTMLRendering=false;Utilities.bDiffMiningEnabled=false;Utilities.bScatterPlotGraphsEnabled=false;Utilities.Id=1;Utilities.IMG_PATH="../explore/images/";Utilities.BRANDING_IMG_PATH="../skins/corporate/branding/";Utilities.CSS_PATH="../skins/";Utilities.SCHEMAS_PATH="../schemas/";Utilities.CSS_SKIN_PATH="../skins/corporate/ans/";Utilities.JS_PATH="../explore/";Utilities.iServerResponseTimeout=5000;Utilities.iIncrement=500;Utilities.iIncrementCount=0;Utilities.eStateContinue=1;Utilities.eStateHold=2;Utilities._i7=new Array();Utilities._aHoldingProcedureParam=new Array();Utilities.iDoubleClickTime=250;Utilities.iDoubleClickDelay=100;Utilities.SetProcedureToHold=function(_Nn,_Ro){Utilities._i7.push(_Nn);Utilities._aHoldingProcedureParam.push(_Ro);};Utilities.SafeDoRemoveHoldingProcedure=function(){Utilities.DeleteAllFromArray(Utilities._i7);Utilities.DeleteAllFromArray(Utilities._aHoldingProcedureParam);};Utilities.ExecuteHoldingProcedure=function(){for(var i=0;i<Utilities._i7.length;i++){var _AG=new Array();for(var j=0;j<Utilities._aHoldingProcedureParam[i].length;j++){_AG.push(Utilities._aHoldingProcedureParam[i][j]);}Utilities.GenerateCallback(Utilities._i7[i],_AG)();}Utilities.DeleteAllFromArray(Utilities._i7);Utilities.DeleteAllFromArray(Utilities._aHoldingProcedureParam);};Utilities.Init=function(){Utilities.loadCRNValues();if(Utilities.GetCRNValue("skin")){Utilities.CSS_SKIN_PATH=Utilities.CSS_PATH+Utilities.GetCRNValue("skin")+"/ans/";Utilities.BRANDING_IMG_PATH=Utilities.CSS_PATH+Utilities.GetCRNValue("skin")+"/branding/";}};Utilities.loadCRNValues=function(){var _aux=CookieJar.GetCookie("CRN");if(_aux){_aux=decodeURIComponent(_aux);var _axr=_aux.split("&");for(var i=0;i<_axr.length;++i){var _aD5=_axr[i].split("=");if(_aD5[0]){var _FT=(_aD5.length>=2)?decodeURIComponent(_aD5[1]):"";Utilities._eC[_aD5[0]]=_FT;}}}};Utilities.GetCRNValue=function(_Vj){return Utilities._eC[_Vj];};Utilities.kDBCSWidthScaleFactor=1.4;Utilities.GetCharWidthScaleFactor=function(_Wj){var _4a=_Wj.indexOf('th')>-1;var _aC5=_Wj.indexOf('zh')>-1;var _aF5=_Wj.indexOf('ko')>-1;var _awp=_Wj.indexOf('ja')>-1;if(_4a||_aC5||_aF5||_awp){return Utilities.kDBCSWidthScaleFactor;}return 1;};Utilities.GenerateId=function(){var _abn="_i"+Utilities.Id;Utilities.Id=Utilities.Id+1;return _abn;};Utilities.GetServerResponseTimeout=function(){return Utilities.iServerResponseTimeout;};Utilities.SetServerResponseTimeout=function(_PC){Utilities.iServerResponseTimeout=_PC;};Utilities.IncrementServerTimeout=function(){Utilities.iIncrementCount++;Utilities.iServerResponseTimeout+=Utilities.iIncrementCount*Utilities.iIncrement;};Utilities.StringToBool=function(_Np){if(_Np=="false"){return false;}else if(_Np=="true"){return true;}Debug.Assert("Unexpected boolean string value");return null;};Utilities.GetShallowClone=function(obj){var _aFe=new Object();for(var i in obj){_aFe[i]=obj[i];}return _aFe;};Utilities.GetTooltipLineLength=function(){return 60;};Utilities.Descheme=function(_C7){var _aCr=_C7;var _abE=_C7.substr(0,ExpAPIXml.kMUN.length);if(_abE==ExpAPIXml.kMUN){_aCr=_C7.substr(_abE.length,(_C7.length-_abE.length));}return _aCr;};Utilities.GetTruncatedString=function(_OZ,_Ne,_CU,_SI){var _ad3=_OZ;if(_SI==null){var _SI=true;}if(_OZ==null){return "";}if(_SI){if(_ad3.length>_Ne){_ad3=_OZ.substr(0,_Ne);_ad3=_CU.ReplaceParam('IDS_TRUNCATED_STRING',1,_ad3);}}else{_ad3=_OZ.substr(0,_Ne);}return _ad3;};Utilities.DoNothing=function(){};Utilities.RemoveSplash=function(){var _Eq=document.getElementById("splash");if(_Eq){Dom.RemoveObject(_Eq);}};Utilities.DisplaySimpleWindow=function(_Th,_KP,_Vp,_TV){if(window[Debug.kUnitHelper]&&ieUnitHelper.bHooked){ieUnitHooks.testError(_Th);}else{var _azp=Utilities.GenerateId();if(_TV){_Th=Utilities.HtmlEncode(_Th);}if(!_Vp||(_Vp=="")){_Vp="directories=no,location=no,status=no,toolbar=no,resizable=yes,scrollbars=yes,top=100,left=100,height=480,width=640";}var _ag3=window.open("",_azp,_Vp);var _BA=_ag3.document;_BA.open();_BA.write('<pre>');_BA.write(Utilities.EncodeString(_Th));_BA.write('</pre>');_BA.close();_BA.title=_KP;_ag3.focus();return _ag3;}};Utilities.GetReplaceToken=function(_Np){return new RegExp("\\"+_Np,"g");};Utilities.HtmlEncode=function(_Np){var _aJR='';if(_Np&&(_Np!='')){var _axW=Utilities.GetReplaceToken('&');_aJR=_Np.replace(_axW,"&");_axW=Utilities.GetReplaceToken("#");_aJR=_aJR.replace(_axW,"#");_axW=Utilities.GetReplaceToken('<');_aJR=_aJR.replace(_axW,"<");_axW=Utilities.GetReplaceToken('>');_aJR=_aJR.replace(_axW,">");_axW=Utilities.GetReplaceToken('"');_aJR=_aJR.replace(_axW,""");_axW=Utilities.GetReplaceToken("'");_aJR=_aJR.replace(_axW,"'");_axW=Utilities.GetReplaceToken("(");_aJR=_aJR.replace(_axW,"(");_axW=Utilities.GetReplaceToken(")");_aJR=_aJR.replace(_axW,")");_axW=Utilities.GetReplaceToken("$");_aJR=_aJR.replace(_axW,"$");}return _aJR;};Utilities.xPathStringHelper=function(_Ee){if(_Ee===null){return null;}else if(_Ee===''){return '';}else if(_o.is_ie5_5up){return _Ee;}var _4q="";var _5U=_Ee.match(/\[[0-9]+\]/g);if(_5U&&_5U.length>0){var _anB=_Ee.split(/\[[0-9]+\]/g);for(var i=0;i<_5U.length;i++){var _asT=_5U[i].replace('[','').replace(']','');_asT=parseInt(_asT)+1;_5U[i]='['+_asT+']';}for(var i=0;i<_anB.length;i++){_4q+=_anB[i];if(_5U[i]){_4q+=_5U[i];}}}else{_4q=_Ee;}return _4q;};function EncodeXPathStr(_Gv){var _axW=Utilities.GetReplaceToken("'");var _ao6=_Gv.replace(_axW,"\\\'");_ao6="'"+_ao6+"'";return _ao6;};Utilities.F_ToXPathString=function(_EX,_RU){var _ak9=_EX;if(_ak9.indexOf("'")==-1){return("'"+_ak9+"'");}if(_ak9.indexOf('"')==-1){return('"'+_ak9+'"');}if(_RU)return EncodeXPathStr(_ak9);var a=new Array();a.push("concat(");var _abS=_ak9.split("'");for(var i=0;i<_abS.length;i++){if(a.length>1){a.push(',');}if(i>0){a.push('"\'"');}var _aga=_abS[i];if(_aga){if(_ak9.indexOf('"')==-1){if(a.length>1){a.push(',');}a.push('"'+_aga+'"');}else{var _ari=_aga.split("'");for(var j=0;j<_ari.length;j++){if(a.length>1){a.push(',');}if(_ari[j]){a.push("'"+_ari[j]+"'");}}}}}a.push(")");_ak9=a.join("");return _ak9;};Utilities.EncodeString=function(_Np){var _aJR='';if(_Np&&(_Np!='')){_aJR=_Np;var _axW=Utilities.GetReplaceToken("\\");_aJR=_aJR.replace(_axW,"\\\\");_axW=Utilities.GetReplaceToken("\r");_aJR=_aJR.replace(_axW,"\\\r");_axW=Utilities.GetReplaceToken("\b");_aJR=_aJR.replace(_axW,"\\\b");_axW=Utilities.GetReplaceToken("\t");_aJR=_aJR.replace(_axW,"\\\t");_axW=Utilities.GetReplaceToken("\n");_aJR=_aJR.replace(_axW,"\\\n");_axW=Utilities.GetReplaceToken("\v");_aJR=_aJR.replace(_axW,"\\\v");_axW=Utilities.GetReplaceToken("\f");_aJR=_aJR.replace(_axW,"\\\f");_axW=Utilities.GetReplaceToken("'");_aJR=_aJR.replace(_axW,"\\\'");_axW=Utilities.GetReplaceToken('"');_aJR=_aJR.replace(_axW,'\\\"');_axW=Utilities.GetReplaceToken("<");_aJR=_aJR.replace(_axW,"\\\<");_axW=Utilities.GetReplaceToken(">");_aJR=_aJR.replace(_axW,"\\\>");}return _aJR;};Utilities.MethodInObject=function(obj,_SZ){if(obj[_SZ]&&typeof obj[_SZ]=="function"){return true;}return false;};Utilities.RemoveAllChildObjects=function(obj){for(var i in obj){if(obj[i]&&!(obj[i]instanceof Function)){obj[i]=null;}}};Utilities.RemoveControlChars=function(_Np){var _ape=new String(_Np);var _9a=new RegExp("[\n\r\t]",'g');_ape=_ape.replace(_9a,"");return _ape;};Utilities.RemoveMUNPrefix=function(_Np){var _ape=new String(_Np);_ape=_ape.replace(ExpAPIXml.kMUN,'');return _ape;};Utilities.DeleteFromArray=function(_GT,obj){var length=_GT.length;var _adb=false;for(var i=0;i<length;i++){if(_GT[i]==obj){_adb=true;}if(_adb==true&&i<(length-1)){_GT[i]=_GT[i+1];}}if(_adb==true){_GT.length--;}return _adb;};Utilities.DeleteNthFromArray=function(_GT,n){var length=_GT.length;if(n>=length||n<0){return;}_GT.splice(n,1);};Utilities.DeleteAllFromArray=function(_GT){if(_GT){_GT.length=0;}};Utilities.InsertToNthInArray=function(_GT,_Tr,n){var length=_GT.length;_GT.splice(n,0,_Tr);};Utilities.IsInArray=function(_GT,obj){for(var i=0;i<_GT.length;i++){if(_GT[i]==obj){return true;}}return false;};Utilities.GetObjIndex=function(_GT,obj){for(var i=0;i<_GT.length;i++){if(_GT[i]==obj){return i;}}return-1;};Utilities.GetObjIndices=function(_GT,obj){var _abC=new Array();for(var i=0;i<_GT.length;i++){if(_GT[i]==obj){_abC.push(i);}}return _abC;};Utilities.CopyArray=function(_GT){if(!_GT){return null;}var _aJb=new Array();return _aJb.concat(_GT);};Utilities.ReverseSortCompare=function(a,b){if(a>b){return-1;}if(a<b){return 1;}return 0;};Utilities.AreArrayContentsEqual=function(_Ea,_VR){if(_Ea.length!=_VR.length){return false;}for(var i=0;i<_Ea.length;i++){if(_Ea[i]!=_VR[i]){return false;}}return true;};Utilities.AreArrayContentsEqualIgnoreOrder=function(_Ea,_VR){if(_Ea.length!=_VR.length){return false;}for(var i=0;i<_Ea.length;i++){if(!Utilities.IsInArray(_VR,_Ea[i])){return false;}}return true;};Utilities.IsInSameArray=function(_TS,_TU,_GT){return Utilities.IsInArray(_GT,_TS)&&Utilities.IsInArray(_GT,_TU);};Utilities.append=function(a1,a2){var _ayj=a2.length;for(var i=0;i<_ayj;++i){a1[a1.length]=a2[i];}};Utilities.ClearObjectArray=function(_U8){for(var i in _U8){delete _U8[i];}_U8=new Object();return _U8;};Utilities.RemoveObjXObjectArray=function(_U8,_HU){delete _U8[_HU];};Utilities.GetObjArrayLength=function(_U8){var j=0;for(var i in _U8){j++;}return j;};Utilities.IsObjectEmpty=function(obj){if(obj){for(var i in obj){return false;}}return true;};Utilities.GetNthFromObjArray=function(_U8,n){var j=1;for(var i in _U8){if(j==n){return _U8[i];}j++;}return null;};Utilities.GetNthObjProperty=function(obj,n){var j=1;for(var i in obj){if(j==n){return i;}j++;}return null;};Utilities.IsInObjArray=function(_GT,obj){for(var i in _GT){if(_GT[i]==obj){return true;}}return false;};Utilities.GetObjIndexFromObjArray=function(_GT,obj){var _PQ=-1;for(var i in _GT){_PQ++;if(_GT[i]==obj){return _PQ;}}return-1;};Utilities.CopyObjArray=function(_U8,_Kt){if(!_U8){return;}for(var i in _U8){_Kt[i]=_U8[i];}};Utilities.CloneObjArray=function(_U8,_Kt){if(!_U8){return;}for(var i in _U8){if(!_U8[i]){continue;}Debug.Assert(_U8[i].Clone);_Kt[i]=_U8[i].Clone();}};Utilities.CopyObjArrayToArray=function(_U8){var _ayg=new Array();for(var i in _U8){_ayg[_ayg.length]=_U8[i];}return _ayg;};Utilities.trim=function(s){if(!s){return "";}var j=s.length;var _aF3;for(var i=0;i<j;i++){_aF3=s.charCodeAt(i);if(32!=_aF3&&12288!=_aF3){break;}}if(i<j-1){for(;j>i;j--){_aF3=s.charCodeAt(j-1);if(32!=_aF3&&12288!=_aF3){break;}}}return s.substring(i,j);};Utilities.NotImplement=function(){if(Debug&&Debug._sj){alert('Sorry, this feature has not yet been implemented');}};Utilities.GenerateCallback=function(_OM,_AG,_Eo){if(_OM){_AG=(_AG instanceof Array)?_AG:new Array();return(function(){/*@if(!@bering_debug)@*/try{/*@end@*/var _aks=_Eo||this;return _OM.apply(_aks,_AG);/*@if(!@bering_debug)@*/}catch(excep){_f.HandleException(excep);}/*@end@*/});}else{return Utilities.DoNothing;}};Utilities.EventCallback=function(_OM,_AG,_Eo,_PR,_AU){if(_OM){_AG=(_AG instanceof Array)?_AG:new Array();return(function(e){/*@if(!@bering_debug)@*/try{/*@end@*/var _aks=_Eo||this;var _agw=_PR?[]:[e||window.event];var _09=_AU?[]:[this];var _av9=_agw.concat(_09);var a=_av9.concat(_AG);return _OM.apply(_aks,a);/*@if(!@bering_debug)@*/}catch(excep){_f.HandleException(excep);}/*@end@*/});}else{return Utilities.DoNothing;}};Utilities.GenerateCallbackUnion=function(_SQ){return(function(){for(var i=0;i<_SQ.length;i++){_SQ[i]();}});};Utilities.ObjToString=function(_Lo){var _Pr="Object: "+(_Lo||"unknown")+"\n";for(var i in this){if(i!="toString"){_Pr+=i+": "+this[i]+"\n";}}return _Pr;};Utilities.HadDoubleClick=function(_KT){var _abX=new Date().getTime();if((_abX-_KT)<Utilities.iDoubleClickDelay){return true;}return false;};function COTException(_F3){this._ny=_F3;this._mV=COTException.caller;};COTException.prototype.GetMessage=function(){return this._ny;};COTException.prototype.GetCaller=function(){return this._mV;};COTException.prototype.Handle=function(_Co){if(Debug&&Debug._sj){var _TL='handling exception: '+this.GetMessage()+' which occurred in \r\n'+this.GetCaller();Utilities.DisplaySimpleWindow(_TL,'Exception Caught');}else{CUIDialogMgr.DisplayMessageBox(CUIMessageBox.kCritical,'MES_CLIENT_ERROR');}};function COTUnexpectedObjectException(_F3){this._ny=_F3;this._mV=COTUnexpectedObjectException.caller;};COTUnexpectedObjectException.prototype.Handle=function(){if(Debug&&Debug._sj){var _TL='handling exception: '+this.GetMessage()+' which occurred in \r\n'+this.GetCaller();Utilities.DisplaySimpleWindow(_TL,'Exception Caught');}};function COTBadResponseException(_F3){this._ny=_F3;this._mV=COTBadResponseException.caller;};COTBadResponseException.prototype.Handle=function(_Co){if(Debug&&Debug._sj){var _TL='handling exception: '+this.GetMessage()+' which occurred in \r\n'+this.GetCaller();Utilities.DisplaySimpleWindow(_TL,'Exception Caught');}else{CUIDialogMgr.DisplayMessageBox(CUIMessageBox.kCritical,'MES_BAD_SERVER_RESPONSE');}};function COTUnsuportedBrowserException(_F3){this._ny=_F3;this._mV=COTUnsuportedBrowserException.caller;};COTUnsuportedBrowserException.prototype.Handle=function(_Co){CUIDialogMgr.DisplayMessageBox(CUIMessageBox.kCritical,'MES_UNSUPPORTED_BROWSER');};function COTUnsupportedServerVersion(_F3){this._ny=_F3;this._mV=COTUnsupportedServerVersion.caller;};COTUnsupportedServerVersion.prototype.Handle=function(_Co){if(Debug&&Debug._sj){alert(this._ny);}else{CUIDialogMgr.DisplayMessageBox(CUIMessageBox.kCritical,'MES_UNSUPPORTED_SERVER_VERSION');}};function COTWorkSheetBusyException(){this._ny="";this._mV=COTWorkSheetBusyException.caller;};COTWorkSheetBusyException.prototype.Handle=function(_Co){CUIDialogMgr.DisplayMessageBox(CUIMessageBox.kWarning,'IDS_WORKSHEET_ALREADY_BUSY');};function COTXMLHttpException(){this._ny="";this._mV=COTXMLHttpException.caller;};COTXMLHttpException.prototype.Handle=function(_Co){var _Ku='MES_XMLHTTP_ERROR';if(_f.oRes._pp['MES_XMLHTTP_ERROR']||_f.oRes._wo['MES_XMLHTTP_ERROR']){_Ku=_f.oRes.ReplaceParam('MES_XMLHTTP_ERROR',1,ExpMiscStr.kProductName);}CUIDialogMgr.DisplayMessageBox(CUIMessageBox.kCritical,_Ku);};var _f=new Object();_f.SetResource=function(_Co){_f.oRes=_Co;};_f.SetWorkSheet=function(_PX){_f.oWS=_PX;};_f.SetCommManager=function(_NY){_f.oCommManager=_NY;};_f.HandleException=function(e){if(e.Handle){e.Handle(_f.oRes);}else{if(Debug&&Debug._sj){if(e.description){alert('Encountered system exception.'+e.description);}throw e;}else{CUIDialogMgr.DisplayMessageBox(CUIMessageBox.kCritical,'MES_CLIENT_ERROR');if(_f.oCommManager&&_f.oCommManager.IsBlocked()){_f.oCommManager.FreeBlockedObject();}if(_f.oWS&&!_f.oWS.AllowInteraction()){_f.oWS.Notify(ExpEvent.kCUIWorksheet_Free);}}}};function COTMsgUtil(){};COTMsgUtil.SubstituteMessage=function(_R9,_FR,_FQ,_FP,_FO,_FN,_FM,_FL){var _abq=new Array();for(var i=1;i<arguments.length;++i){if(typeof arguments[i]!='undefined'){_abq[i]=arguments[i];}}var _2O=new Array();var _aE4=/%\d\b/;var _abu=_R9;var _9G=_abu.match(_aE4);var _PQ=0;while(_9G!=null){_2O[_PQ]=new Object();_2O[_PQ].value=_abu.substring(0,_9G.index);_2O[_PQ].msgNum=parseInt(_9G[0].charAt(1));_abu=_abu.substring(_9G.lastIndex);_9G=_abu.match(_aE4);++_PQ;}var _asd=new Object();_asd.value=_abu;_asd.msgNum=999;_2O[_2O.length]=_asd;var _ee="";for(var i=0;i<_2O.length;++i){_ee+=_2O[i].value;if(_2O[i].msgNum<_abq.length){_ee+=_abq[_2O[i].msgNum];}}return _ee;};function PageQuery(q){if(q.length>1){this.q=q.substring(1,q.length);}else{this.q=null;}this.keyValuePairs=new Array();if(q){for(var i=0;i<this.q.split("&").length;i++){this.keyValuePairs[i]=this.q.split("&")[i];}}this.getKeyValuePairs=function(){return this.keyValuePairs;};this.getValue=function(s){for(var j=0;j<this.keyValuePairs.length;j++){if(this.keyValuePairs[j].split("=")[0]==s){var _PQ=this.keyValuePairs[j].indexOf("=");return this.keyValuePairs[j].substr(_PQ+1);}}return false;};this.getParameters=function(){var a=new Array(this.getLength());for(var j=0;j<this.keyValuePairs.length;j++){a[j]=this.keyValuePairs[j].split("=")[0];}return a;};this.getLength=function(){return this.keyValuePairs.length;};};function queryString(_Ui){var _aG7=new PageQuery(window.location.search);return decodeURIComponent(_aG7.getValue(_Ui));};function Decimal(){};Decimal.expressionDecimal=".";Decimal.displayDecimal=".";Decimal.displayThousand=",";Decimal.displayNegative="-";Decimal.validateDecimal=function(_Fg){var _9u="0123456789 ";var _aik=_Fg.indexOf(Decimal.displayDecimal);var _ape="";for(var i=0;i<_Fg.length;i++){var _4o=_Fg.charAt(i);if((_9u.indexOf(_4o)!=-1)||(_4o==Decimal.displayThousand&&(_aik==-1||i<_aik))||(_4o==Decimal.displayDecimal&&(_aik==-1||i<=_aik))||(_4o==Decimal.displayNegative&&i==0)){_ape+=_4o;}}return _ape;};Decimal.validateInteger=function(_Fg){var _ape=Decimal.validateDecimal(_Fg);var _aik=_ape.indexOf(Decimal.displayDecimal);if(_aik>=0){_ape=_ape.substr(0,_aik);}return _ape;};Decimal.GetExpressionNum=function(_IT){var _ape=new String(_IT);var _9a=new RegExp("[\\"+Decimal.displayThousand+"\\"+" "+"]",'g');_ape=_ape.replace(_9a,"");var _anD=new RegExp("\\"+Decimal.displayDecimal,'g');_ape=_ape.replace(_anD,Decimal.expressionDecimal);return _ape;};Decimal.GetDisplayNum=function(_Cp){var _ape=new String(_Cp);var _anD=new RegExp("\\"+Decimal.expressionDecimal,'g');_ape=_ape.replace(_anD,Decimal.displayDecimal);return _ape;};Decimal.GetNumericDecimal=function(_Pp){_ape=Decimal.validateDecimal(_Pp);var _9a=new RegExp("[\\"+Decimal.displayThousand+"\\"+" "+"]",'g');_ape=_ape.replace(_9a,"");var _anD=new RegExp("\\"+Decimal.displayDecimal,'g');_ape=_ape.replace(_anD,'.');return parseFloat(_ape);};function HashTableArray(){this.keys=new Array();this.values=new Array();};HashTableArray.prototype.Remove=function(_Ui){if(this.values[_Ui]){delete this.values[_Ui];}Utilities.DeleteFromArray(this.keys,_Ui);};HashTableArray.prototype.Get=function(_Ui){return this.values[_Ui];};HashTableArray.prototype.GetAtIndex=function(_PQ){var _Ui=this.keys[_PQ];if(_Ui){return this.values[_Ui];}return null;};HashTableArray.prototype.Put=function(_Ui,_UN){this.Remove(_Ui);this.keys.push(_Ui);this.values[_Ui]=_UN;};HashTableArray.prototype.Length=function(){return this.keys.length;};HashTableArray.prototype.Clear=function(){var _ayj=this.Length();var _Ui;for(var i=0;i<_ayj;i++){_Ui=this.keys[i];if(this.values[_Ui]){delete this.values[_Ui];}Utilities.DeleteNthFromArray(this.keys,i);}};var _m=new Object();var _o=null;var gResource=null;var ws=null;var PSParameters=null;var _e=null;function FindApp(_zs){Debug.Assert(_m[_zs]);return _m[_zs];};function CMainApplication(_PJ){var _zs=_PJ["appname"];if(_zs==undefined){return;}if(!_zs.match(/\w+/)){_zs=null;}if(_zs==null)_zs="main";_m[_zs]=this;this.isRunning=false;this.appname=_zs;this.commManager=null;this.dataManager=null;this.uiManager=null;this.oResources=null;this.bNotForResale=false;this._ot=null;this._ea=null;this._xt=null;this._gk=null;this._dp=null;this._x0=null;this._kY=null;this._bn=null;this._hy=null;this._ac=null;this._vu=null;this._iH='';this._pT='';this._vv='';this._sE="0";this._ft="0";this._jB="0";this._al="0";this._eH='';this.globalAppVars=new Object();this._xY=new Object();this._X=0;this._bf=new CopyPasteHLS();this._wJ=new PlaybackRegressionTestResponses();this.initProductAndContentLocales();this.initParameters(_PJ);window.bLoaded=true;this._q7=false;};CMainApplication.prototype.addRequestTracking=function(_Ej){this._xY[this._X]=_Ej;this._X++;};CMainApplication.prototype.getRequestTracking=function(){var _C2="";if(this._X>0){this._X--;_C2=this._xY[this._X];this._xY[this._X]=null;}return _C2;};CMainApplication.prototype.clearRequestTracking=function(_Ej){Utilities.ClearObjectArray(this._xY);this._X=0;};CMainApplication.prototype.getAboutboxURL=function(){var _Mn="../explore/images/ansAboutBox_";_Mn+=this._aB;_Mn+=".jpg";return _Mn;};CMainApplication.prototype.getResourceURL=function(){var _Mn="../explore/res/ansmsgs_";_Mn+=this._aB;_Mn+=".xml";return _Mn;};CMainApplication.prototype.getStatsURL=function(){var _Mn="../explore/res/cognos_stats.xml";return _Mn;};CMainApplication.prototype.getHotsiteResourceURL=function(){var _Mn="../explore/res/ansmsgs_not_localized.xml";return _Mn;};CMainApplication.prototype.initProductAndContentLocales=function(){this._aB=Utilities.GetCRNValue("productLocale");this._gG=Utilities.GetCRNValue("contentLocale");var _2M=window.navigator.userLanguage?window.navigator.userLanguage:window.navigator.language;if(!this._aB){this._aB=_2M.substr(0,2);}if(!this._gG){this._gG=_2M;}};CMainApplication.prototype.initParameters=function(_PJ){this.SetGateway(g_PSParameters["ui.gateway"]);var _amv=g_PSParameters["ui.action"];if(_amv=="new"){if(!g_PSParameters["isOpenModel"]&&!g_PSParameters["lastDefaultAnalysis"]){this._yh=true;}this.SetPackage(g_PSParameters["ui.object"]);}else if(_amv=="edit"){this.SetQuery(g_PSParameters["ui.object"]);}else if(_amv=="pasteHLS"){this._iH=g_PSParameters["ui.object"];}else if(_amv=="loadFromFile"){this._pT=g_PSParameters["ui.object"];this.SetPackage(g_PSParameters["model"]);}else if(_amv=="renderRespXml"){this.SetPackage(g_PSParameters["ui.object"]);this._vv=g_PSParameters["ui.respXml"];}else if(_amv=="createAnalysis"){this._eH=g_PSParameters["ui.selection"];this.SetPackage(g_PSParameters["ui.object"]);}this.SetCAFContextID(g_PSParameters["ui.cafcontextid"]);this.SetCacheContext(g_PSParameters["ui.cacheContext"]);this.SetHideXLS(g_PSParameters["ui.hideXLS"]);this.SetDefaultAnalysis(g_PSParameters["ui.defaultAnalysis"]);this.SetDrillTargetParms(g_PSParameters["ui.drillThroughTargetParameterValues"]);this.SetRoutingServerGroup(g_PSParameters["ui.routingServerGroup"]);this.SetDefaultBlockSize(g_PSParameters["ui.crosstabItemDisplayCountDefault"]);this.SetMaximumBlockSize(g_PSParameters["ui.crosstabItemDisplayCountLimit"]);this.SetDefaultExpand(g_PSParameters["ui.memberDisplayCountDefault"]);this.SetMaximumExpand(g_PSParameters["ui.memberDisplayCountLimit"]);var _C2=g_PSParameters["as.tracking"];if(_C2!=null){this.addRequestTracking(_C2);g_PSParameters["as.tracking"]=null;}};CMainApplication.prototype.OnLoad=function(){try{var _al9=Dom.IsOKToUse();Debug.Assert(_al9);}catch(e){var _6z=Utilities.GenerateCallback(this.OnLoad,[],this);setTimeout(_6z,100);return;}gResource=new COTResource();this.oResources=gResource;_f.SetResource(this.oResources);_c.SetResource(this.oResources);_o=new CBrowserInfo();this.browserInfo=_o;this.commManager=new CCMCommManager(this,this._ot);this.dataManager=new CDLDataManager(this,this.commManager,this._ea,this._xt);this.uiManager=new CUIManager(this,this.dataManager);this.uiManager.oDialogMgr.Init();document.title=ExpMiscStr.kProductName;if(!this.browserInfo.is_supported){throw new COTUnsuportedBrowserException();}if(this._gk!=ExpMiscStr.kVersion){throw new COTUnsupportedServerVersion("The client version ("+this._gk+") and the server version ("+ExpMiscStr.kVersion+") aren't equal");}this.LoadFiles();};CMainApplication.CreateAnalyzer=function(_Ke,_yS){var _Mg=FindApp(_Ke);var _Li=_Mg.dataManager.GetCurrentDataMatrix();var _AE=new Array();for(var _TE=0;_TE<_Li.GetAxisCount();_TE++){var _akZ=_yS[_TE];for(var i=0;i<_akZ.length;i++){if(i==(_akZ.length-1)){var _Lv=new CUIDragDropMember(_akZ[i]);_Lv.kPopulation=ExpAPIXml.kChildrenPopulation;_Lv.kAction=ExpAPIXml.kActionReplace;var _Jj=_Li.GetAxis(i).DoReplace(_Lv.sId,_Lv.kPopulation,null,_Lv.sLevId,true);_AE.push(_Jj);}else{var _4H=_Mg.dataManager.GetCurrentWSFilterSet();var _aED=_4H.InsertDimFilter(new Array(_akZ[i]),null,true);if(_aED.length){for(var x=0;x<_aED.length;x++){_AE.push(_aED[x]);}}else{_AE.push(_aED);}}}}_Li.SendDMActionArray(_AE);};CMainApplication.prototype.loadInitial=function(){this.uiManager.CreateStartupView();if(this._iH!=''){var _AE=new Array();var _Jj=new CDLAction();_Jj.type="getResponseForHLS";_Jj._eW("hls",this._iH);_AE.push(_Jj);var _aBj=this.dataManager.commManager.CreateExploreRequest(_AE);if(window.bAnalyzer){var _5Y=new Array(this.appname,window.aSelAnalysisItem);Utilities.SetProcedureToHold('CMainApplication.CreateAnalyzer',_5Y);var _ajP=Utilities.ExecuteHoldingProcedure;_aBj.SetDeferredCallBackFunction(_ajP);}_aBj.Send();window.bAnalyzer=null;window.aSelAnalysisItem=null;}else if(this._vv!=''||this._pT!=''){this._wJ._mE=true;var _Zj=null;if(this._pT!=''){_Zj=_c.LoadDocument(this._pT,false,true,false);}else{_Zj=_c.LoadString(this._vv,true,false);}var _ai0=Dom.GetElementsByTagName(_Zj,"ansresponse");for(var i=0;i<_ai0.length;i++){this._wJ.AddResponse(_ai0[i]);}_c.CreateHTTPObject=_c.CreateFakeHTTPObject;if(!this._yh){this.dataManager.IssueInitialRequest();}else{this.SelectDefaultAnalysis();}CBIBus.biBus._wr.sRequestId="request_i1";CBIBus.m_oRequests[CBIBus.m_iRequestID-1].m_oXMLHTTP.responseXML=this._wJ.GetCurrentResp();CBIBus.m_oRequests[CBIBus.m_iRequestID-1].m_oXMLHTTP.readyState=4;CBIBus.OnReadyStateChange(CBIBus.m_iRequestID-1);this._wJ._g9++;return;}else{if(!this._yh){this.dataManager.IssueInitialRequest();}else{this.SelectDefaultAnalysis();}}};CMainApplication.prototype.RenderNextRegressionTestResponse=function(){var _AE=new Array();var _Jj=new CDLAction();_Jj.type="fakeaction";_AE.push(_Jj);Debug.Call(Debug.kUnitHooks,Debug.kStartRequest);Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CMainApplication::RenderNextRegressionTestResponse"]);var _aBj=this.dataManager.commManager.CreateExploreRequest(_AE);_aBj.Send();_aBj.sRequestId="request_i1";var _aIg=this._wJ.GetCurrentResp();CBIBus.m_oRequests[CBIBus.m_iRequestID-1].m_oXMLHTTP.responseXML=_aIg;var _1L=Dom.GetElementsByTagName(_aIg,ExpAPIXml.kEleServerState);this.dataManager.commManager._tO=_1L[0];CBIBus.m_oRequests[CBIBus.m_iRequestID-1].m_oXMLHTTP.readyState=4;CBIBus.OnReadyStateChange(CBIBus.m_iRequestID-1);Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CMainApplication::RenderNextRegressionTestResponse"]);Debug.Call(Debug.kUnitHooks,Debug.kStopRequest);};CMainApplication.prototype.setRunning=function(){this.isRunning=true;Utilities.RemoveSplash();};CMainApplication.prototype.LaunchPortalWelcomeTool=function(){var _X7=document.createElement('form');_X7.setAttribute("action","../bi/v1/disp");_X7.setAttribute("method","post");_X7.setAttribute("name","newLaunch");_X7.setAttribute("target",_X7.name);_X7.appendChild(createHiddenFormField("b_action","xts.run"));_X7.appendChild(createHiddenFormField("m","portal/launch.xts"));_X7.appendChild(createHiddenFormField("ui.tool","AnalysisStudio"));_X7.appendChild(createHiddenFormField("ui.gateway","../bi/v1/disp"));_X7.appendChild(createHiddenFormField("ui.action","new"));_X7.appendChild(createHiddenFormField("ui.backURL","javascript:close()"));_X7.style.display="none";document.body.appendChild(_X7);var _akX=window.open("",_X7.name,"directories=no,location=no,status=no,toolbar=no,resizable=yes,scrollbars=yes,top=0,left=0,height=480,width=650");_akX.focus();_X7.submit();window.close();};CMainApplication.prototype.SafeOnLoad=function(){if(!window.bLoaded){this.LaunchPortalWelcomeTool();return;}/*@if(!@bering_debug)@*/try{/*@end@*/this.OnLoad();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CMainApplication.prototype.SetDefaultBlockSize=function(_KU){if(_KU!=null)this._sE=_KU;};CMainApplication.prototype.SetMaximumBlockSize=function(_KU){if(_KU!=null)this._ft=_KU;};CMainApplication.prototype.SetDefaultExpand=function(_GU){if(_GU!=null)this._jB=_GU;};CMainApplication.prototype.SetMaximumExpand=function(_GU){if(_GU!=null)this._al=_GU;};CMainApplication.prototype.SetGateway=function(_RA){this._ot=_RA;};CMainApplication.prototype.GetGatewayURL=function(){return this._ot;};CMainApplication.prototype.SetPackage=function(_Un){this._ea=_Un;};CMainApplication.prototype.SetQuery=function(_LP){this._xt=_LP;};CMainApplication.prototype.GetCAFContextID=function(){return this._x0;};CMainApplication.prototype.SetCAFContextID=function(_Dh){this._x0=_Dh;};CMainApplication.prototype.GetCacheContext=function(){return this._kY;};CMainApplication.prototype.SetCacheContext=function(_yy){this._kY=_yy;};CMainApplication.prototype.GetHideXLS=function(){return this._bn;};CMainApplication.prototype.SetHideXLS=function(_Nq){this._bn=_Nq;};CMainApplication.prototype.GetRoutingServerGroup=function(){return this._vu;};CMainApplication.prototype.SetRoutingServerGroup=function(_I6){this._vu=_I6;};CMainApplication.prototype.GetDefaultAnalysis=function(){if(this._hy==null)return 'false';return this._hy;};CMainApplication.prototype.HasDefaultAnalysis=function(){if((!this._hy)||(this._hy==DefaultAnalysis.kBlank)){return false;}else{return true;}};CMainApplication.prototype.SetDefaultAnalysis=function(_yX){if(g_PSParameters["lastDefaultAnalysis"]){this._hy=g_PSParameters["lastDefaultAnalysis"];return;}if(_yX!=null&&_yX!=""){this._hy=_yX;}else{this._hy=DefaultAnalysis.kServerDefault;}};CMainApplication.prototype.UpdateDefaultAnalysis=function(_yX,_LT,_HE){if(_yX==DefaultAnalysis.kServerDefault){this._hy=g_PSParameters["ui.defaultAnalysis"];if(this._hy==null||this._hy==DefaultAnalysis.kBlank){this._hy=_yX;}}else if(_yX==DefaultAnalysis.kBlank){this._hy=_yX;}g_PSParameters["lastDefaultAnalysis"]=this._hy;if(_LT){var _aoo=new Date();_aoo.setTime(_aoo.getTime()+315360000000);var _aux=(_HE?ExpAPIXml.kTrue:ExpAPIXml.kFalse)+CookieConstants.kValueSplitter+_yX;CookieJar.SetCookie(CookieConstants.kShowWelcomeDlg,_aux,_aoo);}};CMainApplication.prototype.GetDynamicContext=function(){if(this._eH==null)return 'false';return this._eH;};CMainApplication.prototype.GetDrillTargetParms=function(){return this._ac;};CMainApplication.prototype.SetDrillTargetParms=function(_zW){if(_zW&&_zW!="false"){var _aFm=_zW;var _auE='<item xsi:type="bus:parameterValue';var _aeF='</bus:parameters>';var _aBY=_aFm.indexOf(_auE);var _aEW=_aFm.indexOf(_aeF);while(_aBY!=-1&&_aEW!=-1){this._ac+=_aFm.substring(_aBY,_aEW);_aFm=_aFm.substring(_aEW+_aeF.length);_aBY=_aFm.indexOf(_auE);_aEW=_aFm.indexOf(_aeF);}}};CMainApplication.prototype.LoadFiles=function(){var _aHs=new Array(this.getResourceURL(),this.getAboutboxURL(),this.getHotsiteResourceURL(),"../version.xml");this.oXMLLoader=new XMLLoader();this.oXMLLoader.Load(this,_aHs);};CMainApplication.prototype.initStringsFromResourceFile=function(_Kp,_TR,_R6){var _B4=false;var _Ms=false;var _UK=true;var _6W=_c.RemoveXMLPI(_Kp[_TR]);var _BA=_c.LoadString(_6W,_B4,_Ms,_UK);var _aoX=Dom.GetElementsByTagName(_BA,ExpAPIXml.kEleStringTable);bHotsiteStrings=true;var _6d=_c.LoadString(_6W,_B4,_Ms,false);var _Yn=Dom.GetElementsByTagName(_6d,ExpAPIXml.kEleStringTable);this.oResources.ProcessStrings(_aoX[0],_Yn[0],bHotsiteStrings);};CMainApplication.prototype.loadDefaultResFile=function(){CUIDialogMgr.SafeHideCurrentDialog(this.appname);this.oXMLLoader.Load(this,["../explore/res/ansmsgs_en.xml"]);this._bm=true;};CMainApplication.prototype.XMLLoader_OnAllFilesLoaded=function(_Kp){if(this._bm){this._bm=false;var _TR="../explore/res/ansmsgs_en.xml";this.initStringsFromResourceFile(_Kp,_TR,false);this.loadInitial();return;}_TR="../version.xml";if(_Kp[_TR]!=null){var _6W=_c.RemoveXMLPI(_Kp[_TR]);var _BA=_c.LoadString(_6W);if(_BA.documentElement.getAttribute("isRelease")=="false"){this.bNotForResale=true;}}_TR=this.getHotsiteResourceURL();if(_Kp[_TR]!=null){this.initStringsFromResourceFile(_Kp,_TR,true);}_TR=this.getAboutboxURL();if(_Kp[_TR]!=null){this._hW="ansAboutBox_"+this._aB;}else{this._hW="ansAboutBox_en";}_TR=this.getResourceURL();if(_Kp[_TR]!=null){this.initStringsFromResourceFile(_Kp,_TR,false);this.loadInitial();}else{var _aBt=this.oResources.GetString('MES_MISSING_RESOURCE_FILE');var _aAS=Utilities.GenerateCallback(this.loadDefaultResFile,null,this);var _ajK=Utilities.GenerateCallback(CUIDialogMgr.SafeHandleExit,[this.appname]);CUIDialogMgr._U.SetCallBackFuntion(_aAS,null,_ajK);CUIDialogMgr._U.Display(_aBt,'',CUIConfirmDlg._hw);}};CMainApplication.prototype.SelectDefaultAnalysis=function(){var _aC1=this.GetWelcomeCookie();var _HE=(_aC1.showDlg==ExpAPIXml.kTrue);var _yX=_aC1.defAnalysis;if(!_HE&&_yX){this.UpdateDefaultAnalysis(_yX);this.uiManager.dataManager.IssueInitialRequest();}else{CUIDialogMgr.DisplayDefaultANSDialog();}};CMainApplication.prototype.GetWelcomeCookie=function(){var _anZ=CookieJar.GetCookie(CookieConstants.kShowWelcomeDlg);var _7Y={showDlg:"true",defAnalysis:DefaultAnalysis.kBlank};if(_anZ){var _aiy=_anZ.split(CookieConstants.kValueSplitter);_7Y.showDlg=_aiy[0];_7Y.defAnalysis=_aiy[1];}return _7Y;};CMainApplication.prototype.IsWelcomeDialogEnabled=function(){return(this.GetWelcomeCookie().showDlg==ExpAPIXml.kTrue);};CMainApplication.prototype.ToggleWelcomeDlgSetting=function(){var _aoo=new Date();_aoo.setTime(_aoo.getTime()+315360000000);var _aC1=this.GetWelcomeCookie();var _aaP=_aC1.showDlg;var _yX=_aC1.defAnalysis;CookieJar.DeleteCookie(CookieConstants.kShowWelcomeDlg);sToggleVal=((_aaP==ExpAPIXml.kTrue)?ExpAPIXml.kFalse:ExpAPIXml.kTrue)+CookieConstants.kValueSplitter+_yX;CookieJar.SetCookie(CookieConstants.kShowWelcomeDlg,sToggleVal,_aoo);};CMainApplication.prototype.SetVersion=function(_Lb){this._gk=_Lb;};CMainApplication.prototype.GetVersionString=function(){return this._gk;};CMainApplication.prototype.SetResource=function(_SH){this.oResources=_SH;};CMainApplication.prototype.EditReport=function(_EG,_BU){RSParameters=new Object();if(_BU){RSParameters["folder"]=_BU;}RSParameters["gateway"]=this._ot;RSParameters["report"]=_EG;if(this._vu){RSParameters["routingServerGroup"]=this._vu;}if(this._x0!=""){RSParameters["cafcontextid"]=this._x0;}if(this._bn){RSParameters["hideXLS"]=this._bn;}RSParameters["rs_UIProfile"]=CDLCapability.K_sProfessional;window.open("../pat/rsapp.htm","_blank","menubar=no,toolbar=no,status=no,location=no,resizable=yes,width=700,height=500");return;};CMainApplication.prototype.SetRunType=function(_Wo){this.sOutputFormat=_Wo;};CMainApplication.prototype.RunReport=function(_OS){var _aei=document.getElementById("idReportEngineForm");_aei.target="winNAT_"+(new Date()).getTime();_aei.action=this._ot.replace(/\/v\d+\/disp\/?$/,'/');if(this.sOutputFormat){_aei["run.outputFormat"].value=this.sOutputFormat;}else{_aei["run.outputFormat"].value="HTML";}_aei["ui.spec"].value=_OS;_aei["ui.cafcontextid"].value=this._x0;_aei.modelPath.value=this.uiManager.GetDrillThroughModel();if(this._vu){_aei["ui.routingServerGroup"].value=this._vu;}var _Rh=this.commManager.GetParameterValues();if(_Rh){var _aBC=this.createParametersTemplate(_Rh);_aei.parameterValues.value=_aBC;}this.m_winReport=window.open("blank.htm",_aei.target,"menubar=no,toolbar=no,status=no,location=no,resizable=yes,scrollbars=yes");var _azT=this.m_winReport.document;_azT.open();_azT.write('<html><head><title>');_azT.write(this.oResources.GetString('IDS_RUN_REPORT_WINDOW_TITLE'));_azT.write('</title></head><body style="background-color:window;font:messagebox;font-size:10pt;overflow:auto"><p>');_azT.write(this.oResources.GetString('IDS_REPORT_SUBMITTED'));_azT.write('</p></body></html>');_azT.close();this.m_winReport.focus();_aei.submit();};CMainApplication.prototype.IsSearching=function(){return this.uiManager.IsSearching();};function CBrowserInfo(){var _aw5=navigator.userAgent.toLowerCase();var _2T=parseInt(navigator.appVersion);var _azu=parseFloat(navigator.appVersion);var _aG9=((_aw5.indexOf('mozilla')!=-1)&&(_aw5.indexOf('spoofer')==-1)&&(_aw5.indexOf('compatible')==-1)&&(_aw5.indexOf('opera')==-1)&&(_aw5.indexOf('webtv')==-1)&&(_aw5.indexOf('hotjava')==-1));var _Yp=(_aG9&&(_2T>=4));var _arZ=(_aG9&&((_aw5.indexOf(";nav")!=-1)||(_aw5.indexOf("; nav")!=-1)));var _aac=(_aG9&&(_2T==5));var _aEQ=(_aG9&&(_2T>=5));var _X2=(_aw5.indexOf('gecko')!=-1);var _4y=(_aw5.indexOf('netscape')!=-1);var _aCw=(parseFloat(_aw5.substr(_aw5.indexOf('netscape/')+9)));var _awk=(_aCw>=7.01);var _awv=(_aw5.indexOf('firefox')!=-1);var _ak0=((_aw5.indexOf("msie")!=-1)&&(_aw5.indexOf("opera")==-1));var _aul=(_ak0&&(_2T<4));var _aui=(_ak0&&(_2T==4)&&(_aw5.indexOf("msie 4")!=-1));var _XW=(_ak0&&(_2T>=4));var _auh=(_ak0&&(_2T==4)&&(_aw5.indexOf("msie 5.0")!=-1));var _aFu=(_ak0&&(_2T==4)&&(_aw5.indexOf("msie 5.5")!=-1));var _axy=(_ak0&&!_aul&&!_aui);var _au0=(_ak0&&!_aul&&!_aui&&!_auh);var _auk=(_ak0&&(_2T==4)&&(_aw5.indexOf("msie 6.")!=-1));var _4D=(_ak0&&(_2T==4)&&(_aw5.indexOf("msie 7.")!=-1));var _ag1=(_ak0&&!_aul&&!_aui&&!_auh&&!_aFu);this.bBackCompat=true;if(_ag1||_aEQ){this.bBackCompat=false;}if(_ag1&&(document.compatMode=="BackCompat")){this.bBackCompat=true;}COTStyle.SetBackCompat(this.bBackCompat);this.is_ie5_5up=_au0;this.is_nav7up=_awk||_awv;this.is_netscape=_4y||_awv;this.is_firefox=_awv;this.is_ie7=_4D;this.is_supported=true;};CMainApplication.prototype.DrillThroughSearch=function(){var _Hl=this.uiManager.GetDrillThroughPackage();var _6v=this.getDrillThroughSearchContextString();var _8J=this.commManager.GetParameterValues();var _69=document.createElement("form");_69.setAttribute("id","gotoSearchPage");_69.setAttribute("name","gotoSearchPage");_69.setAttribute("target",_69.name);_69.setAttribute("method","post");_69.setAttribute("action",this.GetGatewayURL()+"/gosearch");_69.style.display="none";document.body.appendChild(_69);_69.appendChild(createHiddenFormField("csn.action","drill"));_69.appendChild(createHiddenFormField("csn.drill",_6v));if(_8J){var _aBC=this.createParametersTemplate(_8J);_69.appendChild(createHiddenFormField("executionParameters",_aBC));}var _akX=window.open("",_69.name,"directories=no,location=no,status=no,toolbar=no,resizable=yes,scrollbars=yes,top=100,left=100,height=480,width=640");_akX.focus();_69.submit();};CMainApplication.prototype.getParameterValuesNodeString=function(_Cn,_Lh){var _aGf=new Object();_aGf['xmlns:xs']="http://www.w3.org/2001/XMLSchema";_aGf['xmlns:bus']="http://developer.cognos.com/schemas/bibus/3/";_aGf['SOAP-ENC:arrayType']="bus:parameterValue[]";_aGf['xmlns:SOAP-ENC']="http://schemas.xmlsoap.org/soap/encoding/";_aGf['xmlns:xsd']="http://www.w3.org/2001/XMLSchema";_aGf['xmlns:xsi']="http://www.w3.org/2001/XMLSchema-instance";_aGf['xsi:type']="SOAP-ENC:Array";var _5K=_c.CreateElement(_Cn,_Lh,true,_aGf);return _5K;};CMainApplication.prototype.getParamValueItemString=function(_Cr,_Rj){var _aGf=new Object();_aGf['xsi:type']="xs:string";var _Lh=_c.CreateElement('bus:name',_Cr,true,_aGf);var _0l='';for(var i=0;i<_Rj.length;i++){var _aii=new Object();_aii['xsi:type']="xs:string";var _FT='';if(_Rj[i]instanceof CDLBLKDataPair){var _zq=_Rj[i].GetDataItem();var _aIN=_Rj[i].GetAdditionInfoName();if(_Rj[i].GetAdditionInfoValue()){_FT=_aIN+'('+Utilities.HtmlEncode(Utilities.Descheme(_zq.GetId()))+','+_Rj[i].GetAdditionInfoValue()+')';}else{_FT=_aIN+'('+Utilities.HtmlEncode(Utilities.Descheme(_zq.GetId()))+')';}}else{_FT=Utilities.HtmlEncode(Utilities.Descheme(_Rj[i].GetId()));}var _5F=_c.CreateElement('bus:use',_FT,true,_aii);_5F+=_c.CreateElement('bus:display',_Rj[i].GetLabel(),true,_aii);var _aAp=new Object();_aAp['xsi:type']="bus:simpleParmValueItem";_0l+=_c.CreateElement('item',_5F,true,_aAp);}var _ac7=new Object();_ac7['SOAP-ENC:arrayType']="bus:parmValueItem[]";_ac7['xsi:type']="SOAP-ENC:Array";_Lh+=_c.CreateElement('bus:value',_0l,true,_ac7);var _an0=new Object();_an0['xsi:type']="bus:parameterValue";var _ahe=_c.CreateElement('item',_Lh,true,_an0);return _ahe;};CMainApplication.prototype.getDrillThroughSearchContextString=function(){var _af2=this.uiManager.GetSelectedDrillSearchContext();var _0u=new Object();for(var i=0;i<_af2.length;i++){var _ab7=_af2[i].GetDimId();if(!_0u[_ab7]){_0u[_ab7]=new Array();}_0u[_ab7].push(_af2[i]);}var _aDw=this.uiManager.GetGeneralDrillSearchContext();var _2U=new Object();for(var i=0;i<_aDw.length;i++){var _ab7=_aDw[i].GetDimId();if(!_2U[_ab7]){_2U[_ab7]=new Array();}_2U[_ab7].push(_aDw[i]);}var _auC=this.uiManager.GetFilterContext();var _adS=new Object();for(var i=0;i<_auC.length;i++){var _ab7=_auC[i].GetDimId();if(!_adS[_ab7]){_adS[_ab7]=new Array();}_adS[_ab7].push(_auC[i]);}var _abg=_c.CreateElement('package',this.dataManager.metadata.GetPackagePath(),true);_abg+=_c.CreateElement('model',this.dataManager.metadata.GetModelPath(),true);var _ZD='';for(var s in _0u){var _aoQ=_0u[s];var _avL=this.dataManager.metadata.GetDimById(s).GetLabel();_ZD+=this.getParamValueItemString(_avL,_aoQ);}_abg+=this.getParameterValuesNodeString('selectedContext',_ZD);_ZD='';var _HT=this.dataManager.GetCurrentDataMatrix().GetCurrentMeasureId();var _NS=this.dataManager.metadata.GetMeasure(_HT);if(_NS){var _avL=_NS.GetDim().GetLabel();_ZD+=this.getParamValueItemString(_avL,new Array(_NS));}_abg+=this.getParameterValuesNodeString('defaultMeasure',_ZD);_ZD='';for(var s in _2U){var _aoQ=_2U[s];var _avL=this.dataManager.metadata.GetDimById(s).GetLabel();_ZD+=this.getParamValueItemString(_avL,_aoQ);}_abg+=this.getParameterValuesNodeString('data',_ZD);_ZD='';for(var s in _adS){var _aoQ=_adS[s];var _avL=this.dataManager.metadata.GetDimById(s).GetLabel();_ZD+=this.getParamValueItemString(_avL,_aoQ);}_abg+=this.getParameterValuesNodeString('filter',_ZD);var _aaB=new Object();_aaB['xmlns:cs']="http://developer.cognos.com/schemas/cs/1/";_abg=_c.CreateElement('cognosSearch',_abg,true,_aaB);return _abg;};CMainApplication.prototype.DrillThrough=function(_Nl){var _Hl=this.uiManager.GetDrillThroughPackage();var _8J=this.commManager.GetParameterValues();var _69=document.createElement("form");_69.setAttribute("id","gotoPage");_69.setAttribute("name","gotoPage");_69.setAttribute("target",_69.name);_69.setAttribute("method","post");_69.setAttribute("action",this.GetGatewayURL());_69.style.display="none";document.body.appendChild(_69);_69.appendChild(createHiddenFormField("objpath",_Hl));if(this._q7){var _ane=this.getSelectionContext(_Hl);_69.appendChild(createHiddenFormField("m","portal/goto2.xts"));_69.appendChild(createHiddenFormField("drillContext",_ane.toString()));}else{var _ayZ=this.getModelDrillThroughContextString();_69.appendChild(createHiddenFormField("m","portal/goto.xts"));_69.appendChild(createHiddenFormField("modeledDrillthru",_ayZ));}_69.appendChild(createHiddenFormField("b_action","xts.run"));_69.appendChild(createHiddenFormField("directLaunch",_Nl));var _7V=this._vu?this._vu:"";_69.appendChild(createHiddenFormField("ui.routingServerGroup",_7V));if(_8J){var _aBC=this.createParametersTemplate(_8J);_69.appendChild(createHiddenFormField("executionParameters",_aBC));}var _akX=window.open("",_69.name,"directories=no,location=no,status=no,toolbar=no,resizable=yes,scrollbars=yes,top=100,left=100,height=480,width=640");_akX.focus();_69.submit();};CMainApplication.prototype.getSelectionContext=function(_Hl){var _ane=new CANSSelectionContext(_Hl);this.uiManager.SetSelectionContext(_ane);return _ane;};CMainApplication.prototype.getModelDrillThroughContextString=function(){var _Y6=this.dataManager.metadata.IsFunctionSupported(ExpAPIXml.kQosMultiHierOfSameDim);var _apl=this.uiManager.GetDrillThroughContext();var _aam=new Object();for(var i=0;i<_apl.length;i++){var _azD="";var _S8=_apl[i].GetLevel();if(_S8){_azD=Utilities.Descheme(_S8.GetId());}else{_azD=Utilities.Descheme(_apl[i].GetHierId());}if(!_aam[_azD]){_aam[_azD]={};}_aam[_azD][_apl[i].GetId()]=_apl[i];}var _ayZ='<context>';_ayZ+='<parameterValues xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:bus="http://developer.cognos.com/schemas/bibus/3/" SOAP-ENC:arrayType="bus:parameterValue[]" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="SOAP-ENC:Array">';for(var s in _aam){var _auT=_aam[s];var _av5=Utilities.Descheme(s);_ayZ+='<item xsi:type="bus:parameterValue">';_ayZ+='<bus:name xsi:type="xs:string">';_ayZ+=Utilities.HtmlEncode(_av5);_ayZ+='</bus:name>';_ayZ+='<bus:value SOAP-ENC:arrayType="bus:parmValueItem[]" xsi:type="SOAP-ENC:Array">';for(var objects in _auT){_ayZ+='<item xsi:type="bus:simpleParmValueItem">';_ayZ+='<bus:use xsi:type="xs:string">';_ayZ+=Utilities.HtmlEncode(Utilities.Descheme(objects));_ayZ+='</bus:use>';_ayZ+='<bus:display xsi:type="xs:string">';_ayZ+=Utilities.HtmlEncode(Utilities.Descheme(_auT[objects].GetLabel()));_ayZ+='</bus:display>';_ayZ+='</item>';}_ayZ+='</bus:value>';_ayZ+='</item>';}_ayZ+='</parameterValues>';_ayZ+='</context>';delete _aam;return _ayZ;};CMainApplication.prototype.okToRelease=function(){if(g_PSParameters["as.tracking"]==null)return true;return false;};CMainApplication.prototype.doOpenAnalysis=function(_QF,_I6){g_PSParameters["query"]=_QF;g_PSParameters["ui.action"]="edit";g_PSParameters["ui.object"]=_QF;g_PSParameters["as.tracking"]=this.getRequestTracking();if(_I6){g_PSParameters["ui.routingServerGroup"]=_I6;}else{g_PSParameters["ui.routingServerGroup"]=null;}Launch();};CMainApplication.prototype.doOpenModel=function(_QF){g_PSParameters["model"]=_QF;g_PSParameters["isOpenModel"]=true;g_PSParameters["ui.action"]="new";g_PSParameters["ui.object"]=_QF;g_PSParameters["as.tracking"]=this.getRequestTracking();Launch();};CMainApplication.prototype.doPasteHLS=function(_SD){g_PSParameters["ui.action"]="pasteHLS";g_PSParameters["ui.object"]=_SD;Launch();};CMainApplication.prototype.OpenHLSFromDiffMining=function(_SD){window.originHLS=_SD;LaunchNewWindow(null);};function Launch(){window.onbeforeunload=null;CMainApplication.prototype.doOpenAnalysis=function(){};PSParameters=new Object();for(var s in g_PSParameters){PSParameters[s]=g_PSParameters[s];}var _6j=null;if(Debug.IsEnabled()){_6j=window.open("../ansdev/exploreDebug.htm","_blank","menubar=no,toolbar=no,status=yes,location=no,resizable=yes,width=300,height=300");}else{_6j=window.open("../explore/explore.htm","_blank","menubar=no,toolbar=no,status=no,location=no,resizable=yes,width=700,height=500");}if(_6j!=null){if(_o.is_ie5_5up&&(CUIManager.bF5||CUIManager.bRefresh)){var i=0;while(_6j.document.readyState!="complete"){i++;}}}};function LaunchNewWindow(_Vg){PSParameters=new Object();for(var s in g_PSParameters){PSParameters[s]=g_PSParameters[s];}if(window.originHLS){PSParameters["ui.action"]="pasteHLS";PSParameters["ui.object"]=window.originHLS;window.originHLS=null;}window.bSkipPostLoad=true;_6j=null;if(Debug.IsEnabled()){_6j=window.open("../explore/exploreDebug.htm","_blank","menubar=no,toolbar=no,status=yes,location=no,resizable=yes,width=700,height=500");}else{_6j=window.open("../explore/explore.htm","_blank","menubar=no,toolbar=no,status=no,location=no,resizable=yes,width=700,height=500");}_6j.focus();_6j.bAnalyzer=true;_6j.aSelAnalysisItem=_Vg;};window.postLoad=function(){window.close();};function createHiddenFormField(name,_UN){var _2a=document.createElement("input");_2a.setAttribute("type","hidden");_2a.setAttribute("name",name);_2a.setAttribute("value",_UN);return(_2a);};function CANSSelectionContext(_MB){this.base=CSelectionContext;this.base(_MB);};CANSSelectionContext.prototype=new CSelectionContext;CANSSelectionContext.superclass=CSelectionContext.prototype;CANSSelectionContext.kMeasureUsage="measure";CANSSelectionContext.kNonMeasureUsage="nonMeasure";CANSSelectionContext.prototype.GetSelectedDataCell=function(){if(this._ep){return this.selections[0];}return null;};CMainApplication.prototype.createParametersTemplate=function(_Iw){var _6A=CMainApplication.m_sParametersTemplate;_6A=_6A.replace("@PARAMETERVALUES@",_Iw);return _6A;};CMainApplication.m_sParametersTemplate='<parameterValues xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="SOAP-ENC:Array" SOAP-ENC:arrayType="bus:parameterValue[]">'+'@PARAMETERVALUES@'+'</parameterValues>';ExpAPIXml.kAttrObjType="type";ExpAPIXml.kAttrIntData='integer';ExpAPIXml.kAttrFloatData='float';ExpAPIXml.kAttrStringData='string';ExpAPIXml.kAttrSegment='segment';ExpAPIXml.kAttrValueDefSegment='defaultsegment';ExpAPIXml.kImmediateDescendants='immediatedescendants';ExpAPIXml.kAllDescendants='alldescendants';ExpAPIXml.kSearchScope='searchscope';ExpAPIXml.kPropertyName='propertyname';ExpAPIXml.kMemberCaption='membercaption';ExpAPIXml.kMeasureCaption='measurecaption';ExpAPIXml.kMeasureDimension='measuredimension';ExpAPIXml.kMemberOp='member';ExpAPIXml.kDisplayType='displaytype';ExpAPIXml.kDefDisplayDsp='value';ExpAPIXml.kPcntRowTotalDsp='percentofrowtotal';ExpAPIXml.kPcntRowSubTotalDsp='percentofrowsubtotal';ExpAPIXml.kPcntColTotalDsp='percentofcoltotal';ExpAPIXml.kPcntColSubTotalDsp='percentofcolsubtotal';ExpAPIXml.kPcntOfTotalDsp='percentoftotal';ExpAPIXml.kNoDataDsp='nocelldata';ExpAPIXml.kAttrNoDataMode='enablenodatamodes';ExpAPIXml.kDefMeaPretType='presentationtype';ExpAPIXml.kDefMeaTemplatePretType='template';ExpAPIXml.kDefMeaActivePretType='active';ExpAPIXml.kDefMeaSecondaryActivePretType='secondaryactive';ExpAPIXml.kDefMeaInactivePretType='inactive';ExpAPIXml.kDefMeaNonePretType='none';ExpAPIXml.kDefMeaSecondaryNonePretType='secondarynone';ExpAPIXml.kAttrContext='context';ExpAPIXml.kEleRequestState="requeststate";ExpAPIXml.kEleClientState="clientstate";ExpAPIXml.kEleServerState="serverstate";ExpAPIXml.kEleAppName="appname";ExpAPIXml.kEleRequestId="requestId";ExpAPIXml.kEleCommands="commands";ExpAPIXml.kEleCommand="command";ExpAPIXml.kEleCmdAction="action";ExpAPIXml.kEleCmdTarget="target";ExpAPIXml.kEleItem="item";ExpAPIXml.kEleObjectType="objtype";ExpAPIXml.kEleObjectPtr="objptr";ExpAPIXml.kXpathExprObjPtrText=ExpAPIXml.kEleItem+"/"+ExpAPIXml.kEleObjectPtr+"/text()";ExpAPIXml.kEleStatus="status";ExpAPIXml.kEleLevelRef="levelref";ExpAPIXml.kEleQFCommand="qs:command";ExpAPIXml.kEleQFCommandNoPreFix="command";ExpAPIXml.kEleQFReport="report";ExpAPIXml.kEleLayout="layout";ExpAPIXml.kEleWorksheet="worksheet";ExpAPIXml.kEleFilterSet="filterset";ExpAPIXml.kEleMetadata="metadata";ExpAPIXml.kEleDataMatrix="datamatrix";ExpAPIXml.kEleChart="chart";ExpAPIXml.kEleCrosstab="crosstab";ExpAPIXml.kEleNamedSets="namedsets";ExpAPIXml.kEleNamedSet="namedset";ExpAPIXml.kEleSubsVars="subsvars";ExpAPIXml.kEleSubsVar="subsvar";ExpAPIXml.kEleCMFolder="cmfolder";ExpAPIXml.kEleResource="resource";ExpAPIXml.kEleVersionInfo="versioninfo";ExpAPIXml.kEleAnalysis="analysis";ExpAPIXml.KEleDescriptiveStats="descriptivestats";ExpAPIXml.kElePropPtr="propptr";ExpAPIXml.kEleCalcPtr="calcptr";ExpAPIXml.kEleCalcDefPtr="calcdefptr";ExpAPIXml.kEleLevelPtr="levelptr";ExpAPIXml.kEleWorksheetPtr="worksheetptr";ExpAPIXml.kEleFilterSetPtr="filtersetptr";ExpAPIXml.kEleMemberPtr="memberptr";ExpAPIXml.kEleMeasurePtr="measureptr";ExpAPIXml.kEleAxisPtr="axisptr";ExpAPIXml.kEleAxisOpExprPtr="blockptr";ExpAPIXml.kEleDataMatrixPtr="datamatrixptr";ExpAPIXml.kEleDimensionPtr="dimensionptr";ExpAPIXml.kEleHierarchyPtr="hierarchyptr";ExpAPIXml.kEleFilter="filter";ExpAPIXml.kEleFilterType="filtertype";ExpAPIXml.kEleFLPosition="position";ExpAPIXml.kEleFLLabel="label";ExpAPIXml.kEleSuppressDef="suppressdef";ExpAPIXml.kEleSuppressType="type";ExpAPIXml.kEleSuppressState="state";ExpAPIXml.kEleItemName="itemname";ExpAPIXml.kEleFilterCaption="caption";ExpAPIXml.kEleUseAsParam="useasparam";ExpAPIXml.kEleUserDefFilter="userdeffilter";ExpAPIXml.kEleUserDefFilterExpr="expression";ExpAPIXml.kEleOrgFilterExprType="origintype";ExpAPIXml.kEleBasicFilterExpr="basic";ExpAPIXml.kEleCombineFilterExpr="combine";ExpAPIXml.kEleGroupedExpr="grouped";ExpAPIXml.kEleSubset="subset";ExpAPIXml.kEleFLSorttype="sorttype";ExpAPIXml.kEleFLSubsettype="subsettype";ExpAPIXml.kEleFLSetSize="setsize";ExpAPIXml.kEleFLSortMeasure="sortmeasure";ExpAPIXml.kEleDefaultMember="defaultmember";ExpAPIXml.kEleAxisExprMember="axisexprmember";ExpAPIXml.kEleHiddenList="hiddenlist";ExpAPIXml.kEleExcludedList="excludedlist";ExpAPIXml.kEleRelParentBlock="relparentblock";ExpAPIXml.kEleAxisOpExprCalc="calculation";ExpAPIXml.kEleCalcName="name";ExpAPIXml.kEleCalcLabel="description";ExpAPIXml.kEleAxisOpExprCalcExpr="expr";ExpAPIXml.kEleAxisOpExprCalcExprApply="apply";ExpAPIXml.kEleAxisOpExprCalcExprCI="ci";ExpAPIXml.kEleAxisOpExprCalcExprCN="cn";ExpAPIXml.kCalcParent="parent";ExpAPIXml.kCalcSibling="sibling";ExpAPIXml.kEleTitle="title";ExpAPIXml.kEleSubtitle="subtitle";ExpAPIXml.kEleReportTemplate="reporttemplate";ExpAPIXml.kEleUseReportTemplate="usereporttemplate";ExpAPIXml.kElePaperOrientation="paperorientation";ExpAPIXml.kElePaperSize="papersize";ExpAPIXml.kEleDisplayFilter="displayfilter";ExpAPIXml.kEleDisplayFilterPos="displayfilterposition";ExpAPIXml.kEleDisplayDataUpdatedOn="displaydataupdatedon";ExpAPIXml.kEleDisplayAllItems="displayallitemsexpand";ExpAPIXml.kEleDisplayOutermostGroups="displayoutermostgroupsonrows";ExpAPIXml.kEleDisplaySections="displaysections";ExpAPIXml.kEleDisplaySectionItem="displaysection";ExpAPIXml.kEleDisplaySetsOnRows="displaysetsonrows";ExpAPIXml.kEleDisplayWarningPage="displaywarning";ExpAPIXml.kElePaperSizes="papersizes";ExpAPIXml.kEleHorizontalPagination="horizontalPagination";ExpAPIXml.kAttrSubTotal="subtotalenabled";ExpAPIXml.kAttrFilterAggr="filteraggregateenabled";ExpAPIXml.kAttrPassedFilterAggr="passedfilteraggregateenabled";ExpAPIXml.kAttrRemainder="remainderenabled";ExpAPIXml.kAttrShowVisible="visibleenabled";ExpAPIXml.kAttrSummary="summaryenabled";ExpAPIXml.kAttrRemainderMode="remaindermode";ExpAPIXml.kNullRemainderMode="null";ExpAPIXml.kSubtractRemainderMode="subtract";ExpAPIXml.kTreatZerosAsNullsForSuppression="treatzerosasnullsforsuppression";ExpAPIXml.kSuppressionState="suppressionstate";ExpAPIXml.kEnableSparsityRemoval="enableSparsityRemoval";ExpAPIXml.kEnableOverallSuppression="enableOverallSuppression";ExpAPIXml.KEnableDescriptiveStatistics="enableDescriptiveStatistics";ExpAPIXml.kNoSuppressionOnRowsOrColumns="none";ExpAPIXml.kSuppressRowsAndCols="both";ExpAPIXml.kSuppressRowsOnly="rows";ExpAPIXml.kSuppressColsOnly="columns";ExpAPIXml.kSuppressionCapability="suppressioncapabilities";ExpAPIXml.kUserCanEditSuppressionOptions="usercaneditsuppressionoptions";ExpAPIXml.kSuppressionCapabilityNone="none";ExpAPIXml.kSuppressionCapabilitySingleEdge="singleedge";ExpAPIXml.kSuppressionCapabilityMultiEdge="multiedge";ExpAPIXml.kEnableSameHierarchyCompatibility="enableSameHierarchyCompatibility";ExpAPIXml.kEnableSumDiffFastCalc="enableSumDiffFastCalc";ExpAPIXml.kEnableMultiRootMembersMetadataFix="enableMultiRootMembersMetadataFix";ExpAPIXml.kEleFormat="format";ExpAPIXml.kEleWhenMissing="whenMissing";ExpAPIXml.kEleWhenZero="whenZero";ExpAPIXml.kEleWhenSecurityError="whenSecurityError";ExpAPIXml.kEleWhenNotApplicable="whenNotApplicable";ExpAPIXml.kEleWhenAnyError="whenAnyError";ExpAPIXml.kEleWhenDivideZero="whenDivideZero";ExpAPIXml.kEleWhenNumericOverflow="whenNumericOverflow";ExpAPIXml.kMissingBlockPlaceHolder="uuid:missingblockplaceholder";ExpAPIXml.kMissingMemberPlaceHolder="mun:INACCESSIBLE_MEMBER";ExpAPIXml.kEleInner="inner";ExpAPIXml.kEleOuter="outer";ExpAPIXml.kEleId="id";ExpAPIXml.kEleElcid="elcid";ExpAPIXml.kEleName="name";ExpAPIXml.kEleLabel="label";ExpAPIXml.kEleValue="value";ExpAPIXml.kEleMultiValue="multivalue";ExpAPIXml.kEleCalcDef="calcdef";ExpAPIXml.kEleCalculations="calculations";ExpAPIXml.kEleCalcPool="calcpool";ExpAPIXml.kEleCalc="calc";ExpAPIXml.kXPathExprCalc="calcpool/calc";ExpAPIXml.kEleCalcExpr="calcexpr";ExpAPIXml.kEleCalcType="type";ExpAPIXml.kEleCalcIsValid="isvalid";ExpAPIXml.kEleCalcValidForFilter="canuseinfilter";ExpAPIXml.kEleCalcCanUseInSort="canuseinsort";ExpAPIXml.kEleCalcCanUseAsMeasure="canuseasmeasure";ExpAPIXml.kEleCalcCanUseAsDimFlt="canuseasdimfilter";ExpAPIXml.kEleMembers="members";ExpAPIXml.kEleRootMembers="rootmembers";ExpAPIXml.kEleMember="member";ExpAPIXml.kEleDimensions="dimensions";ExpAPIXml.kEleDimension="dimension";ExpAPIXml.kEleMeasure="measure";ExpAPIXml.kEleAxis="axis";ExpAPIXml.kEleLevels="levels";ExpAPIXml.kEleLevel="level";ExpAPIXml.kEleHierarchies="hierarchies";ExpAPIXml.kEleHierarchy="hierarchy";ExpAPIXml.kEleDescription="description";ExpAPIXml.kEleIsRagged="isragged";ExpAPIXml.kEleResStrings="resstrings";ExpAPIXml.kEleResString="resstring";ExpAPIXml.kEleLocalization="localization";ExpAPIXml.kEleLocale="locale";ExpAPIXml.kEleLanguage="language";ExpAPIXml.kEleLayoutWorksheets="layoutworksheets";ExpAPIXml.kEleLayoutWorksheet="layoutworksheet";ExpAPIXml.kEleLayoutFilterSets="layoutfiltersets";ExpAPIXml.kEleLayoutFilterSet="layoutfilterset";ExpAPIXml.kEleWorksheetProperty="wsproperty";ExpAPIXml.kEleSearchResult="searchresult";ExpAPIXml.kEleCMAnalysis="cmanalysis";ExpAPIXml.kEleCMReportTemplate="cmreporttemplate";ExpAPIXml.kEleAnnotation="annotation";ExpAPIXml.kEleIsComplete="iscomplete";ExpAPIXml.kEleMaxExpandSize="maxexpandsize";ExpAPIXml.kEleDefExpandSize="defexpandsize";ExpAPIXml.kEleMaxBlockSize="maxblocksize";ExpAPIXml.kEleDefBlockSize="defblocksize";ExpAPIXml.kEleOriginDefBlockSize="originaldefblocksize";ExpAPIXml.kElePopulation="population";ExpAPIXml.kEleHierItem="hierItem";ExpAPIXml.kEleHierDefault="default";ExpAPIXml.kEleHierItemOrdinal="ordinal";ExpAPIXml.kElePropId="propertyId";ExpAPIXml.kEleQoS="qos";ExpAPIXml.kEleQoSLevel="qoslevel";ExpAPIXml.kEleDataSources="dataSources";ExpAPIXml.kEleDataSource="dataSource";ExpAPIXml.kEleCubes="cubes";ExpAPIXml.kEleCube="cube";ExpAPIXml.kEleCubeProperties="cubeProperties";ExpAPIXml.kEleCubeName="cubeName";ExpAPIXml.kEleCubeDescription="cubeDescription";ExpAPIXml.kEleCubeCreatedOn="cubeCreatedOn";ExpAPIXml.kEleCubeDataUpdatedOn="cubeDataUpdatedOn";ExpAPIXml.kEleCubeSchemaUpdatedOn="cubeSchemaUpdatedOn";ExpAPIXml.kEleCubeDefaultMeasure="cubeDefaultMeasure";ExpAPIXml.kEleCubeCurrentPeriod="cubeCurrentPeriod";ExpAPIXml.kQosCaseInSensitiveSrch="MEMBER_SEARCH_CASE_INSENSITIVE";ExpAPIXml.kQosStartsWithSrch="MEMBER_SEARCH_STARTS_WITH";ExpAPIXml.kQosEndsWithSrch="MEMBER_SEARCH_ENDS_WITH";ExpAPIXml.kQosContainsSrch="MEMBER_SEARCH_CONTAINS";ExpAPIXml.kQosHierarchySrch="MEMBER_SEARCH_IN_HIERARCHY";ExpAPIXml.kQosMultiHierOfSameDim="MULTIPLE_HIERARCHIES_OF_SAME_DIMENSION";ExpAPIXml.kQosMultiHierOfSameDimCalc="VALUE_EXPRESSIONS_REF_MULTIPLE_HIERARCHIES_OF_SAME_DIMENSION";ExpAPIXml.kQosMultiMeasureDimCalc="MULTIPLE_MEASURE_DIMENSION_CALCULATIONS";ExpAPIXml.kElePropertyDataType="datatype";ExpAPIXml.kElePropertyDataType2="dataType";ExpAPIXml.kOppositeAxis="oppositeaxis";ExpAPIXml.kCurrentAxis="currentaxis";ExpAPIXml.kReqDefMeasure="requiresDefaultMeasure";ExpAPIXml.kEleSuppressionTuples="suppressiontuples";ExpAPIXml.kEleTupleList="tuplelist";ExpAPIXml.kEleTuple="tuple";ExpAPIXml.kXpathExprSuppressionTuple="suppress/tuple";ExpAPIXml.kEleEntry="entry";ExpAPIXml.kEleBlockId="blockid";ExpAPIXml.kEleCharacterProperty="character";ExpAPIXml.kEleCharacter16Property="characterLength16";ExpAPIXml.kEleCharacter32Property="characterLength32";ExpAPIXml.kEleCharProperty="nChar";ExpAPIXml.kEleVarCharProperty="varChar";ExpAPIXml.kEleMunliteralProperty="munliteral";ExpAPIXml.kEleInt16Property="int16";ExpAPIXml.kEleInt32Property="int32";ExpAPIXml.kEleInt64Property="int64";ExpAPIXml.kEleDecimalProperty="decimal";ExpAPIXml.kEleNumericProperty="numeric";ExpAPIXml.kEleFloatProperty="float";ExpAPIXml.kEleFloat16Property="float16";ExpAPIXml.kEleFloat32Property="float32";ExpAPIXml.kEleFloat64Property="float64";ExpAPIXml.kEleDateProperty="date";ExpAPIXml.kEleDate2Property="date2";ExpAPIXml.kEleTimeProperty="time";ExpAPIXml.kEleTime2Property="time2";ExpAPIXml.kEleDatetimeProperty="dateTime";ExpAPIXml.kEleDatetime2Property="datetime2";ExpAPIXml.kEleIntervalProperty="interval";ExpAPIXml.kEleInterval2Property="interval2";ExpAPIXml.kEleIntervalYMProperty="intervalYM";ExpAPIXml.kEleTimeTZ="timeTZ";ExpAPIXml.kEleTimeStampTZ="timeStampTZ";ExpAPIXml.kEleDBKeyProperty="databaseKey";ExpAPIXml.kEleBitProperty="bit";ExpAPIXml.kEleVarBitProperty="varBit";ExpAPIXml.kEleBinaryProperty="binary";ExpAPIXml.kEleBinaryLen16Property="binaryLength16";ExpAPIXml.kEleBlobProperty="blob";ExpAPIXml.kEleTextBlobProperty="textBlob";ExpAPIXml.kEleBlobArrProperty="blobArray";ExpAPIXml.kEleUnsupportProperty="unsupported";ExpAPIXml.kEleUnknownProperty="unknown";ExpAPIXml.kEleAxisSuppress="suppress";ExpAPIXml.kEleAxisExpression="axisexpr";ExpAPIXml.kEleAxisOp="axisop";ExpAPIXml.kEleAxisOpType="type";ExpAPIXml.kEleMemberList="memberlist";ExpAPIXml.kEleMemberType="membertype";ExpAPIXml.kEleAxisOpExpression="block";ExpAPIXml.kEleAxisOpExprType="type";ExpAPIXml.kEleAxisOpExprSubTotal="subtotalenabled";ExpAPIXml.kEleAxisOpExprFilterAggr="filteraggregateenabled";ExpAPIXml.kEleAxisOpExprPassedFilterAggr="passedfilteraggregateenabled";ExpAPIXml.kEleAxisOpExprHierarchy="hierarchyenabled";ExpAPIXml.kEleAxisOpExprRemainder="remainderenabled";ExpAPIXml.kEleAxisOpExprShowVisible="visibleenabled";ExpAPIXml.kEleAxisOpExprSummary="summaryenabled";ExpAPIXml.kEleAxisOpExprBlockSize="blocksize";ExpAPIXml.kEleAxisOpExprName="name";ExpAPIXml.kEleAxisOpExprIsLocked="lockenabled";ExpAPIXml.kEleAxisOpExprIsLockable="islockable";ExpAPIXml.kEleAxisOpExprSorttype="sorttype";ExpAPIXml.kEleAxisOpExprSorttypeDefault="recordorder";ExpAPIXml.kEleAxisOpExprSorttypeTop="top";ExpAPIXml.kEleAxisOpExprSorttypeBottom="bottom";ExpAPIXml.kEleAxisOpExprSortMeasure="sortmeasure";ExpAPIXml.kEleAxisOpExprSortMember="sortmembers";ExpAPIXml.kEleDefaultSortMember="defaultmember";ExpAPIXml.kEleDefaultSortMeasure="default";ExpAPIXml.kEleAxisOpExprSortProperty="sortproperty";ExpAPIXml.kEleAxisOpExprSortLabel="sortlabel";ExpAPIXml.kEleAxisOpExprFilterExpr="filterexpr";ExpAPIXml.kEleAxisOpExprCanDelete="candelete";ExpAPIXml.kEleAxisOpExprCanAscend="canascend";ExpAPIXml.kEleAxisOpExprCanDescend="candescend";ExpAPIXml.kEleAxisOpExprCanUseAsGoToParam="canuseforgotoparm";ExpAPIXml.kEleAxisOpExprCanCreateCS="cancreatecustomset";ExpAPIXml.kEleAxisOpExprIsFastModeAccurate="inaccurateinfastmode";ExpAPIXml.kEleAxisOpExprLockContext="lockcontext";ExpAPIXml.kEleViews="views";ExpAPIXml.kEleViewRef="viewRef";ExpAPIXml.kAttrFixedXtabColWidth="EstimatedColumnWidthXtabRendering";ExpAPIXml.kEleAxisOpExprV5BlockProps="v5BlockProps";ExpAPIXml.kEleAxisOpExprSegMea1CurValue="segmentedMeasure1CurVal";ExpAPIXml.kEleAxisOpExprSegMea2CurValue="segmentedMeasure2CurVal";ExpAPIXml.kEleAxisOpExprSegMea1MinValue="segmentedMeasure1Min";ExpAPIXml.kEleAxisOpExprSegMea1MaxValue="segmentedMeasure1Max";ExpAPIXml.kEleAxisOpExprSegMea2MinValue="segmentedMeasure2Min";ExpAPIXml.kEleAxisOpExprSegMea2MaxValue="segmentedMeasure2Max";ExpAPIXml.kEleAxisOpExprQuadSegments="quadrantsegments";ExpAPIXml.kEleAxisOpExprQuadSegment="quadrantsegment";ExpAPIXml.kAttrAxisOpExprSegPtr="segptr";ExpAPIXml.kAttrAxisOpExprQuadNum="quad_number";ExpAPIXml.kEleAxisOpExprSegmentRules="segmentRules";ExpAPIXml.kEleAxisOpExprSegRuleMea1="measure1";ExpAPIXml.kEleAxisOpExprSegRuleMea2="measure2";ExpAPIXml.kEleAxisOpExprSegments="segments";ExpAPIXml.kEleAxisOpExprSegment="segment";ExpAPIXml.kEleAxisOpSegId="segid";ExpAPIXml.kEleAxisOpSegCaption="caption";ExpAPIXml.kEleAxisOpSegMeaCurValue="segmentMeasureCurVal";ExpAPIXml.kEleAxisOpSegMeaMaxValue="segmentMeasureMax";ExpAPIXml.kEleAxisOpSegMeaMinValue="segmentMeasureMin";ExpAPIXml.kEleDefaultMeasure="defaultmeasure";ExpAPIXml.kEleCurrentMeasure="currentmeasure";ExpAPIXml.kEleDefault="default";ExpAPIXml.kEleCells="cells";ExpAPIXml.kEleCell="cell";ExpAPIXml.kMaxColLength="maxcollength";ExpAPIXml.kXpathExprRowEdgeLen="rowedge/len/text()";ExpAPIXml.kXpathExprColEdgeLen="coledge/len/text()";ExpAPIXml.kEleAxisData="axisdata";ExpAPIXml.kEleRowCurrentPage="currentrowpage";ExpAPIXml.kEleRowLastPage="lastrowpage";ExpAPIXml.kEleColCurrentPage="currentcolpage";ExpAPIXml.kEleColLastPage="lastcolpage";ExpAPIXml.kAttrRestrictedCellDS="restrictedDataCellDrillThrough";ExpAPIXml.kEleNode="node";ExpAPIXml.kEleData="data";ExpAPIXml.kEleIsTotal="istotal";ExpAPIXml.kEleSuppressionId="suppressionid";ExpAPIXml.kEleNoDataModeDummy="isnodatamodedummy";ExpAPIXml.kAttrDataMode="datamode";ExpAPIXml.kAttrFullDataMode="full";ExpAPIXml.kAttrFasterDataMode="fast";ExpAPIXml.kElePhantom="phantom";ExpAPIXml.kEleProperties="properties";ExpAPIXml.kEleProperty="property";ExpAPIXml.kEleBuildString="buildnumber";ExpAPIXml.kEleApiVersion="apiversion";ExpAPIXml.kEleCharttype="charttype";ExpAPIXml.kEleURL="url";ExpAPIXml.kEleArea="OAREA";ExpAPIXml.kEleShape="shape";ExpAPIXml.kEleCoords="coords";ExpAPIXml.kEleChartMeasure="MEASURE";ExpAPIXml.kEleChartMember="MEMBER";ExpAPIXml.kEleChartCaption="CAPTION";ExpAPIXml.kEleLevelUniqueName="LUN";ExpAPIXml.kEleMemberUniqueName="MUN";ExpAPIXml.kEleParentPtr="PARENT";ExpAPIXml.kEleDataItem="DATAITEM";ExpAPIXml.kEleStartIdx="startidx";ExpAPIXml.kEleScratchPad="scrathpad";ExpAPIXml.kEleIsMeasure="isMeasure";ExpAPIXml.kLegendTitle="legendTitle";ExpAPIXml.kOrdinalAxisTitle="ordinalAxisTitle";ExpAPIXml.kChartElement="chartElement";ExpAPIXml.kOrdinalAxisLabel="ordinalAxisLabel";ExpAPIXml.kChartTopLeft="TopLeft";ExpAPIXml.kChartTopRight="TopRight";ExpAPIXml.kChartBottomLeft="BottomLeft";ExpAPIXml.kChartBottomRight="BottomRight";ExpAPIXml.kEleFldObjects="folderobjects";ExpAPIXml.kEleFldObject="folderobject";ExpAPIXml.kEleFldObjtype="fldobjtype";ExpAPIXml.kEleFldDimension="dimension";ExpAPIXml.kEleFldHierarchy="hierarchy";ExpAPIXml.kEleFldMeasureDim="measuredim";ExpAPIXml.kEleFldMeasure="measure";ExpAPIXml.kEleFolder="folder";ExpAPIXml.kEleFldMeasureFolder="measurefolder";ExpAPIXml.kEleFldObjPtr="fldobjptr";ExpAPIXml.kEleRegAggregate="regularAggregate";ExpAPIXml.kEleUnsupportAggre="unsupported";ExpAPIXml.kEleUnknownAggre="unknown";ExpAPIXml.kEleNoneAggre="none";ExpAPIXml.kEleSumAggre="sum";ExpAPIXml.kEleTotalAggre="total";ExpAPIXml.kEleCountAggre="count";ExpAPIXml.kEleCountDistinctAggre="countDistinct";ExpAPIXml.kEleCountNonZeroAggre="countNonZero";ExpAPIXml.kEleRollUpType="rolluptype";ExpAPIXml.kEleRegRollUp="rollup";ExpAPIXml.kEleComputed="computed";ExpAPIXml.kModelPath="modelsearchpath";ExpAPIXml.kPackage="package";ExpAPIXml.kEleRunLocale="runLocale";ExpAPIXml.kEleDecSep="decSep";ExpAPIXml.kEleThouSep="thousSep";ExpAPIXml.kEleRowPageNumber="rowpagenum";ExpAPIXml.kEleColPageNumber="colpagenum";ExpAPIXml.kEleDescriptiveStats="descriptivestats";ExpAPIXml.kActionType="type";ExpAPIXml.kActionCreate="create";ExpAPIXml.kActionInsert="insert";ExpAPIXml.kActionAppend="append";ExpAPIXml.kActionSetDefMeasure="setdefaultmeasure";ExpAPIXml.kActionMove="move";ExpAPIXml.kActionMerge="merge";ExpAPIXml.kActionModify="modify";ExpAPIXml.kActionDelete="delete";ExpAPIXml.kActionExclude="exclude";ExpAPIXml.kActionEnable="enable";ExpAPIXml.kActionDisable="disable";ExpAPIXml.kActionReplace="replace";ExpAPIXml.kActionData="data";ExpAPIXml.kActionSave="save";ExpAPIXml.kActionLoad="load";ExpAPIXml.kActionNew="new";ExpAPIXml.kActionUndo="undo";ExpAPIXml.kActionSearch="search";ExpAPIXml.kActionSubstitute="substitutemuns";ExpAPIXml.kActionKeepSelectedMembers="keepmembers";ExpAPIXml.kActionGoToPage="gotopage";ExpAPIXml.kActionDisplayName="name";ExpAPIXml.kActionCMType="cmactiontype";ExpAPIXml.kActionCM="cmaction";ExpAPIXml.kActionGetCMFolder="getcmfolder";ExpAPIXml.kActionGetCMRoot="getcmroot";ExpAPIXml.kActionDeleteCMFolder="deletecmfolder";ExpAPIXml.kActionCreateCMFolder="createcmfolder";ExpAPIXml.kActionRenameCMFolder="renamecmfolder";ExpAPIXml.kActionRenameCMAnalysis="renamecmanalysis";ExpAPIXml.kActionDeleteCMAnalysis="deletecmanalysis";ExpAPIXml.kActionGetCMPaperSize="getpapersize";ExpAPIXml.kActionPropVals="getpropertyvalues";ExpAPIXml.kActionMemPropVals="getmemberpropvalues";ExpAPIXml.kActionGetReport="getreport";ExpAPIXml.kActionSuppress="suppress";ExpAPIXml.kActionClearAllSuppression="clearallsuppression";ExpAPIXml.kActionSwap="swap";ExpAPIXml.kActionDrill="drill";ExpAPIXml.kActionGetLineage="getmemberlineage";ExpAPIXml.kActionGetProperties="getproperties";ExpAPIXml.kActionSetProperty="setproperty";ExpAPIXml.kActionGetHLS="gethls";ExpAPIXml.kActionAddClientData="addClientData";ExpAPIXml.kSource="source";ExpAPIXml.kParameter="parameter";ExpAPIXml.kPopulationType="populationtype";ExpAPIXml.kChildrenPopulation="children";ExpAPIXml.kMemberPopulation="member";ExpAPIXml.kPosition="position";ExpAPIXml.kName="name";ExpAPIXml.kUndoState="undostate";ExpAPIXml.kCustomSet="customset";ExpAPIXml.kParamType="type";ExpAPIXml.kCalculation="calculation";ExpAPIXml.kReportCmdType="reportcmd";ExpAPIXml.kEdit="edit";ExpAPIXml.kRun="run";ExpAPIXml.kDrillType="drilltype";ExpAPIXml.kUp="up";ExpAPIXml.kDown="down";ExpAPIXml.kCurrentName="currentName";ExpAPIXml.kCurrentFolder="currentFolder";ExpAPIXml.kReportName="reportname";ExpAPIXml.kSuppressionType="suppressiontype";ExpAPIXml.eZeroSuppress="zero";ExpAPIXml.eNullSuppress="null";ExpAPIXml.eNullAndZeroSuppress="nullandzero";ExpAPIXml.kSuppressionEnabled="suppressionenabled";ExpAPIXml.kFLSortTop="top";ExpAPIXml.kFLSortBottom="bottom";ExpAPIXml.kPlusFunc="plus";ExpAPIXml.kMinusFunc="minus";ExpAPIXml.kProdFunc="times";ExpAPIXml.kDividFunc="divide";ExpAPIXml.kPowerFunc="power";ExpAPIXml.kAbsFunc="abs";ExpAPIXml.kRoundFunc="round";ExpAPIXml.kRoundDownFunc="rounddown";ExpAPIXml.kCentroidFunc="centroid";ExpAPIXml.kSquareRootFunc="sqrt";ExpAPIXml.kPercentFunc="percentage";ExpAPIXml.kPcntOfTotalFunc="percentoftotal";ExpAPIXml.kPcntOfDiffFunc="percentdiff";ExpAPIXml.kSumFunc="sum";ExpAPIXml.kDiffFunc="diff";ExpAPIXml.kAvgFunc="avg";ExpAPIXml.kVarFunc="var";ExpAPIXml.kStddevFunc="stddev";ExpAPIXml.kMedianFunc="median";ExpAPIXml.kMinFunc="min";ExpAPIXml.kMaxFunc="max";ExpAPIXml.kCountFunc="count";ExpAPIXml.kRollUpFunc="rollup";ExpAPIXml.kSingleItemFunc="none";ExpAPIXml.kRankFunc="rank";ExpAPIXml.kPercentileFunc="percentile";ExpAPIXml.kQuartileFunc="quartile";ExpAPIXml.kQuantile="quantile";ExpAPIXml.kIncludedSegment="included";ExpAPIXml.kVisibleSegment="visible";ExpAPIXml.kAllSegment="all";ExpAPIXml.kIndividualMemSegment="individualmember";ExpAPIXml.kLowestOrdiDirection="lowest";ExpAPIXml.kHighestOrdiDirection="highest";ExpAPIXml.kDefaultOrdiDirection='default';ExpAPIXml.kNumberOperands="number";ExpAPIXml.kQuantNum="quantum";ExpAPIXml.kOrdinalDirection="ordinaldirection";ExpAPIXml.kSegmentFunc="segment";ExpAPIXml.kSegmentSumFunc="segmentsum";ExpAPIXml.kEleChartIs3D="is3D";ExpAPIXml.kEleChartShowAsPercent="showaspercent";ExpAPIXml.kEleChartShowValues="showvalues";ExpAPIXml.kEleChartOptions="chartoptions";ExpAPIXml.kEleOChart="OCHART";ExpAPIXml.kEleChartWidth="chart_width";ExpAPIXml.kEleChartHeight="chart_height";ExpAPIXml.kEleChartTransparency="chartEnableTransparencyIE";ExpAPIXml.kEleChartIsStacked="stacked";ExpAPIXml.kEleChartIsStacked100Percent="stacked100Percent";ExpAPIXml.eChartTypeBar="bar";ExpAPIXml.eChartTypeColumn="column";ExpAPIXml.eChartTypePie="pie";ExpAPIXml.eChartTypePareto="pareto";ExpAPIXml.eChartTypeLine="line";ExpAPIXml.eChartTypeArea="area";ExpAPIXml.eChartTypeColumnLine="columnline";ExpAPIXml.eChartTypeScatter="scatter";ExpAPIXml.eChartTypePolar="polar";ExpAPIXml.eChartTypePoint="point";ExpAPIXml.eChartTypeRadar="radar";ExpAPIXml.eChartType3DBar="threeDBar";ExpAPIXml.eChartType3DArea="threeDArea";ExpAPIXml.eChartType3DLine="threeDLine";ExpAPIXml.eChartOptionsBar="barchartoptions";ExpAPIXml.eChartOptionsColumn="columnchartoptions";ExpAPIXml.eChartOptionsPie="piechartoptions";ExpAPIXml.eChartOptionsPareto="paretochartoptions";ExpAPIXml.eChartOptionsLine="linechartoptions";ExpAPIXml.eChartOptionsArea="areachartoptions";ExpAPIXml.eChartOptionsColumnLine="columnlinechartoptions";ExpAPIXml.eChartOptionsScatter="scatterchartoptions";ExpAPIXml.eChartOptionsPolar="polarchartoptions";ExpAPIXml.eChartOptionsPoint="pointchartoptions";ExpAPIXml.eChartOptionsRadar="radarchartoptions";ExpAPIXml.eChartOptions3DBar="threedbarchartoptions";ExpAPIXml.eChartOptions3DArea="threedareachartoptions";ExpAPIXml.eChartOptions3DLine="threedlinechartoptions";ExpAPIXml.kAxisExprChildren="children";ExpAPIXml.kAxisExprMemberset="member";ExpAPIXml.kAxisExprLevelMembers="levelmembers";ExpAPIXml.kAxisExprMeasure="measure";ExpAPIXml.kAxisExprMeasureChildren="measurechildren";ExpAPIXml.kAxisExprDescendants="descendantsatdepth";ExpAPIXml.kAxisExprNested="nested";ExpAPIXml.kAxisExprNamedSet="namedset";ExpAPIXml.kAxisExprV5="v5";ExpAPIXml.kAxisExprSegmtQuadrant="segmentbyquadrant";ExpAPIXml.kAxisOpUnion="union";ExpAPIXml.kAxisOpXjoin="xjoin";ExpAPIXml.kAxisOpNest="nest";ExpAPIXml.kTrue="true";ExpAPIXml.kFalse="false";ExpAPIXml.kOK="OK";ExpAPIXml.kLimited="limited";ExpAPIXml.kRestricted="restricted";ExpAPIXml.kStatusOK="OK";ExpAPIXml.kStatusFail="FAIL";ExpAPIXml.kStatusStaleCell="STALE_CELL";ExpAPIXml.kStatusPrompt="PROMPT";ExpAPIXml.kStatusWorking="working";ExpAPIXml.kStatusStillWorking="stillWorking";ExpAPIXml.kBlock="block";ExpAPIXml.kAxis="axis";ExpAPIXml.kInsertType="inserttype";ExpAPIXml.kDepth="depth";ExpAPIXml.kLevel="level";ExpAPIXml.kMemberTypeInherit="inherit";ExpAPIXml.kFLDimConstrain="dimensionconstrain";ExpAPIXml.kFLComplex="complex";ExpAPIXml.kPortrait="portrait";ExpAPIXml.kLandscape="landscape";ExpAPIXml.kDefaultPaper="default";ExpAPIXml.kLetterPaper="letter";ExpAPIXml.kLegalPaper="legal";ExpAPIXml.k11x17Paper="11x17";ExpAPIXml.kA3Paper="a3";ExpAPIXml.kA4Paper="a4";ExpAPIXml.kB4JISPaper="b4jis";ExpAPIXml.kB5JISPaper="b5jis";ExpAPIXml.kDefaultTemplate="defaultReportTemplate";ExpAPIXml.kReportTemplate="customReportTemplate";ExpAPIXml.kOutputPurpose="outputpurpose";ExpAPIXml.kPrintPurpose="print";ExpAPIXml.kDrillPurpose="drill";ExpAPIXml.kDisplayBreadcrumb="displaybreadcrumb";ExpAPIXml.kFiltersAtTop="begin";ExpAPIXml.kFiltersAtBottom="end";ExpAPIXml.eFilterTypeOr="or";ExpAPIXml.eFilterTypeAnd="and";ExpAPIXml.eSuppressNone=1;ExpAPIXml.eSuppressRows=2;ExpAPIXml.eSuppressCols=3;ExpAPIXml.eSuppressBoth=4;ExpAPIXml.kShowSubtotalsOnly="visible";ExpAPIXml.eCalcRemainder="remainder";ExpAPIXml.eCalcSubtotalVisibleItems="subtotal";ExpAPIXml.eCalcFLAggregate="filteraggregate";ExpAPIXml.eCalcPassedFLAggregate="passedfilteraggregate";ExpAPIXml.eCalcSummary="summary";ExpAPIXml.eCalcTypeCustom="custom";ExpAPIXml.eCalcTypeSpecial="special";ExpAPIXml.eMember="member";ExpAPIXml.eChildren="children";ExpAPIXml.eDescendants="descendants";ExpAPIXml.eLevelMembers="levelmembers";ExpAPIXml.eParents="parents";ExpAPIXml.eRoot="root";ExpAPIXml.eFolder="folder";ExpAPIXml.eMeasureFolder="measurefolder";ExpAPIXml.eDim="dim";ExpAPIXml.eHierarchy="hierarchy";ExpAPIXml.eMeasureRoot="measureroot";ExpAPIXml.eMeasure="measure";ExpAPIXml.eData="data";ExpAPIXml.eSearch="search";ExpAPIXml.eDimRoot="dimroot";ExpAPIXml.eCustomSets="customsets";ExpAPIXml.eCustomSet="customset";ExpAPIXml.eNamedSets="namedsets";ExpAPIXml.eNamedSet="namedset";ExpAPIXml.eNamedSetFolderObj="namedsetfolderobj";ExpAPIXml.eInsertableObjects="insertableobjects";ExpAPIXml.eMore="more";ExpAPIXml.eOther="other";ExpAPIXml.eAnalysisLib="analysislib";ExpAPIXml.eOtherAnalysis="otheranalysis";ExpAPIXml.eNamespace="namespace";ExpAPIXml.kCMPath="searchPath";ExpAPIXml.kAttrCMFolderType="fldType";ExpAPIXml.eCMRootBase="rootbase";ExpAPIXml.eCMRootPublicFolder="publicfld";ExpAPIXml.eCMRootMyFolder="myfld";ExpAPIXml.eCMFMPackage="packagefld";ExpAPIXml.eCMMetricPackage="metricpackagefld";ExpAPIXml.eCMContributorPackage="contributorpackagefld";ExpAPIXml.eCMRegularFolder="regularfld";ExpAPIXml.eCMAnalysis="analysis";ExpAPIXml.eCMReportTemplate="reportTemplate";ExpAPIXml.eLoadingNode="loading";ExpAPIXml.kAttrSessionFld="session";ExpAPIXml.eUpdateOptReplace="replace";ExpAPIXml.eUpdateOptFail="fail";ExpAPIXml.eSubsetTypeInteger="integer";ExpAPIXml.eSubsetTypePercentage="percentage";ExpAPIXml.eSubsetTypeSum="sum";ExpAPIXml.eSubsetTypeSubsVar="substitutionvariable";ExpAPIXml.kUUID="uuid:";ExpAPIXml.kMUN="mun:";ExpAPIXml.rUnknown=1;ExpAPIXml.defaultMaxChildNum=10;ExpAPIXml.defaultMaxRetrievedNum=50;ExpAPIXml.maxBlockSize=20;ExpAPIXml.originDefBlockSize=12;ExpAPIXml.kActionDrillUp="drillup";ExpAPIXml.kActionDrillDown="drilldown";ExpAPIXml.kActionDrillThrough="drillthrough";ExpAPIXml.kContain="contains";ExpAPIXml.kBeginWith="beginswith";ExpAPIXml.kEndWith="endswith";ExpAPIXml.kMatch="match";ExpAPIXml.kNotContain="not_contains";ExpAPIXml.kNotBeginWith="not_beginswith";ExpAPIXml.kNotEndWith="not_endswith";ExpAPIXml.kNotMatch="not_match";ExpAPIXml.kCaseInSensitive="caseinsensitive";ExpAPIXml.kEleSearchExpr="expression";ExpAPIXml.kEleSearchConstraint="constraint";ExpAPIXml.kSearch="search";ExpAPIXml.kDefineMemSet="definememberset";ExpAPIXml.kEleSearchResultId="searchresultid";ExpAPIXml.kEleSearchType="searchtype";ExpAPIXml.kDataTypeInt="integer";ExpAPIXml.kDataTypeFloat="float";ExpAPIXml.kDataTypeString="string";ExpAxisObjType.None="none";ExpAxisObjType.Member="member";ExpAxisObjType.Calc="calc";ExpAxisObjType.TempCalc="tempcalc";ExpAxisObjType.Measure="measure";ExpAxisObjType.PropMember="propertymember";ExpUserSelection.Uniary="uniary";ExpUserSelection.UniaryFactor="uniaryfactor";ExpUserSelection.UniaryScope="uniaryscope";ExpUserSelection.UniaryScopeFactor="uniaryscopefactor";ExpUserSelection.Binary="binary";ExpUserSelection.N_ary="n-ary";ExpUserSelection.MemberUnit="member";ExpUserSelection.BlockUnit="block";ExpUserSelection.Operands="operands";ExpUserSelection.Operator="operator";ExpAPIXml.kEleMissing="missing";ExpAPIXml.kEleMuns="muns";ExpAPIXml.kAttrMissing="missing";ExpAPIXml.kAttrType="type";ExpAPIXml.kAttrReplacement="replacement";ExpAPIXml.kAttrInaccessibleError="inaccessibleErrors";ExpAPIXml.kAttrInvalideError="invalidErrors";ExpAPIXml.kChildAtDepth="descendantsAtDepth";ExpMiscStr.kVersion="0.2";ExpMiscStr.kProductName="IBM Cognos Analysis Studio";ExpMiscStr.kProductLongName="IBM Cognos Analysis Studio";ExpMiscStr.kProductLicense="Licensed Materials - Property of IBM Corp.";ExpMiscStr.kProductCopyright="(c) Copyright IBM Corporation and its licensors 2005, 2010. All Rights Reserved. IBM, IBM logo, ibm.com and Cognos are trademarks or registered trademarks of International Business Machines Corp., registered in many jurisdictions worldwide. Other product and service names might be trademarks of IBM or other companies. A current list of IBM trademarks is available on the Web at www.ibm.com/legal/copytrade.shtml. Java and all Java-based trademarks are trademarks of Sun Microsystems, Inc. in the United States, other countries, or both. This Program is licensed under the terms of the license agreement accompanying the Program. This license agreement may be either located in a Program directory folder or library identified as \"License\" or \"Non_IBM_License\", if applicable, or provided as a printed license agreement. Please read the agreement carefully before using the Program. By using the Program you agree to these terms.";ExpAPIXml.kPlugin="plugin";ExpAPIXml.kCommands="commands";ExpAPIXml.kCommand="command";ExpAPIXml.kStatsLabel="label";ExpAPIXml.kStatsIndex="index";ExpAPIXml.kEleStringTable="stringTable";ExpAPIXml.kEleComponent="component";ExpAPIXml.kEleSection="section";ExpAPIXml.kEleString="string";ExpAPIXml.kEleParam="param";ExpAPIXml.kMessages="Messages";ExpAPIXml.kAttrErrorCode="errorCode";ExpAPIXml.kAttrIndex="index";ExpAPIXml.kActionExpandMember="expandsinglemember";ExpAPIXml.kActionCollapseMember="collapsesinglemember";ExpAPIXml.kEleExpandedMemList="expandedmemberlist";ExpAPIXml.kAttrMemberPtr="memberptr";ExpAPIXml.kAttrExpandedSet="expandedset";ExpAPIXml.kAttrExpanded="expanded";ExpAPIXml.kAttrIndentViewEnabled="indentedviewenabled";ExpAPIXml.kEleCalculatedFilter="calculatedFilter";ExpAPIXml.kAttUseTootip="useTooltip";DMConstants.iMaxCellBlocks=999;DefaultConstants.kDefMeasure="0";DefaultConstants.kDefScope="0";DefaultAnalysis.kBlank="false";DefaultAnalysis.kServerDefault="serverdefaultview";CookieConstants.kShowWelcomeDlg="showwelcomedialog";CookieConstants.kValueSplitter="|";CookieConstants.kDefaultAnalysis="defaultanalysis";ExpAPIXml.kEleWidthData="widthData";ExpAPIXml.kEleRowEdge="rowEdge";ExpAPIXml.kEleColEdge="colEdge";ExpAPIXml.kEleColWidth="columnWidth";ExpAPIXml.kEleWidth="width";ExpAPIXml.kEleEdgeTuple="edgeTuple";HelpConstants.kBaseFile="ug_cr_pps_a";HelpConstants.kMainEntry="id_pps_ui_window";HelpConstants.kSearchLink="dlg_id_ans_srch_dt";HelpConstants.kSetMaxLink="dlg_id_ans_set_max_data_tree";HelpConstants.kOpenAnsLink="dlg_id_ans_open_existing";HelpConstants.kSaveAnsLink="dlg_id_ans_save";HelpConstants.kCustomRankLink="dlg_id_ans_custom_rank";HelpConstants.kCustomSortLink="dlg_id_ans_custom_sort";HelpConstants.kTopBottomLink="dlg_id_ans_top_bottom";HelpConstants.kUserDefFilterLink="dlg_id_ans_ud_filter";HelpConstants.kCombineFiltersLink="dlg_id_ans_cmbne_filters";HelpConstants.kCustomSetLink="dlg_id_ans_sv_cstm_st";HelpConstants.kUserDefCalcLink="dlg_id_ans_ud_calculation";HelpConstants.kReportOptionsLink="dlg_id_ans_set_report_options";HelpConstants.kMainHelp="id_pps_ui_window";HelpConstants.kSetBasedCalcLink="dlg_id_ans_summarize";HelpConstants.kAutoSubtotalsLink="dlg_id_ans_show_subtotals";HelpConstants.kSetDefBlockSizeLink="dlg_dlg_id_ans_specify_details";HelpConstants.kDefaultAnalysisLink="dlg_id_ans_specify_package";HelpConstants.kDataFormatLink="id_ovrde_char";HelpConstants.kCustomSuppressLink="dlgCustomSuppress";HelpConstants.kQuickTour="pstour";HelpConstants.kContents="ug_cr_pps_a";ExpEvent.kCDLDataManager_DataMatrixCreate=0;ExpEvent.kCDLDataManager_CurrentWSFSChange=1;ExpEvent.kCDLDataManager_ChartRefresh=2;ExpEvent.kCDLDataManager_AnalysisCreate=3;ExpEvent.kCDLDataManager_UpdateViews=4;ExpEvent.kCDLDataManager_MissingDataCreate=5;ExpEvent.kCDLDataManager_MissingDataDelete=6;ExpEvent.kCDLDataManager_UpdateTree=7;ExpEvent.kCDLDataManager_CapabilitiesUpdated=8;ExpEvent.kCDLDataMatrix_FullRefresh=10;ExpEvent.kCDLDataMatrix_AxisCreation=11;ExpEvent.kCDLWorksheet_FullRefresh=20;ExpEvent.kCDLWorksheet_FSFullRefresh=21;ExpEvent.kCDLWorksheet_ChartRefresh=22;ExpEvent.kCDLWorksheet_AwaitingResponse=25;ExpEvent.kCDLWorksheet_ProcessingResponse=26;ExpEvent.kCDLWorksheet_FailedResponse=27;ExpEvent.kCDLWorksheet_EndProcessing=28;ExpEvent.kDLFilterSet_FullRefresh=30;ExpEvent.kCDLMember_Merge=40;ExpEvent.kCDLMember_Merge_NoResponse=41;ExpEvent.kCDLMetadata_Replace=50;ExpEvent.kCDLMetadata_FullLineage=51;ExpEvent.kCDLMetadata_WaitLineage=52;ExpEvent.kCDLMetadata_Merge_Properties=53;ExpEvent.kCDLCustomSet_Deleted=60;ExpEvent.kCDLCustomSet_Modified=61;ExpEvent.kCDLCMFolder_Replace=70;ExpEvent.kCDLCMFolder_FailedResponse=71;ExpEvent.kTreeCDLCMFolder_Replace=73;ExpEvent.kTreeCDLCMFolder_FailedResponse=74;ExpEvent.kCDLCMAnalysis_GetRoutingServerGroupDone=75;ExpEvent.kCDLAnalysis_Replace=80;ExpEvent.kCDLCrosstab_Create=90;ExpEvent.kCUIWorksheet_Unload=101;ExpEvent.kCUIWorksheet_Busy=102;ExpEvent.kCUIWorksheet_Free=103;ExpEvent.kCUIWorksheet_WindowResize=104;ExpEvent.kCUIWorksheet_NoAxisSel=105;ExpEvent.kCUIWorksheet_MultiAxisSel=106;ExpEvent.kCUIWorksheet_ChangedAxisSel=107;ExpEvent.kCUIWorksheet_ChangedBlockSel=108;ExpEvent.kCUICrosstab_DrawComplete=151;ExpEvent.kCUICrosstab_DrawStoppable=152;ExpEvent.kCUICrosstab_ColResize=153;ExpEvent.kCUIScrollControl_HScroll=200;ExpEvent.kCUIScrollControl_VScroll=201;ExpEvent.kCUIArrowOnlyScrollControl_Scroll=210;ExpEvent.kCContextMenu_Hide=220;ExpEvent.kCUIPaneSplitter_Move=230;ExpEvent.kCUIManager_Unload=240;ExpEvent.kCUIManager_OnSelChange=241;ExpEvent.kCUIManager_OnWSHeightChange=242;ExpEvent.kCUIManager_OnWindowResize=243;ExpEvent.kCUIManager_OnMissingPaneHeightChange=245;ExpEvent.kCUITreeView_Unload=250;ExpEvent.kCUIMetadataTree_Unload=260;ExpEvent.kCUIMetadataTree_SelChange=261;ExpEvent.kCUIContextMenu_Unload=270;ExpEvent.kCUIContextBar_DrawComplete=280;ExpEvent.kCDLSearchResult_Replace=290;ExpEvent.kCDLSearchResult_NoResponse=291;ExpEvent.kCDLSearchResult_Release=292;ExpEvent.kCDLSearchResult_FailedResponse=293;ExpEvent.kCDLSearchResult_WaitingResp=294;ExpEvent.kCDLSearchResult_Cancellable=295;ExpEvent.kCUIDialogMgr_ShowDialog=300;ExpEvent.kCUIDialogMgr_HideDialog=301;ExpEvent.kCUIListCtrl_OnItemClick=350;ExpEvent.kCUIListCtrl_OnItemDblClick=351;ExpEvent.kCUIListCtrl_OnKeyDown=352;ExpEvent.kCUIListCtrl_OnSelChange=353;ExpEvent.kCUIListCtrl_OnExternalDataDrop=354;ExpEvent.kCUIComboBox_OnSelChange=370;ExpEvent.kCUIComboBox_OnSelection=371;ExpEvent.kCUIComboBox_OnBlurTextBox=372;ExpEvent.kCUICMRoot_Update=389;ExpEvent.kCUICMFolderTree_Update=390;ExpEvent.kCDLWorksheet_SaveSuccess=400;ExpEvent.kCDLWorksheet_NewSuccess=401;ExpEvent.kCDLWorksheet_LoadSuccess=402;ExpEvent.kCDLWorksheet_NameChange=403;ExpEvent.kCDLWorksheet_SaveForEditSuccess=404;ExpEvent.kCDLWorksheet_SaveContinue=405;ExpEvent.kCDLWorksheet_SaveUpdateContinue=406;ExpEvent.kCUISearchDlg_StateChange=420;ExpEvent.kUserSelection_BlockChange=500;ExpEvent.kUserSelection_Clear=501;ExpEvent.kUserSelection_MemberChange=502;ExpEvent.kCUISaveCustomSetDlg_OnOK=530;ExpEvent.kCUIBlockPropertiesPane_ToggleDisplay=550;ExpEvent.kCOTPropsLoadingMgr_Merge_Complete=560;function ExpAPIXml(){};function ExpMiscStr(){};function ExpEvent(){};function ExpAxisObjType(){};function ExpUserSelection(){};function DMConstants(){};function HelpConstants(){};function DefaultConstants(){};function DefaultAnalysis(){};function CookieConstants(){};var _t=new Object();_t["1"]="{0}";_t["2"]="{1}";_t["3"]="{2}";_t["4"]="{3}";_t["5"]="{4}";_t["6"]="{5}";_t["7"]="{6}";_t["8"]="{7}";_t["9"]="{8}";_t["10"]="{9}";function COTResource(_JK){this._pp=new Object();this._oF=new Object();this._wo=new Object();this._oF['MES_SERVER_ERROR']='A server error has occurred. The action could not be completed.';this._oF['MES_CLIENT_ERROR']='An unexpected error occurred. If the problem continues, undo your action or close and re-open your Web browser window.';this._oF['MES_XMLHTTP_ERROR']=ExpMiscStr.kProductName+" requires XML HTTP Request to be enabled. XML HTTP Request can be enabled through the browser's Manage Add-ons dialog accessed from the Tools menu.";this._oF['IDS_BUTTON_OK']='OK';this._oF['IDS_BUTTON_CANCEL']='Cancel';this._oF['MES_UNSUPPORTED_SERVER_VERSION']='The server and client versions do not correspond. Please try clearing your browser cache. If that fails, contact your administrator.';this._oF['MES_UNSUPPORTED_BROWSER']='Your browser is not supported. Please use Internet Explorer 6.0 or higher.';this._oF['MES_MISSING_RESOURCE_FILE']='Unable to run Analysis Studio in the Product Language that has been set. \n Press OK to continue with English, or "Cancel" to exit.';};COTResource.prototype.ProcessStrings=function(_Se,_JD,_R6){Debug.Assert(_JD.nodeName==ExpAPIXml.kEleStringTable);Debug.Assert(_Se.nodeName==ExpAPIXml.kEleStringTable);var _ab4=Dom.GetElementsByTagName(_JD,ExpAPIXml.kEleComponent);var _3m=Dom.GetElementsByTagName(_Se,ExpAPIXml.kEleComponent);for(var i=0;i<_ab4.length;i++){var _aan=_ab4[i].getAttribute(ExpAPIXml.kEleName);var _aaY=Dom.GetElementsByTagName(_ab4[i],ExpAPIXml.kEleSection);var _axK=Dom.GetElementsByTagName(_3m[i],ExpAPIXml.kEleSection);for(var j=0;j<_aaY.length;j++){var _aCB=_aaY[j];var _68=_axK[j];var _adF=false;if(_aCB.getAttribute(ExpAPIXml.kAttrObjType)==ExpAPIXml.kMessages){_adF=true;}this.setStringResources(_68,_aCB,_aan,_adF,_R6);}}};COTResource.prototype.setStringResources=function(_ED,_Wd,_Wc,_L4,_R6){var _aq2=_Wd.getAttribute(ExpAPIXml.kName);var _avo=Dom.GetElementsByTagName(_ED,ExpAPIXml.kEleString);var _aps=Dom.GetElementsByTagName(_Wd,ExpAPIXml.kEleString);for(var i=0;i<_aps.length;i++){var _aAl=_avo[i];var _aDK=_aps[i];var _Vj=_aq2+"_"+_aAl.getAttribute(ExpAPIXml.kName);var _F3="";if(_L4){_F3=_Wc;_F3+="-";_F3+=_aq2;_F3+="-";_F3+=_aAl.getAttribute(ExpAPIXml.kAttrErrorCode);_F3+=" ";}var _aEY=_aDK;var _58=false;if(_aAl.getAttribute("whiteSpace")&&_aAl.getAttribute("whiteSpace")=="preserve"){_aEY=_aAl;_58=true;}for(var j=0;j<_aEY.childNodes.length;j++){var _Eq=_aEY.childNodes[j];if(_Eq.nodeType==_c.NODE_TEXT){_F3+=_c.CleanupCRLF(_Eq.nodeValue);}else if(_Eq.nodeName==ExpAPIXml.kEleParam){var _avP=_t[_Eq.getAttribute(ExpAPIXml.kAttrIndex)];Debug.Assert(_avP);_F3+=_avP;}}if(_R6){this._wo[_Vj]=_F3;}else{this._pp[_Vj]=_F3;}}};COTResource.prototype.GetString=function(_Ed){if(this._pp[_Ed]){return this._pp[_Ed];}else{if(this._wo[_Ed]){return this._wo[_Ed];}else if(this._oF[_Ed]){return this._oF[_Ed];}else{return(_Ed);}}};COTResource.prototype.GetErrorCode=function(_Ed){var _agU=this.GetString(_Ed);var _WH=_agU.indexOf(" ");Debug.Assert(_WH!=-1);if(_WH>=0){return _agU.substring(0,_WH-1);}return "";};COTResource.prototype.GetErrorMessage=function(_Ed){var _agU=this.GetString(_Ed);var _WH=_agU.indexOf(" ");Debug.Assert(_WH!=-1);if(_WH>=0){return _agU.substring(_WH+1,_agU.length-1);}return "";};COTResource.prototype.GetParameterForReplace=function(_Kg){var _aHt=_Kg-1;return new RegExp("\\{"+_aHt+"\\}","g");};COTResource.prototype.GetParameter=function(_Kg){return "{"+(_Kg-1)+"}";};COTResource.prototype.ReplaceParam=function(_Hq,_Kg,_Gl){var _ac0=this.GetString(_Hq);return _ac0.replace(this.GetParameterForReplace(_Kg),_Gl);};COTResource.prototype.ReplaceParamList=function(_Hq,_C4){var _aHB=_C4[0];for(var i=0;i<_C4.length-1;i++){_aHB=this.ReplaceParam(_Hq,1,_aHB);_aHB=this.ReplaceParam(_aHB,2,_C4[i+1]);}return _aHB;};COTResource.prototype.ParseStringForParamOrder=function(_N4,_Lj){var _Nw=new Array();for(var i=0;i<_Lj;i++){_Nw.push(this.GetParameter(i+1));}return this.ParseStringForOrder(_N4,_Nw);};COTResource.prototype.ParseStringForOrder=function(_N4,_Nw){var _Xo=new String(this.GetString(_N4));var _alq=new Array();for(var i=0;i<_Nw.length;i++){var _ahQ=_Xo.indexOf(this.GetString(_Nw[i]));if(_ahQ>=0){_alq[_ahQ]=new COTStringPart(_Nw[i],_ahQ,this.GetString(_Nw[i]).length);}}var _aCD=-1;for(i=0;i<_alq.length;i++){if(_alq[i]){if(_aCD==-1){_alq[i].sBefore=_Xo.slice(0,i);}else{_alq[i].sBefore=_Xo.slice(_aCD+_alq[_aCD]._iI,i);}if(i==_alq.length-1){_alq[i].sAfter=_Xo.slice(parseInt(i)+_alq[i]._iI);}_aCD=parseInt(i);}}Debug.Assert(_alq.length>0,"Could not parse string. Make sure you've rebuilt the string file");return _alq;};function COTStringPart(_JO,_Dl,_On){this.sElement=_JO;this.sBefore="";this.sAfter="";this._g3=_Dl;this._iI=_On;};CUIManager.kiSpaceBtwComponents=5;CUIManager.kiSmallSpaceBtwComponents=2;CUIManager.kiRightWindowMargin=3;CUIManager.kiLeftWindowMargin=3;CUIManager.kiTopWindowMargin=3;CUIManager.kiBottomWindowMargin=6;CUIManager.kiScrollbarWidth=30;function CUIManager(_N0,_VP){this.appobj=_N0;this.dataManager=_VP;this._jf=null;this._aE=new Array();this._qi=null;this.oContextBar=null;this._fQ=null;this.oUIDataMatrix=null;this.oLeftPaneMenu=null;this._fM=null;this.oDialogMgr=new CUIDialogMgr(this);this._mc=false;this._or=null;this._tx=false;this._v5=false;window.oUIManager=this;window.onunload=CUIManager.SafeHandleUnload;window.onbeforeunload=CUIManager.SafeHandleOnBeforeUnload;window.onresize=CUIManager.SafeHandleResize;if(!Debug||!Debug._sj){window.onerror=CUIManager.SafeHandleError;}CUIManager.BindKeyDownEventToBody(CUIManager.SafeHandleKeyDown);document.body.onmousedown=CUIManager.SafeHandleMouseDown;document.body.onhelp=CUIManager.SafeOnHelp;document.body.oncontextmenu=Dom.SafePreventDefault;document.body.ondrag=Dom.SafePreventDefault;this._e6=new Array();this._e6[ExpEvent.kCUIManager_Unload]=new Array();this._e6[ExpEvent.kCUIManager_OnSelChange]=new Array();this._e6[ExpEvent.kCUIManager_OnWSHeightChange]=new Array();this._e6[ExpEvent.kCUIManager_OnWindowResize]=new Array();this._e6[ExpEvent.kCUIManager_OnMissingPaneHeightChange]=new Array();this._kO=new Array();var _1f=document.createElement("IMG");_1f.src=Utilities.IMG_PATH+"pointer_drag_invalid.gif";_1f.id="id_no_drop_cursor";_1f.style.visibility="hidden";_1f.style.position="absolute";document.body.appendChild(_1f);var _abo=document.createElement("IMG");_abo.src=Utilities.IMG_PATH+"blank.gif";_abo.id="id_copy_cursor";_abo.style.visibility="hidden";_abo.style.position="absolute";document.body.appendChild(_abo);var _0v=document.createElement("IMG");_0v.src=Utilities.IMG_PATH+"blank.gif";_0v.id="id_move_cursor";_0v.style.visibility="hidden";_0v.style.position="absolute";document.body.appendChild(_0v);var _70=document.createElement("IMG");_70.src=Utilities.IMG_PATH+"action_drill_up.gif";_70.id="id_"+ExpAPIXml.kActionDrillUp;_70.style.visibility="hidden";_70.style.position="absolute";document.body.appendChild(_70);var _azG=document.createElement("IMG");_azG.src=Utilities.IMG_PATH+"action_drill_down.gif";_azG.id="id_"+ExpAPIXml.kActionDrillDown;_azG.style.visibility="hidden";_azG.style.position="absolute";document.body.appendChild(_azG);var _azR=document.createElement("IMG");_azR.src=Utilities.IMG_PATH+"tool_drillthrough.gif";_azR.id="id_"+ExpAPIXml.kActionDrillThrough;_azR.style.visibility="hidden";_azR.style.position="absolute";document.body.appendChild(_azR);Dom.DisableTextSelection(document);this._wc=false;this.dataManager.Subscribe(this,ExpEvent.kCDLDataManager_MissingDataCreate);this.dataManager.Subscribe(this,ExpEvent.kCDLDataManager_MissingDataDelete);};CUIManager.prototype.GetMetadataTree=function(){return this._qi;};CUIManager.ShowDrillImage=function(_Pv,x,y){var id="id_"+_Pv;var _azP=document.getElementById(id);Debug.Assert(_azP);if(_azP){_azP.style.visibility='visible';_azP.style.zIndex=200;_azP.style.left=x+document.documentElement.scrollLeft+15+'px';_azP.style.top=y+document.documentElement.scrollTop+'px';this._iK=_azP;}};CUIManager.BindKeyDownEventToBody=function(_Tm){if(_o.is_firefox||_o.is_netscape){if(document.addEventListener){document.addEventListener("keypress",_Tm,true);}else if(document.attachEvent){document.attachEvent("onkeypress",_Tm);}Debug.Assert("keyboard event not supported!");}document.body.onkeydown=_Tm;return;};CUIManager.HideDrillImage=function(){if(this._iK){this._iK.style.visibility='hidden';}};CUIManager.GetStartTabIndex=function(obj){if(obj instanceof CUIDialog){return 1;}else{return 100;}};CUIManager.GetLastDlgTabIndex=function(){return 99;};CUIManager.SafeHandleError=function(_Ku,_Mn,_TQ){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}Dom.PreventDefault(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIManager.skipHandleKeyDown=false;CUIManager.SafeHandleKeyDown=function(e){if(CUIManager.skipHandleKeyDown){CUIManager.skipHandleKeyDown=false;return;}/*@if(!@bering_debug)@*/try{/*@end@*/var _azd=CUIManager.ExtractKeyCode(e);if(!e)var e=window.event;if(e.keyCode==Dom.KeyCodes.Delete){window.oUIManager.DoDeleteSelections();}else if(e.keyCode==Dom.KeyCodes.Escape){if(window.oUIManager._or&&window.oUIManager._or.HandleUnselect){window.oUIManager._or.HandleUnselect();}}else if((e.keyCode==Dom.KeyCodes.F5)||(e.ctrlKey&&!e.altKey&&!e.shiftKey)){CUIManager.HandleCommonKeys(e);}else if((e.shiftKey||e.altKey)&&e.ctrlKey&&((_azd=="D".charCodeAt(0))||(_azd=="d".charCodeAt(0)))){if(window.oUIManager.appobj._bf._m0||window.oUIManager.appobj._wJ._mE){window.oUIManager.oMenuBar.ToggleDebugMenu();}}else if(e.shiftKey&&e.ctrlKey&&((_azd=="N".charCodeAt(0))||(_azd=="n".charCodeAt(0)))){if(window.oUIManager.appobj._wJ._mE){PlaybackRegressionTestResponses.PlaybackNextResponse(window.oUIManager.appobj.appname);}}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIManager.ExtractKeyCode=function(e){var ev=(window.event)?window.event:e;if(!ev||!ev.type)return false;var _ahR;if(ev.type.indexOf('key')!=-1){if(_o.is_ie5_5up||ev.type.indexOf('keypress')!=-1){_ahR=(ev.keyCode)?ev.keyCode:((ev.charCode)?ev.charCode:ev.which);}else _ahR=ev.charCode;}return _ahR;};CUIManager.HandleCommonKeys=function(e){if(e.keyCode==Dom.KeyCodes.F5){if(_o.is_firefox){CUIManager.bF5=true;return;}if(_o.is_ie5_5up){e.keyCode=0;}Dom.CancelBubble(e);if(!window.oUIManager._jf){CUIManager.bF5=true;Launch();}else if(!window.oUIManager._jf._my.IsDirty()){CUIManager.bF5=true;Launch();}else{CUIManager.bRefresh=true;CUIManager.bF5=true;}}if(e.ctrlKey&&!e.altKey&&!e.shiftKey){switch(e.keyCode){case "Z".charCodeAt(0):case "X".charCodeAt(0):case "C".charCodeAt(0):case "V".charCodeAt(0):case "A".charCodeAt(0):case Dom.KeyCodes.ArrowLeft:case Dom.KeyCodes.ArrowRight:case Dom.KeyCodes.ArrowUp:case Dom.KeyCodes.ArrowDown:case Dom.KeyCodes.Home:case Dom.KeyCodes.End:break;default:e.returnValue=false;try{e.keyCode=0;}catch(e){}Dom.CancelBubble(e);return;}}};CUIManager.CallCurrentMouseDown=function(e){if(e.type=="mousedown"&&document.body.onmousedown){document.body.onmousedown.call(document.body,e);}};CUIManager.HijackMouseDown=function(_Px,e){if(e){CUIManager.CallCurrentMouseDown(e);}document.body.onmousedown=_Px;window.onmousedown=_Px;};CUIManager.ReleaseMouseDown=function(){document.body.onmousedown=CUIManager.SafeHandleMouseDown;window.onmousedown=CUIManager.SafeHandleMouseDown;};CUIManager.HijackKeyDown=function(_LQ){CUIManager.BindKeyDownEventToBody(_LQ);CUIManager.skipHandleKeyDown=true;};CUIManager.ReleaseKeyDown=function(){if(window.oUIManager.oDialogMgr.IsModalessDialogDisplayed()||window.oUIManager.oDialogMgr.IsModalDialogDisplayed()){CUIManager.BindKeyDownEventToBody(CUIDialog.SafeHandleKeyDown);CUIManager.skipHandleKeyDown=true;}else{CUIManager.BindKeyDownEventToBody(CUIManager.SafeHandleKeyDown);CUIManager.skipHandleKeyDown=false;}};CUIManager.SafeHandleMouseDown=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}window.oUIManager.HandleMouseDown(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIManager.SafeForceTextBoxLoseFocus=function(){if(_o.is_firefox){var _Ll=document.getElementById(window.idCurrentTextBox);if(_Ll){COTInputElementFactory.SafeOnBlurTextBox(null,true);}}};CUIManager.SafeForceComboBoxHide=function(){if(_o.is_firefox){if(document.body.oComboBox){document.body.oComboBox.hideDropDown();}}};CUIManager.prototype.HandleMouseDown=function(e){CUIManager.SafeForceTextBoxLoseFocus();if(CUIManager.bRefresh){CUIManager.bRefresh=false;}var _yW=Dom.GetEventTarget(e);if(_yW==document.body||(this.oAppPane&&_yW==this.oAppPane.GetDom())){if(this._or&&this._or.HandleUnselect){this._or.HandleUnselect(e);}}};CUIManager.SafeHandleOnBeforeUnload=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(CUIManager.bF5&&_o.is_firefox){return this.oUIManager.appobj.oResources.GetString('IDS_FIREFOX_REFRESH_WARNING');}var _J2=this.oUIManager.dataManager.GetCurrentWorkSheet();if(CUIManager.bRefresh&&!CUIManager.bF5){CUIManager.bRefresh=false;}if(_J2&&_J2.IsDirty()){CUIManager.bF5=false;return this.oUIManager.appobj.oResources.GetString('IDS_EXIT_WARNING');}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIManager.SafeHandleUnload=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/this.oUIManager.HandleUnload(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIManager.prototype.HandleUnload=function(e){this.dataManager.commManager.ReleaseConnections();if(CUIManager.bRefresh){Launch();return;}this.Notify(ExpEvent.kCUIManager_Unload);window.oUIManager=null;Utilities.DeleteAllFromArray(this._kO);Utilities.DeleteAllFromArray(this._xK);Utilities.ClearObjectArray(this._e6);if(this.oAppPane){this.oAppPane.Unload();}var _GX=true;Dom.ClearRefs(document.body,_GX);_GX=false;Dom.ClearRefs(window,_GX);Utilities.RemoveAllChildObjects(this);};CUIManager.SafeHandleResize=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(window.oUIManager&&window.oUIManager._mc){if(Dom.GetWindowWidth()!=window.oUIManager.iWindowWidth||Dom.GetWindowHeight()!=window.oUIManager.iWindowHeight){window.oUIManager.HandleResize();}}else if(window.oUIManager&&window.oUIManager._v5){window.oUIManager.HandleDlgResize();}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIManager.prototype.HandleResize=function(_PZ){this.iWindowHeight=Dom.GetWindowHeight();this.iWindowWidth=Dom.GetWindowWidth();var _aiZ=false;if(_PZ!=null){this.oLeftPaneMenu.ChangeWidthBy(_PZ);_aiZ=true;}var _aIj=CUIManager.kiBottomWindowMargin;var _MS=Math.ceil(Dom.GetWindowHeight()-this._dx-_aIj);COTStyle.SetHeight(this.oAppPane.GetDom(),_MS);var _aDC=Math.ceil(Dom.GetWindowWidth()-CUIManager.kiLeftWindowMargin-CUIManager.kiRightWindowMargin);COTStyle.SetWidth(this.oAppPane.GetDom(),_aDC);this.oToolBar.SetWidth(_aDC);this.oMenuBar.SetWidth(_aDC);this.oLeftPaneMenu.HandleResize(_MS,null,_aiZ);this.oVerticalSplitter.SetLeft(this.oLeftPaneMenu.GetRightBorderPos()-2);this.oVerticalSplitter.SetHeight(_MS);var _ahK=this.oLeftPaneMenu.GetRight()+CUIManager.kiSpaceBtwComponents;var _Xt=_aDC-_ahK;this._jf.SetLeft(_ahK);this._jf.SetWidth(_Xt);this.oDialogMgr.SetLeft(_ahK);this.oDialogMgr.SetWidth(_Xt);this.oDialogMgr.HandleResize(_MS);this.oBlockPropsPane.SetLeft(_ahK);this.oBlockPropsPane.SetWidth(_Xt);this.oBlockPropsPane.HandleResize(_MS);if(this.oMissingMunsPane==null){this._jf.UpdateHeight(this.GetWorksheetBottom(),true);}else{this._jf.UpdateHeightForMissingPane();}this._jf.HandleResize();if(this.oMissingMunsPane){this.oMissingMunsPane.HandleResize();}COTStyle.SetHeight(document.body,_MS+this._dx);this.Notify(ExpEvent.kCUIManager_OnWindowResize);CUIContextMenu.HideVisibleMenu();};CUIManager.prototype.HandleDlgResize=function(_PZ){var _aIj=CUIManager.kiBottomWindowMargin;var _MS=Math.ceil(Dom.GetWindowHeight()-this._dx-_aIj);this.oDialogMgr.HandleResize(_MS);};CUIManager.prototype.GetWorksheetBottom=function(){return Math.min(this.oDialogMgr.GetTop(),this.oBlockPropsPane.GetTop())-CUIManager.kiSmallSpaceBtwComponents;};CUIManager.prototype.CreateStartupView=function(){var _aJM=Dom.GetWindowWidth()-CUIManager.kiLeftWindowMargin-CUIManager.kiRightWindowMargin;this.oMenuBar=new CUIMenuBar(this);this.oMenuBar.DrawDummyMenuBar();this.oMenuBar.SetWidth(_aJM);this.oMenuBar.SetTop(CUIManager.kiTopWindowMargin);this.oMenuBar.SetLeft(CUIManager.kiLeftWindowMargin);var _Uz=this.oMenuBar.GetBottom();this.oToolBar=new CUIToolBar(this,document.body,"main_toolbar");this.oToolBar.AddDummyButtons();this.oToolBar.Draw();this.oToolBar.SetTop(_Uz);this.oToolBar.SetLeft(CUIManager.kiLeftWindowMargin);this.oToolBar.SetWidth(_aJM);var _aGj=document.getElementById("splashText");_aGj.className="splashWorking";var _aDk=this.appobj.oResources.GetString('IDS_WORKSHEET_BUSY');_aGj.appendChild(document.createTextNode(_aDk));};CUIManager.prototype.CreateRegularView=function(){this.oMenuBar.DrawDefaultMenuBar();this.oToolBar.AddDefaultButtons();this.oToolBar.Draw();this.oBlockPropsPane.Show();this._n4.UnLoad();this._qi=this._qb;this._qi.Refresh();this._np=this._ol;this.oLeftPaneMenu.UpdateValidSelPanes(new Array(this._qi,this._np),0);this.RemoveDropDestination(this.oMissingMunsPane);this.oMissingMunsPane.Unload();this.oMissingMunsPane=null;this._jf.UpdateHeightForMissingPane();};CUIManager.prototype.CreateMissingDataView=function(){this.oMenuBar.DrawMissingDataMenuBar();this.oToolBar.AddMissingDataButtons();this.oToolBar.Draw();this.oBlockPropsPane.Hide();this._qb=this._qi;this._qb.Hide();var _86=this.oLeftPaneMenu.GetTreeParentDIV();this._n4=new CUIMissingMetadataTree(this,this.appobj.dataManager.metadata);this._n4.Init(_86);this._n4.Refresh();this._n4.InitSubscriptions();this._qi=this._n4;this._ol=this._np;this._ol.Hide();this._i8=new CUIMissingAnalysisItemTree(this,this.appobj.dataManager.metadata,this.appobj.dataManager._kX);this._i8.Init(_86);this._i8.Refresh();this._i8.InitSubscriptions();this._np=this._i8;this.oLeftPaneMenu.UpdateValidSelPanes(new Array(this._qi,this._np),0);this.oMissingMunsPane=new CUIMissingMunsPane(this,this.oAppPane.GetDom());this.oMissingMunsPane.Create();var _P6=this.oLeftPaneMenu.GetRight()+CUIManager.kiSpaceBtwComponents;this.oMissingMunsPane.SetPosition(_P6,0,'px');var _T6=this.GetWorksheetBottom()-this._dx;this.oMissingMunsPane.SetHeight(_T6,'px');if(this.dataManager._vw.IsFixable()){this.AddDropDestination(this.oMissingMunsPane);}this._jf.UpdateHeightForMissingPane();};CUIManager.SafeDoReturnToNormalUI=function(){/*@if(!@bering_debug)@*/try{/*@end@*/window.oUIManager.Notify(ExpEvent.kCDLDataManager_MissingDataDelete);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIManager.prototype.CreateDefaultView=function(_C6,_Iq){this.oUIDataMatrix=new CUIDataMatrix(this);this.dataManager.Subscribe(this.oUIDataMatrix,ExpEvent.kCDLDataManager_DataMatrixCreate);this._fM=new CUIContentManager(this);var _aJM=Dom.GetWindowWidth()-CUIManager.kiLeftWindowMargin-CUIManager.kiRightWindowMargin;this.oMenuBar.DrawDefaultMenuBar();this.oToolBar.AddDefaultButtons();this.oToolBar.Draw();var _Uz=this.oToolBar.GetBottom()+CUIManager.kiSpaceBtwComponents;this.oAppPane=new CUIPane();var _aIj=0.1*Dom.GetWindowHeight();this._dx=_Uz;this.oAppPane.Create(document.body,_aJM,Dom.GetWindowHeight()-_Uz-_aIj,"app_pane","px");this.oAppPane.SetPosition(CUIManager.kiLeftWindowMargin,_Uz,'px');COTStyle.SetWidth(this.oAppPane.GetDom(),100,'%');this.oLeftPaneMenu=new CUILeftPaneMenu(this,this.oAppPane.GetDom());var _86=this.oLeftPaneMenu.GetTreeParentDIV();this._qi=new CUIMetadataTree(this,this.appobj.dataManager.metadata);this._qi.Init(_86);this._qi.Refresh();this._np=new CUIAnalysisItemTree(this,this.appobj.dataManager.metadata,this.appobj.dataManager._kX);this._np.Init(_86);this._np.Refresh();this._np.Hide();var _90=new Array(this._qi,this._np);this.oLeftPaneMenu.CreatePropertiesPane();this.oLeftPaneMenu.SetTabControll();this.oLeftPaneMenu.UpdateValidSelPanes(_90,0);this.oVerticalSplitter=new CUIVertPaneSplitter();this.oVerticalSplitter.OnCreate(this.oAppPane,this,this.oLeftPaneMenu.GetRightBorderPos()-2,'px');for(var i=0;i<_C6.childNodes.length;i++){var obj=_C6.childNodes[i];switch(obj.nodeName){case ExpAPIXml.kEleElcid:var _C7=Dom.GetNodeText(obj);break;case ExpAPIXml.kEleLayoutWorksheets:for(var j=0;j<obj.childNodes.length;j++){var _Yt=obj.childNodes[j];var _4N;Debug.Assert(_Yt.nodeName==ExpAPIXml.kEleLayoutWorksheet);for(var l=0;l<_Yt.childNodes.length;l++){switch(_Yt.childNodes[l].nodeName){case ExpAPIXml.kEleWorksheetPtr:_4N=Dom.GetNodeText(_Yt.childNodes[l]);break;}}var _aIt=this.appobj.dataManager._wn[_4N];this._jf=new CUIWorkSheet(this,_aIt,this.oAppPane.GetDom(),_Iq);}break;case ExpAPIXml.kEleLayoutFilterSets:for(var m=0;m<obj.childNodes.length;m++){var _Yt=obj.childNodes[m];var _7F;Debug.Assert(_Yt.nodeName==ExpAPIXml.kEleLayoutFilterSet);for(var n=0;n<_Yt.childNodes.length;n++){switch(_Yt.childNodes[n].nodeName){case ExpAPIXml.kEleFilterSetPtr:_7F=Dom.GetNodeText(_Yt.childNodes[n]);break;}}}break;}}this.oMenuBar.Init();this.oDialogMgr.CreateTemplate(this.oAppPane.GetDom(),0);this.oBlockPropsPane=new CUIBlockPropertiesPane(this);this.oBlockPropsPane.Init(this.oAppPane.GetDom());this.HandleResize();this._jf.Create(this.oLeftPaneMenu.GetTopPadding(),CUIManager.kiSmallSpaceBtwComponents);this._aE.push(this._jf);this.oDialogMgr.Subscribe(this,ExpEvent.kCUIDialogMgr_ShowDialog);this.oDialogMgr.Subscribe(this,ExpEvent.kCUIDialogMgr_HideDialog);this.oBlockPropsPane.Subscribe(this,ExpEvent.kCUIBlockPropertiesPane_ToggleDisplay);this._fQ=new CUIStatus(this);this._qi.InitSubscriptions();this._np.InitSubscriptions();this._mc=true;this.appobj.setRunning();var _Ke=this.appobj.appname;if(!this._qi._ob.HasEnoughDimensionalData()){var _G3=Utilities.GenerateCallback(CUIDialogMgr.SafeHandleExit,[_Ke]);CUIDialogMgr.DisplayMessageBox(CUIMessageBox.kCritical,'MES_ERROR_NO_DIMENSIONAL_DATA',null,_G3);}else{var _6z=Utilities.GenerateCallback(this.HandleResize,[],this);setTimeout(_6z,50);}};CUIManager.prototype.GetCurrentWorkSheet=function(){return this._jf;};CUIManager.prototype.GetAppName=function(){return this.appobj.appname;};CUIManager.ShowStatusMessage=function(_Ku){window.status=_Ku;};function CUIStatus(_EE){this._i1=_EE;if(Debug.IsEnabled()){window.status="Initializing ...";var _6z=Utilities.GenerateCallback(this.Display,[],this);setTimeout(_6z,2000);}};CUIStatus.prototype.Display=function(){var status=this._i1.dataManager._uJ;if(status.GetLastStatusOK()){window.status="Server connection OK";}else{window.status="Last server connect failed. "+status.GetLastStatusMsg();}var _6z=Utilities.GenerateCallback(this.Display,[],this);setTimeout(_6z,2000);};CUIManager.prototype.IsSearching=function(){return this._tx;};CUIManager.prototype.OnCustomSetDlgClose=function(){this.oLeftPaneMenu.oTabs.SwitchTab(this._np.GetAssoTabId());};CUIManager.prototype.OnSelChange=function(_QP){this._or=_QP;this.Notify(ExpEvent.kCUIManager_OnSelChange);};CUIManager.prototype.GetSelPane=function(){return this._or;};CUIManager.prototype.DoDeleteSelections=function(){if(this._or&&this._or.CanDelete&&this._or.CanDelete()){this._or.DeleteSelectedItems();}else{this._jf.DisplayDeleteErrorMsg();}};CUIManager.prototype.CanDelete=function(){if(this._or&&this._or.DeleteSelectedItems){if(this._or.CanDelete&&this._or.CanDelete()){return true;}}return false;};CUIManager.SafeDoDeleteSelections=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager.DoDeleteSelections();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIManager.SafeDoSearch=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager.DoSearch();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIManager.prototype.DoSearch=function(){if(this._or&&this._or.GetSearchData&&this._or.GetSearchData()&&this._or!=this._qi){this._qi.DoSearchFromData(this._or.GetSearchData());}else{this._qi.DoSearchFromNode(this._qi.GetLastTreeSelection());}};CUIManager.SafeDoHelpTopic=function(_Ke,_NP){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);Debug.Assert(_Mg);if(_Mg){gotoHelp(_Mg._aB,HelpConstants.kBaseFile,_NP);}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIManager.prototype.AddDropDestination=function(obj){this._kO.push(obj);};CUIManager.prototype.RemoveDropDestination=function(obj){Utilities.DeleteFromArray(this._kO,obj);};CUIManager.prototype.AddDeleteDestination=function(el){if(!this._xK){this._xK=new Array();}this._xK.push(el);};CUIManager.prototype.RemoveDeleteDestination=function(el){for(var i=0;this._xK&&i<this._xK.length;i++){if(this._xK[i]==el){Utilities.DeleteNthFromArray(this._xK,i);}}};CUIManager.prototype.OnDragStart=function(e,_CN,_FS){if(this._jf.AllowInteraction()){for(var i=0;i<this._kO.length;i++){var _MU=this._kO[i].GetDIVObj();Debug.Assert(_MU!=null);if(Utilities.MethodInObject(this._kO[i],'SafeHandleDragOver')){_MU.onmousemove=this._kO[i].SafeHandleDragOver;}if(Utilities.MethodInObject(this._kO[i],'SetDropData')){this._kO[i].SetDropData(_CN);}if(Utilities.MethodInObject(this._kO[i],'SafeHandleDragDrop')){_MU.onmouseup=this._kO[i].SafeHandleDragDrop;_MU.oncontextmenu=CUIManager.SafeHandleDragContextMenu;}}return true;}else{return false;}};CUIManager.prototype.OnDragOver=function(e,_CN,_EW){var _3i=CUIDragDrop.eEffectNone;return _3i;};CUIManager.SafeHandleDragContextMenu=function(e){try{if(!e){var e=window.event;}Dom.CancelEvent(e);}catch(e){_f.HandleException(e);}};CUIManager.prototype.OnDragDrop=function(e){for(var i=0;i<this._kO.length;i++){var _MU=this._kO[i].GetDIVObj();if(this._kO[i].GetMouseMoveHandler){_MU.onmousemove=this._kO[i].GetMouseMoveHandler();}else{_MU.onmousemove=null;}if(_MU.onmouseup!=null){_MU.onmouseup=null;}if(this._kO[i].GetContextMenuHandler){_MU.oncontextmenu=this._kO[i].GetContextMenuHandler();}}return true;};CUIManager.prototype.UnSubscribe=function(obj,_Dy){if(this._e6&&this._e6[_Dy]){Utilities.DeleteFromArray(this._e6[_Dy],obj);}};CUIManager.prototype.Subscribe=function(obj,event){if(this._e6[event]){this._e6[event].push(obj);}else{Debug.Assert(false,"Invalid event subscription");}};CUIManager.prototype.Notify=function(event){switch(event){case ExpEvent.kCUIPaneSplitter_Move:this.HandleResize(this.oVerticalSplitter.iLastMove);break;case ExpEvent.kCUISearchDlg_StateChange:if(this.oDialogMgr._jg&&this.oDialogMgr._jg.IsSearching){this._tx=this.oDialogMgr._jg.IsSearching();}else{this._tx=false;}break;case ExpEvent.kCUIDialogMgr_ShowDialog:if(!this.oDialogMgr.IsModalDialogDisplayed()&&this.oDialogMgr._dj.length==0){this.oBlockPropsPane.DoTempHide();if(this.oMissingMunsPane){event=ExpEvent.kCUIManager_OnMissingPaneHeightChange;}else{event=ExpEvent.kCUIManager_OnWSHeightChange;}}break;case ExpEvent.kCUIDialogMgr_HideDialog:if(!this.oDialogMgr.IsModalDialogDisplayed()&&this.oDialogMgr._dj.length==0){this.oBlockPropsPane.DoEndTempHide();if(this.oMissingMunsPane){event=ExpEvent.kCUIManager_OnMissingPaneHeightChange;}else{event=ExpEvent.kCUIManager_OnWSHeightChange;}}break;case ExpEvent.kCUIBlockPropertiesPane_ToggleDisplay:event=ExpEvent.kCUIManager_OnWSHeightChange;break;case ExpEvent.kCDLDataManager_MissingDataCreate:this.CreateMissingDataView();break;case ExpEvent.kCDLDataManager_MissingDataDelete:this.CreateRegularView();break;}var _alZ=this._e6[event];for(var i=0;_alZ&&i<_alZ.length;i++){_alZ[i].Notify(event);}};CUIManager.SafeOnHelp=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}Dom.PreventDefault(e);var _Co=window.oUIManager.appobj.oResources;var _amT=HelpConstants.kMainHelp;CUIManager.SafeDoHelpTopic(window.oUIManager.appobj.appname,_amT);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIManager.prototype.ConfirmLossOfChanges=function(){if(!this._wc){var _acW=this.oBlockPropsPane.IsActive();var _amW;if(_acW){_amW=this.oBlockPropsPane.ConfirmLossOfChanges();}else{_amW=this.oDialogMgr.ConfirmLossOfChanges();}if(_amW==Utilities.eStateHold){this._wc=true;}return _amW;}return '';};CUIManager.prototype.GetDrillThroughContext=function(){var _Ow=new Array();this.GetCurrentWorkSheet().GetDrillThroughContext(_Ow);return _Ow;};CUIManager.prototype.SetSelectionContext=function(_Nu){this.GetCurrentWorkSheet().SetSelectionContext(_Nu);};CUIManager.prototype.GetDrillThroughPackage=function(){return this.dataManager.metadata.GetPackagePath();};CUIManager.prototype.GetDrillThroughModel=function(){return this.dataManager.metadata.GetModelPath();};CUIManager.prototype.GetSelectedDrillSearchContext=function(){var _Ow=new Array();this.GetCurrentWorkSheet().GetImmediateSelectedContext(_Ow);return _Ow;};CUIManager.prototype.GetGeneralDrillSearchContext=function(){var _Ow=this.GetCurrentWorkSheet().GetGeneralContext(_Ow);return _Ow;};CUIManager.prototype.GetFilterContext=function(){var _Ow=this.GetCurrentWorkSheet().GetFilterContext();return _Ow;};function CUIWorkSheet(_EE,_J2,_EP,_Iq){this._m4=_EE;this.oResources=_EE.appobj.oResources;this._my=_J2;this._r1=_EP;this._dO=null;this._sv=false;this._fb=false;this._pA=false;this._wy=false;this._rr=null;this._l9=new CUIPane();this._l9.Create(this._r1,null,null,"worksheet","px");this._st=this._l9.GetDom();this._st.id="worksheet"+Utilities.GenerateId();this._e6=new Array();this._e6[ExpEvent.kCUIWorksheet_Unload]=new Array();this._e6[ExpEvent.kCUIWorksheet_WindowResize]=new Array();this._e6[ExpEvent.kCUIWorksheet_Free]=new Array();this._e6[ExpEvent.kCUIWorksheet_Busy]=new Array();this._e6[ExpEvent.kCUIWorksheet_NoAxisSel]=new Array();this._e6[ExpEvent.kCUIWorksheet_MultiAxisSel]=new Array();this._e6[ExpEvent.kCUIWorksheet_ChangedAxisSel]=new Array();this._e6[ExpEvent.kCUIWorksheet_ChangedBlockSel]=new Array();this._my.Subscribe(this,ExpEvent.kCDLWorksheet_FullRefresh);this._my.Subscribe(this,ExpEvent.kCDLWorksheet_FSFullRefresh);this._my.Subscribe(this,ExpEvent.kCDLWorksheet_AwaitingResponse);this._my.Subscribe(this,ExpEvent.kCDLWorksheet_ProcessingResponse);this._my.Subscribe(this,ExpEvent.kCDLWorksheet_EndProcessing);this._my.Subscribe(this,ExpEvent.kCDLWorksheet_FailedResponse);this._my.Subscribe(this,ExpEvent.kCDLWorksheet_ChartRefresh);this._my.Subscribe(this,ExpEvent.kCDLWorksheet_NameChange);this._my._ak._kX.Subscribe(this,ExpEvent.kCDLAnalysis_Replace);this._m4.Subscribe(this,ExpEvent.kCUIManager_Unload);this._m4.Subscribe(this,ExpEvent.kCUIManager_OnWSHeightChange);this._my._ak.Subscribe(this,ExpEvent.kCDLDataManager_UpdateViews);this._my._ak.Subscribe(this,ExpEvent.kCDLDataManager_CapabilitiesUpdated);this.SetState(CUIWorkSheet.eStateNormal);_f.SetWorkSheet(this);this._rS=false;this._po=false;this._dO=new CUICrosstab(this,this._st,_Iq);this.oContextBar=new CUIContextBar(this);this._k3=false;this._ca=CUIWorkSheet.eLayoutXtabOnly;this._ab=true;this._pW=false;this._e2=ExpAPIXml.eChartTypeColumn;this._mc=false;this._jA=false;this._gr=false;this.UpdateTitleBar();this.descriptiveStatsInserted=false;};CUIWorkSheet.eStateNormal=1;CUIWorkSheet.eStateBusy=2;CUIWorkSheet.eStateProcessing=3;CUIWorkSheet.eStateDrawing=4;CUIWorkSheet.eStateDrawingStoppable=5;CUIWorkSheet.eLayoutXtabOnly=10;CUIWorkSheet.eLayoutXtabAndChart=11;CUIWorkSheet.eLayoutChartOnly=12;CUIWorkSheet.kDisplayCancelDelay=8000;CUIWorkSheet.kiSplitterHeight=3;CUIWorkSheet.kiTopBottomDefault1=5;CUIWorkSheet.kiTopBottomDefault2=10;CUIWorkSheet.kiTopBottomDefault3=20;CUIWorkSheet.ksTopBottomNoneId="none";CUIWorkSheet.ksTopBottomCustomId="custom";CUIWorkSheet.prototype.Create=function(_TM,_PH){this.InitStatus();this.Refresh();this._po=true;this.oContextBar.Subscribe(this,ExpEvent.kCUIContextBar_DrawComplete);this.oContextBar.Refresh(this._r1);this._m4.AddDropDestination(this.oContextBar);this._mc=true;this.SetTop(_TM,_PH);this._rS=true;this.SetState(CUIWorkSheet.eStateDrawing);this._dO.Subscribe(this,ExpEvent.kCUICrosstab_DrawComplete);this._dO.Subscribe(this,ExpEvent.kCUICrosstab_DrawStoppable);this._dO.Create(this.GetXtabHeightPixels());this.UpdateDisplay();this._m4.AddDropDestination(this._dO);this.InitDragMenus();};CUIWorkSheet.prototype.IsDescriptiveStatisticsEnabled=function(){return this._my.IsDescriptiveStatisticsEnabled();};CUIWorkSheet.prototype.IsDisplayBreadcrumbEnabled=function(){return this._my.IsDisplayBreadcrumbEnabled();};CUIWorkSheet.prototype.CheckState=function(_Uc){return(this.eState==_Uc);};CUIWorkSheet.prototype.SetState=function(_Uc){this.eState=_Uc;this._st._qc_auto_ws_state=_Uc;};CUIWorkSheet.prototype.GetXtabHeightPercent=function(){if(this._ca==CUIWorkSheet.eLayoutXtabOnly){return 1.0;}else if(this._ca==CUIWorkSheet.eLayoutXtabAndChart){return 0.45;}else{return 0.0;}};CUIWorkSheet.prototype.IsCrosstabVisible=function(){return(this._ca!=CUIWorkSheet.eLayoutChartOnly);};CUIWorkSheet.prototype.GetXtabHeightPixels=function(){return COTStyle.GetHeightFromOffset(this._st)*this.GetXtabHeightPercent();};CUIWorkSheet.prototype.GetDataWorkSheet=function(){return this._my;};CUIWorkSheet.prototype.GetUICrosstab=function(){return this._dO;};CUIWorkSheet.prototype.GetAppName=function(){return this._m4.GetAppName();};CUIWorkSheet.prototype.SetTop=function(_TM,_PH){if(_TM!=null){this._wY=_TM;this._mA=_PH;}this.oContextBar.SetTop(this._wY);var _ati=this._wY+this.oContextBar.GetHeight()+this._mA*2;this._st.style.top=_ati+'px';this.iTop=_ati;};CUIWorkSheet.kiStatusHeight=18;CUIWorkSheet.kiPageNumWidth=40;CUIWorkSheet.prototype.UpdateHeightForMissingPane=function(){if(this._m4&&this._m4.oMissingMunsPane){var _akg=document.getElementById(this._m4.oMissingMunsPane.sButtonTableId);if(_akg){this._ds=Math.ceil(Dom.GetWindowHeight()-this._m4._dx-CUIManager.kiBottomWindowMargin-COTStyle.GetDisplayHeight(_akg))-CUIManager.kiSpaceBtwComponents;}}else{this._ds=this._m4.GetWorksheetBottom();}};CUIWorkSheet.prototype.UpdateHeight=function(_Ad,_Or){if(_Ad!=null){this._ds=_Ad;}if(this._ds!=null&&this.iTop!=null){this._st.scrollTop=0;var _2v=this._ds-this.iTop-CUIWorkSheet.kiStatusHeight-CUIManager.kiSmallSpaceBtwComponents;COTStyle.SetHeight(this._st,_2v);this._fW=_2v;var _ZI=_2v+CUIManager.kiSmallSpaceBtwComponents;var _ati=this._wY+this.oContextBar.GetHeight()+this._mA*2;_ZI=_ZI+_ati;this._fr.style.top=_ZI+"px";COTStyle.SetHeight(this._fr,CUIWorkSheet.kiStatusHeight);this._iW.style.top=_ZI+"px";COTStyle.SetHeight(this._iW,CUIWorkSheet.kiStatusHeight);this._j2.style.top=_ZI+"px";COTStyle.SetHeight(this._j2,CUIWorkSheet.kiStatusHeight);this._bN.style.top=_ZI+"px";COTStyle.SetHeight(this._bN,CUIWorkSheet.kiStatusHeight);this._ha.style.top=_ZI+"px";COTStyle.SetHeight(this._ha,CUIWorkSheet.kiStatusHeight);this._oI.style.top=_ZI+"px";this._oI.style.left=this._wK+"px";COTStyle.SetHeight(this._oI,CUIWorkSheet.kiStatusHeight);var _au6=0;var _Zo=0;if(this._gg){_au6=this._gg.GetHeight();_Zo=this._gg.GetWidth()+CUIManager.kiScrollbarWidth;if(_Zo>(this._nq-CUIManager.kiScrollbarWidth)){_au6=_au6+CUIManager.kiScrollbarWidth;_Zo=this._nq-CUIManager.kiScrollbarWidth;}}if(this._ca==CUIWorkSheet.eLayoutXtabAndChart){Dom.SetVerticalOverflow(this._st,"auto");if(this._gg&&this._gg.IsInErrorState()){this._jA=false;}var _aic=this.GetXtabHeightPercent();var _6G=this._st.scrollHeight;var _arn=_au6-CUIManager.kiSpaceBtwComponents-CUIWorkSheet.kiSplitterHeight;if(this._jA){_au6=this._oh;var _CC=Math.max(_6G-_au6-CUIManager.kiSpaceBtwComponents-CUIWorkSheet.kiSplitterHeight,CUICrosstab.kiMinHeight);}else{var _apu=600;var _aE8=Math.min(_au6,_apu);_aE8=Math.max(_aE8,CUICrosstab.kiMinHeight);var _aa3=_2v-_arn-CUIManager.kiScrollbarWidth;var _CC=_aE8;if(Math.abs(_aa3-_aE8)<100){_CC=_aa3;}else if(!this._dO.HasVerticalScrollbar()&&this._dO.GetCrosstabHeight()!=0){_CC=this._dO.GetCrosstabHeight();}}this._vN=_au6;var _ahd=_au6+CUIManager.kiSpaceBtwComponents+CUIWorkSheet.kiSplitterHeight;var _aao=true;if((_ahd+_CC)<this._fW){Dom.SetVerticalOverflow(this._st,"hidden");_aao=false;}var _axB=this._nq;if(_aao){_axB=this._nq-CUIManager.kiScrollbarWidth;}else{_Zo=this._nq;}if(!this._c9){this._c9=new CUIHorizPaneSplitter();this._c9.OnCreate(this._l9,this,_au6+CUIManager.kiSmallSpaceBtwComponents,'px','resize_chart_xtab.gif');this._c9.SetParentHasScrollbar(true);}this._c9.SetWidth(_axB);this._c9.SetTop(_au6+CUIManager.kiSmallSpaceBtwComponents);this._dO.SetWidth(_axB);this._dO.SetTop(_ahd);this._dO.UpdateHeight(_CC,_Or);if(this._gg){this._gg.SetWidth(_Zo);this._gg.HandleResize(_au6);}}else if(this._ca==CUIWorkSheet.eLayoutXtabOnly){Dom.SetVerticalOverflow(this._st,"hidden");this._jA=false;this._dO.SetTop(0);this._dO.SetWidth(this._nq);this._dO.UpdateHeight(this.GetXtabHeightPixels(),_Or);if(this._c9){this._c9.Unload();this._c9=null;}}else if(this._ca==CUIWorkSheet.eLayoutChartOnly){Dom.SetVerticalOverflow(this._st,"hidden");_au6=Math.min(_au6,_2v);this._dO.DrawCrosstab();if(this._gg){this._gg.SetWidth(this._nq);this._gg.HandleResize(_au6);}if(this._c9){this._c9.Unload();this._c9=null;}}else{Debug.Assert(false);}}};CUIWorkSheet.prototype.UpdatePagingStatus=function(){var _alL=this._dO._fX;if(_alL){var _an1=document.getElementById(this._dG);if(_alL.IsSingleRowPage()){_an1.style.visibility="hidden";}else{_an1.style.visibility="visible";if(_alL.IsTopPage()){COTInputElementFactory.DisableLink(this._tB);COTInputElementFactory.DisableLink(this._jm);if(_alL.IsLastPage()){COTInputElementFactory.DisableLink(this._if);}else{COTInputElementFactory.EnableLink(this._if);}}else if(_alL.IsLastPage()){COTInputElementFactory.EnableLink(this._tB);COTInputElementFactory.EnableLink(this._jm);COTInputElementFactory.DisableLink(this._if);}else{COTInputElementFactory.EnableLink(this._tB);COTInputElementFactory.EnableLink(this._jm);COTInputElementFactory.EnableLink(this._if);}}var _06=document.getElementById(this._dX);if(_alL.IsSingleColPage()){_06.style.visibility="hidden";}else{_06.style.visibility="visible";if(_alL.IsLeftmostPage()){COTInputElementFactory.DisableLink(this._uO);COTInputElementFactory.DisableLink(this._nO);if(_alL.IsLastColPage()){COTInputElementFactory.DisableLink(this._en);}else{COTInputElementFactory.EnableLink(this._en);}}else if(_alL.IsLastColPage()){COTInputElementFactory.EnableLink(this._uO);COTInputElementFactory.EnableLink(this._nO);COTInputElementFactory.DisableLink(this._en);}else{COTInputElementFactory.EnableLink(this._uO);COTInputElementFactory.EnableLink(this._nO);COTInputElementFactory.EnableLink(this._en);}}var _WA;if((!_alL.IsSingleRowPage())&&(!_alL.IsSingleColPage())){var _atO=parseInt(_alL.GetCurrentRowPageNumber())+1;var _at0=parseInt(_alL.GetCurrentColPageNumber())+1;var _WA=this.oResources.ReplaceParam('IDS_WORKSHEET_2_DIM_CURRENT_PAGE',1,_atO);_WA=this.oResources.ReplaceParam(_WA,2,_at0);}else{var _alB;if(!_alL.IsSingleRowPage()){_alB=parseInt(_alL.GetCurrentRowPageNumber())+1;}else{_alB=parseInt(_alL.GetCurrentColPageNumber())+1;}_WA=this.oResources.ReplaceParam('IDS_WORKSHEET_1_DIM_CURRENT_PAGE',1,_alB);}Dom.ReplaceText(this._fp,_WA);}};CUIWorkSheet.prototype.HasScrollbar=function(){if(this._ca==CUIWorkSheet.eLayoutXtabAndChart){if(this._st.scrollHeight>this._fW){return true;}}return false;};CUIWorkSheet.prototype.OnSplitterMove=function(_IM){if(_IM=this._c9&&this.AllowInteraction()){this._jA=true;this._oh=this._vN+this._c9.iLastMove;this.UpdateHeight(null,true);this.HandleResize();}};CUIWorkSheet.prototype.HandleResize=function(){if(this._mc){this.oContextBar.HandleResize();this._dO.HandleResize();}if(this._oI){var _aEv=document.getElementById(this._vX);COTStyle.SetWidth(_aEv,this._nq,'px');}};CUIWorkSheet.prototype.SetLeft=function(_P6){this._wK=_P6;this._st.style.left=_P6+'px';this.oContextBar.SetLeft(this._wK);};CUIWorkSheet.prototype.SetWidth=function(_F4){this._nq=_F4;COTStyle.SetWidth(this._st,_F4);this.oContextBar.SetWidth(this._nq);this._dO.SetWidth(this._nq);if(this._gg){this._gg.SetWidth(this._nq-CUIManager.kiScrollbarWidth);}if(this._c9){this._c9.SetWidth(this._nq-CUIManager.kiScrollbarWidth);}};CUIWorkSheet.prototype.GetLeft=function(){return this._wK;};CUIWorkSheet.prototype.GetWidth=function(){return this._nq;};CUIWorkSheet.prototype.GetUIAxesContainer=function(){if(this.IsCrosstabVisible()||!this._gg){return this.GetUICrosstab();}else{return this._gg;}};CUIWorkSheet.prototype.HandleSelectedAxisCntx=function(event){if(this._m4.oDialogMgr._jg&&this._m4.oDialogMgr._jg._r3){this.Notify(event);}};CUIWorkSheet.prototype.OnBeforeBlockSelectionChange=function(_JV){if(_JV!=this.GetSelectedBlock()){this._h0=_JV;return this._m4.ConfirmLossOfChanges();}return Utilities.eStateContinue;};CUIWorkSheet.prototype.GetNextBlockSelection=function(){return this._h0;};CUIWorkSheet.prototype.HandleBlockSelection=function(_LY,_No){if(_LY==this.oContextBar){if(this.IsCrosstabVisible()){this._dO.SecondarySelectBlock(_No);}else if(this._gg){this._gg.SecondarySelectBlock(_No);}}else if(_LY==this._dO){this.oContextBar.SecondarySelectBlock(_No);}this.Notify(ExpEvent.kCUIWorksheet_ChangedBlockSel);};CUIWorkSheet.prototype.SetLastBlockSelectionId=function(_L7){this._rr=_L7;};CUIWorkSheet.prototype.ContinueApplyBlockSelection=function(_L7){var _No=this._m4.dataManager.GetCurrentDataMatrix().GetBlock(_L7);if(!_No){return;}if(this.IsCrosstabVisible()){this._dO.SecondarySelectBlock(_No,true);}else if(this._gg){this._gg.SecondarySelectBlock(_No,true);}this.oContextBar.SecondarySelectBlock(_No);this.Notify(ExpEvent.kCUIWorksheet_ChangedBlockSel);};CUIWorkSheet.SafeDoContinueApplyBlockSelection=function(_Qa,_L7){/*@if(!@bering_debug)@*/try{/*@end@*/_Qa.ContinueApplyBlockSelection(_L7);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.prototype.ApplyBlockSelection=function(_L7){var _amW=this._m4.ConfirmLossOfChanges();if(_amW==Utilities.eStateContinue){this.ContinueApplyBlockSelection(_L7);}else if(_amW==Utilities.eStateHold){var _Ro=new Array(this,_L7);Utilities.SetProcedureToHold(CUIWorkSheet.SafeDoContinueApplyBlockSelection,_Ro);this._m4.oDialogMgr.Subscribe(this,ExpEvent.kCUIDialogMgr_HideModalDialog);}};CUIWorkSheet.prototype.HandleUnselect=function(_LY,_Lk){if(_LY==this.oContextBar){if(this.IsCrosstabVisible()){this._dO.UnselectAll(true);}else if(this._gg){this._gg.UnselectAll(true);}}else if(_LY==this._dO){this.oContextBar.UnselectAllItems(true);}else if(this._gg&&_LY==this._gg){this.oContextBar.UnselectAllItems(true);if(this.IsCrosstabVisible()){this._dO.UnselectAll(true);}}if(_Lk){this.Notify(ExpEvent.kCUIWorksheet_ChangedBlockSel);}};CUIWorkSheet.prototype.GetDrillThroughContext=function(_Ow){var _aqV=this.GetUICrosstab();_aqV.GetDrillThroughContext(_Ow);var _4U=this.GetDataWorkSheet().GetDataManager().GetCurrentWSFilterSet();_4U.GetDrillThroughContext(_Ow);};CUIWorkSheet.prototype.SetSelectionContext=function(_Nu){var _aqV=this.GetUICrosstab();if(_aqV){_aqV.SetSelectionContext(_Nu);}var _4U=this.GetDataWorkSheet().GetDataManager().GetCurrentWSFilterSet();_4U.SetSelectionContext(_Nu);};CUIWorkSheet.prototype.GetImmediateSelectedContext=function(_Ow){var _aqV=this.GetUICrosstab();_aqV.GetImmediateSelectedContext(_Ow);};CUIWorkSheet.prototype.GetGeneralContext=function(_Ow){var _azo=new Array();var _I3=this._m4.dataManager.GetCurrentDataMatrix().GetAllBlocksArray();for(var i=0;i<_I3.length;i++){var _aJU=_I3[i].GetDrillThroughSearchData();_azo=_azo.concat(_aJU);}return _azo;};CUIWorkSheet.prototype.GetFilterContext=function(){var _azo=new Array();var _4U=this.GetDataWorkSheet().GetDataManager().GetCurrentWSFilterSet();_4U.GetDrillThroughContext(_azo);return _azo;};CUIWorkSheet.prototype.GetSelectedBlock=function(){if(this.IsCrosstabVisible()&&this._dO._n2){return this._m4.dataManager.GetCurrentDataMatrix().GetBlock(this._dO.GetSingleSelectedBlockId());}else{if(this.oContextBar.GetSelectedBlock()){return this.oContextBar.GetSelectedBlock();}else if(this._gg&&this._gg.GetSelectedBlock()){return this._gg.GetSelectedBlock();}}return null;};CUIWorkSheet.prototype.GetInferredBlock=function(){var _FK=this.GetSelectedBlock();if(!_FK){var _Yj=this.GetUIAxesContainer().GetSelectedAxis();if(_Yj){var _FK=_Yj.GetLastSelection().GetBlock();this.ApplyBlockSelection(_FK.GetId());return _FK;}}return _FK;};CUIWorkSheet.SafeDoInsertDropData=function(_Qa,_Lv,_Tk){/*@if(!@bering_debug)@*/try{/*@end@*/if(_Tk!=null){_Lv.kPopulation=_Tk;}_Qa.InsertDropData(_Lv);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.prototype.InitDragMenus=function(){this.oChildrenRDropCntxMenu=new CUIContextMenu(this._m4.appobj.appname,0,this);this.oHAMCRDropCntxMenu=new CUIContextMenu(this._m4.appobj.appname,0,this);this.oReplaceRDropCntxMenu=new CUIContextMenu(this._m4.appobj.appname,0,this);this.oMultiMemReplaceRDropCntxMenu=new CUIContextMenu(this._m4.appobj.appname,0,this);this.oMultiMemInsertRDropCntxMenu=new CUIContextMenu(this._m4.appobj.appname,0,this);this.oMeasureInsertRDropCntxMenu=new CUIContextMenu(this._m4.appobj.appname,0,this);this.oMeasureReplaceRDropCntxMenu=new CUIContextMenu(this._m4.appobj.appname,0,this);this.oCurrMeasureReplaceRDropCntxMenu=new CUIContextMenu(this._m4.appobj.appname,0,this);this.oCurrMeasureInsertRDropCntxMenu=new CUIContextMenu(this._m4.appobj.appname,0,this);this.oMoveRDropCntxMenu=new CUIContextMenu(this._m4.appobj.appname,0,this);var _IS=false;var _aCV=null;var _BM=this.oResources.GetString('OTH_WORKSHEET_INS_WITH_CHILDREN');var _av2=new ContextItem('',_BM,null,_IS,_aCV,this.oChildrenRDropCntxMenu);_av2.id='OTH_WORKSHEET_INS_WITH_CHILDREN';_BM=this.oResources.GetString('OTH_WORKSHEET_INS_SINGLE_MEM');oWithoutDetails=new ContextItem('',_BM,null,_IS,_aCV,this.oChildrenRDropCntxMenu);oWithoutDetails.id='OTH_WORKSHEET_INS_SINGLE_MEM';var _9B=oWithoutDetails.Clone(this.oMeasureInsertRDropCntxMenu);_9B.SetAsDefault(true);var _auz=oWithoutDetails.Clone(this.oCurrMeasureInsertRDropCntxMenu);_auz.SetAsDefault(true);_av2.Clone(this.oMeasureInsertRDropCntxMenu);_BM=this.oResources.GetString('OTH_WORKSHEET_APPEND_MEM');var _PM=new ContextItem('',_BM,null,_IS,_aCV,this.oHAMCRDropCntxMenu);_PM.id='OTH_WORKSHEET_APPEND_MEM';_BM=this.oResources.GetString('OTH_WORKSHEET_REPLACE_WITH_DETAILS');oRepWDetails=new ContextItem('',_BM,null,_IS,_aCV,this.oReplaceRDropCntxMenu);oRepWDetails.id='OTH_WORKSHEET_REPLACE_WITH_DETAILS';_BM=this.oResources.GetString('OTH_WORKSHEET_REPLACE_WO_DETAILS');_PM=new ContextItem('',_BM,null,_IS,_aCV,this.oReplaceRDropCntxMenu);_PM.id='OTH_WORKSHEET_REPLACE_WO_DETAILS';var _9j=_PM.Clone(this.oMeasureReplaceRDropCntxMenu);_9j.SetAsDefault(true);var _aFk=_PM.Clone(this.oCurrMeasureReplaceRDropCntxMenu);_aFk.SetAsDefault(true);oRepWDetails.Clone(this.oMeasureReplaceRDropCntxMenu);_BM=this.oResources.GetString('OTH_WORKSHEET_MULTI_MEM_REPLACE');_PM=new ContextItem('',_BM,null,_IS,_aCV,this.oMultiMemReplaceRDropCntxMenu);_PM.id='OTH_WORKSHEET_MULTI_MEM_REPLACE';_BM=this.oResources.GetString('OTH_WORKSHEET_MULTI_MEM_INSERT');_PM=new ContextItem('',_BM,null,_IS,_aCV,this.oMultiMemInsertRDropCntxMenu);_PM.id='OTH_WORKSHEET_MULTI_MEM_INSERT';_BM=this.oResources.GetString('OTH_WORKSHEET_MOVE_HERE');_PM=new ContextItem('',_BM,null,_IS,_aCV,this.oMoveRDropCntxMenu);_PM.id='OTH_WORKSHEET_MOVE_HERE';_PM.SetAsDefault(true);var _BM=this.oResources.GetString('OTH_WORKSHEET_CANCEL_DROP');_PM=new ContextItem('',_BM,null,_IS,_aCV,this.oChildrenRDropCntxMenu);_PM.id='OTH_WORKSHEET_CANCEL_DROP';_PM.Clone(this.oHAMCRDropCntxMenu);_PM.Clone(this.oReplaceRDropCntxMenu);_PM.Clone(this.oMultiMemReplaceRDropCntxMenu);_PM.Clone(this.oMultiMemInsertRDropCntxMenu);_PM.Clone(this.oMeasureInsertRDropCntxMenu);_PM.Clone(this.oMoveRDropCntxMenu);_PM.Clone(this.oCurrMeasureInsertRDropCntxMenu);_PM.Clone(this.oCurrMeasureReplaceRDropCntxMenu);_PM.Clone(this.oMeasureReplaceRDropCntxMenu);};CUIWorkSheet.prototype.OnContextMenuHide=function(){if(!CUIDragDrop.IsDragging()){this._dO.HideAllDropZones();this.oContextBar.HideAllDropZones();}};CUIWorkSheet.prototype.SetDZMenu=function(_zA,_Ga,_Q3,_Hu){var _Co=this.oResources;var _FD=this.GetIncludeDetailFlag();var _aln=_zA.length;for(var x=0;x<_Ga.items.length;x++){var _PM=_Ga.items[x];var _ayg=new Array();_PM.SetItemAction(CUIWorkSheet.SafeDoInsertDropData);switch(_PM.id){case 'OTH_WORKSHEET_INS_WITH_CHILDREN':case 'OTH_WORKSHEET_REPLACE_WITH_DETAILS':_zA[_aln]=ExpAPIXml.kChildrenPopulation;_PM.SetAsDefault(_FD&&!_Q3);break;case 'OTH_WORKSHEET_CANCEL_DROP':_ayg=null;_PM.SetItemAction(CUIContextMenu.SafeDoHidePopupMenu);break;case 'OTH_WORKSHEET_APPEND_MEM':_PM.SetAsDefault(true);break;case 'OTH_WORKSHEET_INS_SINGLE_MEM':case 'OTH_WORKSHEET_REPLACE_WO_DETAILS':_zA[_aln]=ExpAPIXml.kMemberPopulation;break;case 'OTH_WORKSHEET_MULTI_MEM_REPLACE':case 'OTH_WORKSHEET_MULTI_MEM_INSERT':if(_Hu){_zA[_aln]=ExpAPIXml.kAxisExprLevelMembers;}else{_zA[_aln]=ExpAPIXml.kMemberPopulation;}_PM.SetAsDefault(true);}if(_ayg!=null){for(var i=0;i<_zA.length;i++){_ayg[i]=_zA[i];}}_Ga.items[x].SetParameterArr(_ayg);}};CUIWorkSheet.prototype.InsertDropData=function(_Lv,e){var _RJ=this._m4.dataManager.metadata;if(e&&!Dom.IsLeftButton(e)){var _Ga=this.oChildrenRDropCntxMenu;if(_Lv.bDelete){_Ga=this.oMoveRDropCntxMenu;}else if(_Lv.kAction==ExpAPIXml.kActionAppend){_Ga=this.oHAMCRDropCntxMenu;}else if(_Lv.kAction==ExpAPIXml.kActionReplace){if(_Lv.aOtherMemIds!=null||_Lv.sCustomSetId!=null||_Lv.sLevId!=null){_Ga=this.oMultiMemReplaceRDropCntxMenu;}else if(_RJ.GetMeasure(_Lv.sMemId)){_Ga=this.oMeasureReplaceRDropCntxMenu;}else{_Ga=this.oReplaceRDropCntxMenu;}}else{if(_Lv.aOtherMemIds!=null||_Lv.sCustomSetId!=null||_Lv.sLevId!=null){_Ga=this.oMultiMemInsertRDropCntxMenu;}else if(_RJ.GetMeasure(_Lv.sMemId)){var _X3=this._m4.dataManager.GetCurrentDataMatrix().GetCurrentMeasure();if(_Lv.kAction==ExpAPIXml.kActionSetDefMeasure&&_X3){_Ga=this.oCurrMeasureReplaceRDropCntxMenu;}else if(_Lv.kAction!=ExpAPIXml.kActionSetDefMeasure){_Ga=this.oMeasureInsertRDropCntxMenu;}else{_Ga=this.oCurrMeasureInsertRDropCntxMenu;}}}_zA=new Array(this,_Lv);var _Hu=_Lv.sLevId?true:false;var _aud=_RJ.GetMeasure(_Lv.sMemId)?true:false;this.SetDZMenu(_zA,_Ga,_aud,_Hu);_Ga.display(e);}else{if(_Lv.bDelete&&_Lv.kAction!=ExpAPIXml.kActionReplace){if(!_Lv.sFilterId){this._my.MoveBlock(_Lv.sBlockId,_Lv.kAction,_Lv.kPosition,_Lv.sTargetAxis,_Lv.sTargetBlock);}else{this._my.MoveFilter(_Lv.sFilterId,_Lv.kAction,_Lv.kPosition,_Lv.sTargetAxis,_Lv.sTargetBlock);}return;}var _Li=this._m4.dataManager.GetCurrentDataMatrix();var _Ix=_Lv.sTargetBlock!=null?ExpAPIXml.kBlock:ExpAPIXml.kAxis;switch(_Lv.kAction){case ExpAPIXml.kActionReplace:if(_Lv.sTargetBlock!=null){var _0B=_Li.GetBlock(_Lv.sTargetBlock);_0B.DoReplace(_Lv.sId,_Lv.kPopulation,_Lv.aDeleteActions,_Lv.aOtherMemIds,_Lv.sBlockId,_Lv.sLevId,_Lv.sFilterId);}else{var _O0=_Li.GetAxisById(_Lv.sTargetAxis);_O0.DoReplace(_Lv.sId,_Lv.kPopulation,_Lv.aOtherMemIds,_Lv.sLevId);}break;case ExpAPIXml.kAxisOpNest:_Li.GetBlock(_Lv.sTargetBlock).Nest();break;case ExpAPIXml.kAxisOpXjoin:if(_Lv.sTargetBlock!=null){this._my.XJoin(_Li.GetDataMatrixId(),_Lv.sId,_Lv.kPopulation,_Lv.kPosition,_Lv.sTargetAxis,_Lv.sTargetBlock,_Ix,_Lv.aDeleteActions,_Lv.aOtherMemIds,_Lv.sLevId,_Lv.sFilterId);}else{var _O0=_Li.GetAxisById(_Lv.sTargetAxis);_O0.Xjoin(_Lv.sId,_Lv.kPopulation,_Lv.kPosition,_Lv.aDeleteActions,_Lv.aOtherMemIds,_Lv.sLevId,_Lv.sFilterId);}break;case ExpAPIXml.kAxisOpUnion:this._my.AddMember(_Li.GetDataMatrixId(),_Lv.sId,_Lv.kPosition,_Lv.sTargetAxis,_Lv.kPopulation,_Lv.sTargetBlock,_Ix,_Lv.aDeleteActions,_Lv.aOtherMemIds,_Lv.sLevId,_Lv.sFilterId);break;case ExpAPIXml.kActionAppend:this._my.AppendMember(_Li.GetDataMatrixId(),_Lv.sId,_Lv.sTargetAxis,_Lv.sTargetBlock,_Lv.aDeleteActions,_Lv.aOtherMemIds);break;case ExpAPIXml.kActionSetDefMeasure:this._my.AddMeasure(_Lv.sId);break;default:Debug.Assert();return;}}};CUIWorkSheet.prototype.Refresh=function(_ST,_Je){this.DrawStatus(_ST,_Je);};CUIWorkSheet.prototype.Unload=function(){if(this._c9){this._c9.Unload();}Dom.RemoveAllChildren(this._st);Utilities.DeleteAllFromArray(this._e6);Utilities.RemoveAllChildObjects(this);};CUIWorkSheet.prototype.Subscribe=function(obj,event){if(this._e6[event]){this._e6[event].push(obj);}else{Debug.Assert(false,"invalid subscription - CUIWorksheet doesn't support event "+event);}if(event==ExpEvent.kCUIWorksheet_Busy&&!this.CheckState(CUIWorkSheet.eStateNormal)){this.Notify(ExpEvent.kCUIWorksheet_Busy);}};CUIWorkSheet.prototype.UnSubscribe=function(obj,event){if(this._e6&&this._e6[event]){Utilities.DeleteFromArray(this._e6[event],obj);}};CUIWorkSheet.prototype.AllowInteraction=function(){return this.CheckState(CUIWorkSheet.eStateNormal);};CUIWorkSheet.prototype.HandleChartRefresh=function(){if(this._my._ek){if(!this._gg){this._gg=new CUIChart(this._my._ek,this);this._gg.Init(this._st);}this._gg.SetDLChart(this._my._ek);this.UpdateLastChartTypeOptions();this._gg.Refresh();this._sv=this._gg.DoesShowValues();if(this._pA){this._sv=false;}this._pA=false;if(this._gg.SupportsThreeDEffect()){this._wy=this._gg.Is3D();}this._fb=this._gg.DoesShowValuesAsPercent();}else{if(this._gg){this._gg.OnHide();this._gg=null;}}};CUIWorkSheet.prototype.Notify=function(event,_FA,_LB,_PT){var _alZ=null;var _amP=null;if(event==ExpEvent.kCDLWorksheet_FullRefresh){/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oDataLayer.StopGlobalTimer();}/*@end@*/if(!this.CheckState(CUIWorkSheet.eStateDrawing)){this.SetState(CUIWorkSheet.eStateDrawing);this.UpdateDisplay();}this._po=true;if(this._m4.dataManager.ForceFullRefresh()){this.oContextBar.Refresh();}else{this.oContextBar.OnWSRefresh();}this._po=false;this.SetTop();this._rS=true;this._dO.OnWSRefresh();this._e3=new Date();}else if(event==ExpEvent.kCDLWorksheet_FSFullRefresh){if(!this.CheckState(CUIWorkSheet.eStateDrawing)){this.SetState(CUIWorkSheet.eStateDrawing);this.UpdateDisplay();}this._po=true;this.oContextBar.OnFSRefresh();this._po=false;this.SetTop();}else if(event==ExpEvent.kCDLAnalysis_Replace){if(!this.CheckState(CUIWorkSheet.eStateDrawing)){this.SetState(CUIWorkSheet.eStateDrawing);this.UpdateDisplay();}if(!this._m4.dataManager._rN){this._po=true;this.oContextBar.OnANSRefresh();this._po=false;}this.SetTop();}else if(event==ExpEvent.kCDLWorksheet_ChartRefresh){this.HandleChartRefresh();if(!this.IsCrosstabVisible()){this._dO.OnWSRefresh();this._rS=true;}this.oContextBar.OnWSRefresh();}else if(event==ExpEvent.kCUIManager_Unload){_amP=ExpEvent.kCUIWorksheet_Unload;}else if(event==ExpEvent.kCDLWorksheet_AwaitingResponse){this.SetState(CUIWorkSheet.eStateBusy);this._gr=false;var _yt=this._m4.oDialogMgr;if(_yt._jg&&_yt._jg instanceof CUIReportOptionsDlg){var _JE=this._my._ak._kX;if(!_JE||!_JE._v6){_yt.HideCurrentDialog();}}else if(_yt.IsModalessDialogDisplayed()&&!_yt.IsModalDialogDisplayed()){if(!(_yt._jg&&_yt._jg instanceof CUISearchDlg)){var _GF=false;var _acG=true;_yt.HideCurrentDialog(_GF,_acG);}}/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oWSUpdate.ClearTimers();g_oWSUpdate.StartGlobalTimer('updates to ws on last request');}/*@end@*/this.UpdateDisplay();_amP=ExpEvent.kCUIWorksheet_Busy;}else if(event==ExpEvent.kCUICrosstab_DrawComplete){if(this._rS){this._rS=false;var _6z=Utilities.GenerateCallback(this.NotifyIfFree,[],this);setTimeout(_6z,10);}}else if(event==ExpEvent.kCUIContextBar_DrawComplete){if(this._po){this._po=false;var _6z=Utilities.GenerateCallback(this.NotifyIfFree,[],this);setTimeout(_6z,10);}}else if(event==ExpEvent.kCUICrosstab_DrawStoppable){this.SetState(CUIWorkSheet.eStateDrawingStoppable);this.UpdateDisplay();}else if(event==ExpEvent.kCDLWorksheet_FailedResponse||event==ExpEvent.kCUIWorksheet_Free){if(event==ExpEvent.kCDLWorksheet_FailedResponse){if(!_PT){CUIDialogMgr.DisplayMessageBox(CUIMessageBox.kCritical,(_FA)?_FA:'MES_SERVER_ERROR',_LB);}}this.onFree();_amP=ExpEvent.kCUIWorksheet_Free;}else if(event==ExpEvent.kCUIWorksheet_NoAxisSel||event==ExpEvent.kCUIWorksheet_MultiAxisSel||event==ExpEvent.kCUIWorksheet_ChangedAxisSel||event==ExpEvent.kCUIWorksheet_ChangedBlockSel){_amP=event;}else if(event==ExpEvent.kCUIDialogMgr_HideModalDialog){Utilities.ExecuteHoldingProcedure();this._m4.oDialogMgr.UnSubscribe(this,ExpEvent.kCUIDialogMgr_HideModalDialog);}else if(event==ExpEvent.kCUIWorksheet_Busy){_amP=ExpEvent.kCUIWorksheet_Busy;}else if(event==ExpEvent.kCDLDataManager_CapabilitiesUpdated){this.UpdateRunMenu();}_alZ=this._e6[_amP];for(var i=0;_alZ&&i<_alZ.length;i++){_alZ[i].Notify(_amP);}if(event==ExpEvent.kCUIManager_Unload){this.Unload();}else if(event==ExpEvent.kCDLWorksheet_ProcessingResponse){this.SetState(CUIWorkSheet.eStateProcessing);/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oDataLayer.ClearTimers();g_oDataLayer.StartGlobalTimer('last data layer crosstab processing');}/*@end@*/this.UpdateDisplay();}else if(event==ExpEvent.kCDLWorksheet_EndProcessing){var _6z=Utilities.GenerateCallback(this.NotifyIfFree,[],this);setTimeout(_6z,10);}else if(event==ExpEvent.kCUIManager_OnWSHeightChange){this.UpdateHeight(this._m4.GetWorksheetBottom());this.HandleResize();}else if(event==ExpEvent.kCDLWorksheet_NameChange){this.UpdateTitleBar();}else if(event==ExpEvent.kCDLDataManager_UpdateViews){if(document.body.setActive){document.body.setActive();}this.UpdateViews();}};CUIWorkSheet.SafeDoShowSortDropDown=function(e,_Ke,x,y){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.uiManager._jf.DoShowSortDropDown(e,_Ke,x,y);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.prototype.DoShowSortDropDown=function(e,_Ke,x,y){if(this.GetSelectedBlock()&&this.GetSelectedBlock().CanSort()){if(!this._ex){this._ex=new CUIContextMenu(_Ke,0,this);CUIWorkSheet.AttachBlockSortItems(_Ke,this.oResources,this._ex);}CUIWorkSheet.UpdateSortItems(this._ex,_Ke,this.GetSelectedBlock());this._ex.display(e,false,x,y);}else{if(!this._dr){this._dr=new CUIContextMenu(_Ke,0,this);CUIWorkSheet.AttachSortItems(this.oResources,this._dr);}var _aCH=this._dO._ax.GetNumberOfSelections();_aCH+=this._dO._bz.GetNumberOfSelections();if(_aCH==1){var _ON;var _Q1;var _HL;var _abM=this._dO._ax;var _8T=this._dO._bz;if(_abM.HasSelection()){_ON=_abM.GetLastSelection();_Q1=_abM;var _axG=true;_HL=_abM.GetDLAxis().GetSelectedTuple(_ON.GetMemberPos(),_ON.GetDepth(),_axG,CDLAxisMember.CanBeUsedInSort);}else if(_8T.HasSelection()){_ON=_8T.GetLastSelection();_Q1=_8T;var _axG=true;_HL=_8T.GetDLAxis().GetSelectedTuple(_ON.GetMemberPos(),_ON.GetDepth(),_axG,CDLAxisMember.CanBeUsedInSort);}if(this.CanCreateSortExpression(_ON,_Q1,_HL)){CUIWorkSheet.UpdateSortMembers(this._dr,_Ke,_ON.GetAxisMember().GetBlock(),_ON,_HL);this._dr.display(e,false,x,y);}else{this.DoPromptForSortSelection();}}else{this.DoPromptForSortSelection();}}};CUIWorkSheet.prototype.CanCreateSortExpression=function(_ON,_Q1,_Rd){var _WR=this.GetDataWorkSheet().GetDataManager();var _Li=_WR.GetCurrentDataMatrix();var _7K=(_Li.GetCurrentMeasureId()!==null);var _Ib=_Q1.GetDLAxis();var _auD=_Li.GetOppositeAxis(_Ib);var _8D=_auD.GetSortableInnerBlocks();if(_8D.length===0||_Rd.length<1){return false;}if(!_7K){var _RJ=_WR.metadata;var _aqb=null;for(var i=0;i<_Rd.length;i++){if(_RJ.GetMeasure(_Rd[i])){_aqb=_Rd[i];}else{var _aGq=_WR._kX.GetCalculation(_Rd[i]);if(_aGq&&_aGq.CanUseAsMeasure()){_aqb=_Rd[i];}}if(_aqb){_7K=true;}}}return _7K;};CUIWorkSheet.prototype.DoPromptForSortSelection=function(){var _Hy=this._m4.oDialogMgr;if(!this._dv){this._dv=new CUISortDlg();this._dv.Init(_Hy);}var _M3=true;this._dv.Display(_M3);};CUIWorkSheet.AttachSortItems=function(_Co,_Ga){var _BM=_Co.GetString('OTH_BLOCKPROP_SORTMENU_NONE');var _apL=new ContextItem('',_BM,CUIWorkSheet.SafeDoSetSortType,true,null,_Ga);_apL.id='OTH_BLOCKPROP_SORTMENU_NONE';_BM=_Co.GetString('OTH_BLOCKPROP_SORTMENU_ASCENDING');_apL=new ContextItem('',_BM,CUIWorkSheet.SafeDoSetSortType,false,null,_Ga);_apL.id='OTH_BLOCKPROP_SORTMENU_ASCENDING';_BM=_Co.GetString('OTH_BLOCKPROP_SORTMENU_DESCENDING');_apL=new ContextItem('',_BM,CUIWorkSheet.SafeDoSetSortType,true,null,_Ga);_apL.id='OTH_BLOCKPROP_SORTMENU_DESCENDING';_BM=_Co.GetString('OTH_BLOCKPROP_SORTMENU_CUSTOM');_apL=new ContextItem('',_BM,CUIWorkSheet.SafeOpenSortDlg,true,null,_Ga);_apL.id='OTH_BLOCKPROP_SORTMENU_CUSTOM';return _Ga;};CUIWorkSheet.AttachBlockSortItems=function(_Ke,_Co,_Ga){var _BM=_Co.GetString('OTH_BLOCKPROP_SORTMENU_NONE');var _apL=new ContextItem('',_BM,CUIWorkSheet.SafeDoSetSortType,true,null,_Ga);_apL.id='OTH_BLOCKPROP_SORTMENU_NONE';var _BM=_Co.GetString('OTH_CROSSTAB_MENU_SORT_LABELS');var _apL=new ContextItem('',_BM,CUIWorkSheet.SafeDoSetSortType,true,null,_Ga);_apL.id='OTH_CROSSTAB_MENU_SORT_LABELS';var _56=_apL.CreateSubMenu(_Ke,_Ga._dl+1,null,false);_BM=_Co.GetString('OTH_BLOCKPROP_SORTMENU_ASCENDING');_apL=new ContextItem('',_BM,CUIWorkSheet.SafeDoSetSortType,false,null,_56);_apL.id='OTH_BLOCKPROP_SORTMENU_ASCENDING';_BM=_Co.GetString('OTH_BLOCKPROP_SORTMENU_DESCENDING');_apL=new ContextItem('',_BM,CUIWorkSheet.SafeDoSetSortType,true,null,_56);_apL.id='OTH_BLOCKPROP_SORTMENU_DESCENDING';_56.SetChildrenComplete();var _BM=_Co.GetString('OTH_CROSSTAB_MENU_SORT_VALUES');var _apL=new ContextItem('',_BM,CUIWorkSheet.SafeDoSetSortType,true,null,_Ga);_apL.id='OTH_CROSSTAB_MENU_SORT_VALUES';var _56=_apL.CreateSubMenu(_Ke,_Ga._dl+1,null,false);_BM=_Co.GetString('OTH_BLOCKPROP_SORTMENU_ASCENDING');_apL=new ContextItem('',_BM,CUIWorkSheet.SafeDoSetSortType,false,null,_56);_apL.id='OTH_BLOCKPROP_SORTMENU_ASCENDING';_BM=_Co.GetString('OTH_BLOCKPROP_SORTMENU_DESCENDING');_apL=new ContextItem('',_BM,CUIWorkSheet.SafeDoSetSortType,true,null,_56);_apL.id='OTH_BLOCKPROP_SORTMENU_DESCENDING';_56.SetChildrenComplete();_BM=_Co.GetString('OTH_BLOCKPROP_SORTMENU_CUSTOM');_apL=new ContextItem('',_BM,CUIWorkSheet.SafeOpenSortDlg,true,null,_Ga);_apL.id='OTH_BLOCKPROP_SORTMENU_CUSTOM';return _Ga;};CUIWorkSheet.UpdateSortMembers=function(_Ga,_Ke,_FK,_zU,_HL){var _Co=FindApp(_Ke).oResources;var _auD=_FK.GetOppositeAxis(_zU);for(var i=0;i<_Ga.items.length;i++){var _apL=_Ga.items[i];var _Ng=false;var _AG;var _amv=CUICrosstab.SafeSortMembers;switch(_apL.id){case 'OTH_BLOCKPROP_SORTMENU_ASCENDING':_AG=new Array(_Ke,_auD,_HL,ExpAPIXml.kEleAxisOpExprSorttypeBottom);break;case 'OTH_BLOCKPROP_SORTMENU_DESCENDING':_AG=new Array(_Ke,_auD,_HL,ExpAPIXml.kEleAxisOpExprSorttypeTop);break;case 'OTH_BLOCKPROP_SORTMENU_NONE':_AG=new Array(_Ke,_auD,_HL,ExpAPIXml.kEleAxisOpExprSorttypeDefault);break;case 'OTH_BLOCKPROP_SORTMENU_CUSTOM':_apL.SetDisplayFlag(false);break;}_apL.SetItemAction(_amv);_apL.SetEnabled(true);_apL.SetRadioState(_Ng);_apL.SetParameterArr(_AG);}return _Ga;};CUIWorkSheet.UpdateSortItems=function(_Ga,_Ke,_FK,_Lz){var _AG=new Array(_Ke,_FK);var _Co=FindApp(_Ke).oResources;var _aaN=_FK.IsCustomSort();var _17=(_FK.oAxis._rk.IsComplete()&&(!_FK.IsExplicitSort()||!_FK.IsCustomSort()));var _aeI=_FK.oAxis._rk.GetCurrentMeasure();for(var i=0;i<_Ga.items.length;i++){var _PM=_Ga.items[i];var _Mj=false;var _Ng=false;var _amv=_Lz?CUISortProperty.SafeDoUpdate:CUIWorkSheet.SafeDoSetSortType;switch(_PM.id){case 'OTH_CROSSTAB_MENU_SORT_LABELS':for(var _awx=0;_awx<_PM._o6.items.length;_awx++){var _apL=_PM._o6.items[_awx];var _4C=false;var _37=false;var _96=true;switch(_apL.id){case 'OTH_BLOCKPROP_SORTMENU_ASCENDING':_AG=new Array(_Ke,_FK,ExpAPIXml.kEleAxisOpExprSorttypeBottom,_96);_37=_FK.IsAscending()&&_FK.IsSortByLabel();_4C=true;if(_37){_Ng=true;}break;case 'OTH_BLOCKPROP_SORTMENU_DESCENDING':_AG=new Array(_Ke,_FK,ExpAPIXml.kEleAxisOpExprSorttypeTop,_96);_37=_FK.IsSortByLabel()&&!_FK.IsAscending();_4C=true;if(_37){_Ng=true;}break;default:Debug.Assert(false);}_apL.SetItemAction(_amv);_apL.SetEnabled(_4C);_apL.SetRadioState(_37);_apL.SetParameterArr(_AG);if(_Lz){_apL.SetSkipUncomitChangesChecking();}}_amv=null;_Mj=true;break;case 'OTH_CROSSTAB_MENU_SORT_VALUES':for(var _apc=0;_apc<_PM._o6.items.length;_apc++){var _apL=_PM._o6.items[_apc];var _4C=false;var _37=false;switch(_apL.id){case 'OTH_BLOCKPROP_SORTMENU_ASCENDING':if(_17&&(!_aeI)){_AG=new Array(_Ke,ExpAPIXml.kEleAxisOpExprSorttypeBottom);_amv=_Lz?CUISortProperty.SafeDoShowSortDlg:CUIWorkSheet.SafeOpenSortDlg;}else{_AG=new Array(_Ke,_FK,ExpAPIXml.kEleAxisOpExprSorttypeBottom);_37=_FK.IsAscending()&&!_aaN&&!_FK.IsSortByLabel();}_4C=(_17&&_aeI);if(_37){_Ng=true;}break;case 'OTH_BLOCKPROP_SORTMENU_DESCENDING':if(_17&&(!_aeI)){_AG=new Array(_Ke,ExpAPIXml.kEleAxisOpExprSorttypeTop);_amv=_Lz?CUISortProperty.SafeDoShowSortDlg:CUIWorkSheet.SafeOpenSortDlg;}else{_AG=new Array(_Ke,_FK,ExpAPIXml.kEleAxisOpExprSorttypeTop);_37=!_aaN&&_FK.IsDescending()&&!_FK.IsSortByLabel();}_4C=(_17&&_aeI);if(_37){_Ng=true;}break;default:Debug.Assert(false);}_apL.SetItemAction(_amv);_apL.SetEnabled(_4C);_apL.SetRadioState(_37);_apL.SetParameterArr(_AG);if(_Lz){_apL.SetSkipUncomitChangesChecking();}}_amv=null;_Mj=(_17&&_aeI);break;case 'OTH_BLOCKPROP_SORTMENU_NONE':_AG=new Array(_Ke,_FK,ExpAPIXml.kEleAxisOpExprSorttypeDefault);_Ng=!_FK.IsExplicitSort();_Mj=true;break;case 'OTH_BLOCKPROP_SORTMENU_CUSTOM':_Ng=_aaN;_Mj=true;_apL.SetDisplayFlag(true);_AG=new Array(_Ke);_amv=_Lz?CUISortProperty.SafeDoShowSortDlg:CUIWorkSheet.SafeOpenSortDlg;break;}_PM.SetItemAction(_amv);_PM.SetEnabled(_Mj);_PM.SetRadioState(_Ng);_PM.SetParameterArr(_AG);if(_Lz){_PM.SetSkipUncomitChangesChecking();}}return _Ga;};CUIWorkSheet.SafeDoSetSortType=function(_Ke,_FK,_RC,_BI){/*@if(!@bering_debug)@*/try{/*@end@*/var _VI=new Array();_VI.push(_FK.SetProperty(ExpAPIXml.kEleAxisOpExprSorttype,ExpAPIXml.kEleAxisOpExprSorttypeDefault,true));var _Le=true;if(_RC!=ExpAPIXml.kEleAxisOpExprSorttypeDefault){_VI.push(_FK.SetProperty(ExpAPIXml.kEleAxisOpExprSorttype,_RC,_Le));if(_FK.HasSortMembers()){_VI.push(_FK.SetSortMembers(_FK._qs,_Le));}else{_VI.push(_FK.SetSortMembers(new Array(DefaultConstants.kDefScope),_Le));}if(_FK._k2){_VI.push(_FK.SetProperty(ExpAPIXml.kEleAxisOpExprSortMeasure,_FK._k2,_Le));}else{_VI.push(_FK.SetProperty(ExpAPIXml.kEleAxisOpExprSortMeasure,DefaultConstants.kDefMeasure,_Le));}if(_BI){_VI.push(_FK.SetProperty(ExpAPIXml.kEleAxisOpExprSortLabel,true,_Le));}}_FK.oAxis._rk.SendDMActionArray(_VI);var _Mg=FindApp(_Ke);_Mg.uiManager._jf.SetLastBlockSelectionId(_FK.GetId());/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.SafeDoShowAutoSummaryDialog=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.uiManager._jf.DoShowAutoSummaryDialog(_Ke);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.prototype.DoShowAutoSummaryDialog=function(_Ke){var _FK=this.GetSelectedBlock();var _Hy=this._m4.oDialogMgr;if(_FK&&_FK.CanApplyAutoSubtotals()){if(!this._ws){this._ws=new CUIAutoSubtotalsDlg();this._ws.Init(_Hy,this);}this._ws.SetHostObj(_FK);this._ws.Display();}else{this.DoPromptForAutoSubtotalsSelection();}};CUIWorkSheet.SafeDoShowSetBasedCalcDropDown=function(e,_Ke,x,y){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.uiManager._jf.DoShowSetBasedCalcDropDown(e,_Ke,x,y);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.prototype.DoShowSetBasedCalcDropDown=function(e,_Ke,x,y){if(!this._uh){this._uh=new CUIContextMenu(_Ke,0,this);}this._uh.Clear();var _FK=this.GetSelectedBlock();if(_FK&&_FK.CanApplySetBasedCalc()){var _Co=this.oResources;this._uh=CUIWorkSheet.AttachSetBasedCalcItems(_Co,this._uh,_Ke,_FK);this._uh.display(e,false,x,y);}else{this.DoPromptForSetBasedCalcSelection();}};CUIWorkSheet.AttachSetBasedCalcItems=function(_Co,_Ga,_Ke,_FK){var _BM;var _apL;var _zA;for(var i=0;i<CUISetBasedCalcExpression.SetBasedCalcOptArray.length;i++){var _J9=CUISetBasedCalcExpression.SetBasedCalcOptArray[i];var _OW=CUIWorkSheet.CreateSetBasedCalcExpr(_J9,_FK,_Co);_zA=new Array(_Ke,_OW);_PM=new ContextItem('',_OW.GetLabel(),CUIWorkSheet.SafeDoSubmitSetBasedCalc,false,_zA,_Ga);_PM.SetEnabled(!_FK.IsEmptyBlock());}return _Ga;};CUIWorkSheet.CreateSetBasedCalcExpr=function(_J9,_FK,_Co){var _IP=new CDLMathMLExprNode(_J9,false,false);var _aot=ExpAPIXml.kSegmentFunc;var _auc=new CDLMathMLExprNode(_aot,true,false);_auc.AddOperands(_FK.GetId(),_FK.GetId(),CUICalculationExpr.CIOperand,-1,ExpAPIXml.kBlock);_auc.AddOperands(ExpAPIXml.kAttrValueDefSegment,ExpAPIXml.kAttrValueDefSegment,CUICalculationExpr.CIOperand,-1,ExpAPIXml.kAttrSegment);_IP.AddOperands(_auc,null,CDLMathMLOperands.Apply);var _OW=new CUISetBasedCalcExpression(_IP,_Co,_FK);return _OW;};CUIWorkSheet.SafeDoSubmitSetBasedCalc=function(_Ke,_OW){/*@if(!@bering_debug)@*/try{/*@end@*/_OW._rB.CreateMathMLCalcExpr(_OW._p8,_OW._ni,_OW._p8);var _Mg=FindApp(_Ke);_Mg.uiManager._jf.SetLastBlockSelectionId(_OW._rB.GetId());/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.SafeDoShowCalcDropDown=function(e,_Ke,x,y){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.uiManager._jf.DoShowCalcDropDown(e,_Ke,x,y);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.prototype.HasValidDescriptiveStatsSelection=function(){var _FK=this.GetSelectedBlock();if(_FK){this._to=_FK;return true;}else if(this.IsCrosstabVisible()&&this.GetUICrosstab()&&this.GetUICrosstab()._hL){var _Yj=this.GetUICrosstab()._hL;var _V7=_Yj._az;_FK=_V7._cu;this._to=_V7;return true;}this._to=null;return false;};CUIWorkSheet.prototype.HasValidCalcSelection=function(){var _FK=this.GetSelectedBlock();if(_FK&&_FK.CanApplyUserDefCalculation()){this._wa=_FK;return true;}else if(this.IsCrosstabVisible()&&this.GetUICrosstab()&&this.GetUICrosstab()._hL){var _Yj=this.GetUICrosstab()._hL;var _V7=_Yj._az;_FK=_V7._cu;if(_FK.CanApplyUserDefCalculation()){if(_FK.IsGroupedDescendantsAtDepth()&&(!_Yj.CanCreateCalcUseSelectedMembers())){if(Utilities.GetObjArrayLength(_Yj._hb)==1){return false;}this._wa=_FK;}else{this._wa=_V7;}return true;}}this._wa=null;return false;};CUIWorkSheet.prototype.canDoEditCalc=function(){if(!this.GetSelectedBlock()){var _Yj=this.GetUICrosstab()._hL;var _V7=_Yj._az;if(_V7._us.length==1){var oMem=_V7._us[0];return(oMem.IsMemberBasedCalc()&&oMem.IsEditable());}}return false;};CUIWorkSheet.prototype.DoShowCalcDropDown=function(e,_Ke,x,y){if(!this._d9){this._d9=new CUIContextMenu(_Ke,0,this);}this._d9.Clear();var _Co=this.oResources;var _FK=null;var _V7=null;if(this.HasValidCalcSelection()){if(this._wa instanceof CDLBlock){_FK=this._wa;}else if(this._wa instanceof CUIUserSelection){_FK=this._wa._cu;_V7=this._wa;}this._d9=CUIWorkSheet.AttachCalcItems(_Co,this._d9,_Ke,_V7,_FK);this._d9.display(e,false,x,y);}else{var _M3=true;CUIWorkSheet.SafeOpenCalcDlg(_Ke,_M3);}};CUIWorkSheet.AttachCalcItems=function(_Co,_Ga,_Ke,_V7,_FK){var _BM;var _apL;var _zA;if(_V7){if(_V7.GetUIAxis().GetUIReportObj().GetUIWorkSheet().canDoEditCalc()){var _UA=new Array(_Ke,_V7);var _atK=new ContextItem(null,_Co.GetString('OTH_TOOLBAR_MENU_CAL_EDIT'),CUICrosstab.SafeDoEditCalc,false,_UA,_Ga);var _aIC=new ContextSeparator(_Ga);}if(_V7.IsRenamable()){_BM=_Co.GetString('OTH_CROSSTAB_MENU_CALC_RENAME');_zA=new Array(_Ke);_apL=new ContextItem('',_BM,CUIWorkSheet.SafeOpenRenameCalcDlg,false,_zA,_Ga);}_V7.PopulateCalOptions();var _aJs=_V7._e4;for(var i in _aJs){_zA=new Array(_Ke,_aJs[i],_FK,_V7);_apL=new ContextItem(null,_aJs[i].GetMenuLabel(),CUICrosstab.SafeDoUserDefCalculation,false,_zA,_Ga);_apL.SetEnabled(!_V7.GetUIAxis().HasNoItemsSelection());_PM.SetTooltip(_aJs[i].GetLabel());}}_BM=_Co.GetString('OTH_CROSSTAB_MENU_CAL_CUSTOMIZE');_zA=new Array(_Ke);_apL=new ContextItem('',_BM,CUIWorkSheet.SafeOpenCalcDlg,false,_zA,_Ga);return _Ga;};CUIWorkSheet.prototype.DoPromptForAutoSubtotalsSelection=function(){var _Hy=this._m4.oDialogMgr;if(!this._ws){this._ws=new CUIAutoSubtotalsDlg();this._ws.Init(_Hy,this);}var _M3=true;var _FK=this.GetInferredBlock();if(_FK&&_FK.CanApplyAutoSubtotals()){this.ApplyBlockSelection(_FK.GetId());this._ws.SetHostObj(_FK);_M3=false;}this._ws.Display(_M3);};CUIWorkSheet.prototype.DoPromptForSetBasedCalcSelection=function(){var _Hy=this._m4.oDialogMgr;if(!this._jn){this._jn=new CUISetBasedCalcDlg();this._jn.Init(_Hy,this);}var _M3=true;var _FK=this.GetInferredBlock();if(_FK&&_FK.CanApplySetBasedCalc()){this.ApplyBlockSelection(_FK.GetId());this._jn.SetHostObj(_FK);_M3=false;}this._jn.Display(_M3);};CUIWorkSheet.prototype.UpdateTitleBar=function(){var _KP=this._m4.appobj.oResources.GetString('IDS_TITLE_BAR_SAVED_ANALYSIS');if(this._my.IsDirty()){var _KP=this.oResources.ReplaceParam('IDS_TITLE_BAR_SAVED_ANALYSIS_DIRTY',1,this._my._aP);}else{var _KP=this.oResources.ReplaceParam('IDS_TITLE_BAR_SAVED_ANALYSIS',1,this._my._aP);}_KP=this.oResources.ReplaceParam(_KP,2,ExpMiscStr.kProductName);document.title=_KP;};CUIWorkSheet.prototype.NotifyIfFree=function(){if(!this._rS&&!this._po&&(!this.CheckState(CUIWorkSheet.eStateBusy)&&!this.CheckState(CUIWorkSheet.eStateNormal))){this.Notify(ExpEvent.kCUIWorksheet_Free);}};CUIWorkSheet.prototype.UpdateDisplay=function(_ST){/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oWSDraw.StartTimer(true);}/*@end@*/Dom.DisplayObject(this._iW,false);Dom.DisplayObject(this._j2,this.CheckState(CUIWorkSheet.eStateDrawing));Dom.DisplayObject(this._bN,this.CheckState(CUIWorkSheet.eStateDrawingStoppable));Dom.DisplayObject(this._ha,false);Dom.DisplayObject(this._fr,this.CheckState(CUIWorkSheet.eStateProcessing));Dom.DisplayObject(this._oI,false);if(this.CheckState(CUIWorkSheet.eStateBusy)){if(_ST){Dom.DisplayObject(this._ha,true);}else{Dom.DisplayObject(this._fr,true);var _6z=Utilities.GenerateCallback(this.DisplayCancel,[],this);setTimeout(_6z,CUIWorkSheet.kDisplayCancelDelay);}}else if(this.CheckState(CUIWorkSheet.eStateNormal)){if(this._gr){if(this._dO.GetNumberOfRowsDisplayed()!=this._dO.GetTotalNumberOfRows()){Dom.ReplaceText(this._hc,this._dO.GetNumberOfRowsDisplayed());Dom.ReplaceText(this._xC,this._dO.GetTotalNumberOfRows());Dom.DisplayObject(this._iW,true);}}else{var _alL=this._dO._fX;if(this.IsCrosstabVisible()&&_alL&&(!this._my._ak.IsInMissingMUNState())){if(!_alL.IsSinglePage()){Dom.DisplayObject(this._oI,true);this.UpdatePagingStatus();}}}}/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oWSDraw.StopTimer(true);}/*@end@*/};CUIWorkSheet.SafeDoShowMore=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/var _Hk=FindApp(_Ke).uiManager;var _amW=_Hk.ConfirmLossOfChanges();if(_amW==Utilities.eStateContinue){CUIWorkSheet.SafeContinueShowMore(_Ke);}else if(_amW==Utilities.eStateHold){var _axQ=Dom.CloneMouseEvent(e);var _Ro=new Array(_Ke);Utilities.SetProcedureToHold(CUIWorkSheet.SafeContinueShowMore,_Ro);var _Qa=FindApp(_Ke).uiManager.GetCurrentWorkSheet();_Hk.oDialogMgr.Subscribe(_Qa,ExpEvent.kCUIDialogMgr_HideModalDialog);}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.prototype.IsDrawingStopped=function(){return this._gr;};CUIWorkSheet.SafeContinueShowMore=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/var _Qa=FindApp(_Ke).uiManager.GetCurrentWorkSheet();_Qa._gr=false;_Qa._rS=true;_Qa.eState=CUIWorkSheet.eStateDrawingStoppable;_Qa.UpdateDisplay();_Qa.Notify(ExpEvent.kCUIWorksheet_Busy);_Qa._dO.ContinueGetCrosstabData();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.prototype.CancelRender=function(){this._gr=true;};CUIWorkSheet.SafeDoPageDown=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager.GetCurrentWorkSheet().DoPageDown();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.prototype.DoPageDown=function(){var _amW=this._m4.ConfirmLossOfChanges();if(_amW==Utilities.eStateContinue){var _alL=this._dO._fX;_alL.PageDown();}else if(_amW==Utilities.eStateHold){Utilities.SetProcedureToHold(CUIWorkSheet.SafeDoPageDown,[this._m4.appobj.appname]);this._m4.oDialogMgr.Subscribe(this,ExpEvent.kCUIDialogMgr_HideModalDialog);}};CUIWorkSheet.SafeDoPageUp=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager.GetCurrentWorkSheet().DoPageUp();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.prototype.DoPageUp=function(){var _amW=this._m4.ConfirmLossOfChanges();if(_amW==Utilities.eStateContinue){var _alL=this._dO._fX;_alL.PageUp();}else if(_amW==Utilities.eStateHold){Utilities.SetProcedureToHold(CUIWorkSheet.SafeDoPageUp,[this._m4.appobj.appname]);this._m4.oDialogMgr.Subscribe(this,ExpEvent.kCUIDialogMgr_HideModalDialog);}};CUIWorkSheet.SafeDoTopPage=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager.GetCurrentWorkSheet().DoTopPage();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.prototype.DoTopPage=function(){var _amW=this._m4.ConfirmLossOfChanges();if(_amW==Utilities.eStateContinue){var _alL=this._dO._fX;_alL.TopPage();}else if(_amW==Utilities.eStateHold){Utilities.SetProcedureToHold(CUIWorkSheet.SafeDoTopPage,[this._m4.appobj.appname]);this._m4.oDialogMgr.Subscribe(this,ExpEvent.kCUIDialogMgr_HideModalDialog);}};CUIWorkSheet.SafeDoPageRight=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager.GetCurrentWorkSheet().DoPageRight();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.prototype.DoPageRight=function(){var _amW=this._m4.ConfirmLossOfChanges();if(_amW==Utilities.eStateContinue){var _alL=this._dO._fX;_alL.PageRight();}else if(_amW==Utilities.eStateHold){Utilities.SetProcedureToHold(CUIWorkSheet.SafeDoPageRight,[this._m4.appobj.appname]);this._m4.oDialogMgr.Subscribe(this,ExpEvent.kCUIDialogMgr_HideModalDialog);}};CUIWorkSheet.SafeDoPageLeft=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager.GetCurrentWorkSheet().DoPageLeft();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.prototype.DoPageLeft=function(){var _amW=this._m4.ConfirmLossOfChanges();if(_amW==Utilities.eStateContinue){var _alL=this._dO._fX;_alL.PageLeft();}else if(_amW==Utilities.eStateHold){Utilities.SetProcedureToHold(CUIWorkSheet.SafeDoPageLeft,[this._m4.appobj.appname]);this._m4.oDialogMgr.Subscribe(this,ExpEvent.kCUIDialogMgr_HideModalDialog);}};CUIWorkSheet.SafeDoLeftmostPage=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager.GetCurrentWorkSheet().DoLeftmostPage();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.prototype.DoLeftmostPage=function(){var _amW=this._m4.ConfirmLossOfChanges();if(_amW==Utilities.eStateContinue){var _alL=this._dO._fX;_alL.LeftmostPage();}else if(_amW==Utilities.eStateHold){Utilities.SetProcedureToHold(CUIWorkSheet.SafeDoLeftmostPage,[this._m4.appobj.appname]);this._m4.oDialogMgr.Subscribe(this,ExpEvent.kCUIDialogMgr_HideModalDialog);}};var _h=false;CUIWorkSheet.prototype.createStatusText=function(_Ij,_F3,_Os){if(_Os){var _afT=document.createElement("IMG");_afT.className='worksheet_loading';_Ij.appendChild(_afT);this._m5=Utilities.IMG_PATH;_afT.src=this._m5+"icon_loading.gif";}var _Tb=_Ij.appendChild(document.createElement('SPAN'));var _aDk=this._m4.appobj.oResources.GetString(_F3);_Tb.appendChild(document.createTextNode(_aDk));return _Tb;};CUIWorkSheet.prototype.InitStatus=function(){var _Ke=this._m4.appobj.appname;var _Co=this._m4.appobj.oResources;var _EP=this._m4.oAppPane.GetDom();this._fr=document.createElement('DIV');this._fr.className="worksheet_status";this.createStatusText(this._fr,'IDS_WORKSHEET_BUSY',true);_EP.appendChild(this._fr);this._ha=document.createElement('DIV');this._ha.className="worksheet_status";var _alq=_Co.ParseStringForParamOrder('IDS_WORKSHEET_BUSY_CANCEL',1);for(var i=0;i<_alq.length;i++){if(_alq[i]){if(_alq[i].sBefore){this.createStatusText(this._ha,_alq[i].sBefore,true);}if(_alq[i].sElement==_Co.GetParameter(1)){var _aut=this.oResources.GetString('IDS_WORKSHEET_CANCEL_REQUEST');this._qJ=COTInputElementFactory.CreateLink(null,_aut,false,"cancelLink");this._qJ.tabIndex=5;this._ha.appendChild(this._qJ);}if(_alq[i].sAfter){this.createStatusText(this._ha,_alq[i].sAfter,false);}}}_EP.appendChild(this._ha);this._j2=document.createElement('DIV');this._j2.className="worksheet_status";this.createStatusText(this._j2,'IDS_WORKSHEET_DRAWING',true);_EP.appendChild(this._j2);this._bN=document.createElement('DIV');this._bN.className="worksheet_status";var _afT=document.createElement("IMG");_afT.className='worksheet_loading';this._bN.appendChild(_afT);this._m5=Utilities.IMG_PATH;_afT.src=this._m5+"icon_loading.gif";var _alq=_Co.ParseStringForParamOrder('IDS_WORKSHEET_DRAWING_STOP',1);for(var i=0;i<_alq.length;i++){if(_alq[i]){if(_alq[i].sBefore){this.createStatusText(this._bN,_alq[i].sBefore,false);}if(_alq[i].sElement==_Co.GetParameter(1)){var _Yc=this.oResources.GetString('IDS_WORKSHEET_STOP_DRAW');this._ps=COTInputElementFactory.CreateLink(null,_Yc,false,"cancelLink");this._ps.onclick=Utilities.GenerateCallback(this.CancelRender,[],this);this._ps.tabIndex=5;this._bN.appendChild(this._ps);}if(_alq[i].sAfter){this.createStatusText(this._bN,_alq[i].sAfter,false);}}}_EP.appendChild(this._bN);this._iW=document.createElement('DIV');this._iW.className="worksheet_status";var _alq=_Co.ParseStringForParamOrder('IDS_WORKSHEET_PARTIAL_DRAW_SHOW_MORE',3);for(var i=0;i<_alq.length;i++){if(_alq[i]){if(_alq[i].sBefore){this.createStatusText(this._iW,_alq[i].sBefore,false);}switch(_alq[i].sElement){case _Co.GetParameter(1):this._hc=this.createStatusText(this._iW,"",false);break;case _Co.GetParameter(2):this._xC=this.createStatusText(this._iW,"",false);break;case _Co.GetParameter(3):var _awJ=this.oResources.GetString('IDS_WORKSHEET_SHOW_MORE');this._rC=COTInputElementFactory.CreateLink(null,_awJ,false,"cancelLink");this._rC.onclick=Utilities.GenerateCallback(CUIWorkSheet.SafeDoShowMore,[_Ke]);this._rC.tabIndex=5;this._iW.appendChild(this._rC);break;default:Debug.Assert(false);}if(_alq[i].sAfter){this.createStatusText(this._iW,_alq[i].sAfter,false);}}}_EP.appendChild(this._iW);this._oI=document.createElement('DIV');this._oI.className="worksheet_paging";var _abw=this._oI.appendChild(document.createElement('TABLE'));_abw.cellSpacing=0;COTStyle.SetWidth(_abw,this._nq,'px');this._vX=Utilities.GenerateId();_abw.id=this._vX;var _ag2=_abw.appendChild(document.createElement('TBODY'));var _NH=_ag2.appendChild(document.createElement('TR'));var _NM=_NH.appendChild(document.createElement('TD'));var _aB5=_NM.appendChild(document.createElement("SPAN"));_aB5.style.whiteSpace='nowrap';_aB5.id=Utilities.GenerateId();this._dG=_aB5.id;COTStyle.SetWidth(_NM,(this._nq-CUIWorkSheet.kiPageNumWidth)/2,'px');var _asw=_aB5.appendChild(document.createElement("SPAN"));_asw.style.whiteSpace='nowrap';var _afT=_asw.appendChild(COTInputElementFactory.CreateImage('top.gif',15,15));var _ahJ=this.oResources.GetString('IDS_WORKSHEET_TOP_PAGE');var _aCq=Utilities.GenerateCallback(CUIWorkSheet.SafeDoTopPage,[_Ke]);this._tB=_asw.appendChild(COTInputElementFactory.CreateLink(_aCq,_ahJ,false,"cancelLink"));this._tB.style.whiteSpace='nowrap';var _asw=_aB5.appendChild(document.createElement("SPAN"));_asw.style.whiteSpace='nowrap';var _afT=_asw.appendChild(COTInputElementFactory.CreateImage('pageup.gif',15,15));var _aCA=this.oResources.GetString('IDS_WORKSHEET_PAGE_UP');var _atU=Utilities.GenerateCallback(CUIWorkSheet.SafeDoPageUp,[_Ke]);this._jm=_asw.appendChild(COTInputElementFactory.CreateLink(_atU,_aCA,false,"cancelLink"));this._jm.style.whiteSpace='nowrap';var _asw=_aB5.appendChild(document.createElement("SPAN"));_asw.style.whiteSpace='nowrap';var _afT=_asw.appendChild(COTInputElementFactory.CreateImage('pagedown.gif',15,15));var _aJV=this.oResources.GetString('IDS_WORKSHEET_PAGE_DOWN');var _azt=Utilities.GenerateCallback(CUIWorkSheet.SafeDoPageDown,[_Ke]);this._if=_asw.appendChild(COTInputElementFactory.CreateLink(_azt,_aJV,false,"cancelLink"));this._if.style.whiteSpace='nowrap';_NM=_NH.appendChild(document.createElement('TD'));this._fp=document.createElement("SPAN");_NM.appendChild(this._fp);this._fp.style.whiteSpace='nowrap';this._fp.style.textAlign='center';this._fp.style.fontSize='70%';this._fp.id=Utilities.GenerateId();this._kx=this._fp.id;COTStyle.SetWidth(_NM,CUIWorkSheet.kiPageNumWidth,'px');this._fp.appendChild(COTInputElementFactory.CreateLabel(' '));_NM=_NH.appendChild(document.createElement('TD'));var _atZ=_NM.appendChild(document.createElement("SPAN"));_atZ.style.whiteSpace='nowrap';_NM.style.textAlign='right';_atZ.id=Utilities.GenerateId();this._dX=_atZ.id;COTStyle.SetWidth(_NM,(this._nq-CUIWorkSheet.kiPageNumWidth)/2,'px');var _asw=_atZ.appendChild(document.createElement("SPAN"));_asw.style.whiteSpace='nowrap';var _afT=_asw.appendChild(COTInputElementFactory.CreateImage('pagefarleft.gif',15,15));var _21=this.oResources.GetString('IDS_WORKSHEET_LEFTMOST_PAGE');var _aAJ=Utilities.GenerateCallback(CUIWorkSheet.SafeDoLeftmostPage,[_Ke]);this._uO=_asw.appendChild(COTInputElementFactory.CreateLink(_aAJ,_21,false,"cancelLink"));this._uO.style.whiteSpace='nowrap';var _asw=_atZ.appendChild(document.createElement("SPAN"));_asw.style.whiteSpace='nowrap';var _afT=_asw.appendChild(COTInputElementFactory.CreateImage('pageleft.gif',15,15));var _WU=this.oResources.GetString('IDS_WORKSHEET_PAGE_LEFT');var _WK=Utilities.GenerateCallback(CUIWorkSheet.SafeDoPageLeft,[_Ke]);this._nO=_asw.appendChild(COTInputElementFactory.CreateLink(_WK,_WU,false,"cancelLink"));this._nO.style.whiteSpace='nowrap';var _asw=_atZ.appendChild(document.createElement("SPAN"));_asw.style.whiteSpace='nowrap';var _afT=_asw.appendChild(COTInputElementFactory.CreateImage('pageright.gif',15,15));var _aF4=this.oResources.GetString('IDS_WORKSHEET_PAGE_RIGHT');var _4X=Utilities.GenerateCallback(CUIWorkSheet.SafeDoPageRight,[_Ke]);this._en=_asw.appendChild(COTInputElementFactory.CreateLink(_4X,_aF4,false,"cancelLink"));this._en.style.whiteSpace='nowrap';_EP.appendChild(this._oI);};CUIWorkSheet.prototype.DrawStatus=function(_ST,_Je){var _Ke=this._m4.appobj.appname;if(this._qJ){this._qJ.onclick=Utilities.GenerateCallback(CUIWorkSheet.SafeDoCancelRequest,[_Ke,_ST,_Je]);}if(!this._bX&&_h){this._bX=this._st.appendChild(document.createElement('BUTTON'));this._bX.className='stab_test';this._bX.appendChild(document.createTextNode('run stability test'));this._bX.onclick=CUIWorkSheet.DoStabilityTest;this._lC=this._st.appendChild(document.createElement('BUTTON'));this._lC.className='stab_test2';this._lC.appendChild(document.createTextNode('run stability test2'));this._lC.onclick=CUIWorkSheet.DoStabilityTest2;this._lD=this._st.appendChild(document.createElement('BUTTON'));this._lD.className='stab_test3';this._lD.appendChild(document.createTextNode('run stability test3'));this._lD.onclick=CUIWorkSheet.DoStabilityTest3;}this.UpdateDisplay(_ST);};CUIWorkSheet.prototype.onFree=function(_OB){if(this.CheckState(CUIWorkSheet.eStateNormal)){return;}this.SetState(CUIWorkSheet.eStateNormal);this._rS=false;this._po=false;this.UpdateDisplay();if(_OB==null){var _OB=true;}if(_OB){this._dO.HideAllDropZones();this.oContextBar.HideAllDropZones();}if(this._rr!=null){this.ApplyBlockSelection(this._rr);this._rr=null;}else{this._rr=null;if(this._dO){this._dO.UnselectAll(true);}if(this._gg){this._gg.UnselectAll(true);}if(this.oContextBar){this.oContextBar.UnselectAllItems(true);}}};CUIWorkSheet.DoStabilityTest=function(){var _Qa=FindApp('main').uiManager.GetCurrentWorkSheet();CUIWorkSheet.oStartTime=new Date();CUIWorkSheet.iTotalTime=100000+CUIWorkSheet.oStartTime.valueOf();CUIWorkSheet.oTimeToDate=CUIWorkSheet.oStartTime;CUIWorkSheet.aDrawTimes=new Array();_Qa.DoStabilityTest();};CUIWorkSheet.DoStabilityTest2=function(){var _Qa=FindApp('main').uiManager.GetCurrentWorkSheet();_Qa.bStabTest=true;CUIWorkSheet.oStartTime=new Date();CUIWorkSheet.iTotalTime=36000+CUIWorkSheet.oStartTime.valueOf();CUIWorkSheet.oTimeToDate=CUIWorkSheet.oStartTime;CUIWorkSheet.aDrawTimes=new Array();_Qa.DoStabilityTest2();};CUIWorkSheet.DoStabilityTest3=function(){var _Qa=FindApp('main').uiManager.GetCurrentWorkSheet();_Qa.bStabTest3=true;CUIWorkSheet.iCount=0;CUIWorkSheet.oStartTime=new Date();CUIWorkSheet.iTotalTime=3600000+CUIWorkSheet.oStartTime.valueOf();CUIWorkSheet.oTimeToDate=CUIWorkSheet.oStartTime;CUIWorkSheet.aDrawTimes=new Array();_Qa.DoStabilityTest3();};CUIWorkSheet.RedoStabilityTest=function(){var _Qa=FindApp('main').uiManager.GetCurrentWorkSheet();CUIWorkSheet.oTimeToDate=new Date();_Qa.DoStabilityTest();};CUIWorkSheet.RedoStabilityTest2=function(){var _Qa=FindApp('main').uiManager.GetCurrentWorkSheet();CUIWorkSheet.oTimeToDate=new Date();_Qa.DoStabilityTest();};CUIWorkSheet.prototype.DoStabilityTest=function(){if(CUIWorkSheet.oTimeToDate.valueOf()<CUIWorkSheet.iTotalTime){this.oLastTime=new Date();this._dO.Refresh();CUIWorkSheet.aDrawTimes.push(new Date().valueOf()-this.oLastTime.valueOf());CUIWorkSheet.aDrawTimes.push('\t');setTimeout(CUIWorkSheet.RedoStabilityTest,100);}else{var _acx=new Date();var _8d=_acx.valueOf()-CUIWorkSheet.oStartTime.valueOf();var _ade=CUIWorkSheet.aDrawTimes.length/2+" Re-draws\nTotal time was "+_8d+" ms\n"+CUIWorkSheet.aDrawTimes.join('');Utilities.DisplaySimpleWindow(_ade,'','',false);}};CUIWorkSheet.prototype.DoStabilityTest2=function(){if(CUIWorkSheet.oTimeToDate.valueOf()<CUIWorkSheet.iTotalTime){this._my.Load("perf2.ans");}else{this.bStabTest=false;var _acx=new Date();var _8d=_acx.valueOf()-CUIWorkSheet.oStartTime.valueOf();var _ade=CUIWorkSheet.aDrawTimes.length/2+" Re-draws\nTotal time was "+_8d+" ms\n"+CUIWorkSheet.aDrawTimes.join('');Utilities.DisplaySimpleWindow(_ade,'','',false);}};CUIWorkSheet.prototype.DoStabilityTest3=function(){if(CUIWorkSheet.iCount<150){this._my.Load("memtest");}else{this.bStabTest3=false;var _acx=new Date();var _8d=_acx.valueOf()-CUIWorkSheet.oStartTime.valueOf();_ade="stab test 3 "+CUIWorkSheet.aDrawTimes.length/2+" Re-draws\nTotal time was "+_8d+" ms\n"+CUIWorkSheet.aDrawTimes.join('');Utilities.DisplaySimpleWindow(_ade,'','',false);}};CUIWorkSheet.prototype.OnRefreshFinish=function(){if(this.bStabTest){var _apa=new Date();CUIWorkSheet.aDrawTimes.push(_apa.valueOf()-CUIWorkSheet.oTimeToDate.valueOf());CUIWorkSheet.aDrawTimes.push('\t');CUIWorkSheet.oTimeToDate=new Date();this.DoStabilityTest2();}else if(this.bStabTest3){var _apa=new Date();CUIWorkSheet.aDrawTimes.push(_apa.valueOf()-CUIWorkSheet.oTimeToDate.valueOf());CUIWorkSheet.aDrawTimes.push('\t');CUIWorkSheet.iCount++;CUIWorkSheet.oTimeToDate=new Date();this.DoStabilityTest3();}};CUIWorkSheet.prototype.DisplayCancel=function(){/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oWSDraw.StartTimer(true);}/*@end@*/if(this.CheckState(CUIWorkSheet.eStateBusy)){Dom.DisplayObject(this._iW,false);Dom.DisplayObject(this._j2,false);Dom.DisplayObject(this._bN,false);Dom.DisplayObject(this._ha,false);Dom.DisplayObject(this._fr,false);Dom.DisplayObject(this._ha,true);}/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oWSDraw.StopTimer(true);}/*@end@*/};CUIWorkSheet.SafeDoCancelRequest=function(_Ke,_ST,_Je){try{var _Qa=FindApp(_Ke).uiManager.GetCurrentWorkSheet();if(_Qa.eState==CUIWorkSheet.eStateBusy){_Qa.CancelRequest(_ST,_Je);}}catch(e){_f.HandleException(e);}};CUIWorkSheet.prototype.CancelRequest=function(_ST,_Je){var _Th=this.oResources.GetString('IDS_WORKKSHEET_REQUEST_CANCELLED');this._m4.appobj.commManager.CancelRequest(this._my,_Th,_ST,_Je);this.onFree();this.Notify(ExpEvent.kCUIWorksheet_Free);};CUIWorkSheet.prototype.DoSetMenuState=function(_MJ,_Ga){var _Ke=this._m4.appobj.appname;var _Li=this.GetDataWorkSheet().GetDataManager().GetCurrentDataMatrix();var _auM=_Li.IsFullDataMode();switch(_MJ){case 'APP_MENUBAR_FILE':for(var i=0;i<_Ga.items.length;i++){switch(_Ga.items[i].id){case 'APP_MENUBAR_NEW':var _56=_Ga.items[i].CreateSubMenu(this._m4.appobj.appname,_Ga._dl+1);var _BM=this.oResources.GetString('APP_MENUBAR_NEW_FROM_DEFAULT');var _AG=new Array(_Ke);var _PM=new ContextItem('',_BM,CUIWorkSheet.SafeDoNewFromDefault,false,_AG,_56);_PM.SetSkipUncomitChangesChecking();_BM=this.oResources.GetString('APP_MENUBAR_NEW_BLANK_CROSSTAB');var _PM=new ContextItem('',_BM,CUIWorkSheet.SafeDoNew,false,_AG,_56);_PM.SetSkipUncomitChangesChecking();_Mt.SetChildrenComplete();_Ga.items[i].SetItemAction(null);break;case 'APP_RUN_MENU_REPORT_STUDIO':var _Vh=(this._m4.dataManager.HasCapability(CDLCapability.K_sCanUseReportStudio)&&this._m4.dataManager.IsSupportedProfile(CDLCapability.K_sProfessional));_Ga.items[i].SetEnabled(_Vh);break;case 'APP_MAIN_MENU_EXIT':var _Vh=(window==window.top);_Ga.items[i].SetEnabled(_Vh);break;}}break;case 'APP_MENUBAR_EDIT':for(var i=0;i<_Ga.items.length;i++){switch(_Ga.items[i].id){case 'APP_MENUBAR_UNDO':_Ga.items[i].SetEnabled(this._my.CanUndo());break;case 'APP_MENUBAR_REDO':_Ga.items[i].SetEnabled(this._my.CanRedo());break;case 'APP_MENUBAR_DELETE':_Ga.items[i].SetEnabled(this._m4.CanDelete());break;case 'APP_MENUBAR_HIDE':_Ga.items[i].SetEnabled(this._dO.CanHide());break;case 'APP_MENUBAR_EXCLUDE':_Ga.items[i].SetEnabled(this._dO.CanExclude());break;}}break;case 'APP_MENUBAR_VIEW':var _af0=_auM&&_Li.IsCompleteExpression();for(var i=0;i<_Ga.items.length;i++){switch(_Ga.items[i].id){case 'APP_VIEW_MENU_OBJECTS_AND_INFO':_Ga.items[i].SetChecked(this._m4.oLeftPaneMenu.IsVisible());break;case 'APP_VIEW_MENU_PROPERTIES_AREA':_Ga.items[i].SetChecked(this._m4.oBlockPropsPane.IsVisible());break;case 'APP_VIEW_MENU_CROSSTAB':_Ga.items[i].SetRadioState(this._ca==CUIWorkSheet.eLayoutXtabOnly);break;case 'APP_VIEW_MENU_CHART':_Ga.items[i].SetRadioState(this._ca==CUIWorkSheet.eLayoutChartOnly);_Ga.items[i].SetEnabled(_af0);break;case 'APP_VIEW_MENU_CROSSTAB_AND_CHART':_Ga.items[i].SetRadioState(this._ca==CUIWorkSheet.eLayoutXtabAndChart);_Ga.items[i].SetEnabled(_af0);break;case 'APP_VIEW_MENU_CHART_TYPE':_Ga.items[i]._o6.Clear();this.AttachChartTypeOptions(_Ga.items[i]._o6);_Ga.items[i].SetEnabled(_af0);break;}}break;case 'APP_MENUBAR_ACTIONS':for(var i=0;i<_Ga.items.length;i++){switch(_Ga.items[i].id){case 'APP_ACTIONS_MENU_INSERT_OPTIONS':var _56=_Ga.items[i]._o6;var _Ss=false;_56.SetAllItemsState(_Ss);for(var _axf=0;_axf<_56.items.length;_axf++){switch(_56.items[_axf].id){case 'APP_ACTIONS_MENU_INSERT_WITH_DETAILS':_56.items[_axf].SetRadioState(this._ab);break;case 'APP_ACTIONS_MENU_INSERT_WO_DETAILS':_56.items[_axf].SetRadioState(!this._ab);break;}}break;case 'APP_MENUBAR_ZERO_SUPPRESSION':CUIContextBar.UpdateZeroSuppressOptions(this._m4.appobj.appname,_Ga.items[i]._o6,this.oContextBar);break;case 'APP_ACTIONS_MENU_SET_DEF_BLOCK_SIZE':_Ga.items[i].SetDisplayFlag(true);break;case 'APP_ACTIONS_MENU_SHOW_WELCOME_DLG':_Ga.items[i].SetChecked(this._m4.appobj.IsWelcomeDialogEnabled());break;}}var _ayQ=_Ga.GetItemById('APP_ACTIONS_MENU_DATA_FORMAT');if(!_ayQ){var _AG=new Array(_Ke);var _2G=this.oResources.GetString('APP_ACTIONS_MENU_DATA_FORMAT');_PM=new ContextItem('',_2G,CUIWorkSheet.SafeDoDataFormatDlg,false,_AG,_Ga,null,true);_PM.id='APP_ACTIONS_MENU_DATA_FORMAT';_PM.AddToParentMenu(_Ga,2);}this._fD=this._my.IsNoDataModeSupported();if(this._fD){var _ahO=_Ga.GetItemById('APP_ACTIONS_MENU_GET_DATA_LATER');if(!_ahO){_aIC=new ContextSeparator(_Ga);_2G=_Co.GetString('APP_ACTIONS_MENU_GET_DATA_LATER');_ahO=new ContextItem('',_2G,null,false,null,_Ga);_ahO.id='APP_ACTIONS_MENU_GET_DATA_LATER';_ahO.SetItemAction(CUIWorkSheet.SafeDoSetDataMode);}var _ai9=new Array(_Li,(_auM?ExpAPIXml.kAttrFasterDataMode:ExpAPIXml.kAttrFullDataMode));_ahO.SetParameterArr(_ai9);_ahO.SetEnabled(this._ca==CUIWorkSheet.eLayoutXtabOnly);_ahO.SetChecked(!_auM);}break;}};CUIWorkSheet.prototype.DisplayDeleteErrorMsg=function(){var _Ku="";if(this.GetUIAxesContainer().HasDataCellSelected&&this.GetUIAxesContainer().HasDataCellSelected()){_Ku=this.oResources.GetString('IDS_DELETE_ERROR_DATA_CELL_SELECTED');}else{if(this.GetSelectedBlock()){_Ku=this.oResources.GetString('IDS_DELETE_ERROR_BLOCK_SELECTED');}else{var _Q1=this.GetUIAxesContainer().GetSelectedAxis();if(_Q1&&_Q1.HasSelection&&_Q1.HasSelection()){var _Xi=_Q1.HasMultipleSelections();if(_Xi){_Ku=this.oResources.GetString('IDS_DELETE_ERROR_MEMBERS_SELECTED_'+_Q1.GetResourceSuffix());}else{_Ku=this.oResources.GetString('IDS_DELETE_ERROR_MEMBER_SELECTED_'+_Q1.GetResourceSuffix());}}else{_Ku=this.oResources.GetString('IDS_DELETE_ERROR_NOTHING_SELECTED');}}}var _ak6=new CUIDeleteErrorMsgBox();_ak6.Init(this._m4.oDialogMgr);_ak6.Display(_Ku);};CUIWorkSheet.AttachRunOptions=function(_DH,_Ke){var _Mg=FindApp(_Ke);var _Co=_Mg.oResources;var _AG=new Array(_Ke,"HTML");_2G=_Co.GetString('APP_RUN_MENU_HTML');_PM=new ContextItem('RunReportHTML.gif',_2G,CUIWorkSheet.SafeRunReport,false,_AG,_DH);_PM.SetSkipUncomitChangesChecking();if(_Mg.uiManager.dataManager.HasCapability(CDLCapability.K_sCanGeneratePDFOutput)){_2G=_Co.GetString('APP_RUN_MENU_PDF');var _AG=new Array(_Ke,"PDF");_PM=new ContextItem('',_2G,CUIWorkSheet.SafeRunReport,false,_AG,_DH);_PM.SetSkipUncomitChangesChecking();}if(_Mg.uiManager.dataManager.HasCapability(CDLCapability.K_sCanGenerateExcelOutput)){_2G=_Co.GetString('APP_RUN_MENU_EXCEL_2007');var _AG=new Array(_Ke,"spreadsheetML");_PM=new ContextItem('',_2G,CUIWorkSheet.SafeRunReport,false,_AG,_DH);_PM.SetSkipUncomitChangesChecking();_2G=_Co.GetString('APP_RUN_MENU_EXCEL_2002');var _AG=new Array(_Ke,"XLWA");_PM=new ContextItem('',_2G,CUIWorkSheet.SafeRunReport,false,_AG,_DH);_PM.SetSkipUncomitChangesChecking();}if(_Mg.uiManager.dataManager.HasCapability(CDLCapability.K_sCanGenerateCSVOutput)){_2G=_Co.GetString('APP_RUN_MENU_CSV');var _AG=new Array(_Ke,"CSV");_PM=new ContextItem('',_2G,CUIWorkSheet.SafeRunReport,false,_AG,_DH);_PM.SetSkipUncomitChangesChecking();}if(_Mg.uiManager.dataManager.HasCapability(CDLCapability.K_sCanGenerateXMLOutput)){_2G=_Co.GetString('APP_RUN_MENU_XML');var _AG=new Array(_Ke,"XML");_PM=new ContextItem('',_2G,CUIWorkSheet.SafeRunReport,false,_AG,_DH);_PM.SetSkipUncomitChangesChecking();}};CUIWorkSheet.UpdateRunOptions=function(_DH,_Ke,_Mg){Utilities.DeleteAllFromArray(_DH.items);var _Mg=FindApp(_Ke);var _Co=_Mg.oResources;var _AG=new Array(_Ke);CUIWorkSheet.AttachRunOptions(_DH,_Ke);_aIC=new ContextSeparator(_DH);_2G=_Co.GetString('APP_RUN_MENU_OPTIONS');_PM=new ContextItem('',_2G,CUIWorkSheet.SafeDoShowReportOptionsDlg,false,_AG,_DH);_PM.id='APP_RUN_MENU_OPTIONS';_PM.SetSkipUncomitChangesChecking();_aIC=new ContextSeparator(_DH);};CUIWorkSheet.prototype.UpdateRunMenu=function(){var _Ke=this._m4.appobj.appname;var _Hv=this._m4.appobj.oResources.GetString('APP_MENUBAR_RUN');var _any=this._m4.oMenuBar.aMenus;for(var i=0;i<_any.length;i++){if(_any[i].sMenuName==_Hv){CUIWorkSheet.UpdateRunOptions(_any[i].oContextMenu,_Ke);break;}}};CUIWorkSheet.SafeDoShowRunMenu=function(e,_Ke,x,y){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.uiManager._jf.DoShowRunMenu(e,_Ke,x,y);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.prototype.DoShowRunMenu=function(e,_Ke,x,y){var _DH=new CUIContextMenu(_Ke,0,this);_DH.SetUnloadOnHide(true);CUIWorkSheet.AttachRunOptions(_DH,_Ke);_DH.display(e,false,x,y);};CUIWorkSheet.SafeDoShowSuppressDropDown=function(e,_Ke,x,y){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.uiManager._jf.DoShowSuppressDropDown(e,_Ke,x,y);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.prototype.DoShowSuppressDropDown=function(e,_Ke,x,y){var _Ox=new CUIContextMenu(_Ke,0,this);_Ox.SetUnloadOnHide(true);this.AttachSuppressOptions(_Ox,_Ke);_Ox.display(e,false,x,y);};CUIWorkSheet.prototype.AttachSuppressOptions=function(_Ox,_Ke){var _Co=this.oResources;var _U9=this._my._ak;var _atJ=_U9._kX;var _QA=this._m4.dataManager.metadata;if(this._my.IsOverallSuppressionEnabled()){var _arX=new Array(_Ke,ExpAPIXml.kNoSuppressionOnRowsOrColumns);_2G=_Co.GetString('IDS_TOOLBAR_NO_ZEROSUPPRESSION');_PM=new ContextItem('',_2G,CUIWorkSheet.SafeChangeZeroSuppression,(_QA._bs==ExpAPIXml.kSuppressionCapabilityNone),_arX,_Ox);_PM.SetSkipUncomitChangesChecking();_PM.SetRadioState(_atJ.GetSuppressionState()==ExpAPIXml.kNoSuppressionOnRowsOrColumns);_arX=new Array(_Ke,ExpAPIXml.kSuppressRowsAndCols);_2G=_Co.GetString('IDS_TOOLBAR_SUPPRESS_ROWSANDCOLS');_PM=new ContextItem('',_2G,CUIWorkSheet.SafeChangeZeroSuppression,(_QA._bs!=ExpAPIXml.kSuppressionCapabilityMultiEdge),_arX,_Ox);_PM.SetSkipUncomitChangesChecking();_PM.SetRadioState(_atJ.GetSuppressionState()==ExpAPIXml.kSuppressRowsAndCols);_arX=new Array(_Ke,ExpAPIXml.kSuppressRowsOnly);_2G=_Co.GetString('IDS_TOOLBAR_SUPPRESS_ROWSONLY');_PM=new ContextItem('',_2G,CUIWorkSheet.SafeChangeZeroSuppression,(_QA._bs==ExpAPIXml.kSuppressionCapabilityNone),_arX,_Ox);_PM.SetSkipUncomitChangesChecking();_PM.SetRadioState(_atJ.GetSuppressionState()==ExpAPIXml.kSuppressRowsOnly);_arX=new Array(_Ke,ExpAPIXml.kSuppressColsOnly);_2G=_Co.GetString('IDS_TOOLBAR_SUPPRESS_COLSONLY');_PM=new ContextItem('',_2G,CUIWorkSheet.SafeChangeZeroSuppression,(_QA._bs==ExpAPIXml.kSuppressionCapabilityNone),_arX,_Ox);_PM.SetSkipUncomitChangesChecking();_PM.SetRadioState(_atJ.GetSuppressionState()==ExpAPIXml.kSuppressColsOnly);var _aIC=new ContextSeparator(_Ox);}if(this._my.IsSparsityRemovalEnabled()){var _awF=this.GetUICrosstab();var _ace=new Array();if(_awF&&this.IsCrosstabVisible()){var _ahh=_awF.IsValidSelectedSuppression(_ace);if(_ahh!=-1&&this._my.IsSparsityRemovalEnabled()){var _2G=(_ahh==0||_ahh==1)?_Co.GetString('IDS_TOOLBAR_SUPPRESS_COLS_OFSELECTION'):_Co.GetString('IDS_TOOLBAR_SUPPRESS_ROWS_OFSELECTION');var _akC=(_ahh==1||_ahh==3);_PM=new ContextItem('',_2G,CUICrosstab.SafeDoSuppression,false,_ace,_Ox);_PM.SetChecked(_akC);if(_akC){_PM.SetItemAction(CUICrosstab.SafeRemoveSuppressionTuples);}else{_PM.SetItemAction(CUICrosstab.SafeDoSuppression);}_PM.SetSkipUncomitChangesChecking();}else{var _2G=_Co.GetString('IDS_TOOLBAR_SUPPRESS_ROWSORCOLS_OFSELECTION');_PM=new ContextItem('',_2G,CUICrosstab.SafeDoSuppression,true,_ace,_Ox);}}_arX=new Array(_Ke);_2G=_Co.GetString('IDS_TOOLBAR_SUPPRESS_CUSTOM');_PM=new ContextItem('',_2G,CUIWorkSheet.SafeCustomizeSuppression,(!this._my.IsSparsityRemovalEnabled()),_arX,_Ox);_PM.SetSkipUncomitChangesChecking();}};CUIWorkSheet.SafeCustomizeSuppression=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.uiManager._jf.CustomizeSuppression();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.prototype.CustomizeSuppression=function(){var _Hy=this._m4.oDialogMgr;var _Qp=this.GetInferredBlock();var _M3=(_Qp==null||!_Qp.IsValidForCustomSuppress());if(!this._iT){this._iT=new CUISuppressionDlg();this._iT.Init(_Hy);}if(!_M3){this._iT.SetHostObj(_Qp);this._iT.Draw();}this._iT.Display(_M3);};CUIWorkSheet.SafeChangeZeroSuppression=function(_Ke,_F5){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.uiManager._jf.ChangeZeroSuppression(_F5);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.prototype.ChangeZeroSuppression=function(_F5){var _U9=this._my._ak;_U9._kX.ChangeZeroSuppression(_F5);};CUIWorkSheet.AttachGoToOptions=function(_Vi,_Ke){var _Mg=FindApp(_Ke);var _Co=_Mg.oResources;var _AG=new Array(_Ke);var _aeM=new Array(_Ke,"false");_2G=_Co.GetString('IDS_TOOLBAR_GOTO_RELATED_CONTENT');_PM=new ContextItem('',_2G,CUIWorkSheet.SafeGoTo,false,_aeM,_Vi);_PM.SetSkipUncomitChangesChecking();_2G=_Co.GetString('IDS_TOOLBAR_GOTO_SEARCH');var _Ss=!_Mg.dataManager.HasCapability(CDLCapability.K_sCanIndexSearch);_PM=new ContextItem('',_2G,CUIWorkSheet.SafeDoDrillThroughSearch,_Ss,_AG,_Vi);_PM.SetSkipUncomitChangesChecking();};CUIWorkSheet.SafeDoShowGoToMenu=function(e,_Ke,x,y){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.uiManager._jf.DoShowGoToMenu(e,_Ke,x,y);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.prototype.DoShowGoToMenu=function(e,_Ke,x,y){var _Vi=new CUIContextMenu(_Ke,0,this);_Vi.SetUnloadOnHide(true);CUIWorkSheet.AttachGoToOptions(_Vi,_Ke);_Vi.display(e,false,x,y);};CUIWorkSheet.SafeDoShowTopBottomDlg=function(_Ke,_RC){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.uiManager._jf.DoShowTopBottomDlg(null,false,_RC);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.prototype.GetSingleMemberSelection=function(){if(this.IsCrosstabVisible()&&this.GetUICrosstab()&&this.GetUICrosstab()._hL){var _Yj=this.GetUICrosstab()._hL;var _VC=_Yj._az;if(_VC.GetUnit()==ExpUserSelection.MemberUnit&&_VC.GetType()==ExpUserSelection.Uniary){return _VC._us[0];}}return null;};CUIWorkSheet.SafeSuppressTuples=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/var _Qa=FindApp(_Ke).uiManager._jf.SuppressTuples();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.prototype.SuppressTuples=function(){var _akV=this.GetSingleMemberSelection();if(!_akV){CUIDialogMgr._jD.SetSeverityType(CUIMessageBox.kInformation);CUIDialogMgr._jD.Display('IDS_WORKSHEET_INFO_SELECT_ROWS_OR_COLUMNS',false,null,_Co.GetString('IDS_WORKSHEET_INFO_TITLE_SUPP_EMPTY_CELLS'));return;}var _0P=true;var _Li=this.GetDataWorkSheet()._ak.GetCurrentDataMatrix();var _Q1=_akV.GetAxis();var _Ib=_Q1.GetDLAxis();var _0z=this.GetUICrosstab().GetOppositeAxis(_Q1).GetDLAxis();var _S6=null;if(!_Li.HasMeasure()){_0P=false;}else{_S6=_Ib.GetSelectedSuppressionTuple(_akV.GetMemberPos(),_akV.GetDepth(),true,CDLAxisMember.CanBeUsedInSuppression);if(!_S6){_0P=false;}}if(_0P){if(_akV.GetSuppressionID()){var _UH=new Array();_UH.push(_akV.GetSuppressionID());this.GetUICrosstab().RemoveSuppressionTuples(_0z,_UH);}else{this.GetUICrosstab().Suppress(_Ib,_S6);}}else{CUIDialogMgr._jD.SetSeverityType(CUIMessageBox.kInformation);CUIDialogMgr._jD.Display('IDS_WORKSHEET_INFO_SUPP_WARNING',false,null,_Co.GetString('IDS_WORKSHEET_INFO_TITLE_SUPP_EMPTY_CELLS'));}};CUIWorkSheet.SafeDoShowTopBottomDropDown=function(e,_Ke,x,y){/*@if(!@bering_debug)@*/try{/*@end@*/var _Qa=FindApp(_Ke).uiManager._jf;_Qa.DoShowTopBottomDropDown(e,_Ke,x,y);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.prototype.DoShowTopBottomDropDown=function(e,_Ke,x,y){var _Qa=FindApp(_Ke).uiManager._jf;var _Qp=_Qa.GetInferredBlock();if(_Qp&&_Qp.CanApplyTopBottom()){if(!this._oX){this._oX=new CUIContextMenu(_Ke,0,this);CUIWorkSheet.AttachTopBottomMenuItems(_Ke,this.oResources,this._oX);}CUIWorkSheet.UpdateTopBottomMenuItems(this.oResources,this._oX,_Ke,_Qp);this._oX.display(e,false,x,y);}else{_M3=true;this.DoShowTopBottomDlg(null,_M3);}};CUIWorkSheet.AttachTopBottomMenuItems=function(_Ke,_Co,_Ga){var sMenuLable,_AG,_PM,oItemTop,oItemBottom,oSubMenuTop,oSubMenuBottom,oSubItem1,oSubItem2,oSubItem3;var _akT=false;sMenuLable=_Co.GetString('IDS_TOOLBAR_TOPBOTTOM_MENU_NONE');_AG=new Array(_Ke,"",-1);_PM=new ContextItem(null,sMenuLable,CUIWorkSheet.SafeRunTopBottom,false,_AG,_Ga);_PM.SetFunctionId(CUIWorkSheet.ksTopBottomNoneId);sMenuLable=_Co.GetString('IDS_TOOLBAR_TOPBOTTOM_MENU_ITEM_TOP');oItemTop=new ContextItem(null,sMenuLable,null,_akT,null,_Ga);oItemTop.SetFunctionId(ExpAPIXml.kFLSortTop);oSubMenuTop=oItemTop.CreateSubMenu(_Ke,_Ga._dl+1);oSubMenuTop.SetChildrenComplete();_AG=new Array(_Ke,ExpAPIXml.kFLSortTop,CUIWorkSheet.kiTopBottomDefault1);oSubItem1=new ContextItem(null,CUIWorkSheet.kiTopBottomDefault1,CUIWorkSheet.SafeRunTopBottom,_akT,_AG,oSubMenuTop);oSubItem1.SetFunctionId(CUIWorkSheet.kiTopBottomDefault1);_AG=new Array(_Ke,ExpAPIXml.kFLSortTop,CUIWorkSheet.kiTopBottomDefault2);oSubItem2=new ContextItem(null,CUIWorkSheet.kiTopBottomDefault2,CUIWorkSheet.SafeRunTopBottom,_akT,_AG,oSubMenuTop);oSubItem2.SetFunctionId(CUIWorkSheet.kiTopBottomDefault2);_AG=new Array(_Ke,ExpAPIXml.kFLSortTop,CUIWorkSheet.kiTopBottomDefault3);oSubItem3=new ContextItem(null,CUIWorkSheet.kiTopBottomDefault3,CUIWorkSheet.SafeRunTopBottom,_akT,_AG,oSubMenuTop);oSubItem3.SetFunctionId(CUIWorkSheet.kiTopBottomDefault3);sMenuLable=_Co.GetString('IDS_TOOLBAR_TOPBOTTOM_MENU_CUSTOM');_AG=new Array(_Ke,ExpAPIXml.kFLSortTop);_PM=new ContextItem('',sMenuLable,CUIWorkSheet.SafeDoShowTopBottomDlg,false,_AG,oSubMenuTop);_PM.SetFunctionId(CUIWorkSheet.ksTopBottomCustomId);sMenuLable=_Co.GetString('IDS_TOOLBAR_TOPBOTTOM_MENU_ITEM_BOTTOM');oItemBottom=new ContextItem(null,sMenuLable,null,_akT,null,_Ga);oItemBottom.SetFunctionId(ExpAPIXml.kFLSortBottom);oSubMenuBottom=oItemBottom.CreateSubMenu(_Ke,_Ga._dl+1);oSubMenuBottom.SetChildrenComplete();_AG=new Array(_Ke,ExpAPIXml.kFLSortBottom,CUIWorkSheet.kiTopBottomDefault1);oSubItem1=new ContextItem(null,CUIWorkSheet.kiTopBottomDefault1,CUIWorkSheet.SafeRunTopBottom,_akT,_AG,oSubMenuBottom);oSubItem1.SetFunctionId(CUIWorkSheet.kiTopBottomDefault1);_AG=new Array(_Ke,ExpAPIXml.kFLSortBottom,CUIWorkSheet.kiTopBottomDefault2);oSubItem2=new ContextItem(null,CUIWorkSheet.kiTopBottomDefault2,CUIWorkSheet.SafeRunTopBottom,_akT,_AG,oSubMenuBottom);oSubItem2.SetFunctionId(CUIWorkSheet.kiTopBottomDefault2);_AG=new Array(_Ke,ExpAPIXml.kFLSortBottom,CUIWorkSheet.kiTopBottomDefault3);oSubItem3=new ContextItem(null,CUIWorkSheet.kiTopBottomDefault3,CUIWorkSheet.SafeRunTopBottom,_akT,_AG,oSubMenuBottom);oSubItem3.SetFunctionId(CUIWorkSheet.kiTopBottomDefault3);sMenuLable=_Co.GetString('IDS_TOOLBAR_TOPBOTTOM_MENU_CUSTOM');_AG=new Array(_Ke,ExpAPIXml.kFLSortBottom);_PM=new ContextItem('',sMenuLable,CUIWorkSheet.SafeDoShowTopBottomDlg,false,_AG,oSubMenuBottom);_PM.SetFunctionId(CUIWorkSheet.ksTopBottomCustomId);return _Ga;};CUIWorkSheet.UpdateTopBottomMenuItems=function(_Co,_Ga,_Ke,_FK){var _3G=((_FK.oAxis._rk.GetCurrentMeasure()!=null)&&_FK.oAxis._rk.GetCurrentMeasure());var _RC="";var _Ql=0;if(_FK&&_FK.HasTopBottomRule()){if(_FK.GetSubset()){_RC=_FK.GetSubset()._aK;if(_FK.GetSubset().IsDefaultSortMeasure()&&_FK.GetSubset().IsDefaultSortMember()){if((_3G&&_FK.GetSubset()._sf==ExpAPIXml.eSubsetTypeInteger)){_Ql=_FK.GetSubset()._uj;}}else{_3G=false;}}}for(var i=0;i<_Ga.items.length;i++){var _PM=_Ga.items[i];_PM.SetRadioState((_PM.GetFunctionId()==CUIWorkSheet.ksTopBottomNoneId&&_RC=="")||(_PM.GetFunctionId()==_RC));if(_PM._o6){var _agt=_PM._o6.items;for(var j=0;j<_agt.length;j++){var _apL=_agt[j];if(j<_agt.length-1){_apL.SetRadioState(_3G&&_PM.GetFunctionId()==_RC&&_apL.GetFunctionId()==_Ql);_apL.SetEnabled(_3G);}else{_apL.SetRadioState(((!_3G)&&_PM.GetFunctionId()==_RC)||(_PM.GetFunctionId()==_RC&&_Ql!=CUIWorkSheet.kiTopBottomDefault1&&_Ql!=CUIWorkSheet.kiTopBottomDefault2&&_Ql!=CUIWorkSheet.kiTopBottomDefault3));}}}}};CUIWorkSheet.SafeRunTopBottom=function(_Ke,_U1,_Rc){/*@if(!@bering_debug)@*/try{/*@end@*/var _Qa=FindApp(_Ke).uiManager._jf;var _Qp=_Qa.GetInferredBlock();_Qa.RunTopBottom(_Ke,_Qp,_U1,_Rc);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.prototype.RunTopBottom=function(_Ke,_Qp,_U1,_Rc){var _azM=DefaultConstants.kDefMeasure;var _alw=new Array(DefaultConstants.kDefScope);var _Dk=ExpAPIXml.eSubsetTypeInteger;var _SA=new CDLFilterExpr(this._my._ak);_SA.SetTopBottom(_Rc,_U1,_azM,_alw,_Dk);this._m4._jf.SetLastBlockSelectionId(_Qp.GetId());_Qp.SetProperty(ExpAPIXml.kEleSubset,_SA);};CUIWorkSheet.SafeDoOpenCustomSetDlgWithInferringRule=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/var _Qa=FindApp(_Ke).uiManager._jf;_Qa.GetUICrosstab().DoAddCustomSet();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.prototype.DoShowTopBottomDlg=function(_FK,_M3,_RC){if(!this.oTopBottomDlg){this.oTopBottomDlg=new CUITopBottomDlg();this.oTopBottomDlg.Init(this._m4.oDialogMgr);}if(_M3){this.oTopBottomDlg.Display(_M3);}else{var _Qp=_FK?_FK:this.GetSelectedBlock();if(!_Qp||!(_Qp.CanApplyTopBottom())){var _M3=true;this.oTopBottomDlg.Display(_M3);}else{this.oTopBottomDlg.Display();this.oTopBottomDlg.SetHostObj(_Qp,_RC);}}};CUIWorkSheet.SafeDoShowReportOptionsDlg=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.uiManager._jf.DoShowReportOptionsDlg();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.prototype.DoShowReportOptionsDlg=function(){if(this._m4.ConfirmLossOfChanges()==Utilities.eStateContinue){if(!this.oReportOptionsDlg){this.oReportOptionsDlg=new CUIReportOptionsDlg();this.oReportOptionsDlg.Init(this._m4.oDialogMgr);}this.oReportOptionsDlg.SetHostObj(this._my._ak._kX);this.oReportOptionsDlg.Display();}else{var _axQ=Dom.CloneMouseEvent(e);var _Ro=new Array(this._m4.GetAppName());Utilities.SetProcedureToHold(CUIWorkSheet.SafeDoShowReportOptionsDlg,_Ro);this._m4.oDialogMgr.Subscribe(this,ExpEvent.kCUIDialogMgr_HideModalDialog);}};CUIWorkSheet.SafeDoExit=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.uiManager._jf.DoExit();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.prototype.DoExit=function(){window.close();};CUIWorkSheet.prototype.DoSave=function(_Vf){if(!this._my.SaveCurrent(_Vf)){this.DoSaveAs(_Vf);}};CUIWorkSheet.prototype.DoSaveAs=function(_Vf){var _TO=true;if(!this.oSaveDlg){this.oSaveDlg=new CUISaveDlg();}if(!this.oSaveDlg._mT){this.oSaveDlg.Init(this._m4.oDialogMgr,_Vf);_TO=false;}if(this.oSaveDlg._mT){this.oSaveDlg.Display(_TO,_Vf,true);}};CUIWorkSheet.SafeDoContinueDoLoad=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager._jf.ContinueDoLoad();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.prototype.ContinueDoLoad=function(){var _TO=true;if(!this.oOpenDlg){this.oOpenDlg=new CUIOpenDlg();}if(!this.oOpenDlg._mT){this.oOpenDlg.Init(this._m4.oDialogMgr);_TO=false;}if(this.oOpenDlg._mT){this.oOpenDlg.Display(_TO);}};CUIWorkSheet.prototype.DoLoad=function(){var _Ke=this._m4.appobj.appname;if(this.HasUnSavedChanges()){var _as9=Utilities.GenerateCallback(CUIDialogMgr.SafeHideCurrentDialog,[_Ke]);var _0d=Utilities.GenerateCallback(CUIWorkSheet.SafeDoSave,[_Ke]);var _ana=Utilities.GenerateCallback(CUIWorkSheet.SafeDoContinueDoLoad,[_Ke]);var _aAS=Utilities.GenerateCallbackUnion([_as9,_0d]);var _aAo=Utilities.GenerateCallbackUnion([_as9,_ana]);CUIDialogMgr._cw.SetCallBackFuntion(_aAS,_aAo);CUIDialogMgr._cw.Display('IDS_WORKKSHEET_CONFIRM_LOAD','',CUIConfirmDlg._hw);}else{CUIWorkSheet.SafeDoContinueDoLoad(_Ke);}};CUIWorkSheet.SafeDoContinueDoNew=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager._jf.ResetDisplayType();FindApp(_Ke).uiManager._jf._my.DoNew();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.prototype.HasUnSavedChanges=function(){return(this._my.IsDirty());};CUIWorkSheet.prototype.DoNew=function(){var _Ke=this._m4.appobj.appname;if(this.HasUnSavedChanges()){var _as9=Utilities.GenerateCallback(CUIDialogMgr.SafeHideCurrentDialog,[_Ke]);var _0d=Utilities.GenerateCallback(CUIWorkSheet.SafeDoSave,[_Ke,true]);var _aru=Utilities.GenerateCallback(CUIWorkSheet.SafeDoContinueDoNew,[_Ke]);var _aAS=Utilities.GenerateCallbackUnion([_as9,_0d]);var _aAo=Utilities.GenerateCallbackUnion([_as9,_aru]);CUIDialogMgr._cw.SetCallBackFuntion(_aAS,_aAo);CUIDialogMgr._cw.Display('IDS_WORKKSHEET_CONFIRM_NEW','',CUIConfirmDlg._hw);}else{CUIWorkSheet.SafeDoContinueDoNew(_Ke);}};CUIWorkSheet.prototype.DoNewFromDefault=function(){var _Ke=this._m4.appobj.appname;if(this.HasUnSavedChanges()){var _as9=Utilities.GenerateCallback(CUIDialogMgr.SafeHideCurrentDialog,[_Ke]);var _0d=Utilities.GenerateCallback(CUIWorkSheet.SafeDoSave,[_Ke,true]);var _aru=Utilities.GenerateCallback(CUIWorkSheet.SafeDoContinueDoNewFromDefault,[_Ke]);var _aAS=Utilities.GenerateCallbackUnion([_as9,_0d]);var _aAo=Utilities.GenerateCallbackUnion([_aru,_as9]);CUIDialogMgr._cw.SetCallBackFuntion(_aAS,_aAo);CUIDialogMgr._cw.Display('IDS_WORKKSHEET_CONFIRM_NEW','',CUIConfirmDlg._hw);}else{CUIWorkSheet.SafeDoContinueDoNewFromDefault(_Ke);}};CUIWorkSheet.SafeDoContinueDoNewFromDefault=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager._jf.ResetDisplayType();FindApp(_Ke).uiManager._jf._my.DoNewFromDefault();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.prototype.DoUndo=function(){this._my.Undo();};CUIWorkSheet.prototype.DoRedo=function(){this._my.Redo();};CUIWorkSheet.SafeDoSave=function(_Ke,_Vf){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.uiManager._jf.DoSave(_Vf);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.SafeDoSaveAs=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.uiManager._jf.DoSaveAs();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.SafeDoLoad=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.uiManager._jf.DoLoad();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.SafeRunReport=function(_Ke,_Wo){try{var _Mg=FindApp(_Ke);_Mg.SetRunType(_Wo);_Mg.uiManager._jf.GetReport();}catch(e){_f.HandleException(e);}};CUIWorkSheet.SafeGoTo=function(_Ke,_Pc){try{var _Mg=FindApp(_Ke);_Mg.DrillThrough(_Pc);}catch(e){_f.HandleException(e);}};CUIWorkSheet.SafeDoDrillThroughSearch=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.DrillThroughSearch();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.SafeEditReport=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.uiManager._jf.EditReport();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.prototype.GetReport=function(){this._my.GetReport();};CUIWorkSheet.SafeGetHLS=function(_Ke,_zE){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.uiManager._jf.GetHLS(_zE);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.prototype.GetHLS=function(_zE){this._my.GetHLS(_zE);};CUIWorkSheet.prototype.EditReport=function(){this._my.EditReport();};CUIWorkSheet.SafeDoNew=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.UpdateDefaultAnalysis(DefaultAnalysis.kBlank);_Mg.uiManager._jf.DoNew();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.SafeDoNewFromDefault=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.UpdateDefaultAnalysis(DefaultAnalysis.kServerDefault);_Mg.uiManager._jf.DoNewFromDefault();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.SafeDoNewToolBar=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);if(_Mg.HasDefaultAnalysis()){_Mg.uiManager._jf.DoNewFromDefault();}else{_Mg.uiManager._jf.DoNew();}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.SafeDoUndo=function(_Ke){try{var _Mg=FindApp(_Ke);if(_Mg.uiManager._jf._my.CanUndo()){_Mg.uiManager._jf.DoUndo();}}catch(e){_f.HandleException(e);}};CUIWorkSheet.SafeDoRedo=function(_Ke){try{var _Mg=FindApp(_Ke);if(_Mg.uiManager._jf._my.CanRedo()){_Mg.uiManager._jf.DoRedo();}}catch(e){_f.HandleException(e);}};CUIWorkSheet.SafeShowDescriptiveStatisticsDropDown=function(e,_Ke,x,y,_AO){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager._jf.ShowDescriptiveStatisticsDropDown(e,x,y,_AO);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.SafeShowChartTypeDropDown=function(e,_Ke,x,y,_AO){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager._jf.ShowChartTypeDropDown(e,x,y,_AO);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.prototype.ShowDescriptiveStatisticsDropDown=function(e,x,y){var _Kk=new CUIContextMenu(this._m4.appobj.appname,0,this,null,false);_Kk.SetUnloadOnHide(true);this.AttachDescriptiveStatisticsOptions(_Kk);_Kk.display(e,false,x,y);};CUIWorkSheet.prototype.AttachDescriptiveStatisticsOptions=function(_Kk){var _aEJ=this.GetDataWorkSheet().GetDataManager().GetDescriptiveStatsObj().GetCommandsList();var _Ke=this._m4.appobj.appname;var _Mj=true;for(var i=0;i<_aEJ.length;i++){var _BM=_aEJ[i].label;var _Gm=_aEJ[i].icon;var _KW=new Object();_KW[ExpAPIXml.kStatsLabel]=_aEJ[i].name;_KW[ExpAPIXml.kStatsIndex]=i;var _Ro=new Array(_Ke,_BM,_KW);var _02=new ContextItem(_Gm,_BM,CUIWorkSheet.SafeInsertDescriptiveStats,!_Mj,_Ro,_Kk);}};CUIWorkSheet.prototype.ShowChartTypeDropDown=function(e,x,y){var _Kk=new CUIContextMenu(this._m4.appobj.appname,0,this,null,false);_Kk.SetUnloadOnHide(true);this.AttachChartTypeOptions(_Kk);_Kk.display(e,false,x,y);};CUIWorkSheet.prototype.AttachChartTypeOptions=function(_Kk){var _Ke=this._m4.appobj.appname;var _Li=this.GetDataWorkSheet().GetDataManager().GetCurrentDataMatrix();var _Mj=_Li.IsFullDataMode()&&_Li.IsCompleteExpression();var _BM=this.oResources.GetString('APP_TOOLBAR_COLUMN_CHART');var _02=new ContextItem('chart_icon_column_cluster_flat.gif',_BM,null,!_Mj,null,_Kk);var _adi=this._gg&&this._gg.GetChartType()==ExpAPIXml.eChartTypeColumn;var _alc=this._gg&&this._gg.GetChartType()==ExpAPIXml.eChartType3DBar;_02.SetRadioState(_adi||_alc);var _aqX=_02.CreateSubMenu(_Ke,_Kk._dl+1);var _KW=new Object();_KW[ExpAPIXml.kEleChartIs3D]=this._wy;_KW[ExpAPIXml.kEleChartIsStacked]=false;_KW[ExpAPIXml.kEleChartIsStacked100Percent]=false;var _5E=new Array(_Ke,ExpAPIXml.eChartTypeColumn,_KW);_BM=this.oResources.GetString('APP_TOOLBAR_COLUMN_CHART_STAN');var _aCO=new ContextItem('',_BM,CUIWorkSheet.SafeSetChartType,!_Mj,_5E,_aqX);_KW=new Object();_KW[ExpAPIXml.kEleChartIsStacked]=true;_KW[ExpAPIXml.kEleChartIsStacked100Percent]=false;_KW[ExpAPIXml.kEleChartIs3D]=this._wy;var _5E=new Array(_Ke,ExpAPIXml.eChartTypeColumn,_KW);_BM=this.oResources.GetString('APP_TOOLBAR_COLUMN_CHART_STACKED');var _8b=new ContextItem('',_BM,CUIWorkSheet.SafeSetChartType,!_Mj,_5E,_aqX);_KW=new Object();_KW[ExpAPIXml.kEleChartIsStacked]=false;_KW[ExpAPIXml.kEleChartIsStacked100Percent]=true;_KW[ExpAPIXml.kEleChartIs3D]=this._wy;var _5E=new Array(_Ke,ExpAPIXml.eChartTypeColumn,_KW);_BM=this.oResources.GetString('APP_TOOLBAR_COLUMN_CHART_STACKED100PERCENT');var _ayl=new ContextItem('',_BM,CUIWorkSheet.SafeSetChartType,!_Mj,_5E,_aqX);var _aib=_adi&&this._gg.IsStacked100Percent();_ayl.SetRadioState(_aib);var _aEM=_adi&&this._gg.IsStacked();_8b.SetRadioState(_aEM);_aCO.SetRadioState(_adi&&!_aEM&&!_aib);var _arR=new Array(this._m4.appobj.appname,ExpAPIXml.eChartType3DBar);_BM=this.oResources.GetString('APP_TOOLBAR_COLUMN_CHART_3D_AXIS');var _aDF=new ContextItem('',_BM,CUIWorkSheet.SafeSetChartType,!_Mj,_arR,_aqX);_aDF.SetRadioState(_alc);var _aIC=new ContextSeparator(_aqX);_KW=new Object();_KW[ExpAPIXml.kEleChartIsStacked]=_aEM;_KW[ExpAPIXml.kEleChartIsStacked100Percent]=_aib;var _Hx=ExpAPIXml.eChartTypeColumn;if(_alc){_Hx=ExpAPIXml.eChartType3DBar;}var _aCS=new Array(this._m4.appobj.appname,_Hx,_KW);_BM=this.oResources.GetString('APP_TOOLBAR_COLUMN_CHART_3D');var _amL=new ContextItem('',_BM,CUIWorkSheet.SafeSetChartThreeDEffect,!_Mj,_aCS,_aqX);_amL.SetChecked(this._wy);_BM=this.oResources.GetString('APP_TOOLBAR_BAR_CHART');var _3p=new ContextItem('chart_icon_bar_cluster_flat.gif',_BM,null,!_Mj,null,_Kk);var _aHK=this._gg&&this._gg.GetChartType()==ExpAPIXml.eChartTypeBar;_3p.SetRadioState(_aHK);var _2B=_3p.CreateSubMenu(this._m4.appobj.appname,_Kk._dl+1);var _KW=new Object();_KW[ExpAPIXml.kEleChartIs3D]=this._wy;_KW[ExpAPIXml.kEleChartIsStacked]=false;_KW[ExpAPIXml.kEleChartIsStacked100Percent]=false;var _5E=new Array(this._m4.appobj.appname,ExpAPIXml.eChartTypeBar,_KW);_BM=this.oResources.GetString('APP_TOOLBAR_BAR_CHART_STAN');var _aCO=new ContextItem('',_BM,CUIWorkSheet.SafeSetChartType,!_Mj,_5E,_2B);_KW=new Object();_KW[ExpAPIXml.kEleChartIsStacked]=true;_KW[ExpAPIXml.kEleChartIsStacked100Percent]=false;_KW[ExpAPIXml.kEleChartIs3D]=this._wy;var _5E=new Array(this._m4.appobj.appname,ExpAPIXml.eChartTypeBar,_KW);_BM=this.oResources.GetString('APP_TOOLBAR_BAR_CHART_STACKED');var _8b=new ContextItem('',_BM,CUIWorkSheet.SafeSetChartType,!_Mj,_5E,_2B);_KW=new Object();_KW[ExpAPIXml.kEleChartIsStacked]=false;_KW[ExpAPIXml.kEleChartIsStacked100Percent]=true;_KW[ExpAPIXml.kEleChartIs3D]=this._wy;var _5E=new Array(this._m4.appobj.appname,ExpAPIXml.eChartTypeBar,_KW);_BM=this.oResources.GetString('APP_TOOLBAR_BAR_CHART_STACKED100PERCENT');var _ayl=new ContextItem('',_BM,CUIWorkSheet.SafeSetChartType,!_Mj,_5E,_2B);var _aEM=_aHK&&this._gg.IsStacked();var _aib=_aHK&&this._gg.IsStacked100Percent();_8b.SetRadioState(_aEM);_ayl.SetRadioState(_aib);_aCO.SetRadioState(_aHK&&!_aEM&&!_aib);var _aIC=new ContextSeparator(_2B);_KW=new Object();_KW[ExpAPIXml.kEleChartIsStacked]=_aEM;_KW[ExpAPIXml.kEleChartIsStacked100Percent]=_aib;var _aCS=new Array(this._m4.appobj.appname,ExpAPIXml.eChartTypeBar,_KW);_BM=this.oResources.GetString('APP_TOOLBAR_BAR_CHART_3D');var _1r=new ContextItem('',_BM,CUIWorkSheet.SafeSetChartThreeDEffect,!_Mj,_aCS,_2B);_1r.SetChecked(this._wy);_BM=this.oResources.GetString('APP_TOOLBAR_PIE_CHART');var _avM=new ContextItem('chart_icon_pie_flat.gif',_BM,null,!_Mj,null,_Kk);var _0m=this._gg&&this._gg.GetChartType()==ExpAPIXml.eChartTypePie;_avM.SetRadioState(_0m);var _7b=_avM.CreateSubMenu(this._m4.appobj.appname,_Kk._dl+1);var _KW=new Object();_KW[ExpAPIXml.kEleChartIs3D]=this._wy;var _ako=new Array(this._m4.appobj.appname,ExpAPIXml.eChartTypePie,_KW);_BM=this.oResources.GetString('APP_TOOLBAR_PIE_CHART_STAN');var _aCO=new ContextItem('',_BM,CUIWorkSheet.SafeSetChartType,!_Mj,_ako,_7b);_aCO.SetRadioState(_0m);var _aIC=new ContextSeparator(_7b);var _4b=new Array(this._m4.appobj.appname);_BM=this.oResources.GetString('APP_TOOLBAR_PIE_CHART_VALUES_AS_PERCENT');var _2k=new ContextItem('',_BM,CUIWorkSheet.SafeShowValuesAsPercent,!_Mj,_4b,_7b);_2k.SetChecked(this._fb);_KW=new Object();var _aCS=new Array(this._m4.appobj.appname,ExpAPIXml.eChartTypePie,_KW);_BM=this.oResources.GetString('APP_TOOLBAR_PIE_CHART_3D');var _axF=new ContextItem('',_BM,CUIWorkSheet.SafeSetChartThreeDEffect,!_Mj,_aCS,_7b);_axF.SetChecked(this._wy);_BM=this.oResources.GetString('APP_TOOLBAR_LINE_CHART');var _aim=new ContextItem('chart_icon_line_cluster_flat.gif',_BM,null,!_Mj,null,_Kk);var _azH=this._gg&&this._gg.GetChartType()==ExpAPIXml.eChartTypeLine;var _aai=this._gg&&this._gg.GetChartType()==ExpAPIXml.eChartType3DLine;_aim.SetRadioState(_azH||_aai);var _ar9=_aim.CreateSubMenu(this._m4.appobj.appname,_Kk._dl+1);var _KW=new Object();_KW[ExpAPIXml.kEleChartIs3D]=this._wy;_KW[ExpAPIXml.kEleChartIsStacked]=false;_KW[ExpAPIXml.kEleChartIsStacked100Percent]=false;var _5E=new Array(this._m4.appobj.appname,ExpAPIXml.eChartTypeLine,_KW);_BM=this.oResources.GetString('APP_TOOLBAR_LINE_CHART_STAN');var _aCO=new ContextItem('',_BM,CUIWorkSheet.SafeSetChartType,!_Mj,_5E,_ar9);_KW=new Object();_KW[ExpAPIXml.kEleChartIsStacked]=true;_KW[ExpAPIXml.kEleChartIsStacked100Percent]=false;_KW[ExpAPIXml.kEleChartIs3D]=this._wy;var _5E=new Array(this._m4.appobj.appname,ExpAPIXml.eChartTypeLine,_KW);_BM=this.oResources.GetString('APP_TOOLBAR_LINE_CHART_STACKED');var _8b=new ContextItem('',_BM,CUIWorkSheet.SafeSetChartType,!_Mj,_5E,_ar9);_KW=new Object();_KW[ExpAPIXml.kEleChartIsStacked]=false;_KW[ExpAPIXml.kEleChartIsStacked100Percent]=true;_KW[ExpAPIXml.kEleChartIs3D]=this._wy;var _5E=new Array(this._m4.appobj.appname,ExpAPIXml.eChartTypeLine,_KW);_BM=this.oResources.GetString('APP_TOOLBAR_LINE_CHART_STACKED100PERCENT');var _ayl=new ContextItem('',_BM,CUIWorkSheet.SafeSetChartType,!_Mj,_5E,_ar9);var _aus=new Array(this._m4.appobj.appname,ExpAPIXml.eChartType3DLine);_BM=this.oResources.GetString('APP_TOOLBAR_LINE_CHART_3D_AXIS');var _asc=new ContextItem('',_BM,CUIWorkSheet.SafeSetChartType,!_Mj,_aus,_ar9);_asc.SetRadioState(_aai);var _aEM=_azH&&this._gg.IsStacked();_8b.SetRadioState(_aEM);var _aib=_azH&&this._gg.IsStacked100Percent();_ayl.SetRadioState(_aib);_aCO.SetRadioState(_azH&&!_aEM&&!_aib);var _aIC=new ContextSeparator(_ar9);_KW=new Object();_KW[ExpAPIXml.kEleChartIsStacked]=_aEM;_KW[ExpAPIXml.kEleChartIsStacked100Percent]=_aib;var _aHD=ExpAPIXml.eChartTypeLine;if(_aai){_aHD=ExpAPIXml.eChartType3DLine;}var _aCS=new Array(this._m4.appobj.appname,_aHD,_KW);_BM=this.oResources.GetString('APP_TOOLBAR_LINE_CHART_3D');var _acK=new ContextItem('',_BM,CUIWorkSheet.SafeSetChartThreeDEffect,!_Mj,_aCS,_ar9);_acK.SetChecked(this._wy);_BM=this.oResources.GetString('APP_TOOLBAR_PARETO_CHART');var _alP=new ContextItem('chart_icon_pareto_flat.gif',_BM,null,!_Mj,null,_Kk);var _ayP=this._gg&&this._gg.GetChartType()==ExpAPIXml.eChartTypePareto;_alP.SetRadioState(_ayP);var _aau=_alP.CreateSubMenu(this._m4.appobj.appname,_Kk._dl+1);var _KW=new Object();_KW[ExpAPIXml.kEleChartIs3D]=this._wy;var _5E=new Array(this._m4.appobj.appname,ExpAPIXml.eChartTypePareto,_KW);_BM=this.oResources.GetString('APP_TOOLBAR_PARETO_CHART_STAN');var _aCO=new ContextItem('',_BM,CUIWorkSheet.SafeSetChartType,!_Mj,_5E,_aau);_aCO.SetRadioState(_ayP);var _aIC=new ContextSeparator(_aau);_KW=new Object();_KW[ExpAPIXml.kEleChartIsStacked]=_aEM;_KW[ExpAPIXml.kEleChartIsStacked100Percent]=_aib;var _aCS=new Array(this._m4.appobj.appname,ExpAPIXml.eChartTypePareto,_KW);_BM=this.oResources.GetString('APP_TOOLBAR_PARETO_CHART_3D');var _adt=new ContextItem('',_BM,CUIWorkSheet.SafeSetChartThreeDEffect,!_Mj,_aCS,_aau);_adt.SetChecked(this._wy);_BM=this.oResources.GetString('APP_TOOLBAR_AREA_CHART');var _apK=new ContextItem('chart_icon_area_cluster_flat.gif',_BM,null,!_Mj,null,_Kk);var _7p=this._gg&&this._gg.GetChartType()==ExpAPIXml.eChartTypeArea;var _al5=this._gg&&this._gg.GetChartType()==ExpAPIXml.eChartType3DArea;_apK.SetRadioState(_7p||_al5);var _aeD=_apK.CreateSubMenu(this._m4.appobj.appname,_Kk._dl+1);var _KW=new Object();_KW[ExpAPIXml.kEleChartIs3D]=this._wy;_KW[ExpAPIXml.kEleChartIsStacked]=false;_KW[ExpAPIXml.kEleChartIsStacked100Percent]=false;var _5E=new Array(this._m4.appobj.appname,ExpAPIXml.eChartTypeArea,_KW);_BM=this.oResources.GetString('APP_TOOLBAR_AREA_CHART_STAN');var _aCO=new ContextItem('',_BM,CUIWorkSheet.SafeSetChartType,!_Mj,_5E,_aeD);_KW=new Object();_KW[ExpAPIXml.kEleChartIsStacked]=true;_KW[ExpAPIXml.kEleChartIsStacked100Percent]=false;_KW[ExpAPIXml.kEleChartIs3D]=this._wy;var _5E=new Array(this._m4.appobj.appname,ExpAPIXml.eChartTypeArea,_KW);_BM=this.oResources.GetString('APP_TOOLBAR_AREA_CHART_STACKED');var _8b=new ContextItem('',_BM,CUIWorkSheet.SafeSetChartType,!_Mj,_5E,_aeD);_KW=new Object();_KW[ExpAPIXml.kEleChartIsStacked]=false;_KW[ExpAPIXml.kEleChartIsStacked100Percent]=true;_KW[ExpAPIXml.kEleChartIs3D]=this._wy;var _5E=new Array(this._m4.appobj.appname,ExpAPIXml.eChartTypeArea,_KW);_BM=this.oResources.GetString('APP_TOOLBAR_AREA_CHART_STACKED100PERCENT');var _ayl=new ContextItem('',_BM,CUIWorkSheet.SafeSetChartType,!_Mj,_5E,_aeD);var _abT=new Array(this._m4.appobj.appname,ExpAPIXml.eChartType3DArea);_BM=this.oResources.GetString('APP_TOOLBAR_AREA_CHART_3D_AXIS');var _azK=new ContextItem('',_BM,CUIWorkSheet.SafeSetChartType,!_Mj,_abT,_aeD);_azK.SetRadioState(_al5);var _aEM=_7p&&this._gg.IsStacked();_8b.SetRadioState(_aEM);var _aib=_7p&&this._gg.IsStacked100Percent();_ayl.SetRadioState(_aib);_aCO.SetRadioState(_7p&&!_aEM&&!_aib);var _aIC=new ContextSeparator(_aeD);_KW=new Object();_KW[ExpAPIXml.kEleChartIsStacked]=_aEM;_KW[ExpAPIXml.kEleChartIsStacked100Percent]=_aib;var _Hx=ExpAPIXml.eChartTypeArea;if(_al5){_Hx=ExpAPIXml.eChartType3DArea;}var _aCS=new Array(this._m4.appobj.appname,_Hx,_KW);_BM=this.oResources.GetString('APP_TOOLBAR_AREA_CHART_3D');var _aoU=new ContextItem('',_BM,CUIWorkSheet.SafeSetChartThreeDEffect,!_Mj,_aCS,_aeD);_aoU.SetChecked(this._wy);_BM=this.oResources.GetString('APP_TOOLBAR_RADAR_CHART');var _8U=new ContextItem('chart_icon_radar_stacked_flat.gif',_BM,null,!_Mj,null,_Kk);var _ahI=_8U.CreateSubMenu(this._m4.appobj.appname,_Kk._dl+1);var _KW=new Object();_KW[ExpAPIXml.kEleChartIs3D]=false;_KW[ExpAPIXml.kEleChartIsStacked]=false;var _5E=new Array(this._m4.appobj.appname,ExpAPIXml.eChartTypeRadar,_KW);_BM=this.oResources.GetString('APP_TOOLBAR_RADAR_CHART_STAN');var _aCO=new ContextItem('',_BM,CUIWorkSheet.SafeSetChartType,!_Mj,_5E,_ahI);_KW=new Object();_KW[ExpAPIXml.kEleChartIsStacked]=true;_KW[ExpAPIXml.kEleChartIs3D]=false;var _5E=new Array(this._m4.appobj.appname,ExpAPIXml.eChartTypeRadar,_KW);_BM=this.oResources.GetString('APP_TOOLBAR_RADAR_CHART_STACKED');var _8b=new ContextItem('',_BM,CUIWorkSheet.SafeSetChartType,!_Mj,_5E,_ahI);var _ad2=this._gg&&this._gg.GetChartType()==ExpAPIXml.eChartTypeRadar;_8U.SetRadioState(_ad2);var _aEM=_ad2&&this._gg.IsStacked();_8b.SetRadioState(_aEM);_aCO.SetRadioState(_ad2&&!_aEM);var _aGs=new Array(this._m4.appobj.appname,ExpAPIXml.eChartTypePoint);_BM=this.oResources.GetString('APP_TOOLBAR_POINT_CHART');var _aGa=new ContextItem('chart_icon_point_flat.gif',_BM,CUIWorkSheet.SafeSetChartType,!_Mj,_aGs,_Kk);_aGa.SetRadioState(this._gg&&this._gg.GetChartType()==ExpAPIXml.eChartTypePoint);if(Utilities.bScatterPlotGraphsEnabled){var _al0=new Array(this._m4.appobj.appname,ExpAPIXml.eChartTypeScatter);_BM=this.oResources.GetString('APP_TOOLBAR_SCATTER_CHART');var _0p=new ContextItem('chart_icon_scatter_flat.gif',_BM,CUIWorkSheet.SafeSetChartType,!_Mj,_al0,_Kk);_0p.SetRadioState(this._gg&&this._gg.GetChartType()==ExpAPIXml.eChartTypeScatter);}var _aIC=new ContextSeparator(_Kk);_KW=new Object();if(this._gg&&this._gg.IsStacked()){_KW[ExpAPIXml.kEleChartIsStacked]=true;}if(this._gg&&this._gg.IsStacked100Percent()){_KW[ExpAPIXml.kEleChartIsStacked100Percent]=true;}var _4b=new Array(this._m4.appobj.appname,_KW);_BM=this.oResources.GetString('APP_TOOLBAR_CHART_SHOWVALUES');var _0p=new ContextItem('',_BM,CUIWorkSheet.SafeShowValues,!_Mj,_4b,_Kk);_0p.SetChecked(this._sv);};CUIWorkSheet.prototype.UpdateLastChartTypeOptions=function(){var oChart=this._my._ek;if(!oChart){return;}this._e2=oChart.GetChartType();var _KW=new Object();switch(this._e2){case ExpAPIXml.eChartTypePie:_KW[ExpAPIXml.kEleChartIs3D]=oChart._p7;_KW[ExpAPIXml.kEleChartShowAsPercent]=oChart._hD;_KW[ExpAPIXml.kEleChartShowValues]=oChart._nb;break;case ExpAPIXml.eChartTypeBar:_KW[ExpAPIXml.kEleChartIs3D]=oChart._p7;_KW[ExpAPIXml.kEleChartShowValues]=oChart._nb;_KW[ExpAPIXml.kEleChartIsStacked]=oChart._le;_KW[ExpAPIXml.kEleChartIsStacked100Percent]=oChart._ug;break;case ExpAPIXml.eChartTypeColumn:_KW[ExpAPIXml.kEleChartIs3D]=oChart._p7;_KW[ExpAPIXml.kEleChartShowValues]=oChart._nb;_KW[ExpAPIXml.kEleChartIsStacked]=oChart._le;_KW[ExpAPIXml.kEleChartIsStacked100Percent]=oChart._ug;break;case ExpAPIXml.eChartTypePareto:_KW[ExpAPIXml.kEleChartIs3D]=oChart._p7;_KW[ExpAPIXml.kEleChartShowValues]=oChart._nb;break;case ExpAPIXml.eChartTypeLine:_KW[ExpAPIXml.kEleChartIs3D]=oChart._p7;_KW[ExpAPIXml.kEleChartShowValues]=oChart._nb;_KW[ExpAPIXml.kEleChartIsStacked]=oChart._le;_KW[ExpAPIXml.kEleChartIsStacked100Percent]=oChart._ug;break;case ExpAPIXml.eChartTypeArea:_KW[ExpAPIXml.kEleChartIs3D]=oChart._p7;_KW[ExpAPIXml.kEleChartShowValues]=oChart._nb;_KW[ExpAPIXml.kEleChartIsStacked]=oChart._le;_KW[ExpAPIXml.kEleChartIsStacked100Percent]=oChart._ug;break;case ExpAPIXml.eChartTypeScatter:_KW[ExpAPIXml.kEleChartShowValues]=oChart._nb;break;case ExpAPIXml.eChartTypePolar:_KW[ExpAPIXml.kEleChartShowValues]=oChart._nb;break;case ExpAPIXml.eChartTypePoint:_KW[ExpAPIXml.kEleChartShowValues]=oChart._nb;break;case ExpAPIXml.eChartTypeRadar:_KW[ExpAPIXml.kEleChartShowValues]=oChart._nb;_KW[ExpAPIXml.kEleChartIsStacked]=oChart._le;break;case ExpAPIXml.eChartType3DBar:_KW[ExpAPIXml.kEleChartShowValues]=oChart._nb;break;case ExpAPIXml.eChartType3DArea:_KW[ExpAPIXml.kEleChartShowValues]=oChart._nb;break;case ExpAPIXml.eChartType3DLine:_KW[ExpAPIXml.kEleChartShowValues]=oChart._nb;break;case ExpAPIXml.eChartTypeColumnLine:_KW[ExpAPIXml.kEleChartIs3D]=oChart._p7;_KW[ExpAPIXml.kEleChartShowValues]=oChart._nb;_KW[ExpAPIXml.kEleChartIsStacked]=oChart._le;_KW[ExpAPIXml.kEleChartIsStacked100Percent]=oChart._ug;break;default:Debug.Assert(false);break;}this._oV=_KW;};CUIWorkSheet.SafeShowValues=function(_Ke,_KW){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager._jf.ShowChartValues(_KW);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.prototype.ShowChartValues=function(_KW){this._sv=!this._sv;Debug.Assert(_KW!=null,"Missing chart options array");if(_KW==null){return;}if(this._gg){var _OA=this._gg.GetChartType();_KW[ExpAPIXml.kEleChartIs3D]=this._wy;this.SetChartType(_OA,_KW);}};CUIWorkSheet.SafeShowValuesAsPercent=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager._jf.ShowChartValuesAsPercent();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.prototype.ShowChartValuesAsPercent=function(){this._fb=!this._fb;var _Ey=false;if(this._fb){_Ey=true;}if(!this._sv){this._pA=true;}var _KW=new Object();_KW[ExpAPIXml.kEleChartIs3D]=this._wy;this.SetChartType(ExpAPIXml.eChartTypePie,_KW,_Ey);};CUIWorkSheet.SafeSetChartThreeDEffect=function(_Ke,_OA,_KW){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager._jf.SetChartThreeDEffect(_OA,_KW);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.prototype.SetChartThreeDEffect=function(_OA,_KW){this._wy=!this._wy;Debug.Assert(_KW!=null,"Missing chart options array");if(_KW==null){return;}_KW[ExpAPIXml.kEleChartIs3D]=this._wy;this.SetChartType(_OA,_KW);};CUIWorkSheet.SafeInsertDescriptiveStats=function(_Ke,_OA,_KW){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager._jf.InsertDescriptiveStats(_Ke,_OA,_KW);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.prototype.InsertDescriptiveStats=function(_Ke,_OA,_KW){var _M3=false;if(this.HasValidDescriptiveStatsSelection()){var _V7=null;var _FK=null;if(this._to instanceof CDLBlock){_FK=this._to;}else if(this._to instanceof CUIUserSelection){_FK=this._to._cu;_V7=this._to;}}else{_M3=true;}this._dO.SafeInsertDescriptiveStats(_OA,_KW,_V7,_FK,_M3);};CUIWorkSheet.SafeDescriptiveStatsRequest=function(_Ke,_OA,_KW){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager._jf.DoDescriptiveStatsRequest(_OA,_KW);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.SafeRemoveDescriptiveStatsRequest=function(_Ke,_OA,_KW){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager._jf.RemoveDescriptiveStatsRequest(_Ke,_OA,_KW);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.prototype.RemoveDescriptiveStatsRequest=function(_Ke,_OA,_KW){var _VI=new Array();_VI.push(this._my.GetDescriptiveStatsAction(ExpAPIXml.kActionDelete,_OA,_KW));this._my.RunDescriptiveStatsRequest(_VI);this._my._ak.descriptiveStatsInserted=false;CUIDialogMgr.SafeHideCurrentDialog(_Ke);};CUIWorkSheet.prototype.DoDescriptiveStatsRequest=function(_OA,_KW){var _VI=new Array();_VI.push(this._my.GetDescriptiveStatsAction(ExpAPIXml.kActionInsert,_OA,_KW));this._my.RunDescriptiveStatsRequest(_VI);this.descriptiveStatsInserted=true;this._my._ak.descriptiveStatsInserted=true;};CUIWorkSheet.SafeSetChartType=function(_Ke,_OA,_KW){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager._jf.SetChartType(_OA,_KW);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.prototype.SetChartType=function(_OA,_KW,_Ey,_Py){var _VI=new Array();if(this._gg){_VI.push(this._gg.GetDLChart().GetDeleteAction());}if(_Py&&this._dO){_VI.push(this._dO.GetDLCrosstab().GetDeleteAction());}if(!_KW){_KW=new Object();}_KW[ExpAPIXml.kEleChartShowValues]=this._sv;if(_Ey){_KW[ExpAPIXml.kEleChartShowValues]=true;}if(_OA==ExpAPIXml.eChartTypePie){_KW[ExpAPIXml.kEleChartShowAsPercent]=this._fb;}_VI.push(this._my.GetAddChartAction(_OA,_KW));this._my.RunChartAndXtabRequest(_VI);this._e2=_OA;this._oV=_KW;};CUIWorkSheet.SafeShowChartDisplayDropDown=function(e,_Ke,x,y){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager._jf.ShowChartDisplayDropDown(e,x,y);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.prototype.ShowChartDisplayDropDown=function(e,x,y){var _Ke=this._m4.appobj.appname;var _Kk=new CUIContextMenu(_Ke,0,this,null,true);_Kk.SetUnloadOnHide(true);var _Li=this.GetDataWorkSheet().GetDataManager().GetCurrentDataMatrix();var _af0=_Li.IsFullDataMode()&&_Li.IsCompleteExpression();var _AG=new Array(_Ke);var _BM=this.oResources.GetString('APP_VIEW_MENU_CROSSTAB');var oCrosstab=new ContextItem('',_BM,CUIWorkSheet.SafeHideChart,false,_AG,_Kk);oCrosstab.id='APP_VIEW_MENU_CROSSTAB';oCrosstab.SetRadioState(this._ca==CUIWorkSheet.eLayoutXtabOnly);var _BM=this.oResources.GetString('APP_VIEW_MENU_CHART');var _Mj=_af0;var oChart=new ContextItem('',_BM,CUIWorkSheet.SafeShowChartOnly,!_Mj,_AG,_Kk);oChart.id='APP_VIEW_MENU_CHART';oChart.SetRadioState(this._ca==CUIWorkSheet.eLayoutChartOnly);var _BM=this.oResources.GetString('APP_VIEW_MENU_CROSSTAB_AND_CHART');_Mj=_af0;var _aG6=new ContextItem('',_BM,CUIWorkSheet.SafeShowCrosstabAndChart,!_Mj,_AG,_Kk);_aG6.id='APP_VIEW_MENU_CROSSTAB_AND_CHART';_aG6.SetRadioState(this._ca==CUIWorkSheet.eLayoutXtabAndChart);_Kk.display(e,false,x,y);};CUIWorkSheet.SafeShowChartOnly=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager._jf.ShowChartOnly();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.prototype.ShowChartOnly=function(){if(this._ca==CUIWorkSheet.eLayoutXtabOnly){this.SetChartType(this._e2,this._oV,false,true);}else if(this._ca==CUIWorkSheet.eLayoutXtabAndChart){var _VI=new Array();if(this._dO){_VI.push(this._dO.GetDLCrosstab().GetDeleteAction());this._my.RunChartAndXtabRequest(_VI);}}else{Debug.Assert(false);}};CUIWorkSheet.SafeShowCrosstabAndChart=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager._jf.ShowCrosstabAndChart();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.prototype.ShowCrosstabAndChart=function(){if(this._ca==CUIWorkSheet.eLayoutXtabOnly){this.SetChartType(this._e2,this._oV);}else if(this._ca==CUIWorkSheet.eLayoutChartOnly){var _VI=new Array();_VI.push(this._my.GetAddXtabAction());this._my.RunChartAndXtabRequest(_VI);}else{Debug.Assert(false);}};CUIWorkSheet.SafeHideChart=function(_Ke){try{FindApp(_Ke).uiManager._jf.HandleChartClose();}catch(e){_f.HandleException(e);}};CUIWorkSheet.prototype.HandleChartClose=function(){var _VI=new Array();if(this._ca==CUIWorkSheet.eLayoutChartOnly){if(this._gg){_VI.push(this._gg.GetDLChart().GetDeleteAction());}_VI.push(this._my.GetAddXtabAction());}else if(this._ca==CUIWorkSheet.eLayoutXtabAndChart){if(this._gg){_VI.push(this._gg.GetDLChart().GetDeleteAction());}}this._my.RunChartAndXtabRequest(_VI);};CUIWorkSheet.prototype.ResetDisplayType=function(){this._ca=CUIWorkSheet.eLayoutXtabOnly;};CUIWorkSheet.SafeDoToggleIncludeDetails=function(_Ke){try{FindApp(_Ke).uiManager._jf.ToggleIncludeDetailFlag();}catch(e){_f.HandleException(e);}};CUIWorkSheet.prototype.ToggleIncludeDetailFlag=function(){this._ab=this._ab?false:true;};CUIWorkSheet.prototype.GetIncludeDetailFlag=function(){if(this._jP){return false;}else{return this._ab;}};CUIWorkSheet.SetIncludeDetailFlag=function(_Ke,_Ph){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager._jf._ab=_Ph;/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.prototype.DisableIncludeDetailFlag=function(){this._pW=true;};CUIWorkSheet.prototype.EnableIncludeDetailFlag=function(){this._pW=false;};CUIWorkSheet.prototype.SwapRowColumn=function(){this._my.SwapRowColumn();};CUIWorkSheet.SafeSwapRowColumn=function(_Ke){try{FindApp(_Ke).uiManager._jf.SwapRowColumn();}catch(e){_f.HandleException(e);}};CUIWorkSheet.prototype.OpenDescriptiveStatsDlg=function(_M3){};CUIWorkSheet.prototype.OpenCalcDlg=function(_M3){var _K9=null;if(!_M3){_K9=this._wa;if(this._wa instanceof CDLBlock){var _aA6=this.GetUIAxesContainer().GetUIAxis(CUIDataMatrix.iRowIndex);_aA6=_aA6.GetDLAxis().GetBlock(this._wa.GetId())?_aA6:this.GetUIAxesContainer().GetUIAxis(CUIDataMatrix.iColIndex);_K9=_aA6._az;}}this._dO.DoCustomizeCalc(_K9);};CUIWorkSheet.SafeOpenDescriptiveStatsDlg=function(_Ke,_M3){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager._jf.OpenDescriptiveStatsDlg(_M3);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.SafeOpenCalcDlg=function(_Ke,_M3){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager._jf.OpenCalcDlg(_M3);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.prototype.OpenSortDlg=function(_Ru){var _FK=this.GetSelectedBlock();if(!this.oSortDlg){this.oSortDlg=new CUISortDlg();this.oSortDlg.Init(this._m4.oDialogMgr);}if(!_FK||(!_FK.CanSort())){var _M3=true;this.oSortDlg.Display(_M3);}else{this.oSortDlg.Draw();this.oSortDlg.Display();this.oSortDlg.SetHostObj(_FK);if(_Ru){this.oSortDlg.SetSortTypeRadio(_Ru);}}};CUIWorkSheet.SafeOpenSortDlg=function(_Ke,_Ru){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager._jf.OpenSortDlg(_Ru);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.prototype.OpenRenameCalcDlg=function(){var _K9=null;var _aA6=this._dO.GetUIAxis(CUIDataMatrix.iRowIndex);if(this._dO._ax.HasSelection()){_K9=this._dO._ax._az;}else if(this._dO._bz.HasSelection()){_K9=this._dO._bz._az;}var _aHm=false;if(!this.oRenameCalcDlg){this.oRenameCalcDlg=new CUIRenameCalcDlg();this.oRenameCalcDlg.Init(this._m4.oDialogMgr);this.oRenameCalcDlg.SubscribeWSEvent();_aHm=true;}this.oRenameCalcDlg.SetUserSelection(_K9,_aHm);this.oRenameCalcDlg.Create();this.oRenameCalcDlg.Display();};CUIWorkSheet.SafeOpenRenameCalcDlg=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager._jf.OpenRenameCalcDlg();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.prototype.OpenFilterDlg=function(_Sr,_M3){var _FK=_Sr!=null?_Sr:this.GetSelectedBlock();var _ano=null;if((!_M3)&&_FK&&_FK.CanApplyUserDefFilter()){var _Gd=_FK.GetUserDefFLT()?_FK.GetUserDefFLT().Clone():null;if(_Gd&&_Gd._lW&&_Gd._lW==ExpAPIXml.kEleCombineFilterExpr){if(!this.oCombineFLTDlg){this.oCombineFLTDlg=new CUICombineFilterDlg();this.oCombineFLTDlg.Init(this._m4.oDialogMgr);this.oCombineFLTDlg.SubscribeWSEvent();}_ano=this.oCombineFLTDlg;}else{if(!this.oUserDefFLTDlg){this.oUserDefFLTDlg=new CUIUserDefFilterDlg();this.oUserDefFLTDlg.Init(this._m4.oDialogMgr);this.oUserDefFLTDlg.InitFLTRuleOptions();this.oUserDefFLTDlg.SubscribeWSEvent();}_ano=this.oUserDefFLTDlg;}_ano.SetHostObj(_FK);_ano.SetInitFilterExpr(_Gd);_ano.Create();_ano.Display();}else{if(!_ano){if(!this.oUserDefFLTDlg){this.oUserDefFLTDlg=new CUIUserDefFilterDlg();this.oUserDefFLTDlg.Init(this._m4.oDialogMgr);this.oUserDefFLTDlg.InitFLTRuleOptions();this.oUserDefFLTDlg.SubscribeWSEvent();}_ano=this.oUserDefFLTDlg;}var _M3=true;_ano.Display(_M3);}};CUIWorkSheet.SafeOpenFilterDlg=function(_Ke,_FK){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager._jf.OpenFilterDlg(_FK);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.SafeDoShowUserDefFilterDropDown=function(e,_Ke,x,y){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.uiManager._jf.DoShowUserDefinedFilterDropDown(e,_Ke,x,y);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.AttachUserDefinedFilterItems=function(_Co,_Ga,_Ke,_FK){var _AG=new Array(_Ke,_FK);var _BM=_Co.GetString('IDS_TOOLBAR_USER_DEF_FILTER_NO_FLT');var _apL=new ContextItem('',_BM,CUIWorkSheet.SafeDoRemoveUserDefinedFilter,false,_AG,_Ga);var _abp=_FK.GetUserDefFLT();_apL.SetRadioState(!_abp);_BM=_Co.GetString('IDS_TOOLBAR_USER_DEF_FILTER_CUSTOM');_apL=new ContextItem('',_BM,CUIWorkSheet.SafeOpenFilterDlg,false,_AG,_Ga);_apL.SetRadioState(_abp);return _Ga;};CUIWorkSheet.prototype.DoShowUserDefinedFilterDropDown=function(e,_Ke,x,y){if(!this._nK){this._nK=new CUIContextMenu(_Ke,0,this);}this._nK.Clear();var _Co=this.oResources;var _FK=this.GetInferredBlock();if(_FK&&_FK.CanApplyUserDefFilter()){this._nK=CUIWorkSheet.AttachUserDefinedFilterItems(_Co,this._nK,_Ke,_FK);this._nK.display(e,false,x,y);}else{var _M3=true;this.OpenFilterDlg(null,_M3);}};CUIWorkSheet.SafeDoRemoveUserDefinedFilter=function(_Ke,_FK){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.uiManager._jf.SetLastBlockSelectionId(_FK.GetId());_FK.SetProperty(ExpAPIXml.kEleUserDefFilter,null);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.prototype.UpdateViews=function(){var _acA=false;var _aoJ=false;var _U9=this._my._ak;var _aon=this._my.GetViewRefArray();for(var i in _U9._pv){if(Utilities.IsInArray(_aon,_U9._pv[i]._ks)){_aoJ=true;this._dO.SetDLCrosstab(_U9._pv[i]);}else{_U9._pv[i].Clear();delete _U9._pv[i];}}for(var i in _U9._fz){if(Utilities.IsInArray(_aon,_U9._fz[i]._ks)){_acA=true;var _Ul=_U9._fz[i];this._gg.SetDLChart(_Ul);this.UpdateLastChartTypeOptions();if(!_aoJ){var _aAb=_Ul._rW;if(_aAb){var _ac3=this._my._rk;_ac3.ProcessData(_aAb,true);for(var i=0;i<_ac3.GetAxisCount();i++){Debug.Assert(this._gg._mx[i]);this._gg._mx[i].Populate();}_Ul._rW=null;}}}else{_U9._fz[i].Release();delete _U9._fz[i];_U9.Notify(ExpEvent.kCDLDataManager_ChartRefresh);}}var _atQ=this._ca;if(_acA&&_aoJ){this._ca=CUIWorkSheet.eLayoutXtabAndChart;}else if(_acA){this._ca=CUIWorkSheet.eLayoutChartOnly;}else if(_aoJ){this._ca=CUIWorkSheet.eLayoutXtabOnly;}this.UpdateHeight();};CUIWorkSheet.SafeDoShowDefBlockSizeDlg=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.uiManager._jf.DoOpenDefBlockSizeDlg();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.SafeOpenGlobalTotalSettingDlg=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.uiManager._jf.OpenGlobalTotalSettingDlg();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.SafeDoDataFormatDlg=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.uiManager._jf.DoOpenDataFormatDlg();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.prototype.DoOpenDataFormatDlg=function(){if(!this.oDataFormatDlg){this.oDataFormatDlg=new CUIDataFormatDlg();this.oDataFormatDlg.Init(this._m4.oDialogMgr);}this.oDataFormatDlg.SetHostObj(this._my._ak._kX);this.oDataFormatDlg.Create();this.oDataFormatDlg.Display();};CUIWorkSheet.prototype.DoOpenDefBlockSizeDlg=function(){if(!this.oDefBlkSizeDlg){this.oDefBlkSizeDlg=new CUISetDefaultBlockSizeDlg();this.oDefBlkSizeDlg.Init(this._m4.oDialogMgr);}this.oDefBlkSizeDlg.SetDefaultValue(this._m4.dataManager.metadata.GetDefBlockSize());this.oDefBlkSizeDlg.Create();this.oDefBlkSizeDlg.Display();};CUIWorkSheet.prototype.OpenGlobalTotalSettingDlg=function(){if(!this.oGlobalTotalSettingDlg){this.oGlobalTotalSettingDlg=new CUIGlobalAutoSubtotalsDlg();this.oGlobalTotalSettingDlg.Init(this._m4.oDialogMgr);}this.oGlobalTotalSettingDlg.SetHostObj();this.oGlobalTotalSettingDlg.Display();};CUIMissingMunsPane.ItemTypeImgArr=new Object();CUIMissingMunsPane.ItemTypeImgArr[ExpAPIXml.eMember]='member.gif';CUIMissingMunsPane.ItemTypeImgArr[ExpAPIXml.eMeasure]='measure.gif';CUIMissingMunsPane.ItemTypeImgArr[ExpAPIXml.eNamedSet]='named_set.gif';CUIMissingMunsPane.ItemTypeImgArr[ExpAPIXml.kLevel]='level_black_sea.gif';CUIMissingMunsPane.ItemTypeImgArr[ExpAPIXml.kEleProperty]='attribute.gif';CUIMissingMunsPane.ItemTypeImgArr[ExpAPIXml.kEleSubsVar]='Substitution.gif';function CUIMissingMunsPane(_EE,_EP){this._m4=_EE;this.oRes=_EE.appobj.oResources;this.sAppName=_EE.appobj.appname;this._hV=this._m4.dataManager._vw;this._r1=_EP;this._st=document.createElement('DIV');this._st.id="missingdatapane"+Utilities.GenerateId();this._st.className="missingDataPane";this._r1.appendChild(this._st);this._fd=document.createElement('TD');this._fd.className="pagerCtrlTBLHeader";this._ji=document.createElement('TD');this._ji.className="missingDataItem";this._mL=null;this._m4.Subscribe(this,ExpEvent.kCUIManager_OnMissingPaneHeightChange);};CUIMissingMunsPane.prototype.GetLastSelectedMissingItem=function(){return this._mL;};CUIMissingMunsPane.prototype.drawWarning=function(){var _7w=this._st.appendChild(document.createElement('DIV'));_7w.className="missingDataErrorMsgDiv";var _zr=_7w.appendChild(document.createElement('TABLE'));var _RK=_zr.appendChild(document.createElement('TBODY'));var _FW=_RK.appendChild(document.createElement('TR'));var _aFT=_FW.appendChild(document.createElement('TD'));var _aiw=_aFT.appendChild(document.createElement('IMG'));_aiw.src=Utilities.IMG_PATH+'msg_warning.gif';var _ala=_FW.appendChild(document.createElement('TD'));_ala.className='infoLabel';var _2Y=this._m4.dataManager.GetCurrentWorkSheet()._aP;var _7s=(this._hV.IsFixable())?'IDS_MISSING_DATA_ERROR_MSG':'IDS_UNKNOWN_DATA_ERROR_MSG';var _F3=this.oRes.ReplaceParam(_7s,1,_2Y);var _TL=_ala.appendChild(document.createTextNode(_F3));};CUIMissingMunsPane.prototype.drawButtonBar=function(_Ht){var _acd=this._st.appendChild(document.createElement('TABLE'));_acd.className='missdatapanebutton';var _6T=_acd.appendChild(document.createElement('TBODY'));var _YO=_6T.appendChild(document.createElement('TR'));var _3K=_YO.appendChild(document.createElement('TD'));this.sButtonTableId=Utilities.GenerateId();_acd.id=this.sButtonTableId;for(var i=0;i<_Ht.length;i++){_3K.appendChild(_Ht[i]);}};CUIMissingMunsPane.prototype.drawInstruction=function(_Sq){var _1m=this._st.appendChild(document.createElement('DIV'));_1m.id=Utilities.GenerateId();this._kM=_1m.id;_1m.className="missingDataFixInstruction";var _Ku=this.oRes.GetString(_Sq);var _az8=_Ku.split('\n');for(var x=0;x<_az8.length;x++){var _TL=document.createTextNode(_az8[x]);_1m.appendChild(_TL);_1m.appendChild(document.createElement('BR'));}};CUIMissingMunsPane.prototype.handleNoValidReplace=function(){this.drawWarning();this.drawInstruction('IDS_MISSING_NO_VALID_REPLACEMENT');var _Ht=new Array();var _aID=this.oRes.GetString('IDS_BUTTON_OK');var _Ke=this.sAppName;var _aj2=Utilities.GenerateCallback(CUIMissingMunsPane.SafeDoCancel,[_Ke]);var _aIq=COTInputElementFactory.CreateButton('MissingMunOKButton',_aID,_aj2,false);this.sOKButtonId=Utilities.GenerateId();_aIq.id=this.sOKButtonId;_Ht.push(_aIq);this.drawButtonBar(_Ht);};CUIMissingMunsPane.prototype.Create=function(_TM){if(!this._hV.IsValidSubstitutionPossible()){this.handleNoValidReplace();return;}this.drawWarning();var _7s=(this._hV.IsFixable())?'IDS_MISSING_ITEM_REP_INSTRUCTION':'IDS_UNKNOWN_DATA_ANALYSIS_UPDATE_INSTRUCTION';this.drawInstruction(_7s);if(this._hV.IsFixable()){var _aw0=this._st.appendChild(document.createElement('DIV'));Dom.SetObjRef(_aw0,this,'oMissMunsPane');this._tb=Utilities.GenerateId();_aw0.id=this._tb;_aw0.onmouseover=CUIMissingMunsPane.SafeHandleMouseOver;_aw0.onmouseout=CUIMissingMunsPane.SafeHandleMouseOut;var _apn=document.createElement('TABLE');_apn.className='missingDataTBL';COTStyle.SetWidth(_apn,100,'%');_aw0.appendChild(_apn);var _aBR=document.createElement('TBODY');_apn.appendChild(_aBR);var _NH=document.createElement('TR');_aBR.appendChild(_NH);var _NM=this._fd.cloneNode(false);_NH.appendChild(_NM);COTStyle.SetWidth(_NM,4,'%');_NM=this._fd.cloneNode(false);_NH.appendChild(_NM);COTStyle.SetWidth(_NM,4,'%');_NM=this._fd.cloneNode(false);_NH.appendChild(_NM);COTStyle.SetWidth(_NM,46,'%');var _apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_MISSING_ITEM'));_NM.appendChild(_apS);_NM=this._fd.cloneNode(false);_NH.appendChild(_NM);COTStyle.SetWidth(_NM,46,'%');_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_NEW_ITEM'));_NM.appendChild(_apS);var _az4=0;this._mN=new Object;this._mZ=new Array();for(var i in this._hV._cW){_az4++;var _aCt=this._hV._cW[i];var _NH=document.createElement('TR');_aBR.appendChild(_NH);_NH.onclick=CUIMissingMunsPane.SafeDoSelectItem;_NH._qD=false;Dom.SetObjRef(_NH,this,'oMissMunsPane');_NM=this._ji.cloneNode(false);_NH.appendChild(_NM);_apS=COTInputElementFactory.CreateLabel(_az4);_NM.appendChild(_apS);_NM=this._ji.cloneNode(false);_NH.appendChild(_NM);_apS=COTInputElementFactory.CreateCheckBox('prunechx',_aCt.GetReplaceItemId(),true);Dom.SetObjRef(_apS,_aCt,'oMissingItem');_NM.appendChild(_apS);_NM=this._ji.cloneNode(false);_NH.appendChild(_NM);var _azP=COTInputElementFactory.CreateImage(CUIMissingMunsPane.ItemTypeImgArr[_aCt.GetDataType()],16,16);_NM.appendChild(_azP);var _Ak=i;_apS=COTInputElementFactory.CreateLabel(i);_NM.appendChild(_apS);_NM=this._ji.cloneNode(false);_NH.appendChild(_NM);var _anK=_aCt.GetReplaceItemId();if(_aCt.GetDataType()==ExpAPIXml.kEleSubsVar){var _8o=new CUIListCtrl(this._m4);_8o.SetMaxHeight(80);_8o.Init();_8o.DisableHAutoScroll();var _ar8=new CUIComboBox(this._m4,_8o);_ar8.SetArrowImageName("substitution_variables.gif");_ar8.SetArrowImageDisabledName("substitution_variables_disabled.gif");_ar8.DisableIcon();_ar8.SetArrowTDClassName("ComboBoxArrowWhite");var _afs=_ar8.Init();_afs.style.display="inline";_ar8.SetWidthByPX(150);_ar8.EnableHoverOverArrowEffect("ComboBoxArrowWhite_hover");this.PopulateSubsVars(this._hV.datamanager.metadata._gY,_ar8);_ar8.Subscribe(this,ExpEvent.kCUIComboBox_OnSelChange);this._mN[_ar8.GetId()]=i;_apS=_afs;this._mZ.push(_ar8);}else{if(_anK){var _Bd=_anK.GetReplaceItemId();_apS=COTInputElementFactory.CreateLabel(_Bd);}else{_apS=COTInputElementFactory.CreateImage('drag_drop.gif',17,13);}}Dom.SetObjRef(_NM,this._hV._cW[i],'oMissingItem');_NM.appendChild(_apS);}var _aAK=document.createElement('DIV');_aAK.className='missingDataAnaUpdateInstruction';var _Ku=this.oRes.GetString('IDS_MISSING_ITEM_ANALYSIS_UPDATE_INSTRUCTION');var _az8=_Ku.split('\n');for(var x=0;x<_az8.length;x++){var _TL=document.createTextNode(_az8[x]);_aAK.appendChild(_TL);_aAK.appendChild(document.createElement('BR'));}_aw0.appendChild(_aAK);}var _Ht=new Array();var _aID=this.oRes.GetString('IDS_BUTTON_OK');var _Ke=this.sAppName;var _akS=Utilities.GenerateCallback(CUIMissingMunsPane.SafeDoSubstituteMUNs,[_Ke]);var _aIq=COTInputElementFactory.CreateButton('MissingMunOKButton',_aID,_akS,false);this.sOKButtonId=Utilities.GenerateId();_aIq.id=this.sOKButtonId;_Ht.push(_aIq);var _aut=this.oRes.GetString('IDS_BUTTON_CANCEL');var _aoV=Utilities.GenerateCallback(CUIMissingMunsPane.SafeDoCancel,[_Ke]);var _Zv=COTInputElementFactory.CreateButton('MissingPaneCancelButton',_aut,_aoV,false,true);this.sCancelButtonId=Utilities.GenerateId();_Zv.id=this.sCancelButtonId;_Ht.push(_Zv);this.drawButtonBar(_Ht);this.HandleResize();};CUIMissingMunsPane.prototype.PopulateSubsVars=function(_SS,_MX){_MX.oListCtrl.ClearAllItems();var _LX;var _Oi=0;var _aFI=null;for(var i in _SS){_LX=_MX.oListCtrl.AddItem('',_SS[i]._xU,0,_SS[i]._bb,_SS[i]._xU);if(_Oi==0){_Oi++;_aFI=_LX;}}_MX.SetValueFromListItem(_aFI,false,false);};CUIMissingMunsPane.prototype.SetPosition=function(_P6,_TM,_Rn){this._st.style.left=_P6+_Rn;this._st.style.top=_TM+_Rn;};CUIMissingMunsPane.prototype.SetHeight=function(_T6,_Rn){this._st.height=_T6+_Rn;};CUIMissingMunsPane.prototype.SafeHandleDragOver=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}this.oMissMunsPane.HandleDragOver(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIMissingMunsPane.prototype.HandleDragOver=function(e){if(!e){var e=window.event;}Dom.CancelEvent(e);var _N9=Dom.GetEventTarget(e);if(_N9.tagName=='IMG'){_N9=_N9.parentNode;}CUIDragDrop.setEffect(CUIDragDrop.eEffectCopy);var _adn=this.IsValidDropTarget(_N9,this._oM);if(_adn){CUIDragDrop.SetCursorImgPosition(e.clientX,e.clientY);var _aeJ=_N9.oMissingItem;this.HighLightReplaceDZ(_N9);_N9.bValidTgt=true;}else{this.handleInvalidDZ(e);CUIDragDrop.SetCursorImgPosition(e.clientX,e.clientY);_N9.bValidTgt=false;}};CUIMissingMunsPane.prototype.IsValidDropTarget=function(_yW,_Lv){if(_yW&&_yW.oMissingItem){var _azF=_Lv.GetDataType(this._m4.dataManager.metadata);if(_yW.oMissingItem.GetDataType()==_azF){return true;}else{return false;}}return false;};CUIMissingMunsPane.prototype.HighLightReplaceDZ=function(_yW){_yW.className="repItemDragOver";};CUIMissingMunsPane.prototype.HideReplaceDZ=function(_yW){if(_yW.oMissingItem){_yW.className="missingDataItem";}};CUIMissingMunsPane.prototype.GetDIVObj=function(){return document.getElementById(this._tb);};CUIMissingMunsPane.prototype.handleInvalidDZ=function(e){CUIDragDrop.setEffect(CUIDragDrop.eEffectNone);CUIDragDrop.SetCursorImgPosition(e.clientX,e.clientY);};CUIMissingMunsPane.prototype.SafeHandleDragDrop=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}this.oMissMunsPane.HandleDragDrop(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIMissingMunsPane.prototype.HandleDragDrop=function(e){if(!this._oM){return;}if(!e){var e=window.event;}var _N9=Dom.GetEventTarget(e);if(_N9.tagName=='IMG'){_N9=_N9.parentNode;}if(_N9.bValidTgt){var _Bd=this._oM.sId;this.setReplaceItemId(_N9,_Bd);this.HideReplaceDZ(_N9);}this._oM=null;};CUIMissingMunsPane.prototype.setReplaceItemId=function(_NM,_Bd){_NM.oMissingItem.SetReplaceItemId(_Bd);Dom.RemoveAllChildren(_NM);var _apS=COTInputElementFactory.CreateLabel(_Bd);_NM.appendChild(_apS);};CUIMissingMunsPane.SafeReplaceLastSelection=function(_Ke,_Lv){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager.oMissingMunsPane.ReplaceLastSelection(_Lv);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIMissingMunsPane.prototype.ReplaceLastSelection=function(_Lv){if(this.GetLastSelectedMissingItem()){this.setReplaceItemId(this.GetLastSelectedMissingItem(),_Lv.sId);}};CUIMissingMunsPane.SafeDoSelectItem=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}this.oMissMunsPane.DoSelectItem(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIMissingMunsPane.prototype.DoSelectItem=function(e){var _N9=Dom.GetEventTarget(e);if(_N9.type&&_N9.type=='checkbox'){return;}while(_N9.tagName!='TR'){_N9=_N9.parentNode;}var _RM=_N9._qD;this.ClearSelections(_N9,false);if(_RM){return;}this.setSelectionState(_N9,true);this._t4=_N9;};CUIMissingMunsPane.prototype.setSelectionState=function(_FW,_RM){_FW._qD=_RM;for(var i=0;i<_FW.childNodes.length;i++){if(_RM){_FW.childNodes[i].className='missingDataItemSelected';if(_FW.childNodes[i].oMissingItem){this._mL=_FW.childNodes[i];}}else{_FW.childNodes[i].className='missingDataItem';}}};CUIMissingMunsPane.prototype.ClearSelections=function(){if(this._t4){this.setSelectionState(this._t4,false);this._t4=null;this._mL=null;}};CUIMissingMunsPane.prototype.SetDropData=function(_FZ){this._oM=_FZ;};CUIMissingMunsPane.SafeHandleMouseOver=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/this.oMissMunsPane.HandleMouseOver(e);/*@if(!@bering_debug)@*/}catch(excep){_f.HandleException(excep);}/*@end@*/};CUIMissingMunsPane.prototype.HandleMouseOver=function(e){if(!e){var e=window.event;}var _N9=Dom.GetEventTarget(e);if(CUIDragDrop.IsDragging()){this.HandleDragOver(e);return;}};CUIMissingMunsPane.prototype.GetMouseMoveHandler=function(){return CUIMissingMunsPane.SafeHandleMouseOver;};CUIMissingMunsPane.SafeHandleMouseOut=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/this.oMissMunsPane.HandleMouseOut(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIMissingMunsPane.prototype.HandleMouseOut=function(e){if(!e){var e=window.event;}var _N9=Dom.GetEventTarget(e);if(this.isLeavingActiveDropZone(e)){this.HideReplaceDZ(_N9);return;}};CUIMissingMunsPane.prototype.isLeavingActiveDropZone=function(e){var _yW=Dom.GetEventTarget(e);if(CUIDragDrop.IsDragging()){var _aqw=Dom.GetToElement(e);if(_aqw!=_yW){return true;}}return false;};CUIMissingMunsPane.SafeDoSubstituteMUNs=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager.oMissingMunsPane.SubstituteMUNs();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIMissingMunsPane.prototype.SubstituteMUNs=function(){if(!this._hV.IsFixable()){this._hV.SubstituteMUNs(true);}else{var _aiT=document.getElementsByName('prunechx');for(var i=0;i<_aiT.length;i++){if(!_aiT[i].checked){_aiT[i].oMissingItem.SetToBePruned(true);}else{_aiT[i].oMissingItem.SetToBePruned(false);}}if(!this._hV.AreAllSubstitutionsDone()){CUIDialogMgr.DisplayMessageBox(CUIMessageBox.kWarning,'IDS_MISSING_INCOMPLETE_REPLACEMENTS');return;}this._hV.SubstituteMUNs();}};CUIMissingMunsPane.prototype.Unload=function(){for(var i=0;this._mZ&&i<this._mZ.length;i++){this._mZ[i].oListCtrl.Unload();this._mZ[i].Unload();}this.ClearSelections();Dom.RemoveObject(this._st);Utilities.RemoveAllChildObjects(this);};CUIMissingMunsPane.SafeDoCancel=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager.oMissingMunsPane.DoCancel();CUIWorkSheet.SafeDoNew(_Ke);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIMissingMunsPane.prototype.DoCancel=function(){this.Unload();};CUIMissingMunsPane.prototype.HandleResize=function(){var _aFb=COTStyle.GetVerticalPaddingHeight(this._st);var _aAB=COTStyle.GetHorizontalPaddingWidth(this._st);var _MS=Math.ceil(Dom.GetWindowHeight()-this._m4._dx-CUIManager.kiBottomWindowMargin-_aFb);if(this._m4.oDialogMgr.IsModalessDialogDisplayed()){_MS=Math.ceil(this._m4.oDialogMgr.GetTop()-this._m4._dx-CUIManager.kiSpaceBtwComponents);}COTStyle.SetHeight(this._st,_MS);var _aDC=Math.ceil(Dom.GetWindowWidth()-CUIManager.kiLeftWindowMargin-CUIManager.kiRightWindowMargin-_aAB);var _aAu=this._m4.oLeftPaneMenu.GetRight()+CUIManager.kiSpaceBtwComponents;var _7g=_aDC-_aAu;COTStyle.SetWidth(this._st,_7g);var _akg=document.getElementById(this.sButtonTableId);COTStyle.SetWidth(_akg,_7g);var _asP=document.getElementById(this._tb);var _aa4=COTStyle.GetDisplayHeight(_akg);if(_asP!=null){var _0V=COTStyle.GetDisplayHeight(_asP.firstChild);var _awz=_asP.offsetTop;var _6H=Math.max((_MS-_awz-_aa4+_aFb),_0V);COTStyle.SetHeight(_asP,_6H,'px');}else{var _adz=document.getElementById(this._kM);var _aGw=COTStyle.GetVerticalPaddingHeight(_adz);var _TM=_adz.offsetTop;var _6H=_MS-_TM-_aa4+_aFb-_aGw;COTStyle.SetHeight(_adz,_6H,'px');}};CUIMissingMunsPane.prototype.SetCurrentTrigger=function(oComboBox){this._dM=oComboBox;};CUIMissingMunsPane.prototype.Notify=function(event){if(event==ExpEvent.kCUIManager_OnMissingPaneHeightChange){this.HandleResize();}else if(event==ExpEvent.kCUIComboBox_OnSelChange){var _aeB=this._mN[this._dM.GetId()];this._hV._cW[_aeB].SetReplaceItemId(this._dM.GetValue());}};CUIWorkSheet.SetRemainderModeNull=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager._jf._my.SetRemainderModeNull();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.SetRemainderModeSubtract=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager._jf._my.SetRemainderModeSubtract();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.SetRemainderModeAggregate=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager._jf._my.SetRemainderModeAggregate();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIWorkSheet.SafeDoSetDataMode=function(_Li,_Hd){/*@if(!@bering_debug)@*/try{/*@end@*/_Li.ModifyDataModeProperty(_Hd);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIContextBar.kLabelTruncateLength=15;CUIContextBar.kTypeItem=1;CUIContextBar.kiMargin=4;CUIContextBar.kiDropBarWidth=6;CUIContextBar.kiRowAxisContextSet=0;CUIContextBar.kiColAxisContextSet=1;CUIContextBar.kiFilterContextSet=2;function CUIContextBar(_Qa){CUIContextBar.kiSplitterCorrection=CUIPaneSplitter.kiStaticDimensionSize/2;this.oUIMgr=_Qa._m4;this.oRes=this.oUIMgr.appobj.oResources;this.aContextSets=new Array();this.aAxisContextSets=new Array();this.aAxisScrollPanes=new Array();this.aAxisFirstVis=new Array();this.aAxisScrollCtrls=new Array();this.aAxisStartArrows=new Array();this.aAxisEndArrows=new Array();this.aAxisSetPanes=null;this.oFilterSetPane=null;this.oDataMgr=null;this.oDLFilterSet=null;this.oUIWS=_Qa;this.subscribeToWSEvents();this.bFilterRuleApplied=false;this.bSuppressionRuleApplied=false;this.bInit=false;this._uC=0;this._nq=600;this._km=600;this._wK=300;this._q4=41;this.iLeftPaneWidth=0;this._jA=false;this._rq=0;this._u2=0;this._rQ=0;this._xM=0;this._aH=null;this._pc=0;this._x1=0;this._cZ=null;this.oUIMgr.Subscribe(this,ExpEvent.kCUIManager_Unload);this.oUIMgr.dataManager._kX.Subscribe(this,ExpEvent.kCDLAnalysis_Replace);this._b4=new Array();this._b4[ExpEvent.kCUIContextBar_DrawComplete]=new Array();this._aG=new Array();var _QA=this.oUIMgr.dataManager.metadata;if(_QA.IsFunctionSupported(ExpAPIXml.kQosMultiHierOfSameDim)){this._cY=true;this._xz=new Object();this._xz[CUIContextBar.kiRowAxisContextSet]=new Object();this._xz[CUIContextBar.kiColAxisContextSet]=new Object();this._xz[CUIContextBar.kiFilterContextSet]=new Object();CUIAbsContextItem.kDragIconHeight=24;CUIContextBar.kiMargin=2;}};CUIContextBar.prototype.GetAxisSet=function(i){return this.aAxisContextSets[i];};CUIContextBar.prototype.subscribeToWSEvents=function(){this.oUIWS.Subscribe(this,ExpEvent.kCUIWorksheet_Busy);this.oUIWS.Subscribe(this,ExpEvent.kCUIWorksheet_Free);};CUIContextBar.prototype.Create=function(){if(!this.oDataMgr){this.oDataMgr=this.oUIMgr.dataManager;this.oDataMgr.Subscribe(ExpEvent.kCDLDataManager_CurrentWSFSChange);this.oDataMgr.Subscribe(this,ExpEvent.kCDLDataManager_DataMatrixCreate);}var _arq=this.oDataMgr.GetCurrentWSFilterSet();if(_arq!=this.oDLFilterSet){this.oDLFilterSet=_arq;this.oDLFilterSet.Subscribe(this,ExpEvent.kDLFilterSet_FullRefresh);}this.refreshAxisSets();this.refreshFilterSets();this.bInit=true;};CUIContextBar.prototype.refreshFilterSets=function(){if(this.oFilterSet){this.oFilterSet.Unload();this.oFilterSet=null;if(this._rl&&this._rl.oContextSet instanceof CUIFilterContextSet){this._rl.oContextSet=null;}}Utilities.DeleteAllFromArray(this.aContextSets);Utilities.DeleteAllFromArray(this._aG);this.aContextSets.push(new CUIFilterContextSet(this));this.oFilterSet=this.aContextSets[0];for(var i=0;i<this.aContextSets.length;i++){this.aContextSets[i].Create();}this._x1=Math.max(this.oFilterSet.aContextItems.length,1);};CUIContextBar.prototype.SetWidth=function(_F4){this._nq=_F4;this._km=_F4;if(this.oContextPane){this._nq-=COTStyle.GetHorizontalExtrasWidth(this.oContextPane.GetDom());COTStyle.SetWidth(this.oContextPane.GetDom(),this._nq);var _81=_F4-COTStyle.GetHorizontalExtrasWidth(this.oInfoPane.GetDom());COTStyle.SetWidth(this.oInfoPane.GetDom(),_81);this.HandleResize();}};CUIContextBar.prototype.Display=function(_EP){if(_EP){this.elParent=_EP;}if(!this.oContextPane){this.oContextPane=new CUIPane();this.oContextPane.Create(this.elParent,null,this._q4,'context_bar','px');var _aAz=COTStyle.GetHorizontalExtrasWidth(this.oContextPane.GetDom());this._nq=this._km-_aAz;COTStyle.SetWidth(this.oContextPane.GetDom(),this._nq);this.oContextPane.SetPosition(this._wK,this._uC,'px');Dom.SetObjRef(this.oContextPane.GetDom(),this,'obj');this.oContextPane.GetDom().onmousedown=CUIContextBar.SafeHandleMouseDown;this.oLeftResizePane=new CUIPane();this.oLeftResizePane.CreatePane(this.oContextPane,null,100,'left_resize_pane','%');this.oLeftResizePane.SetPosition(0,0,'%');COTStyle.SetWidth(this.oLeftResizePane.GetDom(),.4*this._nq);this._a7=.6*this._nq;this._qK=0.5*this._a7;this.oRightResizePane=new CUIPane();this.oRightResizePane.CreatePane(this.oContextPane,null,100,'right_resize_pane','%');this.oRightResizePane.SetTopPosition(0,'%');}if(this._gP){for(var i=0;i<this.aAxisSetPanes.length;i++){if(this.aAxisSetPanes[i]){this.aAxisSetPanes[i].Unload();}}if(this._gP){Utilities.DeleteAllFromArray(this._gP);}}if(this.oRightScrollPane){if(this.oFilterSetPane){this.oFilterSetPane.Unload();}this.oRightResizePane.RemoveThisChild(this.oRightScrollPane);}if(!this._cZ){var _Dn=document.createElement('DIV');this.oRightResizePane.GetDom().appendChild(_Dn);COTStyle.SetHeight(_Dn,100,'%');_Dn.style.position='absolute';_Dn.style.top='0%';_Dn.className='filter_scroll_arrow';var _zh=_Dn.cloneNode(true);this.oRightResizePane.GetDom().appendChild(_zh);var _LS=document.createElement('DIV');_LS.style.position='absolute';var _BD=_LS.cloneNode(false);this.centerArrowImgs(_LS,_BD);_Dn.appendChild(_LS);_zh.appendChild(_BD);this._fy=_Dn;this._oH=_zh;var _yZ=new CUIArrowOnlyCallingContext();_yZ.SetUnitAttributes(this._x1,0,this._pc);var _Au=10;_yZ.SetArrowAttributes(null,_LS,_BD,null,_Au,CUIAbsContextItem.kDragIconHeight);this._cZ=new CUIArrowOnlyScrollControl(this.oUIMgr.appobj);this._cZ.OnCreate(_yZ,false,true);this._cZ.Subscribe(this,ExpEvent.kCUIArrowOnlyScrollControl_Scroll);COTStyle.SetWidth(_Dn,this._cZ.GetArrowWidth());COTStyle.SetWidth(_zh,this._cZ.GetArrowWidth());this.iArrowDisplayWidth=COTStyle.GetDisplayOffsetWidth(_Dn);_zh.style.right='0%';_Dn.style.right=this.iArrowDisplayWidth+"px";}Dom.SetObjRef(this._fy,this.oFilterSet,'oContextSet');Dom.SetObjRef(this._oH,this.oFilterset,'oContextSet');this.oRightScrollPane=new CUIPane();this.oRightScrollPane.CreatePane(this.oRightResizePane,null,100,'scroll_pane','%');this.oRightScrollPane.SetPosition(2*CUIContextBar.kiMargin,0,'px');this._oJ=0;var _ayC=this.aAxisContextSets.length;this.aAxisSetPanes=new Array();for(var i=0;i<this.aAxisFirstVis.length;i++){if(this.aAxisFirstVis[i]>=this.aAxisContextSets[i].aContextItems.length){this.aAxisFirstVis[i]=Math.max(this.aAxisContextSets[i].aContextItems.length-1,0);}}this._gP=new Array();var _87=0;var _Ko=CUIManager.GetStartTabIndex(this);var _Ol=this.getLeftPaneWidth();var _CQ=_Ol;for(var _BZ=0;_BZ<_ayC;_BZ++){if(!this.aAxisScrollPanes[_BZ]){this.aAxisScrollPanes[_BZ]=new CUIPane();this.aAxisScrollPanes[_BZ].CreatePane(this.oLeftResizePane,null,100,"scroll_pane","%");}this.aAxisScrollPanes[_BZ].SetPosition(this._oJ,0,"px");this.setupAxisScrollPane(_BZ);this.aAxisSetPanes[_BZ]=new CUIPane();this.aAxisSetPanes[_BZ].CreatePane(this.aAxisScrollPanes[_BZ],null,100,'axis_context_set','%');this.aAxisSetPanes[_BZ].SetPosition(2*CUIContextBar.kiMargin,0,'px');this.aAxisSetPanes[_BZ].GetDom().style.zIndex=_BZ;this._gP[_BZ]=this.aAxisSetPanes[_BZ];this.aAxisContextSets[_BZ].Display(this.aAxisSetPanes[_BZ],this.aAxisFirstVis[_BZ],_Ko,'axis_context_set');_87=this.updateAxisUnits(_BZ,_CQ);_Ko+=_87;}if(!this.oAxisPaneSplitter&&this.aAxisSetPanes[1]){var _asC=Math.max(this.aAxisScrollPanes[1].GetDom().offsetLeft-CUIContextBar.kiSplitterCorrection,0);this.oAxisPaneSplitter=new CUIVertPaneSplitter();this.oAxisPaneSplitter.OnCreate(this.oContextPane,this,_asC,'px',"context_filter_resize.gif");this.oAxisPaneSplitter.SetHeight(CUIAbsContextItem.kDragIconHeight+1);this.oAxisPaneSplitter.SetTop(this.getItemTop());}else if(this.aAxisSetPanes[1]){var _asC=this.aAxisScrollPanes[1].GetDom().offsetLeft;this.oAxisPaneSplitter.SetLeft(Math.max(_asC,0));}else if(this.oAxisPaneSplitter&&!this.aAxisSetPanes[1]){this.oAxisPaneSplitter.Hide();}if(this._pc>(this.oFilterSet.aContextItems.length-1)){this._pc=Math.max(this.oFilterSet.aContextItems.length-1,0);}var _8G=this.updatePaneSizes(_Ol,this._oJ,this.iArrowDisplayWidth);this.oFilterSetPane=new CUIPane();this.oFilterSetPane.CreatePane(this.oRightScrollPane,100,100,'filter_context_set','%');this.oFilterSet.Display(this.oFilterSetPane,this._pc,_Ko,'filter_context_set');var _ayE=0;if(this._pc<(this._x1-1)){_ayE=this.oFilterSet.GetVisibleItemCount(_8G,this._q4);}this._cZ.SetUnits(this._pc,_ayE,this._x1);var _ae0=this._cZ.ShowIfNeeded();if(_ae0){this._fy.className='filter_scroll_arrow_vis';this._oH.className='filter_scroll_arrow_vis';}else{this._fy.className='filter_scroll_arrow';this._oH.className='filter_scroll_arrow';this.oRightScrollPane.GetDom().style.overflow="visible";}if(!this.oPaneSplitter){var _asC=this.oRightResizePane.GetDom().offsetLeft-CUIContextBar.kiSplitterCorrection;this.oPaneSplitter=new CUIVertPaneSplitter();this.oPaneSplitter.OnCreate(this.oContextPane,this,_asC,'px',"context_filter_resize.gif");this.oPaneSplitter.SetHeight(this._q4-2*CUIContextBar.kiMargin);this.oPaneSplitter.SetTop(CUIContextBar.kiMargin);}var _acu=false;var _Li=this.oDataMgr.GetCurrentDataMatrix();var _I3=new Array();for(var i=0;i<_Li.GetAxisCount();i++){_I3=_I3.concat(_Li.GetAxis(i).GetAllBlocksArray());}var _as2=this.oDataMgr.GetCurrentWSFilterSet();_I3=_I3.concat(_as2.GetAllFilterBlocks());for(var i=0;i<_I3.length;i++){if(_I3[i].HasExcludedList()||_I3[i].HasTopBottomRule()){_acu=true;break;}}this.bFilterRuleApplied=_acu;if(this.oInfoPane){this.oInfoPane.Unload();}this.oInfoPane=new CUIPane();this.oInfoPane.Create(this.elParent,null,null,'filters_applied_info');this.oInfoPane.GetDom().onmousedown=CUIContextBar.SafeHandleMouseDown;Dom.SetObjRef(this.oInfoPane.GetDom(),this,'obj');if(_acu){var _alq=this.oRes.ParseStringForParamOrder('IDS_CONTEXT_BAR_FILTERS_APPLIED',1);for(var i=0;i<_alq.length;i++){if(_alq[i]){if(_alq[i].sBefore){this.oInfoPane.GetDom().appendChild(document.createTextNode(_alq[i].sBefore));}if(_alq[i].sElement==this.oRes.GetParameter(1)){var _Cf=document.createElement('A');_Cf.className="link";var _F3=this.oRes.GetString('IDS_CONTEXT_BAR_FILTERS_APPLIED_LINK');_Cf.appendChild(document.createTextNode(_F3));var _Ke=this.oUIMgr.appobj.appname;_Cf.onmousedown=Utilities.GenerateCallback(CUIBlockPropertiesPane.SafeShowPane,[_Ke]);this.oInfoPane.GetDom().appendChild(_Cf);}if(_alq[i].sAfter){this.oInfoPane.GetDom().appendChild(document.createTextNode(_alq[i].sAfter));}}}}this._pj=null;this.bSuppressionRuleApplied=_Li.HasSuppression();if(this.bSuppressionRuleApplied){if(_acu){var _afT=document.createElement('IMG');_afT.src=Utilities.IMG_PATH+'tv_I.gif';COTStyle.SetHeight(_afT,12);COTStyle.SetWidth(_afT,12);this.oInfoPane.GetDom().appendChild(_afT);}var _afT=COTInputElementFactory.CreateImage('icon_zero_12.gif',12,12);_afT.style.marginRight='3px';_afT.id=Utilities.GenerateId();this._pj=_afT.id;this.oInfoPane.GetDom().appendChild(_afT);var _60=_Li.GetSuppressionContextbarLabel();this.oInfoPane.GetDom().appendChild(document.createTextNode(_60));var _arX=new Array(this.oUIMgr.appobj.appname,ExpAPIXml.eSuppressNone);var _6g=Utilities.GenerateCallback(CUIContextBar.SafeClearSuppress,_arX);var _Cf=COTInputElementFactory.CreateLink(_6g,this.oRes.GetString('APP_MENUBAR_REMOVE_ALL_SUPP'),true);_Cf.className="link";_Cf.style.whiteSpace='nowrap';this.oInfoPane.GetDom().appendChild(_Cf);}this.oInfoPane.SetPosition(this._wK,this._uC+this._q4,'px');var _aAz=COTStyle.GetHorizontalExtrasWidth(this.oInfoPane.GetDom());COTStyle.SetWidth(this.oInfoPane.GetDom(),this._km-_aAz);if(_acu||this.bSuppressionRuleApplied){this.oInfoPane.GetDom().style.visibility="visible";}else{this.oInfoPane.GetDom().style.visibility="hidden";}this.Notify(ExpEvent.kCUIContextBar_DrawComplete,true);};CUIContextBar.prototype.SetSuppressionTooltip=function(){if(this._pj){var _Li=this.oDataMgr.GetCurrentDataMatrix();var _anA=document.getElementById(this._pj);_anA.alt=_Li.GetSuppressionDescription();_anA.title=_anA.alt;}};CUIContextBar.prototype.getItemTop=function(){return this._q4-CUIContextBar.kiMargin-CUIAbsContextItem.kDragIconHeight;};CUIContextBar.prototype.setupAxisScrollPane=function(_BZ,_yT){if(!this.aAxisScrollCtrls[_BZ]){var _Dn=document.createElement('DIV');this.aAxisScrollPanes[_BZ].GetDom().appendChild(_Dn);COTStyle.SetHeight(_Dn,90,'%');_Dn.style.position='absolute';_Dn.style.top='0%';_Dn.className='axis_scroll_arrow';var _zh=_Dn.cloneNode(true);_zh.style.right="0%";_Dn.style.right=this.iArrowDisplayWidth+"px";this.aAxisScrollPanes[_BZ].GetDom().appendChild(_zh);var _LS=document.createElement('DIV');_LS.style.position='absolute';var _BD=_LS.cloneNode(false);this.centerArrowImgs(_LS,_BD);_Dn.appendChild(_LS);_zh.appendChild(_BD);var _yZ=new CUIArrowOnlyCallingContext();_yZ.SetUnitAttributes(this.aAxisContextSets[_BZ].aContextItems.length,0,this.aAxisFirstVis[_BZ]);_yZ.SetArrowAttributes(null,_LS,_BD,null,10,CUIAbsContextItem.kDragIconHeight);this.aAxisScrollCtrls[_BZ]=new CUIArrowOnlyScrollControl(this.oUIMgr.appobj);this.aAxisScrollCtrls[_BZ].OnCreate(_yZ,false,true);this.aAxisScrollCtrls[_BZ].Subscribe(this,ExpEvent.kCUIArrowOnlyScrollControl_Scroll);this.aAxisStartArrows[_BZ]=_Dn;this.aAxisEndArrows[_BZ]=_zh;COTStyle.SetWidth(_Dn,this.aAxisScrollCtrls[_BZ].GetArrowWidth());COTStyle.SetWidth(_zh,this.aAxisScrollCtrls[_BZ].GetArrowWidth());}Dom.SetObjRef(this.aAxisStartArrows[_BZ],this.aAxisContextSets[_BZ],'oContextSet');Dom.SetObjRef(this.aAxisEndArrows[_BZ],this.aAxisContextSets[_BZ],'oContextSet');};CUIContextBar.prototype.getLeftPaneWidth=function(){if(this._jA){var _Ol=this._rq;}else{var _Ol=(this._nq<this._a7)?this._nq:this._a7;}return _Ol;};CUIContextBar.prototype.updatePaneSizes=function(_Ol,_Uu,_GK){var _CQ=_Ol;if(this.aAxisScrollPanes[0]){COTStyle.SetWidth(this.aAxisScrollPanes[0].GetDom(),this._qK);COTStyle.SetWidth(this.aAxisSetPanes[0].GetDom(),Math.max(this._qK-2*_GK));}if(this.aAxisScrollPanes[1]){COTStyle.SetWidth(this.aAxisScrollPanes[1].GetDom(),_Ol-this._qK);COTStyle.SetWidth(this.aAxisSetPanes[1].GetDom(),_Ol-this._qK-2*_GK);}COTStyle.SetWidth(this.oLeftResizePane.GetDom(),_Ol);this._eR=_Ol;this.oRightResizePane.GetDom().style.left=_Ol+"px";COTStyle.SetWidth(this.oRightResizePane.GetDom(),this._nq-_Ol);COTStyle.SetWidth(this.oRightScrollPane.GetDom(),this._nq-_Ol-2*_GK);if(this.oPaneSplitter){this.oPaneSplitter.SetLeft(this.oRightResizePane.GetDom().offsetLeft-CUIContextBar.kiSplitterCorrection);}var _aCK=this._nq-_Ol-2*_GK;return _aCK;};CUIContextBar.prototype.getFirstVisibleAxisIndex=function(_BZ){var _11=0;for(var i=0;i<_BZ;i++){_11+=Math.max(this.aAxisContextSets[i].aContextItems.length,1);}return Math.max(this._u2-_11,0);};CUIContextBar.prototype.centerArrowImgs=function(_LS,_BD){_LS.style.top=this.getItemTop()+'px';_BD.style.top=this.getItemTop()+'px';};CUIContextBar.prototype.GetHeight=function(){var _T6=this._q4;if((this.bFilterRuleApplied||this.bSuppressionRuleApplied)&&this.oInfoPane!=null){_T6+=COTStyle.GetDisplayOffsetHeight(this.oInfoPane.GetDom());}return _T6;};CUIContextBar.prototype.SetTop=function(_TM){this._uC=_TM;if(this.oContextPane){this.oContextPane.GetDom().style.top=_TM+'px';}};CUIContextBar.prototype.SetLeft=function(_P6){this._wK=_P6;if(this.oContextPane){this.oContextPane.GetDom().style.left=_P6+'px';}if(this.oInfoPane){this.oInfoPane.GetDom().style.left=_P6+'px';}};CUIContextBar.prototype.HandleUnselect=function(){this.UnselectAllItems();this.oUIWS.HandleSelectedAxisCntx(ExpEvent.kCUIWorksheet_NoAxisSel);};CUIContextBar.SafeHandleMouseDown=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e)var e=window.event;this.obj.HandleMouseDown(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIContextBar.prototype.HandleMouseDown=function(e){this.oUIMgr.OnSelChange(this);if(CUIScrollControl.IsScrollEvent(e)){return;}var _yW=Dom.GetEventTarget(e);var _Oe=this.getItemFromTarget(_yW);if(_Oe&&_Oe.obj.IsSelectable()){_Oe.obj.SelectItem();}else{this.UnselectAllItems();this.oUIWS.HandleSelectedAxisCntx(ExpEvent.kCUIWorksheet_NoAxisSel);}if(!_Oe&&(!Dom.IsLeftButton(e))){if(_yW.oContextSet){if(_yW.oContextSet.oFltContextSetMenu&&this.oDLFilterSet){var _zZ=this.oDLFilterSet.GetDimFilters();var _akw=_yW.oContextSet.oFltContextSetMenu.GetItemById('IDS_CONTEXTBAR_DEL_ALL_FLT_CONTEXT_ITEMS');var _Mj=!this._qh;var _Ke=this.oUIMgr.appobj.appname;var _zA=new Array(_Ke,_zZ);_akw.SetParameterArr(_zA);if(_Mj){for(var i=0;i<_zZ;i++){if(!_zZ.CanDelete()){_Mj=false;break;}}}_akw.SetEnabled(_Mj);_yW.oContextSet.oFltContextSetMenu.display(e);}}}};CUIContextBar.prototype.HandleContextMenu=function(e){this.oUIMgr.OnSelChange(this);if(CUIScrollControl.IsScrollEvent(e)){return;}var _yW=Dom.GetEventTarget(e);var _Oe=this.getItemFromTarget(_yW);if(_Oe&&_Oe.obj.IsSelectable()){_Oe.obj.SelectItem();}else{this.UnselectAllItems();this.oUIWS.HandleSelectedAxisCntx(ExpEvent.kCUIWorksheet_NoAxisSel);}};CUIContextBar.prototype.SecondarySelectBlock=function(_No){this.UnselectAllItems(true);for(var i=0;i<this.aAxisContextSets.length;i++){var _8X=this.aAxisContextSets[i].GetSimpleItem(_No.GetId());if(_8X){_8X.SelectItem(true);break;}else{var _0E=this.aAxisContextSets[i].GetComboItemByBlockId(_No.GetId());if(_0E){_0E.SemiSelectItem();break;}}}};CUIContextBar.prototype.AddSelectedItem=function(_PM){this._aG.push(_PM);};CUIContextBar.prototype.RemoveSelectedItem=function(_PM){for(var i in this._aG){if(this._aG[i]==_PM){delete this._aG[i];return;}}};CUIContextBar.prototype.DeleteSelectedItems=function(){if(!this._qh){var _VI=new Array();for(var i in this._aG){var _ad1=this._aG[i].GetDeleteAction();Debug.Assert(_ad1);_VI=_VI.concat(_ad1);this._aG[i].UnselectItem();}if(_VI.length>=1){this.oDataMgr.GetCurrentDataMatrix().SendDMActionArray(_VI);}}};CUIContextBar.prototype.CanDelete=function(){for(var i in this._aG){if(this._aG[i].CanDelete&&(!this._aG[i].CanDelete())){return false;}}return true;};CUIContextBar.prototype.GetSearchData=function(){var _7j=null;for(var i in this._aG){_7j=this._aG[i];break;}if(_7j){return _7j.GetSearchData();}return null;};CUIContextBar.prototype.GetSelectedBlock=function(){for(var i=0;i<this._aG.length;i++){if(this._aG[i]instanceof CUIAxisSimpleItem){return this._aG[i].GetBlock();}}return null;};CUIContextBar.prototype.getItemFromTarget=function(el){while(el&&(el!=this.oContextPane.GetDom())){if(el.kType&&el.kType==CUIContextBar.kTypeItem){return el;}el=el.parentNode;}return null;};CUIContextBar.prototype.SafeHandleDragOver=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e)var e=window.event;this.obj.DoDragOver(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIContextBar.prototype.DoDragOver=function(e){if(!this.oUIMgr._jf.AllowInteraction()){return;}var _yW=Dom.GetEventTarget(e);this._rl=null;var _Y2=false;this.HideAllDropZones();var oContextSet=this.getContextSetFromTarget(_yW);var _HF=this.oUIMgr.dataManager._kX;if(oContextSet instanceof CUIFilterContextSet){var _7a=this._oM.sMemId;var _agy=false;var _Tc=this.oUIMgr.dataManager.metadata;var _as2=this.oUIMgr.dataManager.GetCurrentWSFilterSet();if(this._oM.sCustomSetId){if(_HF.GetCustomSet(this._oM.sCustomSetId).CanUseAsBlockFilter()){_agy=true;}}else if(_HF.getBlock(this._oM.sBlockId)){_agy=true;}else if(_Tc.GetNamedSet(this._oM.sId)){if(_Tc.GetNamedSet(this._oM.sId).FromMeasureDim()){_agy=false;}else{_agy=true;}}else if(_Tc.GetMember(_7a)||_as2.GetFilterById(this._oM.sFilterId)){_agy=true;}if(this._oM instanceof CUIDragDropLevel){_agy=false;}var _adK=this.oDataMgr.GetCurrentDataMatrix();if(_adK&&!_adK.IsValidActionForSameHierCompatibilityRule(null,this._oM,null,null,true)){_agy=false;}var _Tc=this.oUIMgr.dataManager.metadata;if(_agy){var _7k=this.oFilterSet.ShowDropZone(e,this._oM);if(this._oM.bDelete){CUIDragDrop.setEffect(CUIDragDrop.eEffectMove);}else{CUIDragDrop.setEffect(CUIDragDrop.eEffectCopy);}_Y2=_7k;}}else if(oContextSet instanceof CUIAxisContextSet){var _7k=oContextSet.ShowDropZone(e,this._oM);if(this._oM.bDelete){CUIDragDrop.setEffect(CUIDragDrop.eEffectMove);}else{CUIDragDrop.setEffect(CUIDragDrop.eEffectCopy);}_Y2=_7k;}if(!_Y2){CUIDragDrop.setEffect(CUIDragDrop.eEffectNone);}Dom.CancelBubble(e);this.oContextPane.GetDom().onmouseout=CUIContextBar.SafeHandleMouseOut;CUIDragDrop.SetCursorImgPosition(e.clientX,e.clientY);};CUIContextBar.prototype.getContextSetFromTarget=function(_yW){while(_yW&&_yW!=this.oContextPane.GetDom()){if(_yW.oContextSet){return _yW.oContextSet;}_yW=_yW.parentNode;}return null;};CUIContextBar.SafeHandleMouseOut=function(e){try{if(!e)var e=window.event;this.obj.HandleMouseOut(e);}catch(e){_f.HandleException(e);}};CUIContextBar.prototype.HandleMouseOut=function(e){var _aqw=Dom.GetToElement(e);if(!Dom.IsDescendant(this.oContextPane.GetDom(),_aqw)){this.HideAllDropZones();}};CUIContextBar.prototype.HideAllDropZones=function(){this.oFilterSet.HideDropZones();for(var i=0;i<this.aAxisContextSets.length;i++){this.aAxisContextSets[i].HideDropZones();}};CUIContextBar.prototype.SetDropTarget=function(oContextSet,_Ux){if(!this._rl){this._rl=new Object();}Dom.SetObjRef(this._rl,oContextSet,'oContextSet');this._rl.iPos=_Ux;};CUIContextBar.prototype.SetDropData=function(_Wn){this._oM=_Wn;};CUIContextBar.prototype.SafeHandleDragDrop=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e)var e=window.event;this.obj.DoDragDrop(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIContextBar.prototype.DeferHandleDragDrop=function(_Lv,e){var _Yb=this._rl.oContextSet;var _axQ=Dom.CloneMouseEvent(e);var _BC=Utilities.GenerateCallback(_Yb.HandleDragDrop,[_Lv,_axQ],_Yb);var _Tc=this.oUIMgr.dataManager.metadata;_Tc.GetLineage(_Lv.GetOrphanAncestorArr(),_BC);};CUIContextBar.prototype.DoDragDrop=function(e){this.oContextPane.GetDom().onmouseout=null;if(!this.oUIMgr._jf.AllowInteraction()){return;}if(this._rl&&this._rl.oContextSet){if(this._oM.GetOrphanAncestorArr&&this._oM.GetOrphanAncestorArr()){this.DeferHandleDragDrop(this._oM,e);}else{this._rl.oContextSet.HandleDragDrop(this._oM,e);}}};CUIContextBar.prototype.ContinueUnselectAllItems=function(_RY){var _Lk=true;for(var i=0;this.oFilterSet&&i<this.oFilterSet.aContextItems.length;i++){this.oFilterSet.aContextItems[i].UnselectItem();}for(var i=0;i<this.aAxisContextSets.length;i++){for(var j=0;j<this.aAxisContextSets[i].aContextItems.length;j++){this.aAxisContextSets[i].aContextItems[j].UnselectItem();}}for(var i in this._aG.length){delete this._aG[i];}this._aG.length=0;if(!_RY){this.oUIWS.HandleUnselect(this,_Lk);}};CUIContextBar.SafeDoContinueUnselectAllItems=function(_N5,_RY){/*@if(!@bering_debug)@*/try{/*@end@*/_N5.ContinueUnselectAllItems(_RY);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIContextBar.prototype.UnselectAllItems=function(_RY){var _amW=this.oUIMgr.ConfirmLossOfChanges();if(_amW==Utilities.eStateContinue){this.ContinueUnselectAllItems(_RY);}else if(_amW==Utilities.eStateHold){var _Ro=new Array(this,_RY);Utilities.SetProcedureToHold(CUIContextBar.SafeDoContinueUnselectAllItems,_Ro);this.oUIMgr.oDialogMgr.Subscribe(this,ExpEvent.kCUIDialogMgr_HideModalDialog);}};CUIContextBar.prototype.Refresh=function(_EP){this.Create();this.Display(_EP);if(this.oUIMgr.dataManager.IsInMissingMUNState()){this.oContextPane.GetDom().style.visibility="hidden";if(this.oInfoPane){this.oInfoPane.GetDom().style.visibility="hidden";}}else{this.oContextPane.GetDom().style.visibility="visible";}};CUIContextBar.prototype.refreshAxisSets=function(){var _adK=this.oDataMgr.GetCurrentDataMatrix();var _aHO=this.oUIMgr.oUIDataMatrix;var _afq=_aHO.GetDefaultAxisCount();if(_adK){this.oDLDataMatrix=_adK;if(this.oDLDataMatrix.GetAxisCount()>_afq){_afq=this.oDLDataMatrix.GetAxisCount();}}var _amH=this.oUIMgr.GetCurrentWorkSheet();if(_amH!=this.oUIWS){this.oUIWS=this.oUIMgr.GetCurrentWorkSheet();this.subscribeToWSEvents();}var _ag6=this.oUIWS.GetUIAxesContainer();this._rQ=_afq;this._xM=_afq;for(var i=0;i<this.aAxisContextSets.length;i++){this.aAxisContextSets[i].Unload();}Utilities.DeleteAllFromArray(this.aAxisContextSets);Utilities.DeleteAllFromArray(this._aG);if(this._rl&&this._rl.oContextSet instanceof CUIAxisContextSet){this._rl.oContextSet=null;}if(this._h7){this._h7.oContextSet=null;this._b9.oContextSet=null;this.oLeftResizePane.GetDom().oContextSet=null;}if(this.aAxisFirstVis.length==0){for(var i=0;i<_afq;i++){this.aAxisFirstVis.push(0);}}for(var i=0;i<_afq;i++){this.aAxisContextSets.push(new CUIAxisContextSet(this,_ag6.GetUIAxis(i),i));this.aAxisContextSets[i].Create();if(this.aAxisContextSets[i].aContextItems.length>1){this._rQ+=this.aAxisContextSets[i].aContextItems.length-1;this._xM+=this.aAxisContextSets[i].aContextItems.length-1;}}};CUIContextBar.prototype.OnSplitterMove=function(_IM){if(_IM==this.oPaneSplitter){this._jA=true;this._rq=this._eR+this.oPaneSplitter.iLastMove;if(this._rq>this._qK+CUIPaneSplitter.kiStaticDimensionSize){this.HandleResize();}else{this._rq=this._eR;this.oPaneSplitter.SetLeft(this._eR-CUIContextBar.kiSplitterCorrection);}}else if(_IM==this.oAxisPaneSplitter){var _arO=this._qK+this.oAxisPaneSplitter.iLastMove;if(_arO<this._eR+CUIPaneSplitter.kiStaticDimensionSize){this._qK=_arO;this.HandleResize();}else{this.oAxisPaneSplitter.SetLeft(this._qK-CUIContextBar.kiSplitterCorrection);}}};CUIContextBar.prototype.Subscribe=function(obj,_Dy){if(this._b4[_Dy]){this._b4[_Dy].push(obj);}};CUIContextBar.prototype.OnWSRefresh=function(){if(this.bInit){this.refreshAxisSets();this.Display();}else{this.Refresh();}};CUIContextBar.prototype.OnFSRefresh=function(){this.refreshFilterSets();this.Display();};CUIContextBar.prototype.OnANSRefresh=function(){this.refreshAxisSets();this.refreshFilterSets();this.Display();};CUIContextBar.prototype.Notify=function(_Dy,_My){switch(_Dy){case ExpEvent.kCDLDataManager_CurrentWSFSChange:if(this.oDLFilterSet){this.oDLFilterSet.UnSubscribe(this,ExpEvent.kDLFilterSet_FullRefresh);}this.oDLFilterSet=this.oUIMgr.dataManager.GetCurrentWSFilterSet();this.oDLFilterSet.Subscribe(this,ExpEvent.kDLFilterSet_FullRefresh);this.refreshFilterSets();this.Display();break;case ExpEvent.kCDLDataManager_DataMatrixCreate:this.oDLDataMatrix=this.oUIMgr.appobj.dataManager.GetCurrentDataMatrix();break;case ExpEvent.kCUIArrowOnlyScrollControl_Scroll:for(var i=0;i<this.aAxisContextSets.length;i++){this.aAxisFirstVis[i]=this.aAxisScrollCtrls[i].GetFirstVisibleIndex();}this._pc=this._cZ.GetFirstVisibleIndex();this.Display();break;case ExpEvent.kCUIManager_Unload:this.HandleUnload();return;break;case ExpEvent.kCUIWorksheet_Busy:this._qh=true;break;case ExpEvent.kCUIWorksheet_Free:this._qh=false;this.SetSuppressionTooltip();break;case ExpEvent.kCUIDialogMgr_HideModalDialog:Utilities.ExecuteHoldingProcedure();this.HideAllDropZones();this.oUIMgr.oDialogMgr.UnSubscribe(this,ExpEvent.kCUIDialogMgr_HideModalDialog);break;}if(this._b4[_Dy]){for(var i=0;i<this._b4[_Dy].length;i++){this._b4[_Dy][i].Notify(_Dy);}}};CUIContextBar.prototype.updateAxisUnits=function(_BZ,_CQ){var _87=0;if(_BZ==0){_87=this.aAxisContextSets[_BZ].GetVisibleItemCount(this._qK-2*this.iArrowDisplayWidth);COTStyle.SetWidth(this._gP[_BZ].GetDom(),this._qK-2*this.iArrowDisplayWidth);this._oJ+=this._qK;}else{this._oJ+=2*this.iArrowDisplayWidth;_87=this.aAxisContextSets[_BZ].GetVisibleItemCount(_CQ-this._oJ);var _aJC=this.aAxisContextSets[_BZ].GetDisplayWidth();this._oJ+=_aJC;this._oJ=Math.min(this._oJ,_CQ);if(_BZ==0){this._qK=Math.min(_aJC+2*this.iArrowDisplayWidth,_CQ);}}var _4n=this.aAxisContextSets[_BZ].aContextItems.length;this.aAxisScrollCtrls[_BZ].SetUnits(this.aAxisFirstVis[_BZ],_87,_4n);var _ae0=this.aAxisScrollCtrls[_BZ].ShowIfNeeded();if(_ae0){this.aAxisStartArrows[_BZ].className='axis_scroll_arrow_vis';this.aAxisEndArrows[_BZ].className='axis_scroll_arrow_vis';this.aAxisSetPanes[_BZ].GetDom().style.overflow="hidden";}else{this.aAxisStartArrows[_BZ].className='axis_scroll_arrow';this.aAxisEndArrows[_BZ].className='axis_scroll_arrow';this.aAxisSetPanes[_BZ].GetDom().style.overflow="visible";}return _87;};CUIContextBar.prototype.HandleResize=function(){if(!this.oContextPane){return;}COTStyle.SetHeight(this.oContextPane.GetDom(),this._q4,'px');var _GK=this.iArrowDisplayWidth;var _Ol=this.getLeftPaneWidth();this._eR=_Ol;var _CQ=Math.max(_Ol,0);this._oJ=0;var _anG=0;for(var i=0;i<this._gP.length;i++){if(this._gP[i]){this.aAxisScrollPanes[i].SetPosition(this._oJ,0,'px');this.updateAxisUnits(i,_CQ);}}if(this.oAxisPaneSplitter&&this.aAxisScrollPanes[1]){var _asC=this.aAxisScrollPanes[1].GetDom().offsetLeft;this.oAxisPaneSplitter.SetLeft(_asC-CUIContextBar.kiSplitterCorrection);}else if(this.oAxisPaneSplitter&&!this.aAxisSetPanes[1]){this.oAxisPaneSplitter.Hide();}var _aCK=this.updatePaneSizes(_Ol,this._oJ,_GK);COTStyle.SetWidth(this.oFilterSetPane.GetDom(),_aCK);if(this._pc<(this._x1-1)){_anG=this.oFilterSet.GetVisibleItemCount(_aCK,this._q4);}this._cZ.SetUnits(null,_anG,this._x1);var _ae0=this._cZ.ShowIfNeeded();if(_ae0){this._fy.className='filter_scroll_arrow_vis';this._oH.className='filter_scroll_arrow_vis';this.oRightScrollPane.GetDom().style.overflow="hidden";}else{this._fy.className='filter_scroll_arrow';this._oH.className='filter_scroll_arrow';this.oRightScrollPane.GetDom().style.overflow="visible";}};CUIContextBar.prototype.ClearBlockCountMap=function(_Qz){var _ayo=this._xz;if(_ayo){if(_Qz>-1){Utilities.ClearObjectArray(_ayo[_Qz]);}else{for(var i in _ayo){Utilities.ClearObjectArray(_ayo[i]);}}}};CUIContextBar.prototype.HandleUnload=function(){if(this.aAxisContextSets){for(var i=0;i<this.aAxisContextSets.length;i++){this.aAxisContextSets[i].Unload();}}if(this.oFilterSet){this.oFilterSet.Unload();}Utilities.DeleteAllFromArray(this.aAxisContextSets);Utilities.DeleteAllFromArray(this.aContextSets);if(this.oFilterSetPane){this.oFilterSetPane.Unload();}if(this.aAxisSetPanes){for(var i=0;i<this.aAxisSetPanes.length;i++){if(this.aAxisSetPanes[i]){this.aAxisSetPanes[i].Unload();this.aAxisSetPanes[i]=null;}}this.aAxisSetPanes.length=0;}if(this._gP){Utilities.DeleteAllFromArray(this._gP);}if(this.aAxisScrollPanes&&this.aAxisScrollPanes.length){for(var i=0;i<this.aAxisScrollPanes.length;i++){if(this.aAxisScrollPanes[i]){this.aAxisScrollPanes[i].Unload();this.aAxisScrollPanes[i]=null;}}this.aAxisScrollPanes.length=0;}if(this.oInfoPane){this.oInfoPane.Unload();}if(this.oContextPane){this.oContextPane.Unload();}if(this._aG){Utilities.DeleteAllFromArray(this._aG);}if(this._cY){this.ClearBlockCountMap();}Utilities.RemoveAllChildObjects(this);};CUIContextBar.prototype.GetDIVObj=function(){return this.oContextPane.GetDom();};CUIContextBar.prototype.GetBlocksCountForDimId=function(_TW){var _1O=0;if(this._cY){for(var _Qz in this._xz){if(this._xz[_Qz][_TW]){_1O+=this._xz[_Qz][_TW];}}return _1O;}return _1O;};CUIContextBar.prototype.UpdateZeroSuppressType=function(_F5){var _HF=this.oUIMgr.dataManager._kX;_HF.ToggleZeroSuppressType(_F5);};CUIContextBar.prototype.ClearAllSuppress=function(){this.oDLDataMatrix.ClearAllSuppression();};CUIContextBar.SafeShowZeroSuppressDropDown=function(e,_Ke,x,y){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager._jf.oContextBar.ShowZeroSuppressDropDown(e,x,y);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIContextBar.prototype.ShowZeroSuppressDropDown=function(e,x,y){if(!this.oZeroSuppMenu){this.oZeroSuppMenu=new CUIContextMenu(this.oUIMgr.appobj.appname,0,this,null,false);CUIContextBar.AttachAxisSuppressOptions(this.oUIMgr.appobj.appname,this.oZeroSuppMenu);CUIContextBar.AttachZeroSuppressOptions(this.oUIMgr.appobj.appname,this.oZeroSuppMenu);}CUIContextBar.UpdateZeroSuppressOptions(this.oUIMgr.appobj.appname,this.oZeroSuppMenu,this);this.oZeroSuppMenu.display(e,false,x,y);};CUIContextBar.AttachZeroSuppressOptions=function(_Ke,_Ga){var _Mg=FindApp(_Ke);var _Co=_Mg.oResources;var _40=_Mg.uiManager;var _HF=_40.dataManager._kX;var _QA=_40.dataManager.metadata;var _BM=_Co.GetString('APP_MENUBAR_SUPP_NULLS');var _arX=new Array(_Ke,ExpAPIXml.eNullSuppress);var _aiu=new ContextItem('',_BM,CUIContextBar.SafeUpdateZeroSuppressType,(!_QA._nJ),_arX,_Ga);_aiu.id='APP_MENUBAR_SUPP_NULLS';_aiu.SetRadioState(!_HF._by);var _BM=_Co.GetString('APP_MENUBAR_SUPP_NULLS_AND_ZEROS');var _arX=new Array(_Ke,ExpAPIXml.eNullAndZeroSuppress);var _aiu=new ContextItem('',_BM,CUIContextBar.SafeUpdateZeroSuppressType,(!_QA._nJ),_arX,_Ga);_aiu.id='APP_MENUBAR_SUPP_NULLS_AND_ZEROS';_aiu.SetRadioState(_HF._by);return _Ga;};CUIContextBar.AttachAxisSuppressOptions=function(_Ke,_Ga){var _Co=FindApp(_Ke).oResources;var _40=FindApp(_Ke).uiManager;var _BM=_Co.GetString('APP_MENUBAR_REMOVE_ALL_SUPP');var _arX=new Array(_Ke,ExpAPIXml.eSuppressNone);var _aEz=new ContextItem('',_BM,CUIContextBar.SafeClearSuppress,false,_arX,_Ga);var _aIC=new ContextSeparator(_Ga);return _Ga;};CUIContextBar.UpdateZeroSuppressOptions=function(_Ke,_Ga,_N5){var _40=FindApp(_Ke).uiManager;var _Co=FindApp(_Ke).oResources;_Ga.ClearAllChecks();var _HF=_40.dataManager._kX;var _PM=_Ga.GetItemById('APP_MENUBAR_SUPP_NULLS');_PM.SetRadioState(!_HF._by);_PM=_Ga.GetItemById('APP_MENUBAR_SUPP_NULLS_AND_ZEROS');_PM.SetRadioState(_HF._by);return;};CUIContextBar.SafeUpdateZeroSuppressType=function(_Ke,_F5){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager._jf.oContextBar.UpdateZeroSuppressType(_F5);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIContextBar.SafeClearSuppress=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager._jf.oContextBar.ClearAllSuppress();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};function CUIAbsContextSet(_Rw){this.oParentBar=_Rw;this.elParent=null;this.aContextItems=new Array();this.elSet=null;};CUIAbsContextSet.prototype.Create=function(){this.oRes=this.oParentBar.oUIMgr.appobj.oResources;};CUIAbsContextSet.prototype.Display=function(_EP,_E3,_zr){if(_EP){this.elSet=_EP.GetDom();Dom.SetObjRef(this.elSet,this,'oContextSet');}this.sClassName=_E3;this.elTable=_zr;};CUIAbsContextSet.prototype.drawInsertArrow=function(_FW){if(this.aContextItems.length==0){this.aCells[0]=document.createElement('TD');_FW.appendChild(this.aCells[0]);this.aCells[0].vAlign="middle";COTStyle.SetHeight(this.aCells[0],CUIAbsContextItem.kDragIconHeight);var _7E=this.aCells[0].appendChild(document.createElement('IMG'));_7E.src=Utilities.IMG_PATH+"drag_drop.gif";}};CUIAbsContextSet.prototype.showEndDropZone=function(){this._lA=document.createElement('DIV');this.elSet.appendChild(this._lA);this._lA.className='end_drop_zone';this._lA.style.position='absolute';var _aAz=COTStyle.GetHorizontalExtrasWidth(this._lA);COTStyle.SetWidth(this._lA,CUIContextBar.kiDropBarWidth-_aAz);COTStyle.SetHeight(this._lA,CUIAbsContextItem.kDragIconHeight-4);var _azP=document.createElement("IMG");_azP.src=Utilities.IMG_PATH+"drop_caret_2x2.gif";COTStyle.SetHeight(_azP,100,'%');COTStyle.SetWidth(_azP,2);this._lA.appendChild(_azP);var _F4=COTStyle.GetDisplayOffsetWidth(this.elTable);var _adg=COTStyle.GetDisplayOffsetWidth(this.elSet);_F4=Math.min(_F4,_adg-2*CUIContextBar.kiDropBarWidth);_F4=Math.max(_F4,0);this._lA.style.left=_F4+"px";this._lA.style.visibility='visible';var _TM=this.oParentBar._q4-CUIContextBar.kiMargin-CUIAbsContextItem.kDragIconHeight-2;this._lA.style.top=_TM+"px";Dom.SetObjRef(this._lA,this,'oContextSet');this.oParentBar.SetDropTarget(this,this.aContextItems.length);return this.aContextItems.length;};CUIAbsContextSet.prototype.showSetDropZone=function(){this.aCells[0].className=this.sClassName+'_dragover';};CUIAbsContextSet.prototype.Refresh=function(_EP){Utilities.DeleteAllFromArray(this.aContextItems);Dom.RemoveAllChildren(this.elSet);this.Create();this.Display(_EP);};CUIAbsContextSet.prototype.Unload=function(){for(var i=0;i<this.aContextItems.length;i++){this.aContextItems[i].Unload();}Utilities.DeleteAllFromArray(this.aContextItems);if(this._lA){this._lA.oContextSet=null;Dom.RemoveObject(this._lA);this._lA=null;}if(this._tS){this._tS.oContextSet=null;Dom.RemoveObject(this._tS);this._tS=null;}if(this.elSet&&this.elSet.oContextSet){this.elSet.oContextSet=null;}if(this._rl&&this._rl.oItem){this._rl.oItem=null;}Utilities.RemoveAllChildObjects(this);};CUIAbsContextSet.prototype.getItemElement=function(el){while(el&&(el!=this.elSet)){if(el.kType&&el.kType==CUIContextBar.kTypeItem){return el;}el=el.parentNode;}return null;};CUIAbsContextSet.prototype.showDZFromEventPos=function(e){var _alQ=e.clientX+Dom.GetScrollLeft();var _6l=Dom.GetRelativeOffset(this.aContextItems[0].elParent,document.body).iLeft;var _3o=_6l;var _aDu=Dom.GetRelativeOffset(this.elSet,document.body).iLeft;var _amo=_aDu+COTStyle.GetDisplayOffsetWidth(this.elSet);_amo=_amo-2*this.oParentBar.iArrowDisplayWidth;var _adr=null;for(var i=1;i<this.aContextItems.length;i++){_3o=Dom.GetRelativeOffset(this.aContextItems[i].elParent,document.body).iLeft;if(_6l>_amo){return-1;}_adr=_6l+((_3o-_6l)/2);if(_alQ<_adr){return this.showDropZoneBeforeItem(i-1);}_6l=_3o;}var _aFq=COTStyle.GetDisplayOffsetWidth(this.aContextItems[this.aContextItems.length-1].elParent);var _abd=_3o+(_aFq/2);if(_3o>_amo){return-1;}if(_alQ<_abd){return this.showDropZoneBeforeItem(this.aContextItems.length-1);}else{return this.showEndDropZone();}};CUIAbsContextSet.prototype.showDropZoneBeforeItem=function(i){var _auo=CUIContextBar.kiDropBarWidth;if(!this._tS){this._tS=document.createElement('DIV');this.oParentBar.GetDIVObj().appendChild(this._tS);this._tS.className='end_drop_zone';this._tS.style.position='absolute';var _aAz=COTStyle.GetHorizontalExtrasWidth(this._tS);COTStyle.SetWidth(this._tS,_auo-_aAz);COTStyle.SetHeight(this._tS,CUIAbsContextItem.kDragIconHeight-4);var _azP=document.createElement("IMG");_azP.src=Utilities.IMG_PATH+"drop_caret_2x2.gif";COTStyle.SetHeight(_azP,100,'%');COTStyle.SetWidth(_azP,2);this._tS.appendChild(_azP);var _TM=this.oParentBar._q4-CUIContextBar.kiMargin-CUIAbsContextItem.kDragIconHeight-2;this._tS.style.top=_TM+"px";}var _CX=Dom.GetRelativeOffset(this.aContextItems[i].elParent,this.oParentBar.GetDIVObj()).iLeft;var _CX=Math.max(_CX,0);this._tS.style.left=(_CX-1)+'px';this._tS.style.visibility='visible';Dom.SetObjRef(this._tS,this,'oContextSet');this.oParentBar.SetDropTarget(this);return i;};CUIAbsContextSet.prototype.HideDropZones=function(){if(this.aCells[0]){this.aCells[0].className="";}if(this._lA){this._lA.style.visibility='hidden';}if(this._tS){this._tS.style.visibility='hidden';}if(this._rl&&this._rl.oItem){this._rl.oItem.HideDropZone();}};function CUIFilterContextSet(_Rw){this.base=CUIAbsContextSet;this.base(_Rw);this._cn=-1;};CUIFilterContextSet.prototype=new CUIAbsContextSet;CUIFilterContextSet.superclass=CUIAbsContextSet.prototype;CUIFilterContextSet.prototype.Create=function(){this._cn=-1;var _N5=this.oParentBar;CUIFilterContextSet.superclass.Create.call(this);if(_N5.oDLFilterSet!=null){var _ack=null;if(_N5._cY){_ack=_N5._xz[CUIContextBar.kiFilterContextSet];}for(var i=0;i<_N5.oDLFilterSet.GetFilterCount();i++){var _EB=_N5.oDLFilterSet.GetFilter(i);var _aew=null;if(_EB instanceof CDLBlockFilter&&_EB.GetBlock()){if(_ack){var _TW=_EB._rB.GetDimId();if(!_ack[_TW]){_ack[_TW]=1;}else{_ack[_TW]+=1;}}if(_EB._rB.IsHAMC()){_aew=new CUIMemberSetFLContextItem(this,i);}else{_aew=new CUIChildrenFLContextItem(this,i);}}if(_aew){_aew.Create(_EB);this.aContextItems.push(_aew);}}}this.InitRDropMenus();var _Ke=_N5.oUIMgr.appobj.appname;this.oFltContextSetMenu=new CUIContextMenu(_Ke,0);var _BM=_N5.oRes.GetString('IDS_CONTEXTBAR_DEL_ALL_FLT_CONTEXT_ITEMS');_PM=new ContextItem('',_BM,CUIFilterContextSet.SafeDoDeleteAllItems,false,null,this.oFltContextSetMenu);_PM.id='IDS_CONTEXTBAR_DEL_ALL_FLT_CONTEXT_ITEMS';};CUIFilterContextSet.prototype.GetFilterItemById=function(_DR){for(var i=0;i<this.aContextItems.length;i++){if(this.aContextItems[i].oDLFilter.elcid==_DR){return this.aContextItems[i];}}return null;};CUIFilterContextSet.prototype.Display=function(_BJ,_I8,_Ko,_E3){var _zr=document.createElement('TABLE');CUIFilterContextSet.superclass.Display.call(this,_BJ,_E3,_zr);if(_I8!=null){this.iFirstVisibleIdx=_I8;}_zr.className='filter_context_table';_zr.title=this.oRes.GetString('IDS_CONTEXTBAR_CONTEXT_TOOLTIP');this.elSet.appendChild(_zr);_zr.cellSpacing=0;_zr.cellPadding=0;COTStyle.SetHeight(_zr,95,'%');var _RK=document.createElement('TBODY');_RK.className='filter_context_tbody';_zr.appendChild(_RK);var _FW=document.createElement('TR');_RK.appendChild(_FW);var _aH3=document.createElement('TD');_FW.appendChild(_aH3);_aH3.colSpan=Math.max(this.aContextItems.length-this.iFirstVisibleIdx,1);var _abL=document.createElement('SPAN');_aH3.appendChild(_abL);_abL.className='rules_label';var _0o=document.createTextNode(this.oRes.GetString('IDS_BLOCK_PROPERTY_PANE_CONTEXT'));_abL.appendChild(_0o);var _FW=document.createElement('TR');_RK.appendChild(_FW);this.aCells=new Array();var _U4=_Ko;for(var i=this.iFirstVisibleIdx;i<this.aContextItems.length;i++){this.aCells[i]=document.createElement('TD');_FW.appendChild(this.aCells[i]);this.aContextItems[i].Display(this.aCells[i],'filter_context_item_name',_U4);_U4++;this.aCells[i].className='filter_context_item';}if(this.aContextItems.length==0){COTStyle.SetWidth(_zr,100,'%');this.drawInsertArrow(_FW);}if(this.aCells[0]){this.aCells[0].style.paddingLeft="7px";}};CUIFilterContextSet.eDZReplace=1;CUIFilterContextSet.eDZInitial=2;CUIFilterContextSet.eDZBtwItems=3;CUIFilterContextSet.prototype.OnContextMenuHide=function(){if(!CUIDragDrop.IsDragging()){this.HideDropZones();}};CUIFilterContextSet.prototype.ShowDropZone=function(e,_Lv){if(this.aContextItems.length==0){this.showSetDropZone();this._rl=new Object();this._rl.oItem=null;this._rl.eDropZoneType=CUIFilterContextSet.eDZInitial;}else{var _Oe=this.getItemElement(Dom.GetEventTarget(e));if(_Oe){if(!_Lv.sFilterId){_Oe.obj.ShowDropZone(e);this._rl=new Object();this._rl.oItem=_Oe.obj;this._rl.eDropZoneType=CUIFilterContextSet.eDZReplace;}else{this._rl=null;}}else{var _Us=this.showDZFromEventPos(e);if(_Us!=-1){this._rl=new Object();this._rl.oItem=null;this._rl.eDropZoneType=CUIFilterContextSet.eDZBtwItems;this._rl.iPos=_Us;}else{this._rl=null;}}}this.oParentBar.SetDropTarget(this);if(this._rl!=null){return true;}return false;};CUIFilterContextSet.prototype.Unload=function(){this.oReplaceRDropCntxMenu.Unload(true);this.oMoveRDropCntxMenu.Unload(true);this.oInsertRDropCntxMenu.Unload(true);if(this.oFltContextSetMenu&&this.oFltContextSetMenu.IsVisible()){CUIContextMenu.HideVisibleMenu();this.oFltContextSetMenu.Unload(true);}this.oParentBar.ClearBlockCountMap(CUIContextBar.kiFilterContextSet);CUIFilterContextSet.superclass.Unload.call(this);};CUIFilterContextSet.prototype.InitRDropMenus=function(){this.oReplaceRDropCntxMenu=new CUIContextMenu(this.oParentBar.oUIMgr.appobj.appname,0,this);this.oMoveRDropCntxMenu=new CUIContextMenu(this.oParentBar.oUIMgr.appobj.appname,0,this);this.oInsertRDropCntxMenu=new CUIContextMenu(this.oParentBar.oUIMgr.appobj.appname,0,this);var _IS=false;var _aCV=null;_BM=this.oParentBar.oRes.GetString('OTH_WORKSHEET_MULTI_MEM_REPLACE');_PM=new ContextItem('',_BM,null,_IS,_aCV,this.oReplaceRDropCntxMenu);_PM.SetAsDefault(true);_PM.id='OTH_WORKSHEET_MULTI_MEM_REPLACE';_BM=this.oParentBar.oRes.GetString('OTH_WORKSHEET_MULTI_MEM_INSERT');_PM=new ContextItem('',_BM,null,_IS,_aCV,this.oInsertRDropCntxMenu);_PM.SetAsDefault(true);_PM.id='OTH_WORKSHEET_MULTI_MEM_INSERT';_BM=this.oParentBar.oRes.GetString('OTH_WORKSHEET_MOVE_HERE');_PM=new ContextItem('',_BM,null,_IS,_aCV,this.oMoveRDropCntxMenu);_PM.SetAsDefault(true);_PM.id='OTH_WORKSHEET_MOVE_HERE';var _BM=this.oParentBar.oRes.GetString('OTH_WORKSHEET_CANCEL_DROP');_PM=new ContextItem('',_BM,null,_IS,_aCV,this.oReplaceRDropCntxMenu);_PM.id='OTH_WORKSHEET_CANCEL_DROP';_PM.Clone(this.oInsertRDropCntxMenu);_PM.Clone(this.oMoveRDropCntxMenu);};CUIFilterContextSet.prototype.SetDZMenu=function(_zA,_Ga,_Lv){var _Co=this.oParentBar.oRes;var _aln=_zA.length;var _35=this.oParentBar.oUIMgr._jf.GetIncludeDetailFlag();for(var x=0;x<_Ga.items.length;x++){var _PM=_Ga.items[x];var _ayg=new Array();_PM.SetItemAction(CUIFilterContextSet.SafeDoInsertDropData);switch(_PM.id){case 'OTH_WORKSHEET_CANCEL_DROP':_ayg=null;_PM.SetItemAction(CUIContextMenu.SafeDoHidePopupMenu);break;case 'OTH_WORKSHEET_MULTI_MEM_REPLACE':case 'OTH_WORKSHEET_MULTI_MEM_INSERT':if(_Lv.aOtherMemIds!=null||!_35){_zA[_aln]=ExpAPIXml.kMemberPopulation;}else{_zA[_aln]=ExpAPIXml.kChildrenPopulation;}break;}if(_ayg!=null){for(var i=0;i<_zA.length;i++){_ayg[i]=_zA[i];}}_Ga.items[x].SetParameterArr(_ayg);}};CUIFilterContextSet.SafeDoInsertDropData=function(oContextSet,_Lv){/*@if(!@bering_debug)@*/try{/*@end@*/oContextSet.HandleDragDrop(_Lv);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIFilterContextSet.prototype.ContinueHandleDragDrop=function(_Lv,e){if(e&&!Dom.IsLeftButton(e)){_zA=new Array(this,_Lv);var _Ga=this.oInsertRDropCntxMenu;if(_Lv.bDelete){_Ga=this.oMoveRDropCntxMenu;}else if(this._rl.eDropZoneType==CUIFilterContextSet.eDZReplace){_Ga=this.oReplaceRDropCntxMenu;}this.SetDZMenu(_zA,_Ga,_Lv);_Ga.display(e);return;}if(this.oParentBar.oDLFilterSet){Debug.Assert(_Lv);var _Tc=this.oParentBar.oUIMgr.dataManager.metadata;var _as2=this.oParentBar.oUIMgr.dataManager.GetCurrentWSFilterSet();var _Li=this.oParentBar.oUIMgr.dataManager.GetCurrentDataMatrix();var _aew=null;if(_Lv.sFilterId!=null){_aew=this.GetFilterItemById(_Lv.sFilterId);if(this._rl==null){return;}}if(_aew&&this._rl&&this._rl.eDropZoneType!=CUIFilterContextSet.eDZReplace){if(this._rl.iPos==_aew.iParentIdx||this._rl.iPos==_aew.iParentIdx+1){this.HideDropZones();return;}this.ReorderFilter(_Lv.sFilterId,this._rl.iPos);}else{var _J5=_Lv.GetRealMembers(_Tc);var _BX=_Lv.sMemId;if(this._rl&&this._rl.eDropZoneType==CUIFilterContextSet.eDZReplace){if(CUIDragDrop.m_oSrcListener==this._rl.oItem){this.HideDropZones();return;}var _UU=null;var _35=this.oParentBar.oUIMgr._jf.GetIncludeDetailFlag();var _Us=this._rl.oItem.oDLFilter.GetPosition();if(_Lv.sBlockId){_UU=this.oParentBar.oDLFilterSet.GetInsertActionForBlock(_Lv.sBlockId,_Us);}else if(_Lv.sCustomSetId){_UU=this.oParentBar.oDLFilterSet.GetInsertActionForCustomSet(_Lv.sCustomSetId,_Us);}else if(_Lv.sNamedSetId){_UU=this.oParentBar.oDLFilterSet.GetInsertActionForNamedSet(_Lv.sNamedSetId,_Us);}else if(_J5||!_35){if(!_J5){_J5=new Array(_BX);}_UU=this.oParentBar.oDLFilterSet.GetInsertActionForMemberList(_J5,_Us);}else{_UU=this.oParentBar.oDLFilterSet.GetInsertActionForMember(_BX,_Us);}var _abW=_Tc.IsFunctionSupported(ExpAPIXml.kQosMultiHierOfSameDim)?_Lv.GetHierOrDimId(_Tc,_Li):_Lv.GetDimId(_Tc,_Li);this.oParentBar.oDLFilterSet.ReplaceFilter(_UU,_abW,this._rl.oItem.oDLFilter);}else{if(this._cn!=-1&&this._rl&&this._rl.iPos>this._cn){this._rl.iPos++;}var _Us=null;if(this._rl&&this._rl.iPos!==null){var _Us=this._rl.iPos;}if(_Lv.sBlockId||_Lv.sCustomSetId){var _Lx=_Lv.sBlockId;if(_Lx==null){_Lx=_Lv.sCustomSetId;}this.oParentBar.oDLFilterSet.InsertComplexFilter(_Lx,_Us);}else{this.InsertDimFilter(_J5?_J5:new Array(_BX),_Us);}}}}};CUIFilterContextSet.SafeDoContinueHandleDragDrop=function(oContextSet,_Lv,e){/*@if(!@bering_debug)@*/try{/*@end@*/oContextSet.ContinueHandleDragDrop(_Lv,e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIFilterContextSet.prototype.HandleDragDrop=function(_Lv,e){var _Ke=this.oParentBar.oUIMgr.appobj.appname;var _HF=this.oParentBar.oUIMgr.dataManager._kX;var _FK=_HF.getBlock(_Lv.sBlockId);if(_FK&&!_FK.CanBeUsedAsContextFilter()){CUIDialogMgr.DisplayMessageBox(CUIMessageBox.kWarning,"MES_CANNOT_ADD_AS_CONTEXT");this.HideDropZones();return;}var _amW=this.oParentBar.oUIMgr.ConfirmLossOfChanges();if(_amW==Utilities.eStateContinue){this.ContinueHandleDragDrop(_Lv,e);}else if(_amW==Utilities.eStateHold){var _axQ=Dom.CloneMouseEvent(e);var _Ro=new Array(this,_Lv,_axQ);Utilities.SetProcedureToHold(CUIFilterContextSet.SafeDoContinueHandleDragDrop,_Ro);this.oParentBar.oUIMgr.oDialogMgr.Subscribe(this.oParentBar,ExpEvent.kCUIDialogMgr_HideModalDialog);}};CUIFilterContextSet.SafeDoInsertDimFilter=function(_Ke,_Lv){/*@if(!@bering_debug)@*/try{/*@end@*/var _Hk=FindApp(_Ke).uiManager;_Hk._jf.oContextBar.oFilterSet.HandleDragDrop(_Lv);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIFilterContextSet.SafeDoModifyDimFilter=function(_Ke,_OE){/*@if(!@bering_debug)@*/try{/*@end@*/var _Hk=FindApp(_Ke).uiManager;if(window.oLastFilter){window.oLastFilter.ModifyFilter(_OE);}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIFilterContextSet.SafeDoDeleteAllItems=function(_Ke,_zZ){/*@if(!@bering_debug)@*/try{/*@end@*/var _Hk=FindApp(_Ke).uiManager;_Hk._jf.oContextBar.oFilterSet.DeleteAllItems(_zZ);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIFilterContextSet.prototype.DeleteAllItems=function(_zZ){if(!this.oParentBar._qh){var _VI=new Array();for(var i=0;i<_zZ.length;i++){var _ad1=_zZ[i].GetDeleteAction();_VI=_VI.concat(_ad1);}if(_VI.length>=1){this.oParentBar.oDataMgr.GetCurrentDataMatrix().SendDMActionArray(_VI);}}};CUIFilterContextSet.prototype.ReorderFilter=function(_Od,_z3){var _EB=this.oParentBar.oDLFilterSet.GetFilterById(_Od);Debug.Assert(_EB);_EB.ModifyPos(_z3);};CUIFilterContextSet.prototype.InsertDimFilter=function(_Rb,_Us){this.oParentBar.oDLFilterSet.InsertDimFilter(_Rb,_Us);};CUIFilterContextSet.prototype.GetVisibleItemCount=function(_F4,_T6){if(this.aContextItems.length==0){return 1;}else{var _aoO=0;for(var i=this.iFirstVisibleIdx;i<this.aContextItems.length;i++){_aoO+=COTStyle.GetDisplayOffsetWidth(this.aCells[i]);if(_aoO>_F4){return i-this.iFirstVisibleIdx;}}return this.aContextItems.length-this.iFirstVisibleIdx;}};function CUIAbsContextItem(_Dx,_Dl){this.oParentSet=_Dx;this.sLabel=null;this.sIcon=null;this.bSelected=false;this.bDragOver=false;this.elItem=null;this.sClassName=null;this.iParentIdx=_Dl;};CUIAbsContextItem.kDragIconHeight=22;CUIAbsContextItem.prototype.IsAxisItem=function(){return false;};CUIAbsContextItem.prototype.IsSelectable=function(){return true;};CUIAbsContextItem.prototype.Create=function(_BM,_Gm){this.sLabel=_BM;this.sIcon=_Gm;this.oContextMenu=new CUIContextMenu(this.oParentSet.oParentBar.oUIMgr.appobj.appname,0,this);};CUIAbsContextItem.prototype.OnContextMenuHide=function(_Ga){var _Mz=document.getElementById(this.sArrowId);if(_Mz&&_Ga==this.oContextMenu){_Mz.bPressed=false;this.SetArrowStyle(_Mz);}};CUIAbsContextItem.prototype.Display=function(_Oe,_E3){if(_Oe){this.elItem=_Oe;}if(_E3){this.sClassName=_E3;}this.SetStyle();Dom.SetObjRef(this.elItem,this,'obj');this.elItem.kType=CUIContextBar.kTypeItem;this.elItem.onmouseover=CUIAbsContextItem.SafeHandleMouseOver;this.elItem.onmouseout=CUIAbsContextItem.SafeHandleMouseOut;};CUIAbsContextItem.prototype.OnDragStart=function(e){if(this.oParentSet.oParentBar.oUIMgr.oDialogMgr.IsModalDialogDisplayed()){return false;}return true;};CUIAbsContextItem.SafeHandleMouseOver=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}if(!CUIDragDrop.IsDragging()){this.obj.bHover=true;this.obj.SetStyle();}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIAbsContextItem.SafeHandleMouseOut=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}this.obj.bHover=false;this.obj.SetStyle();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIAbsContextItem.prototype.GetDeleteAction=function(){Debug.Assert(false,'GetDeleteAction needs to be implemented by derived classes ');};CUIAbsContextItem.prototype.ContinueSelectItem=function(_RY){var _ayR=false;if(!_RY&&this.IsAxisItem()&&this.GetFirstBlock()!=this.oParentSet.oParentBar.GetSelectedBlock()){_ayR=true;}if(!this.bSelected){var _3W=true;this.oParentSet.oParentBar.UnselectAllItems(_3W);this.oParentSet.oParentBar.AddSelectedItem(this);this.bSelected=true;this.SetStyle();}if(this.oParentSet instanceof CUIFilterContextSet||(this instanceof CUIAxisComboItem)){if(!_RY){this.oParentSet.oParentBar.oUIWS.HandleUnselect(this.oParentSet.oParentBar,true);}}else{if(!_RY&&this.IsAxisItem()&&_ayR){this.oParentSet.oParentBar.oUIWS.HandleBlockSelection(this.oParentSet.oParentBar,this.GetFirstBlock());}}};CUIAbsContextItem.SafeDoContinueSelectItem=function(oContextItem,_RY){/*@if(!@bering_debug)@*/try{/*@end@*/oContextItem.ContinueSelectItem(_RY);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIAbsContextItem.prototype.SelectItem=function(_RY){var _amW=Utilities.eStateContinue;if(!this.bSelected){_amW=this.oParentSet.oParentBar.oUIMgr.ConfirmLossOfChanges();}if(_amW==Utilities.eStateContinue){this.ContinueSelectItem(_RY);}else if(_amW==Utilities.eStateHold){var _Ro=new Array(this,_RY);Utilities.SetProcedureToHold(CUIAbsContextItem.SafeDoContinueSelectItem,_Ro);this.oParentSet.oParentBar.oUIMgr.oDialogMgr.Subscribe(this.oParentSet.oParentBar,ExpEvent.kCUIDialogMgr_HideModalDialog);}};CUIAbsContextItem.prototype.UnselectItem=function(){this.bSelected=false;this.SetStyle();this.oParentSet.oParentBar.RemoveSelectedItem(this);};CUIAbsContextItem.prototype.HideDropZone=function(){this.bDragOver=false;this.SetStyle();};CUIAbsContextItem.prototype.ShowDropZone=function(e,_F2){this.bDragOver=true;this.bHAMCDrag=_F2;this.SetStyle();};CUIAbsContextItem.prototype.SetStyle=function(){if(this.elItem){if(this.bSelected){this.elItem.className=this.sClassName+'_selected';}else if(this.bHover&&!this.bDragOver){this.elItem.className=this.sClassName+'_hover';}else{this.elItem.className=this.sClassName;}if(this.bDragOver&&this.bHAMCDrag){this.elItem.className+=" context_item_HAMCdragover";}else if(this.bDragOver){this.elItem.className+=" context_item_dragover";}}};CUIAbsContextItem.prototype.showDropDownMenu=function(e){var _Qb=Dom.GetRelativeOffset(this.elItem,document.body);var x=_Qb.iLeft+2;var y=_Qb.iTop+COTStyle.GetDisplayOffsetHeight(this.elItem);this.oContextMenu.display(e,false,x,y);};CUIAbsContextItem.prototype.Unload=function(){if(this.elItem){Dom.RemoveObject(this.elItem);this.elItem=null;}if(this.elLink){this.elLink=null;}this.oContextMenu.Unload();this.base=null;Utilities.RemoveAllChildObjects(this);};CUIAbsContextItem.prototype.ContinueHandleMouseDownOnArrow=function(_Sm,e){this.oParentSet.oParentBar.oUIMgr.OnSelChange(this.oParentSet.oParentBar);this.SelectItem();this.SetArrowStyle(_Sm);if(Dom.IsLeftButton(e)||!this.elParent||!this.elParent.oncontextmenu){_Sm.bPressed=true;this.HandleMouseDown(e);}else{this.oParentSet.oParentBar.oUIMgr._jf._dO.ShowBlockContextMenu(this.oDLBlock,e);}};CUIAbsContextItem.SafeContinueHandleMouseDownOnArrow=function(oContextItem,_Sm,e){/*@if(!@bering_debug)@*/try{/*@end@*/oContextItem.ContinueHandleMouseDownOnArrow(_Sm,e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIAbsContextItem.SafeHandleMouseDownOnArrow=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e)var e=window.event;var _auN=this.obj;if((!_auN.oParentSet.oParentBar._qh)){var _amW=Utilities.eStateContinue;var _N5=_auN.oParentSet.oParentBar;if(!_auN.bSelected){_amW=_N5.oUIMgr.ConfirmLossOfChanges();}Dom.CancelBubble(e);if(_amW==Utilities.eStateContinue){_auN.ContinueHandleMouseDownOnArrow(_auN,e);}else if(_amW==Utilities.eStateHold){var _axQ=Dom.CloneMouseEvent(e);var _Ro=new Array(_auN,this,_axQ);Utilities.SetProcedureToHold(CUIAbsContextItem.SafeContinueHandleMouseDownOnArrow,_Ro);_N5.oUIMgr.oDialogMgr.Subscribe(_N5,ExpEvent.kCUIDialogMgr_HideModalDialog);}}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIAbsContextItem.SafeHandleMouseOverOnArrow=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/this.bHover=true;this.obj.SetArrowStyle(this);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIAbsContextItem.SafeHandleMouseOutOnArrow=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/this.bHover=false;this.obj.SetArrowStyle(this);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIAbsContextItem.prototype.addAncestorToMenu=function(oMem,_Ga,_BC,_Fu,_BZ,x,y,_I7){var _Ke=this.oParentSet.oParentBar.oUIMgr.appobj.appname;var _CU=FindApp(_Ke).oResources;var _Ss=false;var _VW=oMem._qR;var _aig=new Array();var _aht=null;while(_VW&&_VW._p8&&_VW._ks){_aht=new Object();_aht.elcid=_VW._ks;_aht.label=_VW._p8;_aig.push(_aht);_VW=_VW._qR;}for(var i=_aig.length-1;i>=0;i--){var _AG=new Array(_Ke,_aig[i].elcid,_Fu,_BZ);var _Hn=new ContextItem('',_aig[i].label,_BC,_Ss,_AG,_Ga);var _aIC=new ContextSeparator(_Ga);}};CUIAbsContextItem.prototype.loadMetadataIntoMenu=function(oMem,_BC,e,_Fu,_BZ,_Ga,x,y,_I7){if(!_Ga){var _Ga=this.oContextMenu;}if(oMem!=null){this.addAncestorToMenu(oMem,_Ga,_BC,_Fu,_BZ,x,y,_I7);}this.addChildrenToMenu(oMem,_Ga,_BC,e,_Fu,_BZ,x,y,_I7);};CUIAbsContextItem.prototype.GetSubMenuItems=function(oContextItem,e,x,y){if(x!=null&&y!=null){this._sK=x;this._sL=y;}else{var x=this._sK;var y=this._sL;}if(e){this.elName.oLastEvent=Dom.CloneMouseEvent(e);}else{var e=this.elName.oLastEvent;}var _OE=oContextItem.aCallbackParams[1];var _Fu=oContextItem.aCallbackParams[2];var _BZ=oContextItem.aCallbackParams[3];var _Tc=this.oParentSet.oParentBar.oUIMgr.appobj.dataManager.metadata;var oMem=_Tc.GetMemberOrMeasure(_OE);var _BC=oContextItem._action;oContextItem._o6.Clear();this._lg=oContextItem;if(oContextItem._p5.IsVisible()){this.addChildrenToMenu(oMem,oContextItem._o6,_BC,e,_Fu,_BZ,x,y,oContextItem);}};CUIAbsContextItem.prototype.GetMaxChildCount=function(){return 8;};CUIAbsContextItem.prototype.addChildrenToMenu=function(oMem,_Ga,_BC,e,_Fu,_BZ,x,y,_I7){var _CU=this.oParentSet.oParentBar.oUIMgr.appobj.oResources;var _Ke=this.oParentSet.oParentBar.oUIMgr.appobj.appname;var _Ss=false;var _ZT=false;var _aaa=false;var _ah7=oMem.GetChildCount(_aaa);var _as4=false;if(this.GetMaxChildCount()<_ah7){_ah7=this.GetMaxChildCount();_as4=true;}var _6k=0;for(var i=0;i<_ah7;i++){this._xd=false;_ZT=true;var _AG=new Array(_Ke,oMem.GetChild(i,_aaa)._ks,_Fu,_BZ);if(!oMem.GetChild(i,_aaa).IsComplete()||oMem.GetChild(i,_aaa).GetChildCount(_aaa)){var _56=new CUIContextMenu(_Ke,_Ga._dl+1,this);}if(this._nd!=-1){var _aGI=true;var item=new ContextItem('',oMem.GetChild(i,_aaa)._p8,_BC,_Ss,_AG,_Ga,_56,_aGI);var _PQ=this._sT!=-1?this._sT:this._nd;item.AddToParentMenu(_Ga,_PQ+i);_6k=_PQ+i;}else{var item=new ContextItem('',oMem.GetChild(i,_aaa)._p8,_BC,_Ss,_AG,_Ga,_56);if(i==0){this._sT=_Ga.items.length-1;}_6k=_Ga.items.length-1;}}if(_as4){_BM=_CU.GetString('OTH_CONTEXTBAR_MORE_CHILDREN');var _aGI=true;var _awQ=new ContextItem('',_BM,null,true,null,_Ga,null,_aGI);_awQ.AddToParentMenu(_Ga,_6k+1);}if(oMem.IsComplete()||_ZT){_Ga.SetChildrenComplete();}if(this._qA){var _7R=_CU.GetString('IDS_CONTEXTBAR_LOAD_TIMEOUT');var _agz=new ContextItem('',_7R,null,true,null,_Ga);this._qA=false;this._xd=true;}else if(!oMem.IsComplete()&&!_as4){this._xd=false;oMem.Populate();oMem.Subscribe(this,ExpEvent.kCDLMember_Merge);oMem.Subscribe(this,ExpEvent.kCDLMember_Merge_NoResponse);var _aBd=_CU.GetString('IDS_CONTEXTBAR_LOADING');var _agz=new ContextItem('',_aBd,null,true,null,_Ga);this._nd=_Ga.items.length-1;this._kt=_Ga;}if(e){var _IG=false;if(_Ga._dl==0){this.showDropDownMenu(e);}else{_Ga.display(e,_IG,x,y,_I7);}}};CUIAbsContextItem.prototype.handleMetadataMerge=function(oMem){if(this._kt.IsVisible()){if(this._kt._dl>0){this.GetSubMenuItems(this._lg);}else{if(this._nd!=-1&&this._sT==-1){this.oContextMenu.DeleteItem(this._nd);}else{this.oContextMenu.DeleteSequence(this._sT,this._nd);}this.addChildrenToMenu(oMem,this.oContextMenu,CUIFilterContextSet.SafeDoModifyDimFilter,this.elName.oLastEvent);}}};CUIAbsContextItem.prototype.SetArrowStyle=function(_Mz){_Mz.className='dropdown_arrow';if(_Mz.bPressed){_Mz.className+=' button_pressed';}else if(_Mz.bHover){_Mz.className+=' button_hover';}};CUIAbsContextItem.prototype.constructTooltip=function(_FK,_QG){if(_FK.IsChildren()){var _Tc=this.oParentSet.oParentBar.oUIMgr.appobj.dataManager.metadata;this.sTooltip=_Tc.GetData(_FK.GetMemberIdFromDim()).GetLineageLabel();}else{this.sTooltip=this.sLabel;}var _apV='IDS_CONTEXTBAR';if(_FK.IsLocked()){_apV+='_LOCKED';}if(_FK.HasExcludedList()||_FK.HasTopBottomRule()){_apV+='_FILTERED';}if(_FK.IsExplicitSort()&&!_QG){_apV+='_SORTED';}if(_apV!='IDS_CONTEXTBAR'){_apV+='_BLOCK';this.sTooltip=this.oParentSet.oRes.ReplaceParam(_apV,1,this.sTooltip);if(_FK.HasExcludedList()||_FK.HasTopBottomRule()){this.sTooltip=this.oParentSet.oRes.ReplaceParam(this.sTooltip,2,_FK.GetFilterExprTooltip());}if(_FK.IsExplicitSort()&&!_QG){this.sTooltip=this.oParentSet.oRes.ReplaceParam(this.sTooltip,3,_FK.GetSortLabel());}}};CUIAbsContextItem.prototype.drawDropDownArrow=function(_EP){var _9v=document.createElement('IMG');_EP.appendChild(_9v);_9v.src=Utilities.IMG_PATH+'context_menu_button.gif';COTStyle.SetSize(_9v,10,CUIAbsContextItem.kDragIconHeight);_9v.className='dropdown_arrow';_9v.onmousedown=CUIAbsContextItem.SafeHandleMouseDownOnArrow;_9v.onmouseover=CUIAbsContextItem.SafeHandleMouseOverOnArrow;_9v.onmouseout=CUIAbsContextItem.SafeHandleMouseOutOnArrow;Dom.SetObjRef(_9v,this,'obj');this.sArrowId=Utilities.GenerateId();_9v.id=this.sArrowId;return _9v;};function CUIAxisContextItem(_Dx,_Qj,_BZ){this.base=CUIAbsContextItem;this.base(_Dx,_Qj);this.iAxisIdx=_BZ;this.bDraggable=false;};CUIAxisContextItem.prototype=new CUIAbsContextItem;CUIAxisContextItem.superclass=CUIAbsContextItem.prototype;CUIAxisContextItem.kNonFlt=0;CUIAxisContextItem.kExcludeFltOnly=1;CUIAxisContextItem.kTBFltOnly=2;CUIAxisContextItem.kUserDefFltOnly=3;CUIAxisContextItem.kMultiFltCombo=4;CUIAxisContextItem.kExcludeFltLocked=5;CUIAxisContextItem.kTBFltLocked=6;CUIAxisContextItem.kUserDefFltLocked=7;CUIAxisContextItem.kMultiFltComboLocked=8;CUIAxisContextItem.aFltComboTypeImgMap=new Object();CUIAxisContextItem.aFltComboTypeImgMap[CUIAxisContextItem.kExcludeFltOnly]='excluded_items.gif';CUIAxisContextItem.aFltComboTypeImgMap[CUIAxisContextItem.kTBFltOnly]='icon_topBottom16.gif';CUIAxisContextItem.aFltComboTypeImgMap[CUIAxisContextItem.kUserDefFltOnly]='filter_16.gif';CUIAxisContextItem.aFltComboTypeImgMap[CUIAxisContextItem.kMultiFltCombo]='generic_filter.gif';CUIAxisContextItem.aFltComboTypeImgMap[CUIAxisContextItem.kExcludeFltLocked]='excluded_item_lock.gif';CUIAxisContextItem.aFltComboTypeImgMap[CUIAxisContextItem.kTBFltLocked]='top_bottom_lock.gif';CUIAxisContextItem.aFltComboTypeImgMap[CUIAxisContextItem.kUserDefFltLocked]='icon_filter_hold.gif';CUIAxisContextItem.aFltComboTypeImgMap[CUIAxisContextItem.kMultiFltComboLocked]='generic_filter_lock.gif';CUIAxisContextItem.prototype.IsAxisItem=function(){return true;};CUIAxisContextItem.prototype.GetDepth=function(){return this.iParentIdx;};CUIAxisContextItem.SafeOnMouseDownOnDragHandle=function(e){try{if(!e){var e=window.event;}if(!this.obj.oParentSet.oParentBar._qh){CUIDragDropSource.HandleMouseDown(e,this,this.obj,null,this.obj.bDraggable);}}catch(e){_f.HandleException(e);}};CUIAxisContextItem.prototype.Display=function(_EP,_E3,_U4,_FW){_EP.className="axis_context_item";Dom.RemoveAllChildren(this.elName);this.elName=document.createElement('DIV');var _NM=_FW.appendChild(document.createElement('TD'));_NM.appendChild(this.elName);this.elParent=_EP;var _YN=document.createElement('TABLE');var _aHV=_YN.appendChild(document.createElement('TBODY'));var _akt=_aHV.appendChild(document.createElement('TR'));_YN.cellPadding=0;_YN.cellSpacing=0;this.elName.appendChild(_YN);Dom.SetObjRef(this.elName,this,'obj');CUIAxisContextItem.superclass.Display.call(this,_NM,_E3);var _Xr=this.oDLBlock.GetFilterCombinationType();if(_Xr!=CUIAxisContextItem.kNonFlt){var _ayY=CUIAxisContextItem.aFltComboTypeImgMap[_Xr];var _BC=null;var _Ke=this.oParentSet.oParentBar.oUIMgr.appobj.appname;switch(_Xr){case CUIAxisContextItem.kTBFltOnly:_BC=Utilities.GenerateCallback(CUIWorkSheet.SafeDoShowTopBottomDlg,[_Ke]);break;case CUIAxisContextItem.kUserDefFltOnly:_BC=Utilities.GenerateCallback(CUIWorkSheet.SafeOpenFilterDlg,[_Ke]);break;default:_BC=Utilities.GenerateCallback(CUICrosstab.SafeDoToggleBlockPropPane,[_Ke]);break;}var _afT=COTInputElementFactory.CreateImage(_ayY,16,16,_BC);_afT.className='filter_icon';var _ah1=_akt.appendChild(document.createElement('TD'));_ah1.className='context_item_name_component';_ah1.appendChild(_afT);}else if(this.oDLBlock.IsLocked()){var _BC=Utilities.GenerateCallback(CUICrosstab.SafeDoToggleBlockPropPane,[_Ke]);var _afT=COTInputElementFactory.CreateImage('icon_hold.gif',16,16,_BC);_afT.className='filter_icon';var _ah1=_akt.appendChild(document.createElement('TD'));_ah1.className='context_item_name_component';_ah1.appendChild(_afT);}if(this.oDLBlock.IsExplicitSort()){_afT=document.createElement('IMG');var _ah1=_akt.appendChild(document.createElement('TD'));_ah1.className='context_item_name_component';_ah1.appendChild(_afT);if(this.oDLBlock.IsAscending()){_afT.src=Utilities.IMG_PATH+'summary_sort_ascending.gif';}else{_afT.src=Utilities.IMG_PATH+'summary_sort_descending.gif';}COTStyle.SetHeight(_afT,16);COTStyle.SetWidth(_afT,16);_afT.className='filter_icon';}_EP.title=this.sTooltip;var _arJ=_akt.appendChild(document.createElement('TD'));_arJ.className='context_item_name_component';this.elLink=document.createElement('A');this.elLink.tabIndex=_U4;Dom.SetObjRef(this.elLink,this,'obj');this.elLink.className='invisible_link';_arJ.appendChild(this.elLink);var _ady=Utilities.GetTruncatedString(this.sLabel,CUIContextBar.kLabelTruncateLength,this.oParentSet.oRes);var _aBx=document.createTextNode(_ady);this.elLink.appendChild(_aBx);this.sLevelLabel=_aBx;var _NM=_FW.appendChild(document.createElement('TD'));this.drawDropDownArrow(_NM);};CUIAxisContextItem.prototype.HandleContextMenu=function(e){};CUIAxisContextItem.prototype.SetLabel=function(_BM){this.sLevelLabel.nodeValue=_BM;};CUIAxisContextItem.SafeDoDrill=function(_Ke,_Df,_CP,_BZ){/*@if(!@bering_debug)@*/try{/*@end@*/var _N5=FindApp(_Ke).uiManager._jf.oContextBar;var _awP=_N5.aAxisContextSets[_BZ];var _aDy=_awP.GetSimpleItem(_CP);_aDy.DoDrill(_Df,_aDy.oDLBlock);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIAxisContextItem.prototype.DoDrill=function(_Df,_FK){var _Tc=this.oParentSet.oParentBar.oUIMgr.appobj.dataManager.metadata;var _aEy=_Tc.GetMemberOrMeasure(_Df);var _ahY=true;if(_FK.IsChildren()||_FK.IsChildrenMeasureBlock()){var _apC=_Tc.GetMemberOrMeasure(_FK.GetLastDataMemberId());if(!_apC.IsChild(_aEy,true)){_ahY=false;}if(!_ahY){_ahY=_aEy.GetChild(0,true)?_ahY:true;}}if(_ahY){Debug.Assert(_FK.oAxis!=null);if(_FK.oAxis){var _LF=_FK.GetFirstAxisMember(_Df);_LF.DrillDown();}}else{var _amO=_aEy.GetChild(0,true)._ks;_FK.DrillUp(_amO);}};CUIAxisContextItem.prototype.addChildrenToMenu=function(oMem,_Ga,_BC,e,_Fu,_BZ,x,y,_I7){var _Ss=false;var _Ke=this.oParentSet.oParentBar.oUIMgr.appobj.appname;var _Li=this.oParentSet.oParentBar.oUIMgr.dataManager.GetCurrentDataMatrix();var _FK=_Li.GetBlock(_Fu);var _F7=_Li.GetAxis(this.iAxisIdx).GetAllNodesInBlock(_FK);for(var i=0;i<_F7.length;i++){var _aaU=_F7[i];if(!_aaU.IsCalc()&&!_aaU.IsSummaryMem()&&!_aaU.IsNoItemsNode()){var _AG=new Array(_Ke,_aaU.GetMemberId(),_Fu,_BZ);var _Hn=new ContextItem('',_aaU.GetLabel(),_BC,_Ss,_AG,_Ga);}}};CUIAxisContextItem.SafeDoAddItemToContext=function(_Ke,_L7){/*@if(!@bering_debug)@*/try{/*@end@*/var _Li=FindApp(_Ke).dataManager.GetCurrentDataMatrix();var _FK=_Li.GetBlock(_L7);var _J3=_FK.GetDeleteAction();var _as2=FindApp(_Ke).dataManager.GetCurrentWSFilterSet();_as2.InsertComplexFilter(_L7,_J3);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};function CUIAxisSimpleItem(_Dx,_Qj,_OE,_No,_BZ){this.base=CUIAxisContextItem;this.base(_Dx,_Qj,_BZ);this.sMemElcid=_OE;this.oDLBlock=_No;this.iAxisIdx=_BZ;};CUIAxisSimpleItem.prototype=new CUIAxisContextItem;CUIAxisSimpleItem.superclass=CUIAxisContextItem.prototype;CUIAxisSimpleItem.prototype.GetDeleteAction=function(){return this.oDLBlock.GetDeleteAction();};CUIAxisSimpleItem.prototype.GetSearchData=function(){return this.oDLBlock.GetSearchData();};CUIAxisSimpleItem.prototype.GetBlock=function(){return this.oDLBlock;};CUIAxisSimpleItem.prototype.updateBlocks=function(_JE){this.oDLBlock=_JE.getBlock(this.sBlockId);};CUIAxisSimpleItem.prototype.IsOK=function(){if(this.GetBlock()&&!this.GetBlock().bNulledOut){return true;}return false;};CUIAxisSimpleItem.prototype.GetFirstBlock=function(){return this.GetBlock();};CUIAxisSimpleItem.prototype.HasMeasures=function(){return this.oDLBlock.HasMeasures();};CUIAxisSimpleItem.prototype.HasDimOrHierInCommon=function(_Lv,_Tc,_Li){var _arp=null;if(_Tc.IsFunctionSupported(ExpAPIXml.kQosMultiHierOfSameDim)){_arp=_Lv.GetHierOrDimId(_Tc,_Li);return(this.oDLBlock.GetHierarchyOrDimId()==_arp);}else{_arp=_Lv.GetDimId(_Tc,_Li);return(this.oDLBlock.GetDimId()==_arp);}};CUIAxisSimpleItem.prototype.Create=function(){CUIAxisSimpleItem.superclass.Create.call(this);var _Tc=this.oParentSet.oParentBar.oUIMgr.appobj.dataManager.metadata;this.sLabel=this.oDLBlock.GetLabel();this.sBlockId=this.oDLBlock.GetId();this.constructTooltip(this.oDLBlock);};CUIAxisSimpleItem.prototype.Display=function(_EP,_E3,_U4){if(!this.IsOK()){return;}var _FK=this.GetBlock();var _N5=this.oParentSet.oParentBar;var _TW=_FK.GetDimId();var _ahk=(_N5.GetBlocksCountForDimId(_TW)>1);var _zr=document.createElement('TABLE');var _RK=_zr.appendChild(document.createElement('TBODY'));var _FW=_RK.appendChild(document.createElement('TR'));_zr.cellPadding=0;_zr.cellSpacing=0;_EP.appendChild(_zr);this.bDraggable=true;var _afT=document.createElement('IMG');_afT.src=Utilities.IMG_PATH+"context_item_handle_22.gif";COTStyle.SetWidth(_afT,6);COTStyle.SetHeight(_afT,CUIAbsContextItem.kDragIconHeight);_afT.className='drag_handle';_afT.onmousedown=CUIAxisContextItem.SafeOnMouseDownOnDragHandle;Dom.SetObjRef(_afT,this,'obj');_afT.obj=this;_afT.kType=CUIContextBar.kTypeItem;var _NM=_FW.appendChild(document.createElement('TD'));_NM.appendChild(_afT);var _NM=_FW.appendChild(document.createElement('TD'));if(_ahk){_E3='dup_dim_'+_E3;this.className=_E3;}var _T6=CUIAxisSimpleItem.superclass.Display.call(this,_EP,_E3,_U4,_FW);var _Tc=_N5.oUIMgr.appobj.dataManager.metadata;this.elParent.title=this.sTooltip;if(_ahk&&(_FK.IsChildren()||_FK.IsLevelMembers())){this.elLink.parentNode.className='dup_dim_context_item_name_component';var _atC=document.createElement('DIV');this.elLink.parentNode.appendChild(_atC);_atC.className='hierarchy_label';var _aoy=_Tc.GetHierarchyById(_FK.GetHierarchyOrDimId()).GetLabel();_aoy=Utilities.GetTruncatedString(_aoy,CUIContextBar.kLabelTruncateLength,this.oParentSet.oRes);_atC.appendChild(document.createTextNode(_aoy));}this.elName.onmousedown=CUIAxisContextItem.SafeOnMouseDownOnDragHandle;Dom.SetObjRef(this.elParent,this,'obj');this.elParent.oncontextmenu=CUIAxisSimpleItem.SafeHandleContextMenu;};CUIAxisSimpleItem.SafeHandleContextMenu=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e)var e=window.event;this.obj.HandleContextMenu(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIAxisSimpleItem.prototype.HandleContextMenu=function(e){if(this.oParentSet.oParentBar._qh){return;}this.SelectItem();this.oParentSet.oParentBar.oUIWS._dO.ShowBlockContextMenu(this.oDLBlock,e);};CUIAxisSimpleItem.prototype.HandleMouseDown=function(e){if(!this.IsOK()){return;}this._qA=false;this.elName.oLastEvent=Dom.CloneMouseEvent(e);this.oContextMenu.Clear();var _Ke=this.oParentSet.oParentBar.oUIMgr.appobj.appname;var _ahl=new Array(_Ke,this.iAxisIdx,this.oDLBlock.GetId());var _aDs=this.oParentSet.oRes.GetString('OTH_CONTEXTBAR_DELETE_BLOCK');var _Ss=!this.CanDelete();var _apq=new ContextItem('tool_main_delete.gif',_aDs,CUIAxisSimpleItem.SafeDoDeleteAxisLevel,_Ss,_ahl,this.oContextMenu);_apq.id='OTH_CONTEXTBAR_DELETE_BLOCK';var _aIC=new ContextSeparator(this.oContextMenu);_Ss=false;var _Tc=this.oParentSet.oParentBar.oUIMgr.appobj.dataManager.metadata;var _Co=this.oParentSet.oRes;var oMem=null;if(this.oDLBlock.GetLastDataMemberId()){oMem=_Tc.GetMemberOrMeasure(this.oDLBlock.GetLastDataMemberId());}this.loadMetadataIntoMenu(oMem,CUIAxisContextItem.SafeDoDrill,e,this.oDLBlock.GetId(),this.iAxisIdx);var _apD=this.GetSearchData();if(_apD){var _aIC=new ContextSeparator(this.oContextMenu);var _ZF='';for(var i in _apD){if(_apD[i].GetLabel){_ZF=_apD[i].GetLabel();break;}}var _BM=_Co.ReplaceParam('IDS_SEARCH',1,_ZF);var _AG=new Array(_Ke);var _aJJ=new ContextItem('icon_search.gif',_BM,CUIManager.SafeDoSearch,false,_AG,this.oContextMenu);}if(this.oDLBlock.CanApplyUserDefFilter()){_BM=_Co.GetString('OTH_CROSSTAB_MENU_FILTER');var _aew=new ContextItem('filter_16.gif',_BM,null,false,null,this.oContextMenu);_aew.id='OTH_CROSSTAB_MENU_FILTER';_Mt=_aew.CreateSubMenu(_Ke,this.oContextMenu._dl+1);_Mt=CUIWorkSheet.AttachUserDefinedFilterItems(_Co,_Mt,_Ke,this.oDLBlock);_Mt.SetChildrenComplete();}if(this.oDLBlock.CanBeUsedAsContextFilter()){var _aIC=new ContextSeparator(this.oContextMenu);var _BM=_Co.GetString('OTH_CONTEXTBAR_ADD_TO_CONTEXT');var _AG=new Array(_Ke,this.oDLBlock.GetId());var _aFO=new ContextItem("",_BM,CUIAxisContextItem.SafeDoAddItemToContext,false,_AG,this.oContextMenu);if(_aew)_aew.id='OTH_CONTEXTBAR_ADD_TO_CONTEXT';}var _IG=false;if(this.oContextMenu._dl==0){this.showDropDownMenu(e);}else{this.oContextMenu.display(e,_IG,x,y,_I7);}};CUIAxisSimpleItem.SafeDoDeleteAxisLevel=function(_Ke,_BZ,_CP){try{var _N5=FindApp(_Ke).uiManager._jf.oContextBar;var _awP=_N5.aAxisContextSets[_BZ];var _aDy=_awP.GetSimpleItem(_CP);_aDy.DoDeleteAxisLevel(_Ke);}catch(e){_f.HandleException(e);}};CUIAxisSimpleItem.prototype.DoDeleteAxisLevel=function(_Ke){var _ac3=FindApp(_Ke).dataManager.GetCurrentDataMatrix();var _O0=_ac3.GetAxis(this.iAxisIdx);var _I3=new Array();_I3[0]=this.oDLBlock;_O0.DoDeleteMultipleBlocks(_I3);};CUIAxisSimpleItem.prototype.CanDelete=function(){return this.oDLBlock.CanDelete();};CUIAxisSimpleItem.prototype.Notify=function(_Dy){if(_Dy==ExpEvent.kCDLMember_Merge&&!this._xd){if(this.oParentSet){var oMem=this.oParentSet.oParentBar.oUIMgr.dataManager.metadata.GetMemberOrMeasure(this.sMemElcid);this.handleMetadataMerge(oMem);}}else if(_Dy==ExpEvent.kCDLMember_Merge_NoResponse){this._qA=true;if(this.oParentSet){var oMem=this.oParentSet.oParentBar.oUIMgr.dataManager.metadata.GetMemberOrMeasure(this.sMemElcid);this.handleMetadataMerge(oMem);}}};CUIAxisSimpleItem.prototype.OnDragStart=function(e){var _aby=CUIAxisSimpleItem.superclass.OnDragStart.call(this,e);if(_aby){var _Lv=new CUIDragDropBlock(this.GetBlock().GetId(),this.sMemElcid,true);var _Hk=this.oParentSet.oParentBar.oUIMgr;CUIDragDrop.Start(this,_Hk,_Lv,CUIDragDrop.eEffectNone,e);var _Bu=new Array(this.sLabel);CUIDragDrop.SetTooltipItems(null,_Bu);CUIDragDrop.ShowTooltip(e.clientX,e.clientY);}else{return;}};function CUIAxisComboItem(_Dx,_Qj,_BZ,_Uh){this.base=CUIAxisContextItem;this.base(_Dx,_Qj,_BZ);this.sLabel="";this.iComboIdx=_Uh;this.aBlocks=new Array();this.aBlocks[0]=new Array();this.aBlockIds=new Array();this.aBlockIds[0]=new Array();this._bl=0;this.bDraggable=false;};CUIAxisComboItem.prototype=new CUIAxisContextItem;CUIAxisComboItem.superclass=CUIAxisContextItem.prototype;CUIAxisComboItem.prototype.Create=function(){CUIAxisComboItem.superclass.Create.call(this);var _Co=this.oParentSet.oParentBar.oUIMgr.appobj.oResources;this.sLabel=_Co.GetString('IDS_CONTEXTBAR_UNIONED_AXIS');};CUIAxisComboItem.prototype.IsSelectable=function(){return false;};CUIAxisComboItem.prototype.GetFirstBlock=function(){for(var i=0;i<this.aBlocks.length;i++){for(var j=0;j<this.aBlocks[i].length;j++){return this.aBlocks[i][j];}}return null;};CUIAxisComboItem.prototype.GetSearchData=function(){return null;};CUIAxisComboItem.prototype.updateBlocks=function(_JE){for(var i=0;i<this.aBlocks.length;i++){for(var j=0;j<this.aBlocks[i].length;j++){this.aBlocks[i][j]=_JE.getBlock(this.aBlockIds[i][j]);}}};CUIAxisComboItem.prototype.IsOK=function(){if(this.GetFirstBlock()&&!this.GetFirstBlock().bNulledOut){return true;}return false;};CUIAxisComboItem.prototype.GetSimpleBlockArray=function(){var _aIi=new Array();for(var i=0;i<this.aBlocks.length;i++){for(var j=0;j<this.aBlocks[i].length;j++){_aIi.push(this.aBlocks[i][j]);}}return _aIi;};CUIAxisComboItem.prototype.HasMeasures=function(){for(var i=0;i<this.aBlocks.length;i++){for(var j=0;j<this.aBlocks[i].length;j++){if(this.aBlocks[i][j].HasMeasures()){return true;}}}return false;};CUIAxisComboItem.prototype.SemiSelectItem=function(){this.bSemiSelected=true;this.SetStyle();};CUIAxisComboItem.prototype.SetStyle=function(){if(this.elItem){if(this.bSemiSelected){this.elItem.className=this.sClassName+'_semiselect';}else{this.elItem.className=this.sClassName;}if(this.bDragOver){this.elItem.className+=" context_item_dragover";}}};CUIAxisComboItem.prototype.UnselectItem=function(){this.bSemiSelected=false;CUIAxisComboItem.superclass.UnselectItem.call(this);};CUIAxisComboItem.prototype.HasDimOrHierInCommon=function(_Lv,_Tc,_Li){var _aly=_Tc.IsFunctionSupported(ExpAPIXml.kQosMultiHierOfSameDim);var _9s=_aly?_Lv.GetHierOrDimId(_Tc,_Li):_Lv.GetDimId(_Tc,_Li);for(var i=0;i<this.aBlocks.length;i++){for(var j=0;j<this.aBlocks[i].length;j++){sCurrentMetaId=_aly?this.aBlocks[i][j].GetHierarchyOrDimId():this.aBlocks[i][j].GetDimId();if(_9s==sCurrentMetaId){return true;}}}return false;};CUIAxisComboItem.prototype.Display=function(_EP,_E3,_U4){if(!this.IsOK()){return;}_EP.className="axis_context_item";var _zr=document.createElement('TABLE');var _RK=_zr.appendChild(document.createElement('TBODY'));var _FW=_RK.appendChild(document.createElement('TR'));_zr.cellPadding=0;_zr.cellSpacing=0;_EP.appendChild(_zr);Dom.RemoveAllChildren(this.elName);this.elName=document.createElement('DIV');var _NM=_FW.appendChild(document.createElement('TD'));_NM.appendChild(this.elName);this.elParent=_EP;Dom.SetObjRef(this.elName,this,'obj');this.elParent.title=this.sLabel;CUIAxisContextItem.superclass.Display.call(this,_NM,_E3,_FW);var _ab2=false;var _au3=false;var _Z0=false;var _aFM=CUIAxisContextItem.kNonFlt;for(var i=0;i<this.aBlocks.length;i++){for(var j=0;j<this.aBlocks[i].length;j++){if(this.aBlocks[i][j].IsExplicitSort()){_ab2=true;}if(this.aBlocks[i][j].IsLocked()){_au3=true;}var _6C=this.aBlocks[i][j].GetFilterCombinationType();if(_6C!=CUIAxisContextItem.kNonFlt&&(_aFM!=CUIAxisContextItem.kMultiFltComboLocked)){_Z0=true;if(_aFM==CUIAxisContextItem.kNonFlt){_aFM=_6C;}else{if(_au3){_aFM=CUIAxisContextItem.kMultiFltComboLocked;}else{_aFM=CUIAxisContextItem.kMultiFltCombo;}}}if((_aFM==CUIAxisContextItem.kMultiFltComboLocked)&&_ab2){break;}}}if(_aFM!=CUIAxisContextItem.kNonFlt){var _ayY=CUIAxisContextItem.aFltComboTypeImgMap[_aFM];var _Ke=this.oParentSet.oParentBar.oUIMgr.appobj.appname;var _BC=Utilities.GenerateCallback(CUICrosstab.SafeDoToggleBlockPropPane,[_Ke]);var _afT=COTInputElementFactory.CreateImage(_ayY,16,16,_BC);this.elName.appendChild(_afT);_afT.className='filter_icon';}else if(_au3){var _afT=COTInputElementFactory.CreateImage('icon_hold.gif',16,16);this.elName.appendChild(_afT);_afT.className='filter_icon';}if(_ab2){_afT=document.createElement('IMG');this.elName.appendChild(_afT);_afT.src=Utilities.IMG_PATH+'summary_sort_combination.gif';COTStyle.SetHeight(_afT,16);COTStyle.SetWidth(_afT,16);_afT.className='filter_icon';}var _aEn='IDS_CONTEXTBAR';if(_au3){_aEn+='_LOCKED';}if(_Z0){_aEn+='_FILTERED';}if(_ab2){_aEn+='_SORTED';}if(_aEn!='IDS_CONTEXTBAR'){_aEn+='_BLOCK_IN_COMBO';this.sTooltip=this.oParentSet.oRes.GetString(_aEn);}else{this.sTooltip=this.sLabel;}this.elParent.title=this.sTooltip;this.elLink=document.createElement('A');this.elLink.tabIndex=_U4;Dom.SetObjRef(this.elLink,this,'obj');this.elLink.className='invisible_link';this.elName.appendChild(this.elLink);var _ady=Utilities.GetTruncatedString(this.sLabel,CUIContextBar.kLabelTruncateLength,this.oParentSet.oRes);var _aBx=document.createTextNode(_ady);this.elLink.appendChild(_aBx);this.sLevelLabel=_aBx;var _NM=_FW.appendChild(document.createElement('TD'));this.drawDropDownArrow(_NM);this.elName.onmousedown=CUIAxisContextItem.SafeOnMouseDownOnDragHandle;};CUIAxisComboItem.prototype.AddLevel=function(){this._bl++;if(this.aBlocks.length<=this._bl){this.aBlocks[this._bl]=new Array();this.aBlockIds[this._bl]=new Array();}};CUIAxisComboItem.prototype.DecrementCurrentLevel=function(){this._bl--;};CUIAxisComboItem.prototype.AddChildLevel=function(){this.AddLevel();};CUIAxisComboItem.prototype.AddBlock=function(_FK){this.aBlocks[this._bl].push(_FK);this.aBlockIds[this._bl].push(_FK.GetId());};CUIAxisComboItem.prototype.HandleMouseDown=function(e){this._qA=false;this.elName.oLastEvent=Dom.CloneMouseEvent(e);this.oContextMenu.Clear();var _N5=this.oParentSet.oParentBar;var _Ke=_N5.oUIMgr.appobj.appname;var _ahl=new Array(_Ke,this.iAxisIdx,this.iComboIdx);var _aDs=this.oParentSet.oRes.GetString('OTH_CONTEXTBAR_DELETE_BLOCKS');var _Ss=!this.CanDelete();var _apq=new ContextItem('tool_main_delete.gif',_aDs,CUIAxisComboItem.SafeDoDeleteAxisLevel,_Ss,_ahl,this.oContextMenu);_apq.id='OTH_CONTEXTBAR_DELETE_BLOCKS';var _2l=new ContextSeparator(this.oContextMenu);_Ss=false;var _Tc=_N5.oUIMgr.appobj.dataManager.metadata;for(var i=0;i<this.aBlocks.length;i++){for(var j=0;j<this.aBlocks[i].length;j++){var _FK=this.aBlocks[i][j];var _AG=new Array(_Ke,this.aBlocks[i][j].GetId(),this.iAxisIdx);var _56=new CUIContextMenu(_Ke,this.oContextMenu._dl+1,this);var _TW=_FK.GetDimId();var _ahk=(_N5.GetBlocksCountForDimId(_TW)>1);var _BM=_FK.GetLabel();if(_ahk){_BM=_FK.AddingDataDetailToBlockLabel(_BM);}var item=new ContextItem('',_BM,null,_Ss,_AG,this.oContextMenu,_56);}var _2l=new ContextSeparator(this.oContextMenu);}this.showDropDownMenu(e);};CUIAxisComboItem.prototype.GetSubMenuItems=function(oContextItem,e,x,y){this._sK=x;this._sL=y;if(e){this.elName.oLastEvent=Dom.CloneMouseEvent(e);}oContextItem._o6.Clear();var _Ke=oContextItem.aCallbackParams[0];var _Fu=oContextItem.aCallbackParams[1];var _BZ=oContextItem.aCallbackParams[2];var _Tc=this.oParentSet.oParentBar.oUIMgr.appobj.dataManager.metadata;var _ac3=FindApp(_Ke).dataManager.GetCurrentDataMatrix();var _O0=_ac3.GetAxis(this.iAxisIdx);var _FK=_O0.GetBlock(_Fu);var _Ss=!_FK.CanDelete();var _ahl=new Array(_Ke,this.iAxisIdx,this.iComboIdx,_FK.GetId());var _aDs=this.oParentSet.oRes.GetString('OTH_CONTEXTBAR_DELETE_BLOCK');var _apq=new ContextItem('tool_main_delete.gif',_aDs,CUIAxisComboItem.SafeDeleteBlock,_Ss,_ahl,oContextItem._o6);_apq.id='OTH_CONTEXTBAR_DELETE_BLOCK';var oMem=null;_Ss=false;var _Co=this.oParentSet.oRes;if(!_FK.IsHAMC()&&_FK.CanDrillUpOrDown()){var _Tc=this.oParentSet.oParentBar.oUIMgr.appobj.dataManager.metadata;if(_FK.GetLastDataMemberId()){oMem=_Tc.GetMemberOrMeasure(_FK.GetLastDataMemberId());}this._lg=oContextItem;var _aIC=new ContextSeparator(oContextItem._o6);this.loadMetadataIntoMenu(oMem,CUIAxisComboItem.SafeDoDrillOnBlock,e,_FK.GetId(),this.iAxisIdx,oContextItem._o6,x,y,oContextItem);}else if((_FK.IsHAMC())&&_FK.CanDrillDown()){var _aIC=new ContextSeparator(oContextItem._o6);this.addChildrenToMenu(oMem,oContextItem._o6,CUIAxisComboItem.SafeDoDrillOnBlock,e,_FK.GetId(),this.iAxisIdx,x,y,oContextItem);}var _apD=_FK.GetSearchData();if(_apD){var _aIC=new ContextSeparator(oContextItem._o6);var _ZF='';var _ahn=(Utilities.GetObjArrayLength(_apD)==1);for(var i in _apD){if(_ahn){_ZF=_apD[i].GetLabel();break;}else{if(_apD[i].IsRootMember&&_apD[i].IsRootMember()){_ZF=_apD[i].GetLabel();break;}}}var _BM=_Co.ReplaceParam('IDS_SEARCH',1,_ZF);var _AG=new Array(_Ke,_FK);var _aJJ=new ContextItem('icon_search.gif',_BM,CUIAxisComboItem.SafeDoSearch,false,_AG,oContextItem._o6);}if(_FK.CanApplyUserDefFilter()){_BM=_Co.GetString('OTH_CROSSTAB_MENU_FILTER');var _aew=new ContextItem('filter_16.gif',_BM,null,false,null,oContextItem._o6);_aew.id='OTH_CROSSTAB_MENU_FILTER';var _Mt=_aew.CreateSubMenu(_Ke,oContextItem._o6._dl+1);_Mt=CUIWorkSheet.AttachUserDefinedFilterItems(_Co,_Mt,_Ke,_FK);_Mt.SetChildrenComplete();}if(_FK.CanBeUsedAsContextFilter()){var _aIC=new ContextSeparator(oContextItem._o6);var _BM=_Co.GetString('OTH_CONTEXTBAR_ADD_TO_CONTEXT');var _AG=new Array(_Ke,_FK.GetId());var _aFO=new ContextItem("",_BM,CUIAxisContextItem.SafeDoAddItemToContext,false,_AG,oContextItem._o6);if(_aew)_aew.id='OTH_CONTEXTBAR_ADD_TO_CONTEXT';}oContextItem._o6.SetChildrenComplete();oContextItem._o6.display(e,false,x,y,oContextItem);};CUIAxisComboItem.SafeDoSearch=function(_Ke,_FK){/*@if(!@bering_debug)@*/try{/*@end@*/var _aci=_FK.GetSearchData();FindApp(_Ke).uiManager._qi.DoSearchFromData(_aci,_FK.eType);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIAxisComboItem.SafeDoFilter=function(_Ke,_FK){/*@if(!@bering_debug)@*/try{/*@end@*/var _aci=_FK.GetSearchData();FindApp(_Ke).uiManager._jf.OpenFilterDlg(_FK);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIAxisComboItem.prototype.DrillOnBlock=function(_Ke,_L7,_UF){for(var i=0;i<this.aBlocks.length;i++){for(var j=0;j<this.aBlocks[i].length;j++){if(this.aBlocks[i][j].GetId()==_L7){this.DoDrill(_UF,this.aBlocks[i][j]);return;}}}Debug.Assert(false);};CUIAxisComboItem.SafeDoDrillOnBlock=function(_Ke,_UF,_L7,_BZ){/*@if(!@bering_debug)@*/try{/*@end@*/var _N5=FindApp(_Ke).uiManager._jf.oContextBar;var _awP=_N5.aAxisContextSets[_BZ];var _aDy=_awP.GetComboItemByBlockId(_L7);;_aDy.DrillOnBlock(_Ke,_L7,_UF);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIAxisComboItem.prototype.DeleteBlock=function(_Ke,_L7){var _ac3=FindApp(_Ke).dataManager.GetCurrentDataMatrix();var _O0=_ac3.GetAxis(this.iAxisIdx);var _FK=_O0.GetBlock(_L7);_O0.DoDeleteMultipleBlocks(new Array(_FK));};CUIAxisComboItem.SafeDeleteBlock=function(_Ke,_BZ,_Uh,_L7){/*@if(!@bering_debug)@*/try{/*@end@*/var _N5=FindApp(_Ke).uiManager._jf.oContextBar;var _awP=_N5.aAxisContextSets[_BZ];var _aDy=_awP.GetComboItem(_Uh);_aDy.DeleteBlock(_Ke,_L7);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIAxisComboItem.prototype.DoDeleteAxisLevel=function(_Ke){var _48=new Array();for(var i=this.aBlocks.length-1;i>=0;i--){for(var j=0;j<this.aBlocks[i].length;j++){_48.push(this.aBlocks[i][j]);}}Debug.Assert(_48.length>0);if(_48.length>0){var _O0=_48[0].oAxis;_O0.DoDeleteMultipleBlocks(_48);}};CUIAxisComboItem.SafeDoDeleteAxisLevel=function(_Ke,_BZ,_Uh){try{var _N5=FindApp(_Ke).uiManager._jf.oContextBar;var _awP=_N5.aAxisContextSets[_BZ];var _aDy=_awP.GetComboItem(_Uh);_aDy.DoDeleteAxisLevel(_Ke);}catch(e){_f.HandleException(e);}};CUIAxisComboItem.prototype.CanDelete=function(){return true;};CUIAxisComboItem.prototype.GetDeleteAction=function(){var _DF=new Array();for(var i=0;i<this.aBlocks.length;i++){for(var j=0;j<this.aBlocks[i].length;j++){_DF.push(this.aBlocks[i][j].GetDeleteAction());}}return _DF;};function CUIAxisLevelItem(_Dx,_Qj,_Pz,_No,_BZ,_OE){this.base=CUIAxisContextItem;this.base(_Dx,_Qj,_BZ);this.sLevElcid=_Pz;this.oDLBlock=_No;this.sMemElcid=_OE;this.bDraggable=true;};CUIAxisLevelItem.prototype=new CUIAxisSimpleItem;CUIAxisLevelItem.superclass=CUIAxisSimpleItem.prototype;CUIAxisLevelItem.prototype.Create=function(){var _Tc=this.oParentSet.oParentBar.oUIMgr.appobj.dataManager.metadata;CUIAxisLevelItem.superclass.Create.call(this,this.sLabel);this.constructTooltip(this.oDLBlock);};CUIAxisLevelItem.prototype.OnDragStart=function(e){CUIAxisLevelItem.superclass.OnDragStart.call(this,e);var _Lv=new CUIDragDropLevelBlock(this.GetBlock().GetId(),this.sMemElcid,this.sLevElcid);var _Hk=this.oParentSet.oParentBar.oUIMgr;CUIDragDrop.Start(this,_Hk,_Lv,CUIDragDrop.eEffectNone,e);var _Bu=new Array(this.sLabel);CUIDragDrop.SetTooltipItems(null,_Bu);CUIDragDrop.ShowTooltip(e.clientX,e.clientY);};function CUIAxisMemListItem(_Dx,_Qj,_J5,_No,_BZ){this.base=CUIAxisSimpleItem;this.base(_Dx,_Qj,_BZ);this.aMemberIds=_J5;this.oDLBlock=_No;this.iAxisIdx=_BZ;};CUIAxisMemListItem.prototype=new CUIAxisSimpleItem;CUIAxisMemListItem.superclass=CUIAxisSimpleItem.prototype;CUIAxisMemListItem.prototype.GetDeleteAction=function(){return this.oDLBlock.GetDeleteAction();};CUIAxisMemListItem.prototype.GetSearchData=function(){return this.oDLBlock.GetSearchData();};CUIAxisMemListItem.prototype.Create=function(){CUIAxisMemListItem.superclass.Create.call(this);var _Tc=this.oParentSet.oParentBar.oUIMgr.appobj.dataManager.metadata;if(this.oDLBlock.GetLastDataMemberId()){var oMem=_Tc.GetData(this.oDLBlock.GetLastDataMemberId());if(this.oDLBlock.IsSingleItemHAMC()){this.sMemElcid=oMem._ks;}else if(this.oDLBlock.IsNamedSet()){this.sMemElcid=oMem._bb;}else{this.sMemElcid=oMem.GetRootMember()._ks;}}};CUIAxisMemListItem.prototype.Display=function(_EP,_E3,_U4){CUIAxisMemListItem.superclass.Display.call(this,_EP,_E3,_U4);this.elParent.title=this.sTooltip;};CUIAxisMemListItem.prototype.HandleMouseDown=function(e){this.elName.oLastEvent=Dom.CloneMouseEvent(e);this.oContextMenu.Clear();var _Ss=!this.CanDelete();var _Co=this.oParentSet.oRes;var _Ke=this.oParentSet.oParentBar.oUIMgr.appobj.appname;var _ahl=new Array(_Ke,this.iAxisIdx,this.oDLBlock.GetId());var _aDs=_Co.GetString('OTH_CONTEXTBAR_DELETE_BLOCK');var _apq=new ContextItem('tool_main_delete.gif',_aDs,CUIAxisSimpleItem.SafeDoDeleteAxisLevel,_Ss,_ahl,this.oContextMenu);_apq.id='OTH_CONTEXTBAR_DELETE_BLOCK';_Ss=false;var _aIC=new ContextSeparator(this.oContextMenu);this.addChildrenToMenu(null,this.oContextMenu,CUIAxisContextItem.SafeDoDrill,e,this.oDLBlock.GetId(),this.iAxisIdx);var _apD=this.oDLBlock.GetSearchData();if(_apD){var _aIC=new ContextSeparator(this.oContextMenu);var _ZF='';var _ahn=(Utilities.GetObjArrayLength(_apD)==1);for(var i in _apD){if(_ahn){_ZF=_apD[i].GetLabel();break;}else{if(_apD[i].IsRootMember&&_apD[i].IsRootMember()){_ZF=_apD[i].GetLabel();break;}}}var _BM=_Co.ReplaceParam('IDS_SEARCH',1,_ZF);var _AG=new Array(_Ke);var _aJJ=new ContextItem('icon_search.gif',_BM,CUIManager.SafeDoSearch,false,_AG,this.oContextMenu);}if(this.oDLBlock.CanApplyUserDefFilter()){_BM=_Co.GetString('OTH_CROSSTAB_MENU_FILTER');var _aew=new ContextItem('filter_16.gif',_BM,null,false,null,this.oContextMenu);_aew.id='OTH_CROSSTAB_MENU_FILTER';var _Mt=_aew.CreateSubMenu(_Ke,this.oContextMenu._dl+1);_Mt=CUIWorkSheet.AttachUserDefinedFilterItems(_Co,_Mt,_Ke,this.oDLBlock);_Mt.SetChildrenComplete();}if(this.oDLBlock.CanBeUsedAsContextFilter()){var _aIC=new ContextSeparator(this.oContextMenu);var _BM=_Co.GetString('OTH_CONTEXTBAR_ADD_TO_CONTEXT');var _AG=new Array(_Ke,this.oDLBlock.GetId());var _aFO=new ContextItem("",_BM,CUIAxisContextItem.SafeDoAddItemToContext,false,_AG,this.oContextMenu);if(_aew)_aew.id='OTH_CONTEXTBAR_ADD_TO_CONTEXT';}this.showDropDownMenu(e);};CUIAxisMemListItem.prototype.CanDelete=function(){return this.oDLBlock.CanDelete();};CUIAxisMemListItem.prototype.OnDragStart=function(e){var _aby=CUIAxisMemListItem.superclass.OnDragStart.call(this,e);if(_aby){var _Lv=new CUIDragDropMemListBlock(this.GetBlock().GetId(),this.aMemberIds,true);var _Hk=this.oParentSet.oParentBar.oUIMgr;CUIDragDrop.Start(this,_Hk,_Lv,CUIDragDrop.eEffectNone,e);var _Bu=new Array(this.sLabel);CUIDragDrop.SetTooltipItems(null,_Bu);CUIDragDrop.ShowTooltip(e.clientX,e.clientY);}};function CUIAxisDepthBasedItem(_Dx,_Qj,_OE,_No,_BZ){this.base=CUIAxisSimpleItem;this.base(_Dx,_Qj,_OE,_No,_BZ);};CUIAxisDepthBasedItem.prototype=new CUIAxisSimpleItem;CUIAxisDepthBasedItem.superclass=CUIAxisSimpleItem.prototype;function CUIAxisContextSet(_Rw,_Q1,_BZ){this.base=CUIAbsContextSet;this.base(_Rw);this.oDLDataMatrix=null;this.oUIWS=null;this.oUIAxis=_Q1;this.iAxisIdx=_BZ;this._rl=null;};CUIAxisContextSet.prototype=new CUIAbsContextSet;CUIAxisContextSet.superclass=CUIAbsContextSet.prototype;CUIAxisContextSet.eDZReplace=1;CUIAxisContextSet.eDZEnd=2;CUIAxisContextSet.eDZAppendToHAMC=3;CUIAxisContextSet.eDZNest=4;CUIAxisContextSet.prototype.Create=function(){CUIAxisContextSet.superclass.Create.call(this);this.aComboItems=new Array();this.oDLDataMatrix=this.oParentBar.oUIMgr.appobj.dataManager.GetCurrentDataMatrix();this.oDLMetadata=this.oParentBar.oUIMgr.appobj.dataManager.metadata;this.CreateAxisItems();};CUIAxisContextSet.prototype.Display=function(_EP,_I8,_Ko,_E3){Dom.RemoveAllChildren(this.elSet);var _zr=document.createElement('TABLE');CUIAxisContextSet.superclass.Display.call(this,_EP,_E3,_zr);if(_I8!=null){this.iFirstVisibleIdx=_I8;}this.elSet.appendChild(_zr);COTStyle.SetHeight(_zr,95,'%');_zr.cellSpacing=0;_zr.cellPadding=0;_zr.className='axis_context_table';_zr.title=this.oParentBar.oRes.GetString('IDS_CONTEXTBAR_ROWCOLUMN_TOOLTIP');var _RK=document.createElement('TBODY');_zr.appendChild(_RK);_RK.className='axis_context_tbody';var _FW=document.createElement('TR');_RK.appendChild(_FW);var _aJE=document.createElement('TD');COTStyle.SetHeight(_aJE,12);_FW.appendChild(_aJE);_aJE.colSpan=Math.max(this.aContextItems.length-this.iFirstVisibleIdx,1);var _at8=document.createElement('SPAN');_aJE.appendChild(_at8);_at8.className='axis_label';var _BM=this.oParentBar.oRes.GetString('IDS_CONTEXTBAR_'+this.oUIAxis.GetResourceSuffix());var _0o=document.createTextNode(_BM);_at8.appendChild(_0o);var _XK=this.oParentBar.oUIMgr.dataManager._kX.GetSuppressionState();if(_XK==ExpAPIXml.kSuppressRowsAndCols||(_XK==ExpAPIXml.kSuppressRowsOnly&&this.oUIAxis.IsRowAxis())||(_XK==ExpAPIXml.kSuppressColsOnly&&this.oUIAxis.IsColAxis())){var _afT=COTInputElementFactory.CreateImage('suppression_right.gif',6,6);_at8.appendChild(_afT);if(_o.is_ie5_5up){_zr.style.marginTop="-9px";}}var _89=document.createElement('TR');_RK.appendChild(_89);this.aCells=new Array();var _U4=_Ko;for(var i=this.iFirstVisibleIdx;i<this.aContextItems.length;i++){this.aCells[i]=document.createElement('TD');_89.appendChild(this.aCells[i]);this.aContextItems[i].Display(this.aCells[i],'axis_context_item_name',_U4);_U4++;COTStyle.SetHeight(this.aCells[i],CUIAbsContextItem.kDragIconHeight);}if(this.aContextItems.length==0){COTStyle.SetWidth(_zr,100,'%');this.drawInsertArrow(_89);}if(this.aCells[0]){this.aCells[0].style.paddingLeft="7px";}};CUIAxisContextSet.prototype.ShowDropZone=function(e,_Lv){var _Us=null;var _atr=false;var _O0=this.oDLDataMatrix.GetAxis(this.iAxisIdx);if(this.aContextItems.length==0){if(this.elSet){var _atr=COTValidation.IsValidDrop(_O0,_Lv,this.oDLMetadata,ExpAPIXml.kAxisOpXjoin);if(_atr){this.showSetDropZone();this._rl=new Object();this._rl.oItem=null;this._rl.eDropZoneType=CUIAxisContextSet.eDZEnd;_atr=true;}}}else{var _Oe=this.getItemElement(Dom.GetEventTarget(e));if(_Oe&&_Oe.obj.IsOK()){var _0K=false;if(_Oe.obj.GetBlock&&_Oe.obj.GetBlock()&&!_Lv.sLevId){_0K=COTValidation.IsHAMCDrop(this.oDLMetadata,_Oe.obj.GetBlock(),_Lv);if(_0K&&COTValidation.IsDropWithNewMembers(_Lv,_Oe.obj.GetBlock())){_Oe.obj.ShowDropZone(e,_0K);this._rl=new Object();this._rl.oItem=_Oe.obj;this._rl.eDropZoneType=CUIAxisContextSet.eDZAppendToHAMC;_atr=true;}}if(!_atr&&!_0K){var _aIE=false;if(!(_Oe.obj instanceof CUIAxisComboItem)){_aIE=COTValidation.IsValidDrop(_O0,_Lv,this.oDLMetadata,ExpAPIXml.kActionReplace,_Oe.obj.GetFirstBlock());}if(_aIE){_Oe.obj.ShowDropZone(e);this._rl=new Object();this._rl.oItem=_Oe.obj;this._rl.eDropZoneType=CUIAxisContextSet.eDZReplace;_atr=true;}}}else if(!_Oe){var _M6=this.getValidItemIdxFromEventPos(e);if(_M6!=-1){var _64=_M6;if(_M6>0){var _Qp=this.aContextItems[_M6-1].GetFirstBlock();var _aG2=ExpAPIXml.kEleInner;_64=_M6-1;}else{var _Qp=this.aContextItems[_M6].GetFirstBlock();var _aG2=ExpAPIXml.kEleOuter;}var _arx=this.aContextItems[_64].HasDimOrHierInCommon(_Lv,this.oDLMetadata,this.oDLDataMatrix);var _7z=false;var _azj;if(!_arx){if(this.aContextItems[_64]instanceof CUIAxisComboItem){var _I3=this.aContextItems[_64].GetSimpleBlockArray();_7z=true;for(var i=0;_7z&&i<_I3.length;i++){if(!_I3[i].IsGroupedDescendantsAtDepth()&&!_I3[i].IsOuterNestedBlock()){_7z=COTValidation.IsValidDrop(_O0,_Lv,this.oDLMetadata,ExpAPIXml.kAxisOpXjoin,_I3[i],_aG2);}else if(_I3[i].IsGroupedDescendantsAtDepth()&&!_I3[i].IsOuterNestedBlock()){_7z=this.oDLDataMatrix.IsValidActionForSameHierCompatibilityRule(ExpAPIXml.kAxisOpXjoin,_Lv,_I3[i],_O0);}}}else{_7z=COTValidation.IsValidDrop(_O0,_Lv,this.oDLMetadata,ExpAPIXml.kAxisOpXjoin,_Qp,_aG2);}_azj=CUIAxisContextSet.eDZEnd;}else{if(this.aContextItems[_64]instanceof CUIAxisComboItem){var _I3=this.aContextItems[_64].GetSimpleBlockArray();for(var i=0;i<_I3.length;i++){if(_Lv.GetDimId(this.oDLMetadata,this.oDLDataMatrix)!=_I3[i].GetDimId()){_7z=false;break;}else{_7z=_7z||COTValidation.IsValidDrop(_O0,_Lv,this.oDLMetadata,ExpAPIXml.kAxisOpXjoin,_I3[i],_aG2);}}}else{_7z=COTValidation.IsValidDrop(_O0,_Lv,this.oDLMetadata,ExpAPIXml.kAxisOpXjoin,_Qp,_aG2);}_azj=CUIAxisContextSet.eDZNest;}if(_7z){if(_M6==this.aContextItems.length){this.showEndDropZone();}else{this.showDropZoneBeforeItem(_M6);}this._rl=new Object();this._rl.oItem=null;this._rl.eDropZoneType=_azj;this._rl.iPos=_M6;_atr=true;}}}}if(!_atr){this._rl=null;}this.oParentBar.SetDropTarget(this,_Us);return _atr;};CUIAbsContextSet.prototype.getValidItemIdxFromEventPos=function(e){var _alQ=e.clientX+Dom.GetScrollLeft();var _6l=Dom.GetRelativeOffset(this.aContextItems[0].elParent,document.body).iLeft;var _3o=_6l;var _aDu=Dom.GetRelativeOffset(this.elSet,document.body).iLeft;var _amo=_aDu+COTStyle.GetDisplayOffsetWidth(this.elSet);_amo=_amo-2*this.oParentBar.iArrowDisplayWidth;var _adr=null;for(var i=1;i<this.aContextItems.length;i++){_3o=Dom.GetRelativeOffset(this.aContextItems[i].elParent,document.body).iLeft;_adr=_6l+((_3o-_6l)/2);if(_alQ<_adr){if(_6l>_amo){return-1;}if(this.aContextItems[i-1]instanceof CUIAxisComboItem&&this.aContextItems[i-2]instanceof CUIAxisComboItem){return-1;}return(i-1);}_6l=_3o;}var _Y1=this.aContextItems.length;var _aFq=COTStyle.GetDisplayOffsetWidth(this.aContextItems[_Y1-1].elParent);var _abd=_3o+(_aFq/2);if(_alQ<_abd){if(_3o>_amo){return-1;}if(this.aContextItems[_Y1-1]instanceof CUIAxisComboItem&&this.aContextItems[_Y1-2]instanceof CUIAxisComboItem){return-1;}return(_Y1-1);}else{return this.aContextItems.length;}};CUIAxisContextSet.prototype.ContinueHandleDragDrop=function(_Ke,_Lv,e){var _UD=this.oParentBar.oUIMgr._jf;var _35=this.oParentBar.oUIMgr._jf.GetIncludeDetailFlag();var _O0=this.oDLDataMatrix.GetAxis(this.iAxisIdx);_Lv.sTargetAxis=_O0.GetId();if(_Lv.sCustomSetId){var _HF=this.oParentBar.oUIMgr.dataManager._kX;if(!_HF.GetCustomSet(_Lv.sCustomSetId).CanUseOnAxis()){CUIDialogMgr.DisplayMessageBox(CUIConfirmDlg._hw,"MES_CANNOT_INSERT_CUSTOM_SET");this.HideDropZones();return;}}if(this._rl.iPos!=null&&_Lv.sBlockId){var _FK=_O0.GetBlock(_Lv.sBlockId);var _8X=this.GetSimpleItem(_Lv.sBlockId);if(_FK&&_8X){if(this._rl.iPos==_8X.iParentIdx||this._rl.iPos==_8X.iParentIdx+1){this.HideDropZones();return;}}}var _WT=ExpAPIXml.kChildrenPopulation;var _RJ=this.oParentBar.oUIMgr.dataManager.metadata;var _Li=this.oParentBar.oUIMgr.dataManager.GetCurrentDataMatrix();var _aud=Utilities.IsInArray(_RJ.GetMeasureDimIdArr(),_Lv.GetDimId(_RJ,_Li));if(_Lv.aOtherMemIds||(!_35&&!_Lv.bDelete)||_aud){_WT=ExpAPIXml.kMemberPopulation;}var _y2=null;if(_Lv.sLevId){_WT=ExpAPIXml.kAxisExprLevelMembers;if(!_Lv.sCustomSetId){_y2=_Lv.sLevId;}}var _X0=null;_Lv.kPopulation=_WT;if(this._rl.eDropZoneType==CUIAxisContextSet.eDZReplace){_Lv.kAction=ExpAPIXml.kActionReplace;_Lv.sTargetBlock=this._rl.oItem.GetFirstBlock().GetId();if(this._rl.oItem instanceof CUIAxisComboItem){var _at4=this._rl.oItem.GetSimpleBlockArray();Utilities.DeleteFromArray(_at4,this._rl.oItem.GetFirstBlock());for(var i=0;i<_at4.length;i++){_Lv.aDeleteActions.push(_at4[i].GetDeleteAction());}}_UD.InsertDropData(_Lv,e);}else if(this._rl.eDropZoneType==CUIAxisContextSet.eDZAppendToHAMC){_Lv.kAction=ExpAPIXml.kActionAppend;_Lv.sTargetBlock=this._rl.oItem.GetBlock().GetId();_UD.InsertDropData(_Lv,e);}else if(this._rl.eDropZoneType==CUIAxisContextSet.eDZNest){_Lv.kPosition=ExpAPIXml.kEleInner;_Lv.kAction=ExpAPIXml.kAxisOpNest;_Lv.sTargetBlock=_Lv._b5;_UD.InsertDropData(_Lv,e);}else{_Lv.kAction=ExpAPIXml.kAxisOpXjoin;if(this.aContextItems.length==0){_Lv.kPosition=ExpAPIXml.kEleInner;_UD.InsertDropData(_Lv,e);}else{var _8j=ExpAPIXml.kEleOuter;var _Us=this._rl.iPos;if(_Us==this.aContextItems.length){_8j=ExpAPIXml.kEleInner;_Us=_Us-1;if(this.aContextItems[_Us]instanceof CUIAxisComboItem){_Lv.kPosition=ExpAPIXml.kEleInner;_UD.InsertDropData(_Lv,e);return;}}if(this.aContextItems[_Us]instanceof CUIAxisComboItem){if(_Us>=1){_Us=_Us-1;_8j=ExpAPIXml.kEleInner;}else{_Lv.kPosition=ExpAPIXml.kEleOuter;_UD.InsertDropData(_Lv,e);return;}}var _0B=this.aContextItems[_Us].GetBlock();_Lv.sTargetBlock=_0B.GetId();_Lv.kPosition=_8j;_UD.InsertDropData(_Lv,e);}}};CUIAxisContextSet.SafeDoContinueHandleDragDrop=function(_Ke,_GL,_Lv,e){/*@if(!@bering_debug)@*/try{/*@end@*/_GL.ContinueHandleDragDrop(_Ke,_Lv,e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIAxisContextSet.prototype.HandleDragDrop=function(_Lv,e){if(!this._rl){this.HideDropZones();return;}if(this._rl.oItem&&this._rl.oItem.GetBlock&&COTValidation.IsDropFromSameBlock(_Lv,this._rl.oItem.GetBlock())){this.HideDropZones();return;}var _UD=this.oParentBar.oUIMgr._jf;var _Ke=_UD._m4.appobj.appname;var _amW=_UD._m4.ConfirmLossOfChanges();if(_amW==Utilities.eStateContinue){this.ContinueHandleDragDrop(_Ke,_Lv,e);}else if(_amW==Utilities.eStateHold){var _axQ=Dom.CloneMouseEvent(e);var _Ro=new Array(_Ke,this,_Lv,_axQ);Utilities.SetProcedureToHold(CUIAxisContextSet.SafeDoContinueHandleDragDrop,_Ro);_UD._m4.oDialogMgr.Subscribe(this.oParentBar,ExpEvent.kCUIDialogMgr_HideModalDialog);}};CUIAxisContextSet.prototype.GetDisplayWidth=function(){return COTStyle.GetDisplayOffsetWidth(this.elTable);};CUIAxisContextSet.prototype.GetVisibleItemCount=function(_F4){if(this.aContextItems.length==0){if((COTStyle.GetDisplayOffsetWidth(this.elTable)<=_F4)&&(COTStyle.GetDisplayOffsetWidth(this.elSet)<=_F4)){return 1;}else{return 0;}}else{var _aoO=0;for(var i=this.iFirstVisibleIdx;i<this.aContextItems.length;i++){_aoO+=COTStyle.GetDisplayOffsetWidth(this.aCells[i]);if(_aoO>_F4){return i-this.iFirstVisibleIdx;}}return this.aContextItems.length-this.iFirstVisibleIdx;}};CUIAxisContextSet.prototype.CreateAxisItems=function(){if(this.oDLDataMatrix){this.oParentBar.ClearBlockCountMap(this.iAxisIdx);var _O0=this.oDLDataMatrix.GetAxis(this.oUIAxis.GetAxisIndex());if(_O0&&_O0.expressionNode&&!_O0.IsStale()){var _aDI=_O0.GetAllOps();if(!_aDI||_aDI.length==0){this.processBlock(_O0.GetSingleBlock(),false);}else{this.processOp(_aDI[0],false);}}}};CUIAxisContextSet.prototype.processOp=function(_IY,_Lr){var _O0=this.oDLDataMatrix.GetAxis(this.oUIAxis.GetAxisIndex());if(!(_IY instanceof CDLAxisOp)){this.processBlock(_O0.GetBlock(_IY),_Lr);return;}if(_IY.eType==CDLAxisOp.eTypeUnion||_IY.eType==CDLAxisOp.eTypeNest){if(!_Lr){var _0E=new CUIAxisComboItem(this,this.aContextItems.length,this.iAxisIdx,this.aComboItems.length);this.aContextItems.push(_0E);this.aContextItems[this.aContextItems.length-1].Create();this.aComboItems.push(_0E);_Lr=true;}}this.processOp(_IY.oLeftOperand,_Lr);if(_IY.eType==CDLAxisOp.eTypeXJoin||_IY.eType==CDLAxisOp.eTypeNest){if(this.aComboItems.length>0&&_Lr){this.aComboItems[this.aComboItems.length-1].AddLevel();}}this.processOp(_IY.oRightOperand,_Lr);if(_IY.eType==CDLAxisOp.eTypeXJoin||_IY.eType==CDLAxisOp.eTypeNest){if(this.aComboItems.length>0&&_Lr){this.aComboItems[this.aComboItems.length-1].DecrementCurrentLevel();}}};CUIAxisContextSet.prototype.processBlock=function(_FK,_Lr){Debug.Assert(_FK instanceof CDLBlock);if(this.oParentBar._cY){var _TW=_FK.GetDimId();var _50=this.oParentBar._xz[this.iAxisIdx];if(!_50[_TW]){_50[_TW]=1;}else{_50[_TW]+=1;}}if(this.aComboItems.length>0&&_Lr){this.aComboItems[this.aComboItems.length-1].AddBlock(_FK);}else if(_FK.IsHAMC()){this.aContextItems.push(new CUIAxisMemListItem(this,this.aContextItems.length,_FK._nx,_FK,this.iAxisIdx));this.aContextItems[this.aContextItems.length-1].Create();}else if(_FK.IsLevelMembers()){this.aContextItems.push(new CUIAxisLevelItem(this,this.aContextItems.length,_FK._dl,_FK,this.iAxisIdx,_FK.GetLastDataMemberId()));this.aContextItems[this.aContextItems.length-1].Create();}else if(_FK.IsDepthBased()){var _Lx=_FK.GetLastDataMemberId();if(!_Lx&&_FK.GetRootParentBlock()){_Lx=_FK.GetRootParentBlock().GetLastDataMemberId();}var _aEa=new CUIAxisDepthBasedItem(this,this.aContextItems.length,_Lx,_FK,this.iAxisIdx);this.aContextItems.push(_aEa);this.aContextItems[this.aContextItems.length-1].Create();}else{this.aContextItems.push(new CUIAxisSimpleItem(this,this.aContextItems.length,_FK.GetLastDataMemberId(),_FK,this.iAxisIdx));this.aContextItems[this.aContextItems.length-1].Create();}};CUIAxisContextSet.prototype.GetItemCount=function(){return this.aContextItems.length;};CUIAxisContextSet.prototype.GetItem=function(i){return this.aContextItems[i];};CUIAxisContextSet.prototype.GetSimpleItem=function(_CP){Debug.Assert(_CP!=null);for(var i=0;i<this.aContextItems.length;i++){if(this.aContextItems[i].oDLBlock&&this.aContextItems[i].oDLBlock.GetId()==_CP){return this.aContextItems[i];}}return null;};CUIAxisContextSet.prototype.GetComboItem=function(_PQ){Debug.Assert(_PQ>=0);Debug.Assert(this.aComboItems.length>0);if(_PQ>=0&&this.aComboItems.length>0){return this.aComboItems[_PQ];}return null;};CUIAxisContextSet.prototype.GetComboItemByBlockId=function(_L7){for(var x=0;x<this.aComboItems.length;x++){for(var i=0;i<this.aComboItems[x].aBlocks.length;i++){for(var j=0;j<this.aComboItems[x].aBlocks[i].length;j++){if(this.aComboItems[x].aBlocks[i][j].GetId()==_L7){return this.aComboItems[x];}}}}return null;};function CUIFilterContextItem(_Dx,_Qj){this.base=CUIAbsContextItem;this.base(_Dx,_Qj);};CUIFilterContextItem.prototype=new CUIAbsContextItem;CUIFilterContextItem.superclass=CUIAbsContextItem.prototype;CUIFilterContextItem.prototype.Create=function(_EB){CUIFilterContextItem.superclass.Create.call(this,_EB.GetLabel());this.oDLFilter=_EB;var _QG=true;this.constructTooltip(this.oDLFilter.GetBlock(),true);};CUIFilterContextItem.prototype.ModifyFilter=function(_BX){var _4J="";var _Hx=ExpAPIXml.kChildrenPopulation;var _J5=new Array(_BX);_4J=CDLDataManager.CreateSetExpression(_Hx,_J5);this.oDLFilter.ModifySetExpression(_4J);};CUIFilterContextItem.SafeDoDeleteFilter=function(_Mh){/*@if(!@bering_debug)@*/try{/*@end@*/_Mh.oDLFilter.DeleteFilter();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIFilterContextItem.SafeDoSetFilterAsParam=function(_Mh){/*@if(!@bering_debug)@*/try{/*@end@*/_Mh.oDLFilter.SetFilterAsParam();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIFilterContextItem.prototype.GetDeleteAction=function(){return this.oDLFilter.GetDeleteAction();};CUIFilterContextItem.prototype.CanBeUsedAsParam=function(e){if(!this.oDLFilter._rB._ma){return false;}if(this.oDLFilter._rB.GetUserDefFLT()||this.oDLFilter._rB.HasTopBottomRule()||this.oDLFilter._rB.HasExcludedMembers()){return false;}if(this.oParentSet.oParentBar.oUIMgr.dataManager.GetAnalysis().GetDisplayBreadcrumb()){return false;}return true;};function CUIChildrenFLContextItem(_Dx,_Qj){this.base=CUIAbsContextItem;this.base(_Dx,_Qj);this.oDLFilter=null;this._q9=false;this._xd=false;};CUIChildrenFLContextItem.prototype=new CUIFilterContextItem;CUIChildrenFLContextItem.superclass=CUIAbsContextItem.prototype;CUIChildrenFLContextItem.prototype.GetSearchData=function(){return this.oDLFilter.GetBlock().GetSearchData();};CUIChildrenFLContextItem.prototype.Display=function(_EP,_E3,_U4){var _FK=this.oDLFilter.GetBlock();var _N5=this.oParentSet.oParentBar;var _TW=_FK.GetDimId();var _ahk=(_N5.GetBlocksCountForDimId(_TW)>1);var _zr=document.createElement('TABLE');var _RK=_zr.appendChild(document.createElement('TBODY'));var _FW=_RK.appendChild(document.createElement('TR'));_zr.cellPadding=0;_zr.cellSpacing=0;_EP.appendChild(_zr);var _29=document.createElement('IMG');_29.src=Utilities.IMG_PATH+"context_item_handle_22.gif";COTStyle.SetWidth(_29,6);_29.className='drag_handle';_29.onmousedown=CUIChildrenFLContextItem.SafeOnMouseDownOnDragHandle;Dom.SetObjRef(_29,this,'obj');_29.kType=CUIContextBar.kTypeItem;var _NM=_FW.appendChild(document.createElement('TD'));_NM.appendChild(_29);this.elParent=_EP;this.elName=document.createElement('DIV');var _NM=_FW.appendChild(document.createElement('TD'));_NM.appendChild(this.elName);if(this.oDLFilter&&this.oDLFilter.IsRootMemberDummyFilter()){_E3='filter_context_item_name_root';}if(_ahk){_E3='dup_dim_'+_E3;this.className=_E3;}CUIChildrenFLContextItem.superclass.Display.call(this,_NM,_E3);this.elName.onmousedown=CUIChildrenFLContextItem.SafeOnMouseDownOnDragHandle;this.elName.oncontextmenu=CUIChildrenFLContextItem.SafeHandleOnContextMenu;Dom.SetObjRef(this.elName,this,'obj');var _Xr=_FK.GetFilterCombinationType();if(_Xr!=CUIAxisContextItem.kNonFlt){var _ayY=CUIAxisContextItem.aFltComboTypeImgMap[_Xr];var _Ke=_N5.oUIMgr.appobj.appname;var _afT=COTInputElementFactory.CreateImage(_ayY,16,16);this.elName.appendChild(_afT);_afT.className='filter_icon';}else if(_FK.IsLocked()){var _afT=COTInputElementFactory.CreateImage('icon_hold.gif',16,16);this.elName.appendChild(_afT);_afT.className='filter_icon';}this.elLink=document.createElement('A');this.elLink.tabIndex=_U4;Dom.SetObjRef(this.elLink,this,'obj');this.elLink.className='invisible_link';var _CU=_N5.oUIMgr.appobj.oResources;var _7C=Utilities.GetTruncatedString(this.sLabel,CUIContextBar.kLabelTruncateLength,_CU);_0o=document.createTextNode(_7C);this.elLink.appendChild(_0o);this.elName.appendChild(this.elLink);if(_ahk){var _Tc=_N5.oUIMgr.dataManager.metadata;var _atC=document.createElement('DIV');_atC.className='hierarchy_label';var _aoy=_Tc.GetHierarchyById(_FK.GetHierarchyOrDimId()).GetLabel();_aoy=Utilities.GetTruncatedString(_aoy,CUIContextBar.kLabelTruncateLength,this.oParentSet.oRes);_atC.appendChild(document.createTextNode(_aoy));this.elName.appendChild(_atC);}this.elParent.title=this.sTooltip;var _NM=_FW.appendChild(document.createElement('TD'));this.drawDropDownArrow(_NM);};CUIChildrenFLContextItem.SafeHandleOnContextMenu=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e)var e=window.event;this.obj.HandleOnContextMenu(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIChildrenFLContextItem.prototype.HandleOnContextMenu=function(e){if(this.oParentSet.oParentBar._qh){return;}this.HandleMouseDown(e);};CUIChildrenFLContextItem.SafeOnMouseDownOnDragHandle=function(e){try{if(!e){var e=window.event;}if(!this.obj.oParentSet.oParentBar._qh){CUIDragDropSource.HandleMouseDown(e,this,this.obj);}}catch(e){_f.HandleException(e);}};CUIChildrenFLContextItem.prototype.OnDragStart=function(e){var _aby=CUIChildrenFLContextItem.superclass.OnDragStart.call(this);if(_aby){var _C7='';var _UY=this.oDLFilter.GetMember();if(_UY){_C7=_UY._ks;}var _Lv=new CUIDragDropDimFilter(this.oDLFilter.elcid,_C7,true);var _Hk=this.oParentSet.oParentBar.oUIMgr;CUIDragDrop.Start(this,_Hk,_Lv,CUIDragDrop.eEffectNone,e);var _Bu=new Array(this.sLabel);var _QX=new Array();CUIDragDrop.SetTooltipItems(_QX,_Bu);CUIDragDrop.ShowTooltip(e.clientX,e.clientY);}};CUIChildrenFLContextItem.prototype.HandleMouseDown=function(e){Dom.SetObjRef(window,this,'oLastFilter');this._qA=false;this.elName.oLastEvent=Dom.CloneMouseEvent(e);this.oContextMenu.Clear();var _Ke=this.oParentSet.oParentBar.oUIMgr.appobj.appname;var _CU=FindApp(_Ke).oResources;var _Ss=!this.CanDelete();this._nd=-1;this._sT=-1;var _ahl=new Array(this);var _aDs=_CU.GetString('OTH_CONTEXTBAR_DELETE_FILTER');var _apq=new ContextItem('tool_main_delete.gif',_aDs,CUIFilterContextItem.SafeDoDeleteFilter,_Ss,_ahl,this.oContextMenu);var _aIC=new ContextSeparator(this.oContextMenu);_Ss=false;var _aq6=false;if(!this.oDLFilter.GetBlock().HasExcludedList()&&!this.oDLFilter.GetBlock().HasTopBottomRule()&&this.oDLFilter.GetBlock().IsChildren()){var oMem=this.oDLFilter.GetMember();this.loadMetadataInclSibIntoMenu(oMem,CUIFilterContextSet.SafeDoModifyDimFilter,e);_aq6=true;}if(_aq6){var _aIC=new ContextSeparator(this.oContextMenu);_aq6=false;}if(this.CanBeUsedAsParam()){var _9g=new Array(this);var _aw3=_CU.GetString('OTH_USE_AS_GOTO_PARA_FOR_DRILL_THROUGH');var _aAO=new ContextItem('',_aw3,CUIFilterContextItem.SafeDoSetFilterAsParam,_Ss,_9g,this.oContextMenu);var _Ng=this.oDLFilter.bUsedAsParam?true:false;_aAO.SetChecked(_Ng);_aq6=true;}if(this.oDLFilter.GetBlock().IsChildren()){_aq6=true;var oMem=this.oDLFilter.GetMember();_BM=_CU.ReplaceParam('OTH_SEARCH_CHILDREN',1,oMem._p8);var _azW=new Array(_Ke);var _awQ=new ContextItem('icon_search.gif',_BM,CUIManager.SafeDoSearch,false,_azW,this.oContextMenu);}if(!_aq6){this.oContextMenu.RemoveItem(this.oContextMenu.items.length-1);}this.showDropDownMenu(e);};CUIChildrenFLContextItem.prototype.CanDelete=function(){return this.oDLFilter.GetBlock().CanDelete();};CUIChildrenFLContextItem.prototype.loadMetadataInclSibIntoMenu=function(oMem,_BC,e){if(!_Ga){var _Ga=this.oContextMenu;}this.addAncestorToMenu(oMem,_Ga,_BC);this.addSiblingToMenu(oMem,_Ga,_BC);this.addChildrenToMenu(oMem,_Ga,_BC);};CUIChildrenFLContextItem.prototype.addSiblingToMenu=function(oMem,_Ga,_BC){var _Ke=this.oParentSet.oParentBar.oUIMgr.appobj.appname;var _CU=FindApp(_Ke).oResources;var _Ss=false;var _VW=oMem._qR;var _anj=null;var _aBK=null;if(_VW){var _aIC=new ContextSeparator(_Ga);var _Gg=false;var _XX=_VW.GetChildIndex(oMem,_Gg);if(_XX>0){var _ak1=_VW.GetChild(_XX-1,_Gg)._ks;var _awl=_CU.ReplaceParam('OTH_PREV_SIB_MEMBER',1,_VW.GetChild(_XX-1,_Gg)._p8);var _AG=new Array(_Ke,_ak1);var _3s=new ContextItem('',_awl,_BC,_Ss,_AG,this.oContextMenu);}else if(_XX==0){var _awl=_CU.GetString('OTH_NONE_PREV_SIB');var _3s=new ContextItem('',_awl,null,true,null,this.oContextMenu);}else{var _awl=_CU.GetString('OTH_UNKOWN_PREV_SIB_MEMBER');var _3s=new ContextItem('',_awl,null,true,null,this.oContextMenu);}var _art=(_XX==(_VW.GetChildCount(_Gg)-1));if(_XX==-1||_art){if(!_VW._v1){var _Zx=_CU.GetString('OTH_UNKOWN_NEXT_SIB');}else{var _Zx=_CU.GetString('OTH_NONE_NEXT_SIB');}var _amn=new ContextItem('',_Zx,null,true,null,this.oContextMenu);}else if(!_art){var _aDn=_VW.GetChild(_XX+1,_Gg)._ks;var _Zx=_CU.ReplaceParam('OTH_NEXT_SIB_MEMBER',1,_VW.GetChild(_XX+1,_Gg)._p8);var _AG=new Array(_Ke,_aDn);var _amn=new ContextItem('',_Zx,_BC,_Ss,_AG,this.oContextMenu);}if(!_VW.GetMetadata().GetOrphan(_VW.GetId())){_BM=_CU.ReplaceParam('OTH_SEARCH_OTHER_SIB',1,_VW._p8);var _azW=new Array(_Ke,_VW);var _awQ=new ContextItem('icon_search.gif',_BM,CUIMetadataTree.SafeDoSearchFromData,false,_azW,this.oContextMenu);}var _aIC=new ContextSeparator(_Ga);}};CUIChildrenFLContextItem.prototype.Notify=function(_Dy){var _zf=this.oContextMenu;if(_Dy==ExpEvent.kCDLMember_Merge&&!this._xd){if(this.oDLFilter){var oMem=this.oDLFilter.GetMember();this.handleMetadataMerge(oMem);}}else if(_Dy==ExpEvent.kCDLMember_Merge_NoResponse){this._qA=true;if(this.oDLFilter){var oMem=this.oDLFilter.GetMember();this.handleMetadataMerge(oMem);}}};function CUIMemberSetFLContextItem(_Dx,_Qj){this.base=CUIAbsContextItem;this.base(_Dx);this.oDLFilter=null;};CUIMemberSetFLContextItem.prototype=new CUIFilterContextItem;CUIMemberSetFLContextItem.superclass=CUIAbsContextItem.prototype;CUIMemberSetFLContextItem.prototype.GetSearchData=function(){return this.oDLFilter.GetBlock().GetSearchData();};CUIMemberSetFLContextItem.prototype.constructTooltip=function(){this.sTooltip=this.oDLFilter.GetBlock().getHAMCFilterDescription();};CUIMemberSetFLContextItem.prototype.Display=function(_EP,_E3,_U4){var _zr=document.createElement('TABLE');var _RK=_zr.appendChild(document.createElement('TBODY'));var _FW=_RK.appendChild(document.createElement('TR'));_zr.cellPadding=0;_zr.cellSpacing=0;_EP.appendChild(_zr);var _29=document.createElement('IMG');_29.src=Utilities.IMG_PATH+"context_item_handle_22.gif";COTStyle.SetWidth(_29,6);_29.className='drag_handle';_29.onmousedown=CUIMemberSetFLContextItem.SafeOnMouseDownOnDragHandle;Dom.SetObjRef(_29,this,'obj');_29.kType=CUIContextBar.kTypeItem;var _NM=_FW.appendChild(document.createElement('TD'));_NM.appendChild(_29);this.elParent=_EP;this.elName=document.createElement('DIV');_NM=_FW.appendChild(document.createElement('TD'));_NM.appendChild(this.elName);CUIMemberSetFLContextItem.superclass.Display.call(this,_NM,_E3);this.elName.onmousedown=CUIMemberSetFLContextItem.SafeOnMouseDownOnDragHandle;this.elName.oncontextmenu=CUIMemberSetFLContextItem.SafeHandleOnContextMenu;Dom.SetObjRef(this.elName,this,'obj');var _Xr=this.oDLFilter.GetBlock().GetFilterCombinationType();if(_Xr!=CUIAxisContextItem.kNonFlt){var _ayY=CUIAxisContextItem.aFltComboTypeImgMap[_Xr];var _Ke=this.oParentSet.oParentBar.oUIMgr.appobj.appname;var _afT=COTInputElementFactory.CreateImage(_ayY,16,16);this.elName.appendChild(_afT);_afT.className='filter_icon';}else if(this.oDLFilter.GetBlock().IsLocked()){var _afT=COTInputElementFactory.CreateImage('icon_hold.gif',16,16);this.elName.appendChild(_afT);_afT.className='filter_icon';}this.elLink=document.createElement('A');this.elLink.tabIndex=_U4;Dom.SetObjRef(this.elLink,this,'obj');this.elLink.className='invisible_link';var _CU=this.oParentSet.oParentBar.oUIMgr.appobj.oResources;var _7C=Utilities.GetTruncatedString(this.sLabel,CUIContextBar.kLabelTruncateLength,_CU);_0o=document.createTextNode(_7C);this.elLink.appendChild(_0o);this.elName.appendChild(this.elLink);this.elParent.title=this.sTooltip;var _NM=_FW.appendChild(document.createElement('TD'));this.drawDropDownArrow(_NM);};CUIMemberSetFLContextItem.prototype.GetDisplayWidth=function(){var _F4=0;_F4=Math.max(COTStyle.GetDisplayOffsetWidth(this.elImg),COTStyle.GetDisplayOffsetWidth(this.elLabel));_F4+=COTStyle.GetHorizontalBordersWidth(this.elDiv);_F4+=COTStyle.GetHorizontalPaddingWidth(this.elDiv);return _F4;};CUIMemberSetFLContextItem.SafeHandleOnContextMenu=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e)var e=window.event;this.obj.HandleOnContextMenu(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIMemberSetFLContextItem.prototype.HandleOnContextMenu=function(e){if(this.oParentSet.oParentBar._qh){return;}this.HandleMouseDown(e);};CUIMemberSetFLContextItem.SafeOnMouseDownOnDragHandle=function(e){try{if(!e){var e=window.event;}CUIDragDropSource.HandleMouseDown(e,this,this.obj);}catch(e){_f.HandleException(e);}};CUIMemberSetFLContextItem.prototype.OnDragStart=function(e){var _aby=CUIMemberSetFLContextItem.superclass.OnDragStart.call(this);if(_aby){CUIMemberSetFLContextItem.superclass.OnDragStart.call(this);var _Lv=new CUIDragDropOrListFilter(this.oDLFilter.elcid,this.oDLFilter._rB._nx,true);var _Hk=this.oParentSet.oParentBar.oUIMgr;CUIDragDrop.Start(this,_Hk,_Lv,CUIDragDrop.eEffectNone,e);var _Bu=new Array(this.sLabel);var _QX=new Array();CUIDragDrop.SetTooltipItems(_QX,_Bu);CUIDragDrop.ShowTooltip(e.clientX,e.clientY);}};CUIMemberSetFLContextItem.prototype.HandleMouseDown=function(e){Dom.SetObjRef(window,this,'oLastFilter');this.oContextMenu.Clear();var _Ke=this.oParentSet.oParentBar.oUIMgr.appobj.appname;var _CU=FindApp(_Ke).oResources;var _Ss=!this.oDLFilter.GetBlock().CanDelete();var _ahl=new Array(this);var _aDs=_CU.GetString('OTH_CONTEXTBAR_DELETE_FILTER');var _apq=new ContextItem('tool_main_delete.gif',_aDs,CUIFilterContextItem.SafeDoDeleteFilter,_Ss,_ahl,this.oContextMenu);var _aIC=new ContextSeparator(this.oContextMenu);_Ss=false;var _aq6=false;var _RJ=this.oParentSet.oParentBar.oUIMgr.dataManager.metadata;var _Ze=this.oDLFilter.GetBlock().GetDefinitionIds();for(var i=0;i<_Ze.length;i++){if(_RJ.GetMember(_Ze[i])){var _AG=new Array(_Ke,_Ze[i]);var _PM=new ContextItem('',_RJ.GetMember(_Ze[i]).GetLabel(),CUIFilterContextSet.SafeDoModifyDimFilter,false,_AG,this.oContextMenu);_aq6=true;}}if(_aq6){var _aIC=new ContextSeparator(this.oContextMenu);_aq6=false;}if(this.CanBeUsedAsParam()){_aq6=true;var _9g=new Array(this);var _aw3=_CU.GetString('OTH_USE_AS_GOTO_PARA_FOR_DRILL_THROUGH');var _aAO=new ContextItem('',_aw3,CUIFilterContextItem.SafeDoSetFilterAsParam,_Ss,_9g,this.oContextMenu);var _Ng=this.oDLFilter.bUsedAsParam?true:false;_aAO.SetChecked(_Ng);}var _apD=this.oDLFilter.GetBlock().GetSearchData();if(_apD){_aq6=true;var _ZF='';for(var i in _apD){if(_apD[i].IsRootMember()&&_apD[i].GetLabel){_ZF=_apD[i].GetLabel();break;}}var _BM=_CU.ReplaceParam('IDS_SEARCH',1,_ZF);var _azW=new Array(_Ke);var _awQ=new ContextItem('icon_search.gif',_BM,CUIManager.SafeDoSearch,false,_azW,this.oContextMenu);}if(!_aq6){this.oContextMenu.RemoveItem(this.oContextMenu.items.length-1);}this.showDropDownMenu(e);};CUIMemberSetFLContextItem.prototype.CanDelete=function(){return this.oDLFilter.GetBlock().CanDelete();};function CUIChart(_Ul,_PX){this._qC=_Ul;this._jN=_PX;this._p2=null;this._mx=new Array();this._hL=null;if(Utilities.bScatterPlotGraphsEnabled){this._xZ=new Object();this._xZ[ExpAPIXml.kChartTopLeft]=new ChartSegment(0,0,0,0);this._xZ[ExpAPIXml.kChartTopRight]=new ChartSegment(0,0,0,0);this._xZ[ExpAPIXml.kChartBottomLeft]=new ChartSegment(0,0,0,0);this._xZ[ExpAPIXml.kChartBottomRight]=new ChartSegment(0,0,0,0);}};CUIChart.prototype.Init=function(_EP){this._jN.Subscribe(this,ExpEvent.kCUIWorksheet_Unload);this._p2=document.createElement('DIV');this._p2.className="ChartPane";_EP.appendChild(this._p2);};CUIChart.prototype.SetDLChart=function(_Ul){this._qC=_Ul;};CUIChart.prototype.GetDLChart=function(){return this._qC;};CUIChart.prototype.IsInErrorState=function(){return this._qC.IsInErrorState();};CUIChart.prototype.GetChartType=function(){return this._qC.GetChartType();};CUIChart.prototype.Is3D=function(){return this._qC._p7;};CUIChart.prototype.GetHeight=function(){if(this.IsInErrorState()){return COTStyle.GetHeightFromOffset(this._O);}return Number(this._qC.GetHeight());};CUIChart.prototype.GetWidth=function(){return Number(this._qC.GetWidth());};CUIChart.prototype.SetWidth=function(_F4){COTStyle.SetWidth(this._p2,_F4);};CUIChart.prototype.SupportsThreeDEffect=function(){return this._qC.SupportsThreeDEffect();};CUIChart.prototype.IsStacked=function(){return this._qC._le;};CUIChart.prototype.IsStacked100Percent=function(){return this._qC._ug;};CUIChart.prototype.DoesShowValues=function(){return this._qC._nb;};CUIChart.prototype.DoesShowValuesAsPercent=function(){return this._qC._hD;};CUIChart.prototype.GetUIWorkSheet=function(){return this._jN;};CUIChart.prototype.GetDataWorkSheet=function(){return this._jN.GetDataWorkSheet();};CUIChart.prototype.GetUIAxis=function(i){Debug.Assert(i<this._mx.length);if(i<this._mx.length){return this._mx[i];}return null;};CUIChart.prototype.GetAxisCount=function(){return this.GetDataWorkSheet()._rk.GetAxisCount();};CUIChart.prototype.GetOppositeAxis=function(_Q1){for(var i=0;i<this._mx.length;i++){if(_Q1!=this._mx[i]){return this._mx[i];}}return null;};CUIChart.prototype.GetSelectedAxis=function(){return null;};CUIChart.prototype.SetLastAxisSelected=function(_Q1){this._hL=_Q1;};CUIChart.prototype.DrawErrorState=function(){var _ayu=this._p2.appendChild(document.createElement('DIV'));this._O=_ayu;var _7w=_ayu.appendChild(document.createElement('DIV'));_7w.className="chartError";var _zr=_7w.appendChild(document.createElement('TABLE'));var _RK=_zr.appendChild(document.createElement('TBODY'));var _FW=_RK.appendChild(document.createElement('TR'));var _aFT=_FW.appendChild(document.createElement('TD'));var _aiw=_aFT.appendChild(document.createElement('IMG'));_aiw.src=Utilities.IMG_PATH+'msg_warning.gif';var _ala=_FW.appendChild(document.createElement('TD'));_ala.className='infoLabel';var _F3=this._jN.oResources.ReplaceParam('MES_CHART_ERROR',1,ExpMiscStr.kProductName);var _TL=_ala.appendChild(document.createTextNode(_F3));var _Ke=this._jN._m4.appobj.appname;this._Y=Utilities.GenerateCallback(CUIWorkSheet.SafeHideChart,[_Ke]);var _F0=document.createElement('TBODY');var _aE1=document.createElement('table');_aE1.className='dialogbuttons';_aE1.appendChild(_F0);_ayu.appendChild(_aE1);this._ke=Utilities.GenerateId();_aE1.id=this._ke;_EJ=document.createElement('TR');_Cs=document.createElement('TD');COTStyle.SetWidth(_Cs,60,'px');var _aID=this._jN.oResources.GetString('IDS_BUTTON_CLOSE');_Cs.appendChild(COTInputElementFactory.CreateButton('OKButton',_aID,this._Y,false,false,1));_EJ.appendChild(_Cs);_F0.appendChild(_EJ);if(_o.is_ie5_5up){var _aaT=COTStyle.GetHeightFromOffset(_aE1);_aaT+=COTStyle.GetHeightFromOffset(_7w);COTStyle.SetHeight(_ayu,_aaT);}else{var _aov=2;var _anC=6;var _avh=12;_7w.style.marginTop=_avh+"px";_7w.style.marginBottom=_anC+"px";_ayu.style.marginTop=-_avh+"px";var _aaT=COTStyle.GetHeightFromOffset(_ayu);COTStyle.SetHeight(_ayu,_aaT+_anC+_aov);}};CUIChart.prototype.Refresh=function(){Dom.RemoveAllChildren(this._p2);if(this._qC._he.IsInMissingMUNState()){return;}Dom.SetObjRef(this._p2,this,'oChart');this._p2.onclick=CUIChart.SafeHandleClick;var _ac3=this._qC._he.GetCurrentDataMatrix();for(var i=0;i<_ac3.GetAxisCount();i++){if(!this._mx[i]){this._mx[i]=new CUIChartAxis(this,i);this._mx[i].Init();}this._mx[i].Populate();}if(this._qC.IsInErrorState()){this.DrawErrorState();return;}var _aBO=document.getElementById("ImageMap");var _8g=Dom.GetImmediateChildByName(_aBO,"MAP");Dom.RemoveAllChildren(_8g);Dom.SetObjRef(_aBO,this,'oChart');for(var i=0;i<this._qC.GetChartAreaCount();i++){var _JC=this._qC.GetChartArea(i);var _W3=document.createElement('AREA');_8g.appendChild(_W3);var _XP=new String(_JC.GetShape());_W3.shape=_XP.toLowerCase();_W3.coords=_JC.GetCoords();_W3.title=this.constructTooltip(_JC);_W3.onclick=CUIChart.SafeHandleClick;_W3.onmouseover=CUIChart.SafeHandleMouseOver;_W3.onmouseout=CUIChart.SafeHandleMouseOut;_W3.onmousemove=CUIChart.SafeHandleMouseOver;_W3.noHref=true;_W3.iChartAreaIdx=i;}_aBO.style.display="block";var _afT=document.createElement('IMG');_afT.className="chart";var _Mn=this._qC.GetURL();_afT.src=_Mn;_afT.useMap="#ChartMap";COTStyle.SetWidth(_afT,5000);COTStyle.SetHeight(_afT,5000);if(this._qC.GetWidth()!=-1){COTStyle.SetWidth(_afT,parseInt(this._qC.GetWidth()));}if(this._qC.GetHeight()!=-1){COTStyle.SetHeight(_afT,parseInt(this._qC.GetHeight()));}this._p2.appendChild(_afT);if(Utilities.bScatterPlotGraphsEnabled&&(this._qC.GetChartType()==ExpAPIXml.eChartTypeScatter)){var _TM=this._jN.iTop+this._jN._m4._dx+CUIManager.kiTopWindowMargin;var _P6=this._jN._wK+CUIManager.kiLeftWindowMargin;var _Ul=this._qC;var _Li=_Ul._he.GetCurrentDataMatrix();var _RJ=this._qC._he.metadata;this.SetYAxisMeasure(_Li.sSegMea2Mun,_RJ.GetMeasure(_Li.sSegMea2Mun).GetLabel());this.SetXAxisMeasure(_Li.sSegMea1Mun,_RJ.GetMeasure(_Li.sSegMea1Mun).GetLabel());this._lH=_Li.GetBlock(_Li._bF);var _aEq=_Ul.GetTopMostChartArea();var _azb=_Ul.GetBottomMostChartArea();this.oVerticalSlider=new CUIVertChartSlider();var _DT=_aEq.iYCoord;var _OK=_azb.iYCoord;this.oVerticalSlider.OnCreate('black_dot.gif',this,this._p2,parseInt(this._lH._nZ),parseInt(this._lH._mh),this._lH._pd,_DT,_OK,_TM);var _W5=_Ul.GetLeftMostChartArea();var _8q=_Ul.GetRightMostChartArea();var _PL=_W5.iXCoord;var _St=_8q.iXCoord;this.oHorizontalSlider=new CUIHorizChartSlider();this.oHorizontalSlider.OnCreate('black_dot.gif',this,this._p2,parseInt(this._lH._q3),parseInt(this._lH._bW),this._lH._uZ,_PL,_St,_P6);var _aju=this.oHorizontalSlider.GetZeroXPosition()+9-15;this.oVerticalSlider.SetHandlerInitLeftPos(_aju);var _amR=this.oVerticalSlider.GetZeroYPosition()+10+3;this.oHorizontalSlider.SetHandlerInitTopPos(_amR);}};CUIChart.prototype.SetXAxisMeasure=function(_Pi,_MZ){this.xMeasureId=_Pi;this.xMeasureLabel=_MZ;};CUIChart.prototype.SetYAxisMeasure=function(_Pi,_MZ){this.yMeasureId=_Pi;this.yMeasureLabel=_MZ;};CUIChart.prototype.SetTopSegYMaxMeasure=function(_SC){this._xZ[ExpAPIXml.kChartTopLeft].SetYMaxMeasure(_SC);this._xZ[ExpAPIXml.kChartTopRight].SetYMaxMeasure(_SC);};CUIChart.prototype.SetRightSegXMaxMeasure=function(_Rl){this._xZ[ExpAPIXml.kChartTopRight].SetXMaxMeasure(_Rl);this._xZ[ExpAPIXml.kChartBottomRight].SetXMaxMeasure(_Rl);};CUIChart.prototype.CreateHSegments=function(_DB){this._xZ[ExpAPIXml.kChartTopLeft].SetXMaxMeasure(_DB);this._xZ[ExpAPIXml.kChartBottomLeft].SetXMaxMeasure(_DB);this._xZ[ExpAPIXml.kChartTopRight].SetXMinMeasure(_DB);this._xZ[ExpAPIXml.kChartBottomRight].SetXMinMeasure(_DB);this._lH._oL=_DB;this._lH.ModifySegmentMeasureValue();};CUIChart.prototype.CreateVSegments=function(_DB){this._xZ[ExpAPIXml.kChartTopLeft].SetYMinMeasure(_DB);this._xZ[ExpAPIXml.kChartBottomLeft].SetYMaxMeasure(_DB);this._xZ[ExpAPIXml.kChartTopRight].SetYMinMeasure(_DB);this._xZ[ExpAPIXml.kChartBottomRight].SetYMaxMeasure(_DB);this._lH._R=_DB;this._lH.ModifySegmentMeasureValue();};CUIChart.prototype.ListSegments=function(){for(var s in this._xZ){var _aIO=this._xZ[s];alert(s+" segment: \n"+this.yMeasureLabel+">"+_aIO.iMinYMeasure+" and "+this.yMeasureLabel+" <"+_aIO.iMaxYMeasure+" \n"+this.xMeasureLabel+" > "+_aIO.iMinXMeasure+" and "+this.xMeasureLabel+" < "+_aIO.iMaxXMeasure);}};CUIChart.prototype.constructTooltip=function(_JC){if(_JC.GetChartMemberCount()==0){return "";}var _Rz="";if(_JC.IsTitle()){if(_JC.GetChartMemberCount()==1){return _JC.GetChartMember(0).GetCaption();}else{var _Nv=new Array();for(var i=0;i<_JC.GetChartMemberCount();i++){var _aiU=_JC.GetChartMember(i);if(_aiU._tW){continue;}if(_aiU.sUseTooltip){_Nv.push(_aiU.sUseTooltip);}else{_Nv.push(_aiU.GetCaption());}}return this._jN.oResources.ReplaceParamList('IDS_CHART_TITLE_TOOLTIP_MEMBERS',_Nv);}}var _apB=_JC.GetChartMember(0).GetLevelLabel();_Rz=this._jN.oResources.ReplaceParam('IDS_CHART_INTERSECT_TOOLTIP_MEMBER',1,_apB);_Rz=this._jN.oResources.ReplaceParam(_Rz,2,_JC.GetChartMember(0).GetCaption());var _aHB=_Rz;for(var i=1;i<_JC.GetChartMemberCount();i++){_Rz=this._jN.oResources.ReplaceParam('IDS_CHART_INTERSECT_TOOLTIP_MEMBERS',1,_aHB);var _apB=_JC.GetChartMember(i).GetLevelLabel();_aHB=this._jN.oResources.ReplaceParam('IDS_CHART_INTERSECT_TOOLTIP_MEMBER',1,_apB);_aHB=this._jN.oResources.ReplaceParam(_aHB,2,_JC.GetChartMember(i).GetCaption());_aHB=this._jN.oResources.ReplaceParam(_Rz,2,_aHB);}if(Utilities.bScatterPlotGraphsEnabled&&(this._qC.GetChartType()==ExpAPIXml.eChartTypeScatter)){_aHB=_Rz;var _aho=_JC.GetChartMeasures();if(_aho){for(var _axX=0;_axX<_aho.length;_axX++){_Rz=this._jN.oResources.ReplaceParam('IDS_CHART_INTERSECT_TOOLTIP_MEMBERS',1,_aHB);var _Ba=_aho[_axX].GetMeasureLabel();_aHB=this._jN.oResources.ReplaceParam('IDS_CHART_INTERSECT_TOOLTIP_MEMBER',1,_Ba);_aHB=this._jN.oResources.ReplaceParam(_aHB,2,_aho[_axX].GetCaption());_aHB=this._jN.oResources.ReplaceParam(_Rz,2,_aHB);}}_Rz=_aHB;}else{var _Rz=_aHB;if(_JC.GetChartMeasure()){var _Ba=_JC.GetChartMeasure().GetMeasureLabel();if(!_Ba){_Ba=this._qC._he.GetCurrentDataMatrix().GetCurrentMeasureLabel();}_Rz=this._jN.oResources.ReplaceParam('IDS_CHART_INTERSECT_TOOLTIP',1,_Rz);_Rz=this._jN.oResources.ReplaceParam(_Rz,2,_Ba);_Rz=this._jN.oResources.ReplaceParam(_Rz,3,_JC.GetChartMeasure().GetCaption());}}return _Rz;};CUIChart.prototype.SecondarySelectBlock=function(_No,_U7){this.UnselectAll(true);var _aAG=_U7?true:false;var _RM=false;for(var i=0;i<this._mx.length;i++){if(this._mx[i].GetBlock(_No.GetId())){this._mx[i].SelectBlock(null,_No,_aAG);_RM=true;break;}}if(_RM){this._n2=true;this._uH=_No.GetId();}};CUIChart.prototype.GetSelectedBlock=function(){if(this._n2){for(var i=0;i<this._mx.length;i++){var _afd=this._mx[i].GetBlock(this._uH);if(_afd){return _afd;}}}return null;};CUIChart.prototype.UnselectAll=function(_RY){var _Lk=false;if(this._n2&&!_RY){_Lk=true;this._jN.OnBeforeBlockSelectionChange();}for(var i=0;i<this._mx.length;i++){this._mx[i].UnselectAllMembers();}this._n2=false;this._uH=null;if(!_RY){this._jN.HandleUnselect(this,_Lk);}};CUIChart.getChartFromEventTarget=function(el){var oChart=el.oChart;while(!oChart&&el!=document.body){el=el.parentNode;oChart=el.oChart;}return oChart;};CUIChart.SafeHandleClick=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/var _V9=this.iChartAreaIdx;var oChart=CUIChart.getChartFromEventTarget(this);if(oChart){oChart.HandleClick(_V9);}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIChart.SafeDoContinueHandleClick=function(_Ke,_V9){/*@if(!@bering_debug)@*/try{/*@end@*/var _asU=FindApp(_Ke).uiManager._jf._gg;_asU.ContinueHandleClick(_V9);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIChart.prototype.ContinueHandleClick=function(_V9){if(this._qC){if(_V9==null){this.UnselectAll();this._jN.HandleSelectedAxisCntx(ExpEvent.kCUIWorksheet_NoAxisSel);}else{var _JC=this._qC.GetChartArea(_V9);Debug.Assert(_JC);if(_JC){_JC.DoDrill();this.UnselectAll();this._jN.HandleSelectedAxisCntx(ExpEvent.kCUIWorksheet_NoAxisSel);}}}};CUIChart.prototype.HandleClick=function(_V9){Debug.Assert(this._qC);if(!this._jN.AllowInteraction()){return;}var _Ke=this._jN.GetAppName();var _V9=(_V9!=null)?_V9:null;var _amW=this._jN._m4.ConfirmLossOfChanges();if(_amW==Utilities.eStateContinue){this.ContinueHandleClick(_V9);}else if(_amW==Utilities.eStateHold){var _Ro=new Array(_Ke,_V9);Utilities.SetProcedureToHold(CUIChart.SafeDoContinueHandleClick,_Ro);this._jN._m4.oDialogMgr.Subscribe(this,ExpEvent.kCUIDialogMgr_HideModalDialog);}};CUIChart.SafeHandleMouseOut=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}var oChart=CUIChart.getChartFromEventTarget(this);if(oChart){oChart.HandleMouseOut(e);}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIChart.prototype.HandleMouseOut=function(e){CUIManager.HideDrillImage();this._p2.style.cursor="default";};CUIChart.SafeHandleMouseOver=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}var _V9=this.iChartAreaIdx;var oChart=CUIChart.getChartFromEventTarget(this);if(oChart){oChart.HandleMouseOver(e,_V9);}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIChart.prototype.HandleMouseOver=function(e,_V9){var _JC=this._qC.GetChartArea(_V9);Debug.Assert(_JC);if(_JC&&_JC.CanDrillUp()){CUIManager.ShowDrillImage(ExpAPIXml.kActionDrillUp,e.clientX,e.clientY);}else if(_JC&&_JC.CanDrillDown()){CUIManager.ShowDrillImage(ExpAPIXml.kActionDrillDown,e.clientX,e.clientY);}if(_JC&&_JC.CanDrillUp()||_JC.CanDrillDown()){this._p2.style.cursor="pointer";this._p2.style.cursor="hand";}};CUIChart.prototype.HandleResize=function(_T6,_TM){COTStyle.SetHeight(this._p2,_T6,'px');};CUIChart.prototype.Unload=function(){if(this._p2){this._p2.oChart=null;Dom.RemoveObject(this._p2);}var _aBO=document.getElementById("ImageMap");if(_aBO){_aBO.oChart=null;}for(var i=0;this._mx&&i<this._mx.length;i++){this._mx[i].Unload();}Utilities.RemoveAllChildObjects(this);};CUIChart.prototype.OnClose=function(){this._jN.HandleChartClose();};CUIChart.prototype.OnHide=function(){this.Unload();};CUIChart.prototype.Notify=function(_Dy){if(_Dy==ExpEvent.kCUIWorksheet_Unload){this.Unload();}else if(_Dy==ExpEvent.kCUIDialogMgr_HideModalDialog){Utilities.ExecuteHoldingProcedure();this._jN._m4.oDialogMgr.UnSubscribe(this,ExpEvent.kCUIDialogMgr_HideModalDialog);}};function ChartSegment(_T0,_SC,_It,_Rl){this.iMinYMeasure=0;this.iMaxYMeasure=0;this.iMinXMeasure=0;this.iMinXMeasure=0;};ChartSegment.prototype.SetYMinMeasure=function(_T0){this.iMinYMeasure=_T0;};ChartSegment.prototype.SetYMaxMeasure=function(_SC){this.iMaxYMeasure=_SC;};ChartSegment.prototype.SetXMinMeasure=function(_It){this.iMinXMeasure=_It;};ChartSegment.prototype.SetXMaxMeasure=function(_Rl){this.iMaxXMeasure=_Rl;};function CUIToolBar(_Hk,_EP,_E3){this.oUIMgr=_Hk;this.oUIMgr.Subscribe(this,ExpEvent.kCUIManager_Unload);this._J=document.createElement('DIV');_EP.appendChild(this._J);if(_E3){this._J.className=_E3;}this.aButtons=new Array();this.aToolGroups=new Array();this._rI=16;};CUIToolBar.kSpaceBtwToolGroups=10;CUIToolBar.kiBorderWidth=1;CUIToolBar.prototype.SetButtonSize=function(_Cg){this._rI=_Cg;};CUIToolBar.prototype.Clear=function(){for(var i=0;i<this.aToolGroups.length;i++){this.aToolGroups[i].Unload();}Utilities.DeleteAllFromArray(this.aToolGroups);this._rP=null;this.aButtons=new Array();this.aToolGroups=new Array();};CUIToolBar.prototype.AddMissingDataButtons=function(){this.Clear();this.aToolGroups.push(new CUIToolGroup(this));this.aToolGroups[0].AddButton("tool_main_new_16.gif","tool_main_new_16.gif",'IDS_TOOLBAR_NEW',CUIWorkSheet.SafeDoNewToolBar,true);this.aToolGroups[0].AddButton("icon_file_open.gif","icon_file_open.gif",'IDS_TOOLBAR_OPEN',CUIWorkSheet.SafeDoLoad,true);if(this.oUIMgr.dataManager._vw.IsFixable()){this.aToolGroups.push(new CUIToolGroup(this));this.aToolGroups[1].AddButton("icon_search.gif","icon_search.gif",'IDS_TOOLBAR_SEARCH',CUIManager.SafeDoSearch,true);}};CUIToolBar.prototype.AddDefaultButtons=function(){this.Clear();this.aToolGroups.push(new CUIToolGroup(this));this.aToolGroups[0].AddButton("tool_main_new_16.gif","tool_main_new_16.gif",'IDS_TOOLBAR_NEW',CUIWorkSheet.SafeDoNewToolBar,true);this.aToolGroups[0].AddButton("icon_file_open.gif","icon_file_open.gif",'IDS_TOOLBAR_OPEN',CUIWorkSheet.SafeDoLoad,true);this.aToolGroups[0].AddButton("tool_main_save.gif","tool_main_save.gif",'IDS_TOOLBAR_SAVE',CUIWorkSheet.SafeDoSave,true);this.aToolGroups[0].AddButton("tool_main_saveas.gif","tool_main_saveas.gif",'IDS_TOOLBAR_SAVE_AS',CUIWorkSheet.SafeDoSaveAs,true);this.aToolGroups.push(new CUIToolGroup(this));this.aToolGroups[1].AddButton("tool_main_delete.gif","tool_main_delete.gif",'IDS_TOOLBAR_DELETE',CUIManager.SafeDoDeleteSelections,true);this.aToolGroups[1].AddButton("icon_undo16.gif","icon_undo16.gif",'IDS_TOOLBAR_UNDO',CUIWorkSheet.SafeDoUndo,true,true);this.aToolGroups[1].AddButton("icon_redo16.gif","icon_redo16.gif",'IDS_TOOLBAR_REDO',CUIWorkSheet.SafeDoRedo,true,true);this.aToolGroups[1].AddButton("icon_search.gif","icon_search.gif",'IDS_TOOLBAR_SEARCH',CUIManager.SafeDoSearch,true);this.aToolGroups.push(new CUIToolGroup(this));var _aeg=true;this.aToolGroups[2].AddDropDownButton("RunReportHTML.gif","RunReportHTML.gif",'IDS_TOOLBAR_REPORTHTML',CUIWorkSheet.SafeDoShowRunMenu,true,_aeg);var _Ke=this.oUIMgr.appobj.appname;var _GB=Utilities.GenerateCallback(CUIWorkSheet.SafeGoTo,[_Ke,"true"]);this.aToolGroups[2].AddDropDownButtonCombo("icon_go_to_16.gif","icon_go_to_16.gif",'IDS_TOOLBAR_GOTO',_GB,CUIWorkSheet.SafeDoShowGoToMenu,true,_aeg);this.aToolGroups.push(new CUIToolGroup(this));var _7i=this.aToolGroups[3].AddDropDownButton("filter_16.gif","filter_16.gif",'IDS_TOOLBAR_FILTER',CUIWorkSheet.SafeDoShowUserDefFilterDropDown,true);this.aToolGroups[3].AddDropDownButton("icon_topBottom16.gif","icon_topBottom16.gif",'IDS_TOOLBAR_TOPBOTTOM',CUIWorkSheet.SafeDoShowTopBottomDropDown,true);var _WR=this.oUIMgr.dataManager;this._rP=this.aToolGroups[3].AddDropDownButton("icon_zero_16.gif","icon_zero_16.gif",'APP_MENUBAR_ZERO_SUPPRESSION',CUIWorkSheet.SafeDoShowSuppressDropDown,true);this.aToolGroups[3].AddDropDownButton("sort_16.gif","sort_16.gif",'IDS_TOOLBAR_SORT',CUIWorkSheet.SafeDoShowSortDropDown,true);this.aToolGroups.push(new CUIToolGroup(this));this.aToolGroups[4].AddButton("subtotals.gif","subtotals.gif",'IDS_TOOLBAR_AUTO_SUBTOTAL',CUIWorkSheet.SafeDoShowAutoSummaryDialog,true);var _aoP=this.aToolGroups[4].AddDropDownButton("tool_summary_total_16.gif","tool_summary_total_16.gif",'IDS_SET_BASED_CALCS',CUIWorkSheet.SafeDoShowSetBasedCalcDropDown,true);this.aToolGroups[4].AddDropDownButton("calculation16x16.gif","calculation16x16.gif",'IDS_TOOLBAR_CALCULATION',CUIWorkSheet.SafeDoShowCalcDropDown,true);this.aToolGroups.push(new CUIToolGroup(this));this.aToolGroups[5].AddDropDownButton("display_16.gif","display_16.gif",'IDS_TOOLBAR_CHART_CROSSTAB_VIEW',CUIWorkSheet.SafeShowChartDisplayDropDown,true);this.aToolGroups[5].AddDropDownButton("icon_chart.gif","icon_chart.gif",'IDS_TOOLBAR_CHART',CUIWorkSheet.SafeShowChartTypeDropDown,true);this.aToolGroups.push(new CUIToolGroup(this));this.aToolGroups[6].AddButton("swapRowColumn.gif","swapRowColumn.gif",'IDS_TOOLBAR_SWAP_ROW_COLUMN',CUIWorkSheet.SafeSwapRowColumn,true);this.aToolGroups[6].AddButton("Custom_set.gif","Custom_set.gif",'IDS_TOOLBAR_ADD_CUSTOMSET',CUIWorkSheet.SafeDoOpenCustomSetDlgWithInferringRule,true);};CUIToolBar.prototype.AddDummyButtons=function(){this.Clear();this.aToolGroups.push(new CUIToolGroup(this));this.aToolGroups[0].AddButton("tool_main_new_16.gif","tool_main_new_16.gif",'IDS_TOOLBAR_NEW',CUIToolBar.DoNothing,false);this.aToolGroups[0].AddButton("icon_file_open.gif","icon_file_open.gif",'IDS_TOOLBAR_OPEN',CUIToolBar.DoNothing,false);this.aToolGroups[0].AddButton("tool_main_save.gif","tool_main_save.gif",'IDS_TOOLBAR_SAVE',CUIToolBar.DoNothing,false);this.aToolGroups[0].AddButton("tool_main_saveas.gif","tool_main_saveas.gif",'IDS_TOOLBAR_SAVE_AS',CUIToolBar.DoNothing,false);this.aToolGroups.push(new CUIToolGroup(this));this.aToolGroups[1].AddButton("tool_main_delete.gif","tool_main_delete.gif",'IDS_TOOLBAR_DELETE',CUIToolBar.DoNothing,false);this.aToolGroups[1].AddButton("icon_undo16.gif","icon_undo16.gif",'IDS_TOOLBAR_UNDO',CUIToolBar.DoNothing,false,true);this.aToolGroups[1].AddButton("icon_redo16.gif","icon_redo16.gif",'IDS_TOOLBAR_REDO',CUIToolBar.DoNothing,false,true);this.aToolGroups[1].AddButton("icon_search.gif","icon_search.gif",'IDS_TOOLBAR_SEARCH',CUIToolBar.DoNothing,false);this.aToolGroups.push(new CUIToolGroup(this));var _aeg=true;this.aToolGroups[2].AddDropDownButton("RunReportHTML.gif","RunReportHTML.gif",'IDS_TOOLBAR_REPORTHTML',CUIToolBar.DoNothing,false,_aeg);this.aToolGroups[2].AddDropDownButtonCombo("icon_go_to_16.gif","icon_go_to_16.gif",'IDS_TOOLBAR_GOTO',CUIToolBar.DoNothing,CUIToolBar.DoNothing,true,_aeg);this.aToolGroups.push(new CUIToolGroup(this));this.aToolGroups[3].AddButton("filter_16.gif","filter_16.gif",'IDS_TOOLBAR_FILTER',CUIToolBar.DoNothing,false);this.aToolGroups[3].AddButton("icon_topBottom16.gif","icon_topBottom16.gif",'IDS_TOOLBAR_TOPBOTTOM',CUIToolBar.DoNothing,false);this._rP=this.aToolGroups[3].AddToggleButton("icon_zero_16_toggle.gif","icon_zero_16_toggle.gif",'IDS_TOOLBAR_NULL_SUPPRESSION_ROWS_OR_COLUMNS','IDS_TOOLBAR_NULL_SUPPRESSION_ROWS_OR_COLUMNS',CUIToolBar.DoNothing,false,false);this.aToolGroups[3].AddDropDownButton("sort_16.gif","sort_16.gif",'IDS_TOOLBAR_SORT',CUIToolBar.DoNothing,false);this.aToolGroups.push(new CUIToolGroup(this));this.aToolGroups[4].AddDropDownButton("subtotals.gif","subtotals.gif",'IDS_TOOLBAR_AUTO_SUBTOTAL',CUIToolBar.DoNothing,false);this.aToolGroups[4].AddDropDownButton("tool_summary_total_16.gif","tool_summary_total_16.gif",'IDS_SET_BASED_CALCS',CUIToolBar.DoNothing,false);this.aToolGroups[4].AddDropDownButton("calculation16x16.gif","calculation16x16.gif",'IDS_TOOLBAR_CALCULATION',CUIToolBar.DoNothing,false);this.aToolGroups.push(new CUIToolGroup(this));this.aToolGroups[5].AddDropDownButton("display_16.gif","display_16.gif",'IDS_TOOLBAR_CHART_CROSSTAB_VIEW',CUIToolBar.DoNothing,false);this.aToolGroups[5].AddDropDownButton("icon_chart.gif","icon_chart.gif",'IDS_TOOLBAR_CHART',CUIToolBar.DoNothing,false);this.aToolGroups.push(new CUIToolGroup(this));this.aToolGroups[6].AddButton("swapRowColumn.gif","swapRowColumn.gif",'IDS_TOOLBAR_SWAP_ROW_COLUMN',CUIToolBar.DoNothing,false);this.aToolGroups[6].AddButton("Custom_set.gif","Custom_set.gif",'IDS_TOOLBAR_ADD_CUSTOMSET',CUIToolBar.DoNothing,false);};CUIToolBar.DoNothing=function(){};CUIToolBar.SafeNotImplemented=function(){try{if(Debug&&Debug._sj){alert('Will be implemented soon');}}catch(e){_f.HandleException(e);}};CUIToolBar.prototype.Draw=function(){Dom.RemoveAllChildren(this._J);for(var i=0;i<this.aToolGroups.length;i++){if(i==0){this.aToolGroups[i].Draw(this._J,0);}else{var _6r=document.createElement('IMG');this._J.appendChild(_6r);_6r.className='toolbar_group_sep';_6r.src=Utilities.IMG_PATH+"sep.gif";this.aToolGroups[i].Draw(this._J,0);}}};CUIToolBar.prototype.SetTop=function(_TM){this._J.style.top=_TM+'px';this._uC=_TM;};CUIToolBar.prototype.SetLeft=function(_P6){this._J.style.left=_P6+"px";};CUIToolBar.prototype.SetWidth=function(_F4){var _9F=COTStyle.GetHorizontalExtrasWidth(this._J);COTStyle.SetWidth(this._J,_F4-_9F);};CUIToolBar.prototype.GetBottom=function(){Debug.Assert(this.aToolGroups[0]);Debug.Assert(this.aToolGroups[0].aButtons[0]);var _T6=COTStyle.GetDisplayOffsetHeight(this.aToolGroups[0].aButtons[0].elImg);return this._uC+_T6;};CUIToolBar.prototype.Notify=function(event){if(event==ExpEvent.kCUIManager_Unload){this.Unload();}else if(event==ExpEvent.kCUIDialogMgr_HideModalDialog){Utilities.ExecuteHoldingProcedure();this.oUIMgr.oDialogMgr.UnSubscribe(this,ExpEvent.kCUIDialogMgr_HideModalDialog);}else if(event==ExpEvent.kUserSelection_MemberChange||event==ExpEvent.kCUIWorksheet_NoAxisSel||event==ExpEvent.kCUIWorksheet_MultiAxisSel||event==ExpEvent.kCUIWorksheet_ChangedBlockSel){}};CUIToolBar.prototype.Unload=function(){this.Clear();Utilities.RemoveAllChildObjects(this);};function CUIToolGroup(_P3,_BM){this.oParentToolBar=_P3;this.aButtons=new Array();};CUIToolGroup.prototype.AddButton=function(_Pj,_IV,_Rz,_BC,_OC,_RX){this.aButtons.push(new CUIToolButton(this.oParentToolBar,_Pj,_IV,_Rz,_BC,_OC,_RX));return this.aButtons[this.aButtons.length-1];};CUIToolGroup.prototype.AddToggleButton=function(_Pj,_I1,_Te,_Vq,_BC,_Mj,_OC){this.aButtons.push(new CUIToggleToolButton(this.oParentToolBar,_Pj,_I1,_Te,_Vq,_BC,_Mj,_OC));return this.aButtons[this.aButtons.length-1];};CUIToolGroup.prototype.AddDropDownButton=function(_Pj,_I1,_Rz,_BC,_OC,_RX,_DU){this.aButtons.push(new CUIDropDownButton(this.oParentToolBar,_Pj,_I1,_Rz,_BC,_OC,_RX));return this.aButtons[this.aButtons.length-1];};CUIToolGroup.prototype.AddDropDownButtonCombo=function(_Pj,_I1,_Rz,_zl,_yO,_OC,_RX,_DU){var _aGL=new CUIDropDownButtonCombo(this.oParentToolBar,_Pj,_I1,_Rz,_zl,_yO,_OC,_RX);this.aButtons.push(_aGL);return _aGL;};CUIToolGroup.kiSpaceBtwButtons=3;CUIToolGroup.prototype.Draw=function(_MU,_P6){var _azP=null;for(var i=0;i<this.aButtons.length;i++){if(i==0){this.aButtons[i].Draw(_MU,_P6);}else{this.aButtons[i].Draw(_MU,CUIToolGroup.kiSpaceBtwButtons);}}};CUIToolGroup.prototype.Unload=function(){for(var i=0;i<this.aButtons.length;i++){if(this.aButtons[i].Unload){this.aButtons[i].Unload();}}Utilities.DeleteAllFromArray(this.aButtons);Utilities.RemoveAllChildObjects(this);};function CUIToolButton(_P3,_Pj,_IV,_Rz,_BC,_OC,_RX){this.oParentToolBar=_P3;this.sImageName=_Pj;this.sDisableImageName=_IV;this.sTooltip=_Rz;this.fCallback=_BC;this.bAffectsWorkSheet=_OC;this.sCSSClassName='toolbar_button';this.elImg=null;this.eState=CUIToolButton.eStateNormal;this.bSkipCHGCheck=_RX?true:false;this.bVisible=true;};CUIToolButton.eStateNormal=0;CUIToolButton.eStateHover=1;CUIToolButton.eStateDisabled=2;CUIToolButton.prototype.Draw=function(_MU,_P6){var _aej=_MU.appendChild(document.createElement('DIV'));_aej.style.marginLeft=_P6+"px";var _azP=_aej.appendChild(document.createElement('IMG'));_azP.src=Utilities.IMG_PATH+this.sImageName;var _BM=this.oParentToolBar.oUIMgr.appobj.oResources.GetString(this.sTooltip);_aej.title=_BM;_aej.onclick=CUIToolButton.SafeHandleClick;_aej.onmousedown=CUIToolButton.SafeHandleMouseDown;_aej.onmouseover=CUIToolButton.SafeHandleMouseOver;_aej.onmouseout=CUIToolButton.SafeHandleMouseOut;Dom.SetObjRef(_aej,this,'oToolButton');this.elImg=_aej;this.SetStyle();COTStyle.SetSize(_aej,this.oParentToolBar._rI,this.oParentToolBar._rI);if(!this.bVisible){this.elImg.style.display='none';}};CUIToolButton.prototype.Disable=function(){this.eState=CUIToolButton.eStateDisabled;this.SetStyle();COTInputElementFactory.DisableInput(this.elImg);};CUIToolButton.prototype.Enable=function(){this.eState=CUIToolButton.eStateNormal;this.SetStyle();COTInputElementFactory.EnableInput(this.elImg);};CUIToolButton.prototype.SetText=function(_zm){this.sTooltip=_zm;var _BM=this.oParentToolBar.oUIMgr.appobj.oResources.GetString(this.sTooltip);this.elImg.title=_BM;this.elImg.alt=_BM;};CUIToolButton.prototype.Unload=function(){if(this.elImg){this.elImg.oToolButton=null;this.elImg=null;}Utilities.RemoveAllChildObjects(this);};CUIToolButton.prototype.SetStyle=function(){switch(this.eState){case CUIToolButton.eStateNormal:this.elImg.src=Utilities.IMG_PATH+this.sImageName;this.elImg.className=this.sCSSClassName;break;case CUIToolButton.eStateHover:this.elImg.src=Utilities.IMG_PATH+this.sImageName;this.elImg.className=this.sCSSClassName+'_hover';break;case CUIToolButton.eStateDisabled:this.elImg.src=Utilities.IMG_PATH+this.sDisableImageName;this.elImg.className=this.sCSSClassName+'_disabled';break;case CUIToolButton.eStatePressed:this.elImg.src=Utilities.IMG_PATH+this.sImageName;this.elImg.className=this.sCSSClassName+'_pressed';break;default:Debug.Assert(false,'invalid state');break;}};CUIToolButton.prototype.SetVisibility=function(_DX){this.bVisible=_DX;};CUIToolButton.prototype.ShowButton=function(_DX){this.bVisible=true;this.elImg.style.display='inline';var _9v=document.getElementById(this._sD);if(_9v){_9v.style.display='inline';}};CUIToolButton.prototype.HideButton=function(_DX){this.bVisible=false;this.elImg.style.display='none';var _9v=document.getElementById(this._sD);if(_9v){_9v.style.display='none';}};CUIToolButton.SafeHandleMouseDown=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/this.oToolButton.eState=CUIToolButton.eStatePressed;this.oToolButton.SetStyle();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIToolButton.prototype.ContinueHandleClick=function(e){var _Ke=this.oParentToolBar.oUIMgr.appobj.appname;this.eState=CUIToolButton.eStateHover;this.SetStyle();if(this.fCallback){this.fCallback(_Ke);}};CUIToolButton.SafeDoContinueHandleClick=function(_UQ,e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}_UQ.ContinueHandleClick(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIToolButton.SafeHandleClick=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/this.oToolButton.HandleClick(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIToolButton.prototype.HandleClick=function(e){var _Qa=this.oParentToolBar.oUIMgr._jf;if(!_Qa||(this.bAffectsWorkSheet&&(!_Qa.AllowInteraction()))){return;}if(this.bSkipCHGCheck){this.ContinueHandleClick(e);}else{var _amW=this.oParentToolBar.oUIMgr.ConfirmLossOfChanges();if(_amW==Utilities.eStateContinue){this.ContinueHandleClick(e);}else if(_amW==Utilities.eStateHold){var _axQ=Dom.CloneMouseEvent(e);var _Ro=new Array(this,_axQ);Utilities.SetProcedureToHold(CUIToolButton.SafeDoContinueHandleClick,_Ro);this.oParentToolBar.oUIMgr.oDialogMgr.Subscribe(this.oParentToolBar,ExpEvent.kCUIDialogMgr_HideModalDialog);}}};CUIToolButton.SafeHandleMouseOver=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/this.oToolButton.eState=CUIToolButton.eStateHover;this.oToolButton.SetStyle();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIToolButton.SafeHandleMouseOut=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/this.oToolButton.eState=CUIToolButton.eStateNormal;this.oToolButton.SetStyle();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};function CUIToggleToolButton(_P3,_Pj,_I1,_Te,_Vq,_BC,_SP,_OC){this.base=CUIToolButton;var _Rz=_Te;if(!_SP){_Rz=_Vq;}this.base(_P3,_Pj,_I1,_Rz,_BC);this.sTooltipOn=_Te;this.sTooltipOff=_Vq;this.bToggleOn=_SP;this.eState=_SP?CUIToggleToolButton.eStateON:CUIToggleToolButton.eStateOFF;this.bAffectsWorkSheet=_OC?false:true;this.bChangeToggleStateOnCLK=false;};CUIToggleToolButton.prototype=new CUIToolButton;CUIToggleToolButton.superclass=CUIToolButton.prototype;CUIToggleToolButton.prototype.Draw=function(_Ij,_P6){var _1Q=_P6;var _avn=CUIToggleToolButton.superclass.Draw.call(this,_Ij,_P6);this.elImg.onmouseout=CUIToggleToolButton.SafeHandleMouseOut;this.elImg.onmouseover=CUIToggleToolButton.SafeHandleMouseOver;this.elImg.onclick=CUIToggleToolButton.SafeHandleClick;this.elImg.onmousedown=CUIToggleToolButton.SafeHandleMouseDown;};CUIToggleToolButton.prototype.ChangeToggleStateOnClick=function(_U5){this.bChangeToggleStateOnCLK=_U5;};CUIToggleToolButton.eStateON=0;CUIToggleToolButton.eStateOFF=1;CUIToggleToolButton.eStateONHover=2;CUIToggleToolButton.eStateOFFHover=3;CUIToggleToolButton.prototype.SetStyle=function(){switch(this.eState){case CUIToggleToolButton.eStateON:this.elImg.className=this.sCSSClassName+'_on';break;case CUIToggleToolButton.eStateOFF:this.elImg.className=this.sCSSClassName+'_off';break;case CUIToggleToolButton.eStateONHover:this.elImg.className=this.sCSSClassName+'_on_hover';break;case CUIToggleToolButton.eStateOFFHover:this.elImg.className=this.sCSSClassName+'_hover';break;default:Debug.Assert(false,'invalid state');break;}};CUIToggleToolButton.SafeHandleMouseOver=function(e){try{this.oToolButton.eState=this.oToolButton.bToggleOn?CUIToggleToolButton.eStateONHover:CUIToggleToolButton.eStateOFFHover;this.oToolButton.SetStyle();}catch(e){_f.HandleException(e);}};CUIToggleToolButton.SafeHandleMouseOut=function(e){try{this.oToolButton.eState=this.oToolButton.bToggleOn?CUIToggleToolButton.eStateON:CUIToggleToolButton.eStateOFF;this.oToolButton.SetStyle();}catch(e){_f.HandleException(e);}};CUIToggleToolButton.prototype.SetToggleState=function(_K6){this.bToggleOn=_K6;this.eState=_K6?CUIToggleToolButton.eStateON:CUIToggleToolButton.eStateOFF;var _Ic=this.oParentToolBar.oUIMgr.appobj.oResources.GetString(_K6?this.sTooltipOn:this.sTooltipOff);this.elImg.alt=_Ic;this.elImg.title=_Ic;this.SetStyle();};CUIToggleToolButton.SafeHandleMouseDown=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}Dom.CancelEvent(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIToggleToolButton.SafeHandleClick=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/this.oToolButton.HandleClick(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIToggleToolButton.prototype.HandleClick=function(e){var _Qa=this.oParentToolBar.oUIMgr._jf;if(!_Qa||(this.bAffectsWorkSheet&&(!_Qa.AllowInteraction()))){return;}if(!e)var e=window.event;var _Ke=this.oParentToolBar.oUIMgr.appobj.appname;if(this.bChangeToggleStateOnCLK){this.bToggleOn=this.bToggleOn?false:true;this.eState=this.bToggleOn?CUIToggleToolButton.eStateON:CUIToggleToolButton.eStateOFF;this.SetStyle();var _abY=this.oParentToolBar.oUIMgr.appobj.oResources.GetString(this.sTooltipOn);var _avD=this.oParentToolBar.oUIMgr.appobj.oResources.GetString(this.sTooltipOff);this.elImg.alt=this.bToggleOn?_abY:_avD;this.elImg.title=this.bToggleOn?_abY:_avD;}if(this.fCallback){this.fCallback(_Ke);}};function CUIDropDownButton(_P3,_Pj,_I1,_Rz,_Qo,_OC,_RX){this.base=CUIToolButton;var _BC=null;this.base(_P3,_Pj,_I1,_Rz,_BC,_OC,_RX);this._tA=_Qo;this.sCSSClassName='toolbar_dropdown_button';};CUIDropDownButton.prototype=new CUIToolButton;CUIDropDownButton.superclass=CUIToolButton.prototype;CUIDropDownButton.prototype.SetText=function(_zm){this.sTooltip=_zm;var _BM=this.oParentToolBar.oUIMgr.appobj.oResources.GetString(this.sTooltip);this.elImg.title=_BM;this.elImg.alt=_BM;var _Mz=document.getElementById(this._sD);_Mz.title=_BM;};CUIDropDownButton.prototype.Draw=function(_Ij,_P6){CUIDropDownButton.superclass.Draw.call(this,_Ij,_P6);this.fCallback=this.HandleMouseDown;var _7I=document.createElement('A');_7I.className='toolbar_arrow';_7I.title=this.oParentToolBar.oUIMgr.appobj.oResources.GetString(this.sTooltip);_7I.onmouseover=CUIToolButton.SafeHandleMouseOver;_7I.onmouseout=CUIToolButton.SafeHandleMouseOut;_7I.onclick=CUIToolButton.SafeHandleClick;_7I.onmousedown=CUIToolButton.SafeHandleMouseDown;Dom.SetObjRef(_7I,this,'oToolButton');this._sD=Utilities.GenerateId();_7I.id=this._sD;var _ajN=document.createElement('IMG');_7I.appendChild(_ajN);_ajN.src=Utilities.IMG_PATH+"toolbar_drop_arrow.gif";COTStyle.SetHeight(_ajN,this.oParentToolBar._rI);COTStyle.SetWidth(_ajN,7);COTStyle.SetHeight(_7I,this.oParentToolBar._rI+3);COTStyle.SetWidth(_7I,7);_Ij.appendChild(_7I);this.SetStyle();if(!this.bVisible){_7I.style.display='none';}};CUIDropDownButton.prototype.SetStyle=function(){var _7I=document.getElementById(this._sD);if(!_7I){return;}switch(this.eState){case CUIToolButton.eStateNormal:this.elImg.className=this.sCSSClassName;_7I.className='toolbar_arrow';break;case CUIToolButton.eStateHover:this.elImg.className=this.sCSSClassName+'_hover';_7I.className='toolbar_arrow_hover';break;case CUIToolButton.eStateDisabled:this.elImg.className=this.sCSSClassName+'_disabled';_7I.className='toolbar_arrow_disabled';break;case CUIToolButton.eStatePressed:this.elImg.className=this.sCSSClassName+'_pressed';_7I.className='toolbar_arrow_pressed';break;default:Debug.Assert(false,'invalid state');break;}};CUIDropDownButton.prototype.Unload=function(){var _9v=document.getElementById(this._sD);if(_9v){_9v.oToolButton=null;}CUIDropDownButton.superclass.Unload.call(this);};CUIDropDownButton.prototype.HandleMouseDown=function(e){var _Qb=Dom.GetRelativeOffset(this.elImg,document.body);var x=_Qb.iLeft;var y=_Qb.iTop+COTStyle.GetDisplayOffsetHeight(this.elImg);this._tA(e,this.oParentToolBar.oUIMgr.appobj.appname,x,y);Dom.SetFocus(document.getElementById(this._sD));};function CUIDropDownButtonCombo(_P3,_Pj,_I1,_Rz,_zl,_yO,_OC,_RX){this.base=CUIToolButton;this.base(_P3,_Pj,_I1,_Rz,_zl,_OC,_RX);this._tA=_yO;this.sCSSClassName='toolbar_button';};CUIDropDownButtonCombo.prototype=new CUIToolButton;CUIDropDownButtonCombo.superclass=CUIToolButton.prototype;CUIDropDownButtonCombo.prototype.Draw=function(_Ij,_P6){CUIDropDownButtonCombo.superclass.Draw.call(this,_Ij,_P6);var _7I=document.createElement('A');_7I.className='toolbar_arrow_combo';_7I.onmouseover=Utilities.EventCallback(this.HandleArrowMouseOver,[],this);_7I.onmouseout=Utilities.EventCallback(this.HandleArrowMouseOut,[],this);_7I.onclick=Utilities.EventCallback(this.HandleArrowClick,[],this);_7I.onmousedown=Utilities.EventCallback(this.HandleArrowMouseDown,[],this);this._sD=Utilities.GenerateId();_7I.id=this._sD;var _ajN=document.createElement('IMG');_7I.appendChild(_ajN);_ajN.src=Utilities.IMG_PATH+"toolbar_drop_arrow.gif";COTStyle.SetHeight(_ajN,this.oParentToolBar._rI);COTStyle.SetWidth(_ajN,7);COTStyle.SetHeight(_7I,this.oParentToolBar._rI+3);COTStyle.SetWidth(_7I,7);_Ij.appendChild(_7I);this.SetStyle(_7I);};CUIDropDownButtonCombo.prototype.SetStyle=function(el){var _7I=el?el:document.getElementById(this._sD);if(!_7I){return;}switch(this.eState){case CUIToolButton.eStateNormal:this.elImg.className=this.sCSSClassName;_7I.className='toolbar_arrow_combo';break;case CUIToolButton.eStateHover:this.elImg.className=this.sCSSClassName+'_hover';_7I.className='toolbar_arrow_combo_hover';break;case CUIToolButton.eStateDisabled:this.elImg.className=this.sCSSClassName+'_disabled';break;case CUIToolButton.eStatePressed:this.elImg.className=this.sCSSClassName+'_pressed';break;default:Debug.Assert(false,'invalid state');break;}};CUIDropDownButtonCombo.prototype.HandleArrowMouseOver=function(e,el){this.eState=CUIToolButton.eStateHover;this.SetStyle(el);};CUIDropDownButtonCombo.prototype.HandleArrowMouseOut=function(e,el){this.eState=CUIToolButton.eStateNormal;this.SetStyle(el);};CUIDropDownButtonCombo.prototype.HandleArrowClick=function(e,el){var _Qb=Dom.GetRelativeOffset(this.elImg,document.body);var x=_Qb.iLeft;var y=_Qb.iTop+COTStyle.GetDisplayOffsetHeight(this.elImg);this._tA(e,this.oParentToolBar.oUIMgr.appobj.appname,x,y);Dom.SetFocus(el);};CUIDropDownButtonCombo.prototype.HandleArrowMouseDown=function(e,el){el.className='toolbar_arrow_combo_pressed';};function CUIMenuBar(_Hk,_E3){this.oUIMgr=_Hk;this._J=document.createElement('DIV');document.body.appendChild(this._J);if(!_E3)_E3='menubar';this._J.className=_E3;this._fB=document.createElement('DIV');this._J.appendChild(this._fB);this._fB.className='menubar_content_div';this.aMenus=new Array();this.oVisibleMenu=null;this._tQ=false;this._gB=false;this.oUIMgr.Subscribe(this,ExpEvent.kCUIManager_Unload);};CUIMenuBar.prototype.Init=function(){this.oUIMgr._jf.Subscribe(this,ExpEvent.kCUIWorksheet_Busy);this.oUIMgr._jf.Subscribe(this,ExpEvent.kCUIWorksheet_Free);};CUIMenuBar.prototype.SetWidth=function(_F4){var _9F=COTStyle.GetHorizontalExtrasWidth(this._J);COTStyle.SetWidth(this._J,_F4-_9F);};CUIMenuBar.prototype.SetLeft=function(_P6){this._J.style.left=_P6+"px";};CUIMenuBar.prototype.SetTop=function(_TM){this._uC=_TM;this._J.style.top=_TM+"px";};CUIMenuBar.prototype.ClearMenus=function(){this.Unload();this.aMenus=new Array();};CUIMenuBar.prototype.DrawMissingDataMenuBar=function(){this.ClearMenus();var _Ke=this.oUIMgr.appobj.appname;var _Co=this.oUIMgr.appobj.oResources;var _AG=new Array(_Ke);var _aC4=new CUIContextMenu(_Ke,0,this);var _2G=_Co.GetString('APP_MENUBAR_NEW');var _PM=new ContextItem("tool_main_new_16.gif",_2G,CUIWorkSheet.SafeDoNew,false,_AG,_aC4);_PM.id='APP_MENUBAR_NEW';_2G=_Co.GetString('APP_MENUBAR_OPEN');_PM=new ContextItem('icon_file_open.gif',_2G,CUIWorkSheet.SafeDoLoad,false,_AG,_aC4);_PM.id='APP_MENUBAR_OPEN';_aIC=new ContextSeparator(_aC4);_2G=_Co.GetString('APP_MAIN_MENU_EXIT');_PM=new ContextItem('',_2G,CUIWorkSheet.SafeDoExit,false,_AG,_aC4);_PM.id='APP_MAIN_MENU_EXIT';var _aA7=this.AddMenu('APP_MENUBAR_FILE',CUIMenu.DefaultCallback,_aC4);var _agI=new CUIContextMenu(_Ke,0,this);_2G=_Co.GetString('APP_MENUBAR_SEARCH');_PM=new ContextItem("icon_search.gif",_2G,CUIManager.SafeDoSearch,false,_AG,_agI);_PM.id='APP_MENUBAR_SEARCH';var _6n=this.AddMenu('APP_MENUBAR_EDIT',null,_agI);var _adU=new CUIContextMenu(_Ke,0,this);_2G=_Co.GetString('APP_HELP_MENU_HELP');var _aEK=new Array(_Ke,HelpConstants.kMainEntry);_PM=new ContextItem('',_2G,CUIManager.SafeDoHelpTopic,false,_aEK,_adU);_PM.SetSkipUncomitChangesChecking();_2G=_Co.GetString('APP_HELP_MENU_CONTENTS');var _aEK=new Array(_Ke,HelpConstants.kContents);_PM=new ContextItem('',_2G,CUIMenuBar.SafeDoGeneralGuide,false,_aEK,_adU);_PM.SetSkipUncomitChangesChecking();_2G=_Co.GetString('APP_HELP_MENU_COGNOS_WEB');_PM=new ContextItem('',_2G,CUIAboutDlg.SafeOpenWWWCognosWindow,false,_AG,_adU);_PM.SetSkipUncomitChangesChecking();_aIC=new ContextSeparator(_adU);_2G=_Co.ReplaceParam('APP_MENUBAR_ABOUT',1,ExpMiscStr.kProductName);_PM=new ContextItem('',_2G,CUIAboutDlg.SafeDoDisplay,false,_AG,_adU);this.AddMenu('APP_MENUBAR_HELP',null,_adU);this.Draw();};CUIMenuBar.prototype.DrawDefaultMenuBar=function(){this.ClearMenus();var _Ke=this.oUIMgr.appobj.appname;var _Co=this.oUIMgr.appobj.oResources;var _AG=new Array(_Ke);var _aC4=new CUIContextMenu(_Ke,0,this);var _2G=_Co.GetString('APP_MENUBAR_NEW');var _PM=new ContextItem("tool_main_new_16.gif",_2G,CUIWorkSheet.SafeDoNew,false,_AG,_aC4);_PM.id='APP_MENUBAR_NEW';_2G=_Co.GetString('APP_MENUBAR_OPEN');_PM=new ContextItem('icon_file_open.gif',_2G,CUIWorkSheet.SafeDoLoad,false,_AG,_aC4);_PM.id='APP_MENUBAR_OPEN';var _aIC=new ContextSeparator(_aC4);_2G=_Co.GetString('APP_MENUBAR_SAVE');_PM=new ContextItem('tool_main_save.gif',_2G,CUIWorkSheet.SafeDoSave,false,_AG,_aC4);_PM.id='APP_MENUBAR_SAVE';_2G=_Co.GetString('APP_MENUBAR_SAVE_AS');_PM=new ContextItem('tool_main_saveas.gif',_2G,CUIWorkSheet.SafeDoSaveAs,false,_AG,_aC4);_PM.id='APP_MENUBAR_SAVE_AS';_aIC=new ContextSeparator(_aC4);_2G=_Co.GetString('APP_MAIN_MENU_EXIT');_PM=new ContextItem('',_2G,CUIWorkSheet.SafeDoExit,false,_AG,_aC4);_PM.id='APP_MAIN_MENU_EXIT';var _aA7=this.AddMenu('APP_MENUBAR_FILE',CUIMenu.DefaultCallback,_aC4);var _agI=new CUIContextMenu(_Ke,0,this);_2G=_Co.GetString('APP_MENUBAR_UNDO');_PM=new ContextItem('icon_undo16.gif',_2G,CUIWorkSheet.SafeDoUndo,false,_AG,_agI);_PM.id='APP_MENUBAR_UNDO';_PM.SetSkipUncomitChangesChecking();_2G=_Co.GetString('APP_MENUBAR_REDO');_PM=new ContextItem('icon_redo16.gif',_2G,CUIWorkSheet.SafeDoRedo,false,_AG,_agI);_PM.id='APP_MENUBAR_REDO';_PM.SetSkipUncomitChangesChecking();_aIC=new ContextSeparator(_agI);_2G=_Co.GetString('APP_MENUBAR_DELETE');_PM=new ContextItem("tool_main_delete.gif",_2G,CUIManager.SafeDoDeleteSelections,false,_AG,_agI);_PM.id='APP_MENUBAR_DELETE';_2G=_Co.GetString('APP_MENUBAR_HIDE');_PM=new ContextItem("",_2G,CUICrosstab.SafeDoHide,false,_AG,_agI);_PM.id='APP_MENUBAR_HIDE';_2G=_Co.GetString('APP_MENUBAR_EXCLUDE');_PM=new ContextItem("excluded_items.gif",_2G,CUICrosstab.SafeDoExclude,false,_AG,_agI);_PM.id='APP_MENUBAR_EXCLUDE';_aIC=new ContextSeparator(_agI);_2G=_Co.GetString('APP_MENUBAR_SEARCH');_PM=new ContextItem("icon_search.gif",_2G,CUIManager.SafeDoSearch,false,_AG,_agI);_PM.id='APP_MENUBAR_SEARCH';var _6n=this.AddMenu('APP_MENUBAR_EDIT',null,_agI);var _aoD=new CUIContextMenu(_Ke,0,this);_2G=_Co.GetString('APP_VIEW_MENU_CROSSTAB');_PM=new ContextItem('',_2G,CUIWorkSheet.SafeHideChart,true,_AG,_aoD);_PM.id='APP_VIEW_MENU_CROSSTAB';_2G=_Co.GetString('APP_VIEW_MENU_CHART');_PM=new ContextItem('',_2G,CUIWorkSheet.SafeShowChartOnly,true,_AG,_aoD);_PM.id='APP_VIEW_MENU_CHART';_2G=_Co.GetString('APP_VIEW_MENU_CROSSTAB_AND_CHART');_PM=new ContextItem('',_2G,CUIWorkSheet.SafeShowCrosstabAndChart,true,_AG,_aoD);_PM.id='APP_VIEW_MENU_CROSSTAB_AND_CHART';_aIC=new ContextSeparator(_aoD);_2G=_Co.GetString('APP_VIEW_MENU_CHART_TYPE');_PM=new ContextItem('icon_chart.gif',_2G,null,false,_AG,_aoD);_PM.id='APP_VIEW_MENU_CHART_TYPE';var _56=_PM.CreateSubMenu(_Ke,1,this,false);_2G=_Co.GetString('APP_MENUBAR_SWAP_ROW_COLUMN');_PM=new ContextItem('swapRowColumn.gif',_2G,CUIWorkSheet.SafeSwapRowColumn,true,_AG,_aoD);_PM.id='APP_MENUBAR_SWAP_ROW_COLUMN';_aIC=new ContextSeparator(_aoD);_2G=_Co.GetString('APP_VIEW_MENU_OBJECTS_AND_INFO');_PM=new ContextItem('',_2G,CUILeftPaneMenu.SafeDoMenuToggle,true,_AG,_aoD);_PM.id='APP_VIEW_MENU_OBJECTS_AND_INFO';_2G=_Co.GetString('APP_VIEW_MENU_PROPERTIES_AREA');_PM=new ContextItem('',_2G,CUICrosstab.SafeDoToggleBlockPropPane,false,_AG,_aoD);_PM.id='APP_VIEW_MENU_PROPERTIES_AREA';var _7d=this.AddMenu('APP_MENUBAR_VIEW',null,_aoD);var _ahB=new CUIContextMenu(_Ke,0,this);_2G=_Co.GetString('APP_MENUBAR_ZERO_SUPPRESSION');_PM=new ContextItem('icon_zero_16.gif',_2G,null,true,_AG,_ahB);_PM.id='APP_MENUBAR_ZERO_SUPPRESSION';var _56=_PM.CreateSubMenu(_Ke,1,this);CUIContextBar.AttachAxisSuppressOptions(_Ke,_56);CUIContextBar.AttachZeroSuppressOptions(_Ke,_56);_2G=_Co.GetString('APP_ACTIONS_MENU_SET_DEF_BLOCK_SIZE');_PM=new ContextItem('',_2G,CUIWorkSheet.SafeDoShowDefBlockSizeDlg,true,_AG,_ahB);_PM.id='APP_ACTIONS_MENU_SET_DEF_BLOCK_SIZE';_2G=_Co.GetString('APP_ACTIONS_MENU_SET_GLOBAL_TOTALS');_PM=new ContextItem('',_2G,CUIWorkSheet.SafeOpenGlobalTotalSettingDlg,true,_AG,_ahB);_PM.id='APP_ACTIONS_MENU_SET_GLOBAL_TOTALS';_2G=_Co.GetString('APP_ACTIONS_MENU_INSERT_OPTIONS');_PM=new ContextItem('',_2G,null,true,_AG,_ahB);_PM.id='APP_ACTIONS_MENU_INSERT_OPTIONS';var _UG=true;var _56=_PM.CreateSubMenu(_Ke,1,null,_UG);var _aGN=new Array(_Ke,true);_2G=_Co.GetString('APP_ACTIONS_MENU_INSERT_WITH_DETAILS');_PM=new ContextItem('',_2G,CUIWorkSheet.SetIncludeDetailFlag,false,_aGN,_56);_PM.id='APP_ACTIONS_MENU_INSERT_WITH_DETAILS';_PM.SetSkipUncomitChangesChecking();var _aGN=new Array(_Ke,false);_2G=_Co.GetString('APP_ACTIONS_MENU_INSERT_WO_DETAILS');_PM=new ContextItem('',_2G,CUIWorkSheet.SetIncludeDetailFlag,false,_aGN,_56);_PM.id='APP_ACTIONS_MENU_INSERT_WO_DETAILS';_PM.SetSkipUncomitChangesChecking();var _aey=this.AddMenu('APP_MENUBAR_ACTIONS',null,_ahB);_aIC=new ContextSeparator(_ahB);_2G=_Co.GetString('APP_ACTIONS_MENU_SHOW_WELCOME_DLG');_PM=new ContextItem('',_2G,CUIMenuBar.SafeSetWelcomeDlgSetting,false,_AG,_ahB);_PM.id='APP_ACTIONS_MENU_SHOW_WELCOME_DLG';_PM.SetChecked(this.oUIMgr.appobj.IsWelcomeDialogEnabled());var _DH=new CUIContextMenu(_Ke,0,this);CUIWorkSheet.AttachRunOptions(_DH,_Ke);_aIC=new ContextSeparator(_DH);_2G=_Co.GetString('APP_RUN_MENU_OPTIONS');_PM=new ContextItem('',_2G,CUIWorkSheet.SafeDoShowReportOptionsDlg,false,_AG,_DH);_PM.id='APP_RUN_MENU_OPTIONS';_PM.SetSkipUncomitChangesChecking();_aIC=new ContextSeparator(_DH);var _WN=this.AddMenu('APP_MENUBAR_RUN',null,_DH);var _adU=new CUIContextMenu(_Ke,0,this);_2G=_Co.GetString('APP_HELP_MENU_HELP');var _aEK=new Array(_Ke,HelpConstants.kMainEntry);_PM=new ContextItem('',_2G,CUIManager.SafeDoHelpTopic,false,_aEK,_adU);_PM.SetSkipUncomitChangesChecking();_2G=_Co.GetString('APP_HELP_MENU_CONTENTS');var _aEK=new Array(_Ke,HelpConstants.kContents);_PM=new ContextItem('',_2G,CUIMenuBar.SafeDoGeneralGuide,false,_aEK,_adU);_PM.SetSkipUncomitChangesChecking();_2G=_Co.GetString('APP_HELP_MENU_COGNOS_WEB');_PM=new ContextItem('',_2G,CUIAboutDlg.SafeOpenWWWCognosWindow,false,_AG,_adU);_PM.SetSkipUncomitChangesChecking();_aIC=new ContextSeparator(_adU);_2G=_Co.ReplaceParam('APP_MENUBAR_ABOUT',1,ExpMiscStr.kProductName);_PM=new ContextItem('',_2G,CUIAboutDlg.SafeDoDisplay,false,_AG,_adU);/*@if(@bering_test)@*/if(Debug.IsEnabled()){_aIC=new ContextSeparator(_adU);_2G="Start Recording Regression Test";_PM=new ContextItem('',_2G,RegressionTest.StartRecording,false,_AG,_adU);_PM.SetSkipUncomitChangesChecking();_2G="Stop Recording Regression Test";_PM=new ContextItem('',_2G,RegressionTest.StopRecording,false,_AG,_adU);_PM.SetSkipUncomitChangesChecking();_aIC=new ContextSeparator(_adU);}/*@end@*//*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){_2G="Get last crosstab rendering time";_PM=new ContextItem('',_2G,PerfMonitor.GetResults,false,_AG,_adU);_PM.SetSkipUncomitChangesChecking();var _ahZ=this.oUIMgr.dataManager.metadata.IsFunctionSupported(ExpAPIXml.kQosHierarchySrch)?"":"immediate descendants ";_2G="Get "+_ahZ+"search time";_PM=new ContextItem('',_2G,PerfMonitor.GetSearchPerfResults,false,_AG,_adU);_PM.SetSkipUncomitChangesChecking();}/*@end@*//*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d&&Utilities.bEnableInnerHTMLRendering){_aIC=new ContextSeparator(_adU);_2G="Refresh Normal Crosstab";_PM=new ContextItem('',_2G,CUICrosstab.TestRefreshNormalCrosstab,false,_AG,_adU);_PM.SetSkipUncomitChangesChecking();_2G="Refresh Inner HTML Crosstab";_PM=new ContextItem('',_2G,CUICrosstab.TestRefreshInnerHTMLCrosstab,false,_AG,_adU);_PM.SetSkipUncomitChangesChecking();_2G="Print Crosstab DOM";_PM=new ContextItem('',_2G,CUICrosstab.TestPrintCrosstabDom,false,_AG,_adU);_PM.SetSkipUncomitChangesChecking();}/*@end@*/this.AddMenu('APP_MENUBAR_HELP',null,_adU);if(this._gB){this.ShowDebugMenu();}this.Draw();};CUIMenuBar.SafeSetWelcomeDlgSetting=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);Debug.Assert(_Mg);_Mg.ToggleWelcomeDlgSetting();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIMenuBar.prototype.DrawDummyMenuBar=function(){this.ClearMenus();var _Ke=this.oUIMgr.appobj.appname;var _Co=this.oUIMgr.appobj.oResources;var _AG=new Array(_Ke);var _aC4=new CUIContextMenu(_Ke,0,this);this.AddMenu('APP_MENUBAR_FILE',null,_aC4);var _agI=new CUIContextMenu(_Ke,0,this);this.AddMenu('APP_MENUBAR_EDIT',null,_agI);var _aoD=new CUIContextMenu(_Ke,0,this);this.AddMenu('APP_MENUBAR_VIEW',null,_aoD);var _ahB=new CUIContextMenu(_Ke,0,this);this.AddMenu('APP_MENUBAR_ACTIONS',null,_ahB);var _DH=new CUIContextMenu(_Ke,0,this);this.AddMenu('APP_MENUBAR_RUN',null,_DH);var _adU=new CUIContextMenu(_Ke,0,this);this.AddMenu('APP_MENUBAR_HELP',null,_adU);this.Draw();};CUIMenuBar.SafeDoGeneralGuide=function(_Ke,_EQ){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);Debug.Assert(_Mg);if(_Mg){gotoHelp(_Mg._aB,_EQ,'');}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIMenuBar.prototype.GetBottom=function(){return COTStyle.GetDisplayOffsetHeight(this._J)+this._uC;};CUIMenuBar.prototype.AddMenu=function(_Hv,_BC,_zf){var _MJ=_Hv;_Hv=this.oUIMgr.appobj.oResources.GetString(_Hv);var _anJ=new CUIMenu(this,_MJ,_Hv,_BC,_zf);this.aMenus.push(_anJ);return _anJ;};CUIMenuBar.prototype.Draw=function(){var _O3=null;for(var i=0;i<this.aMenus.length;i++){_O3=document.createElement('A');var _aob=document.createTextNode(this.aMenus[i].sMenuName);_O3.appendChild(_aob);this._fB.appendChild(_O3);_O3.onmousedown=this.aMenus[i].fCallback;_O3.onmouseover=CUIMenuBar.SafeHandleMouseOver;_O3.onmouseout=CUIMenuBar.SafeHandleMouseOut;_O3.oMenu=this.aMenus[i];this.aMenus[i].elLink=_O3;this.aMenus[i].SetStyle();}};CUIMenuBar.prototype.SetVisibleMenu=function(_Ga){this.oVisibleMenu=_Ga;};CUIMenuBar.prototype.OnContextMenuHide=function(_zf){if(this.oVisibleMenu&&this.oVisibleMenu.oContextMenu==_zf){this.oVisibleMenu.bVisible=false;this.oVisibleMenu.bPressed=false;this.oVisibleMenu.SetStyle();this.SetVisibleMenu(null);}};CUIMenuBar.SafeHandleMouseOver=function(e){try{if(!e)var e=window.event;this.oMenu.oParentBar.HandleMouseOver(e,this);}catch(e){_f.HandleException(e);}};CUIMenuBar.prototype.HandleMouseOver=function(e,_Pq){_Pq.oMenu.bHovered=true;_Pq.oMenu.SetStyle();if(this.oVisibleMenu&&(this.oVisibleMenu!=_Pq.oMenu)){this.oVisibleMenu.OnHide();_Pq.oMenu.OnShow(e);}};CUIMenuBar.SafeHandleMouseOut=function(e){try{if(!e)var e=window.event;this.oMenu.bHovered=false;this.oMenu.SetStyle();}catch(e){_f.HandleException(e);}};CUIMenuBar.prototype.Notify=function(_Dy){if(_Dy==ExpEvent.kCUIManager_Unload){this.Unload();}else if(_Dy==ExpEvent.kCUIWorksheet_Busy||_Dy==ExpEvent.kCUIWorksheet_Free){this.UpdateContextMenus();}};CUIMenuBar.prototype.UpdateContextMenus=function(){if(this.oVisibleMenu&&this.oVisibleMenu.oContextMenu){this.oVisibleMenu.OnShow();}};CUIMenuBar.prototype.Unload=function(){for(var i=0;i<this.aMenus.length;i++){this.aMenus[i].elLink.oMenu=null;this.aMenus[i].elLink=null;}Dom.RemoveAllChildren(this._fB);};CUIMenuBar.prototype.ToggleDebugMenu=function(){if(this._tQ){this._gB=false;this.HideDebugMenu();}else{this._gB=true;this.DrawDefaultMenuBar();}};CUIMenuBar.prototype.ShowDebugMenu=function(){this._tQ=true;var _Ke=this.oUIMgr.appobj.appname;var _Co=this.oUIMgr.appobj.oResources;var _AG=new Array(_Ke);var _ajM=new CUIContextMenu(_Ke,0,this);if(this.oUIMgr.appobj._bf._m0){var _2G="Copy Analysis Specification to Clipboard";var _PM=new ContextItem("",_2G,CopyPasteHLS.GetHLSFromServer,false,_AG,_ajM);_2G="Open Analysis Specification from Clipboard";_PM=new ContextItem("",_2G,CopyPasteHLS.PasteHLSFromClipboard,false,_AG,_ajM);var _aIC=new ContextSeparator(_ajM);_2G="Copy V5 Specification to Clipboard";_PM=new ContextItem("",_2G,CopyPasteHLS.GetV5SpecFromServer,false,_AG,_ajM);_aIC=new ContextSeparator(_ajM);_2G="Copy Undo Stack to Clipboard";_PM=new ContextItem("",_2G,CopyPasteHLS.CopyUndoStackToClipboard,false,_AG,_ajM);}_aIC=new ContextSeparator(_ajM);_2G="Copy last entire soap request to Clipboard ";_PM=new ContextItem("",_2G,CBIBus.GetLastSoapRequest,false,[],_ajM);_2G="Copy last entire soap response to Clipboard";_PM=new ContextItem("",_2G,CBIBus.GetLastSoapResponse,false,[],_ajM);if(this.oUIMgr.appobj._wJ._mE){var _2G="Render Next Response (Ctrl+Shift+N)";var _PM=new ContextItem("",_2G,PlaybackRegressionTestResponses.PlaybackNextResponse,false,_AG,_ajM);_2G="Enter Regular Client/Server Mode";_PM=new ContextItem("",_2G,PlaybackRegressionTestResponses.EnterInteractiveMode,false,_AG,_ajM);}_aIC=new ContextSeparator(_ajM);var _2G="Enable User Perceived Time Trace";var _PM=new ContextItem("",_2G,PerfMonitor.EnablePerceivedUserTime,false,_AG,_ajM);var _2G="Disable User Perceived Time Trace";var _PM=new ContextItem("",_2G,PerfMonitor.DisablePerceivedUserTime,false,_AG,_ajM);var _aaM=this.AddMenu('Debug',CUIMenu.DefaultCallback,_ajM);};CUIMenuBar.prototype.HideDebugMenu=function(){this._tQ=false;this.DrawDefaultMenuBar();};function CUIMenu(_Rw,_Lx,_Hv,_BC,_zf){this.oParentBar=_Rw;this.id=_Lx;this.sMenuName=_Hv;this.fCallback=CUIMenu.SafeOnShow;this.oContextMenu=_zf;this.sClassName='menu';this.bHovered=false;this.bVisible=false;};CUIMenu.prototype.SetStyle=function(){if(this.elLink){if(this.bPressed){this.elLink.className=this.sClassName+'_pressed';}else if(this.bHovered){this.elLink.className=this.sClassName+'_hover';}else{this.elLink.className=this.sClassName;}}};CUIMenu.SafeOnShow=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(this.oMenu.oContextMenu&&!this.oMenu.bVisible){if(!e)var e=window.event;this.oMenu.OnShow(e);}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIMenu.prototype.OnShow=function(e){if(this.oContextMenu){if(this.elLink){Dom.SetFocus(this.elLink);this.bPressed=true;this.SetStyle();var _Qb=Dom.GetRelativeOffset(this.elLink,document.body);var x=_Qb.iLeft;var y=_Qb.iTop+COTStyle.GetDisplayOffsetHeight(this.elLink);}var _Ss=((!this.oParentBar.oUIMgr._jf)||(!this.oParentBar.oUIMgr._jf.AllowInteraction()));this.oContextMenu.SetAllItemsState(_Ss);if(!_Ss&&this.oParentBar.oUIMgr._jf){this.oParentBar.oUIMgr._jf.DoSetMenuState(this.id,this.oContextMenu);}if(!e){var e=this._bq;}else{this._bq=Dom.CloneMouseEvent(e);}this.oContextMenu.display(e,false,x,y);this.oParentBar.SetVisibleMenu(this);this.bVisible=true;}};CUIMenu.prototype.OnHide=function(){this.oContextMenu.hideMenuAndChildren();this.oParentBar.SetVisibleMenu(null);this.bVisible=false;this.bPressed=false;this.SetStyle();};CUIDialog.eNormalState=1;CUIDialog.eModalState=2;function CUIDialog(){this._gM=document.createElement('TD');this._gM.className="dialogText";this._l4=document.createElement('TD');this._l4.className="dialogText_bold";this._g5=document.createElement('TD');this._g5.className="infoLabel";this._K=document.createElement('TD');this._K.className="dialogInnerFuncLink";this._p2=null;this._r3=false;this._t9=true;this._hB=true;this._iG='IDS_BUTTON_OK';this._gp='IDS_BUTTON_CANCEL';this._om=-1;this._qu=CUIDialog.eNormalState;this._ym=null;};CUIDialog.prototype.Init=function(_yt,_Sb,_EO){Debug.Assert(_yt);this.oDialogMgr=_yt;if(!_Sb){this.oDialogMgr.oUIMgr.Subscribe(this,ExpEvent.kCUIManager_Unload);}this.sAppName=this.oDialogMgr.oUIMgr.appobj.appname;this.oRes=this.oDialogMgr.oUIMgr.appobj.oResources;if(!_EO){this.SetInvalidSelSupport();}};CUIDialog.prototype.SetResource=function(_Co){this.oRes=_Co;};CUIDialog.prototype.SetModalState=function(){this._qu=CUIDialog.eModalState;};CUIDialog.prototype.GetDiv=function(){return this._p2;};CUIDialog.prototype.Notify=function(_Dy){if(_Dy==ExpEvent.kCUIManager_Unload){this.Unload();}};CUIDialog.prototype.ClearMainDiv=function(){if(this._p2){Dom.RemoveObject(this._p2);}this._p2=null;};CUIDialog.prototype.Unload=function(){if(this._p2){Dom.RemoveObject(this._p2);}Utilities.RemoveAllChildObjects(this);};CUIDialog.prototype.DrawTitleBar=function(_AX,_MY){this._kC=new CUIDialogTitleBar(_AX,this.sAppName);var _aJd=this._gl?this._gl:null;var _aFU='IDS_HELP';var _Kz=this.oRes.GetString(_aFU);var _J0=this.oRes.GetString('IDS_CLOSE');if(_MY!=null&&_MY[_aFU]){var _afx=this._kC.Init(_J0,_Kz,_MY[_aFU],_aJd);}else{var _afx=this._kC.Init(_J0,null,null,_aJd);}this._dw=Utilities.GenerateId();_afx.id=this._dw;return _afx;};CUIDialog.prototype.GetLinkByName=function(_Dj){var _MY=this._p2.getElementsByTagName('A');for(var i=0;i<_MY.length;i++){if(_MY[i].innerHTML==this.oRes.GetString(_Dj)){return _MY[i];}}return null;};CUIDialog.prototype.SetAlternativeLabelForOKButton=function(_yM){this._iG=_yM;};CUIDialog.prototype.DrawMainButtons=function(){var _F0=document.createElement('TBODY');var _aE1=document.createElement('table');_aE1.className='dialogbuttons';_aE1.appendChild(_F0);this._p2.appendChild(_aE1);this._ke=Utilities.GenerateId();_aE1.id=this._ke;var _EJ=document.createElement('TR');var _Cs=_EJ.appendChild(document.createElement('TD'));if(this._t9){if(this._iP){var _aID=this.oRes.GetString('IDS_DIALOG_BUTTON_SAVE_DONT_APPLY');var _apS=COTInputElementFactory.CreateButton('OKButton',_aID,this._yi,false,false,this._om);this._te=Utilities.GenerateId();_apS.id=this._te;_Cs.appendChild(_apS);}else{var _aID=this.oRes.GetString(this._iG);var _apS=_Cs.appendChild(COTInputElementFactory.CreateButton('OKButton',_aID,this._Y,false,false,this._om));}}if(this._hB){var _aut=this.oRes.GetString(this._gp);var _Ke=this.sAppName;if(!this._of){this._of=Utilities.GenerateCallback(CUIDialogMgr.SafeHideCurrentDialog,[_Ke]);}var _Zv=_Cs.appendChild(COTInputElementFactory.CreateButton('CancelButton',_aut,this._of,false,true,this._om+1));}_F0.appendChild(_EJ);return _EJ;};CUIDialog.prototype.DrawMsg=function(_F0,_Ku,_Bx){var _az8=_Ku.split('\n');_EJ=document.createElement('TR');_Cs=document.createElement('TD');_Cs.colSpan=_Bx;var _Bb='msg_information.gif';if(this._sY){_Bb=this._sY;}var _agf=COTInputElementFactory.CreateImage(_Bb,32,32,null,true,true);_Cs.appendChild(_agf);_Cs.appendChild(_agf);_EJ.appendChild(_Cs);_Cs=document.createElement('TD');COTStyle.SetWidth(_Cs,100,'%');_Cs.className="dialogText";_Cs.style.textAlign="left";var _aHJ=document.createElement('DIV');for(var x=0;x<_az8.length;x++){var _TL=document.createTextNode(_az8[x]);_aHJ.appendChild(_TL);_aHJ.appendChild(document.createElement('BR'));}_Cs.appendChild(_aHJ);_EJ.appendChild(_Cs);_F0.appendChild(_EJ);if(this._ho&&this.ShowMessageInDetail){this.ShowMessageInDetail(_F0);}};CUIDialog.prototype.IsVisible=function(){return this._r3;};CUIDialog.prototype.OnHide=function(){this._r3=false;this._ym=null;};CUIDialog.prototype.GetDlgContentDiv=function(){if(this._hU){return document.getElementById(this._hU);}return null;};CUIDialog.prototype.CreateDialogDiv=function(){var _Ij=document.createElement('DIV');var _Ke=this.sAppName;switch(this._qu){case CUIDialog.eNormalState:_Ij.style.position='absolute';_Ij.style.left='0px';_Ij.style.top='0px';COTStyle.SetWidth(_Ij,100,'%');break;case CUIDialog.eModalState:break;}this._p2=_Ij;return _Ij;};CUIDialog.SafeHandleKeyDown=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}if(window.oUIManager.oDialogMgr.IsModalDialogDisplayed()){window.oUIManager.oDialogMgr._H.HandleKeyDown(e);}else{if(window.oUIManager.oDialogMgr._jg){window.oUIManager.oDialogMgr._jg.HandleKeyDown(e);}}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIDialog.prototype.HandleKeyDown=function(e){if(e.keyCode==Dom.KeyCodes.Enter&&this._Y){if(this._li&&this._jM){Dom.CancelEvent(e);this._cv();}else{if(!document._tZ&&Dom.GetEventTarget(e).name!="CancelButton"){Dom.CancelEvent(e);this._Y();}else if(Dom.GetEventTarget(e).name=="CancelButton"){this._of();}}}else{CUIManager.HandleCommonKeys(e);}};CUIDialog.prototype.DisplayInvalidSelection=function(_MG,_MY,_Nk,_Li,_US,_LO,_Ua){var _Ku='IDS_SELECTION_DLG_NO_VALID_SET';var _Av=null;if(_Nk.length==0){if(_LO){var _W7=new Array();for(var i=0;i<_Li.GetAxisCount();i++){_W7=_W7.concat(_Li.GetAxis(i).GetAllBlocksArray());}if(_W7.length>0){_Ku='IDS_SELECTION_DLG_NO_VALID_NON_HAMC_SET';}}}else{var _Av=document.createElement('TABLE');_Av.cellSpacing=10;var _aDR=_Av.appendChild(document.createElement('TBODY'));_Ku=this.oRes.GetString('IDS_SELECTION_DLG_PICK_OTHER_SET_'+_US);this.DrawMsg(_aDR,_Ku,1);var _abU=Dom.GetElementsByTagName(_Av,'TD');var _aAq=_abU[_abU.length-1];var _0F=_aAq.appendChild(document.createElement('DIV'));_0F.className="dialog_block_list";var _aGg=new Array();for(var i=0;i<_Nk.length;i++){_aGg.push("["+i+"]");}var _aAm=this.oRes.ReplaceParamList('IDS_BLOCKPROP_VALUE_LIST',_aGg);var _alq=this.oRes.ParseStringForOrder(_aAm,_aGg);for(var i=0;i<_alq.length;i++){if(_alq[i]){if(_alq[i].sBefore){_0F.appendChild(document.createTextNode(_alq[i].sBefore));}var _aqL=_alq[i].sElement.substr(1,1);var _Cf=_0F.appendChild(document.createElement('A'));_Cf.className="link";Dom.SetObjRef(_Cf,this,'oDialog');_Cf.sBlockID=_Nk[_aqL].GetId();_Cf.onmousedown=CUIDialog.SafeHandleMouseDownOnBlockList;_Cf.appendChild(document.createTextNode(_Nk[_aqL].GetLabel()));if(_alq[i].sAfter){_0F.appendChild(document.createTextNode(_alq[i].sBefore));}}}if(_Ua){_0F.style.paddingBottom='10px';_aAq.appendChild(document.createTextNode(this.oRes.GetString(_Ua)));}}this._u9=this._Y;var _Ke=this.sAppName;this._jM=true;this._Y=Utilities.GenerateCallback(CUIDialogMgr.SafeHideCurrentDialog,[_Ke]);this.DrawDialog(_MG,_MY,_Av,"",_Ku);this._Y=this._u9;};CUIDialog.prototype.SetInvalidSelSupport=function(){this._li=true;this._jM=false;var _Ke=this.sAppName;this._cv=Utilities.GenerateCallback(CUIDialogMgr.SafeHideCurrentDialog,[_Ke]);};CUIDialog.SafeHandleMouseDownOnBlockList=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/this.oDialog.HandleMouseDownOnBlockList(this.sBlockID);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIDialog.prototype.HandleMouseDownOnBlockList=function(_Mc){this.oDialogMgr.oUIMgr._jf.ApplyBlockSelection(_Mc);};CUIDialog.prototype.DrawDialog=function(_MG,_MY,_Av,_Rr,_BK,_G3){this.ClearMainDiv();var _Ij=this.CreateDialogDiv();var _agP='';if(this._eB&&(this._eB!='')){_agP=this.oRes.ReplaceParam(_MG,1,this.oRes.GetString('IDS_DLG_TITLE_DETAIL_SEPSTR'));_agP=this.oRes.ReplaceParam(_agP,2,this._eB);}else{_agP=this.oRes.ReplaceParam(_MG,1,'');_agP=this.oRes.ReplaceParam(_agP,2,'');}var _aw9=this.DrawTitleBar(_agP,_MY);_Ij.appendChild(_aw9);var _F0=document.createElement('TBODY');var _aE1=document.createElement('table');_aE1.className='dialogIntroTable';_aE1.appendChild(_F0);var _5p=document.createElement('DIV');this._hU=Utilities.GenerateId();_5p.id=this._hU;var className=(this._qu==CUIDialog.eModalState)?Dom.GetStyleByBrowser('modalDialogContentDiv'):'dlgContentDiv';_5p.className=className;_5p._u3=1000000;_Ij.appendChild(_5p);_5p.appendChild(_aE1);if((!_Av)&&(_BK)){var _ah8=this.oRes.GetString(_BK);this.DrawMsg(_F0,_ah8,(_4R)?2:1);var _aEd=this._hB;var _YT=this._iP;var _Ke=this.sAppName;if(this._iP){this._iP=false;}if(_G3){this._Y=_G3;}else{this._Y=Utilities.GenerateCallback(CUIDialogMgr.SafeHideCurrentDialog,[_Ke]);}this._hB=false;this.DrawMainButtons();this._hB=_aEd;this._iP=_YT;}else{var _ajf=false;if(_Rr){var _aqg=document.createElement('TR');_F0.appendChild(_aqg);var _aqp=document.createElement('TD');_aqp.className='dialogIntroText';_aqg.appendChild(_aqp);var _TL=document.createTextNode(this.oRes.GetString(_Rr));_aqp.appendChild(_TL);_ajf=true;}var _4R=false;for(var i in _MY){if(i!='IDS_HELP'){var _9W=false;if((!_ajf)&&(!_9W)){var _aqg=document.createElement('TR');_F0.appendChild(_aqg);_9W=true;}_aqp=document.createElement('TD');_aqg.appendChild(_aqp);_aqp.className='dlginnerlink';_aqp.appendChild(COTInputElementFactory.CreateLink(_MY[i],this.oRes.GetString(i),true));_4R=true;}}_5p.appendChild(_Av);this._fk=_Av;this.DrawMainButtons();}this.oDialogMgr.Show(this);this._r3=true;};CUIDialog.prototype.Display=function(_MG,_MY,_Av,_Rr,_BK,_G3){if(this._li){this._jM=false;}this.DrawDialog(_MG,_MY,_Av,_Rr,_BK,_G3);if(this._ym){var _A4=document.getElementById(this._ym);if(_A4){_A4.focus();}}};CUIDialog.prototype.SetDefaultFocusId=function(_Be){this._ym=_Be;};CUIDialog.prototype.CanStackPreviousDlg=function(){return false;};function CUIAboutDlg(){this.base=CUIDialog;this.base();};CUIAboutDlg.prototype=new CUIDialog;CUIAboutDlg.superclass=CUIDialog.prototype;CUIAboutDlg.prototype.Display=function(_VT){var _Ke=this.sAppName;var _Av=document.createElement('DIV');_Av.className='aboutDlgDiv';var _zr=_Av.appendChild(document.createElement('TABLE'));var _RK=_zr.appendChild(document.createElement('TBODY'));var _FW=_RK.appendChild(document.createElement('TR'));var _NM=_FW.appendChild(document.createElement('TD'));_zr.cellSpacing=0;_zr.cellPadding=0;COTStyle.SetWidth(_zr,100,'%');var _at2=this.oDialogMgr.oUIMgr.appobj._hW+'.jpg';var _6w=document.createElement('DIV');_6w.className='aboutImageDiv';var _X6=COTInputElementFactory.CreateImage(_at2);_X6.className='aboutImageTemplate';_6w.appendChild(_X6);_NM.appendChild(_6w);this._Y=Utilities.GenerateCallback(CUIDialogMgr.SafeHideCurrentDialog,[_Ke]);this._hB=false;var _KP=this.oRes.ReplaceParam('IDS_ABOUT_DLG_TITLE',1,ExpMiscStr.kProductName);var _apm=this.oRes.ReplaceParam('IDS_ABOUT_DLG_INSTRUCTION',1,ExpMiscStr.kProductLongName);CUIAboutDlg.superclass.Display.call(this,_KP,null,_Av,"");};CUIAboutDlg.SafeDoDisplay=function(_Ke){try{var _VN=new CUIAboutDlg();var _Hy=FindApp(_Ke).uiManager.oDialogMgr;_VN.Init(_Hy);_VN.Display(FindApp(_Ke).dataManager._xb);}catch(e){_f.HandleException(e);}};CUIAboutDlg.SafeOpenWWWCognosWindow=function(_Ke){try{var _Mn=FindApp(_Ke).oResources.GetString('IDS_ABOUT_DLG_COGNOS_LINK');var _ag3=window.open(_Mn);}catch(e){_f.HandleException(e);}};CUISearchDlg.eStateNormal=1;CUISearchDlg.eStateBusy=2;CUISearchDlg.eSrchResultStateInit=1;CUISearchDlg.eSrchResultStateComplete=2;CUISearchDlg.eSrchResultStateIdol=3;CUISearchDlg.eSrchResultStateContinue=4;CUISearchDlg.eSrchRSNoSortState=1;CUISearchDlg.eSrchRSAscendSortState=2;CUISearchDlg.eSrchRSDescendSortState=3;CUISearchDlg.SortStateArray=new Array(CUISearchDlg.eSrchRSNoSortState,CUISearchDlg.eSrchRSAscendSortState,CUISearchDlg.eSrchRSDescendSortState);CUISearchDlg.kSortByName=1;CUISearchDlg.kSortByPath=2;CUISearchDlg.kNonAggreMeasure='non-aggregate';CUISearchDlg.sButtonAnchorColor='#000000';CUISearchDlg.sDisabledButtonAnchorColor='#CCCCCC';function CUISearchDlg(){this.base=CUIDialog;this.base();this._eq='';this._pf=new Array();this._v9='';this._ut=new Array();this._bk=new Array();this._ya=new Object();this._ya[ExpAPIXml.kBeginWith]="IDS_SEARCH_DLG_START_EXACT";this._ya[ExpAPIXml.kContain]="IDS_SEARCH_DLG_CONTAIN_EXACT";this._ya[ExpAPIXml.kMatch]="IDS_SEARCH_DLG_MATCH_EXACT";this._ya[ExpAPIXml.kEndWith]="IDS_SEARCH_DLG_END_EXACT";this._e6=new Array();this._e6[ExpEvent.kCDLSearchResult_Release]=new Array();this._e6[ExpEvent.kCUISearchDlg_StateChange]=new Array();this._hz=new Array();this._d7=new Array();this._ux=true;this._co=null;this._lY=false;this._pm=true;this._dP=true;this._bH=false;this._qu=CUISearchDlg.eStateNormal;this._qn=CUISearchDlg.eSrchResultStateIdle;this._qF=CUISearchDlg.kSortByName;this._f8=CUISearchDlg.eSrchRSNoSortState;this._rG=CUISearchDlg.eSrchRSNoSortState;this._gs=new Array();this._cF=new Array();this._nU=false;};CUISearchDlg.prototype=new CUIDialog;CUISearchDlg.superclass=CUIDialog.prototype;CUISearchDlg.prototype.Init=function(_yt){CUISearchDlg.superclass.Init.call(this,_yt);this._yk=document.createElement('TD');this._yk.className="pagerCtrlTBLHeader";this._xD=document.createElement('TD');this._xD.className="pagerCtrlTBLHeaderLastColumn";this._o0=document.createElement('TR');for(var i=0;i<2;i++){var _arF=document.createElement('TD');this._o0.appendChild(_arF);}this._o0.className="srchDlgResultItem";this.oMemberSrchResultContextMenu=new CUIContextMenu(this.sAppName,0);this.oMeasureSrchResultContextMenu=new CUIContextMenu(this.sAppName,0);this.InitContextMenu();this.oDialogMgr.oUIMgr._jf.Subscribe(this,ExpEvent.kCUIWorksheet_Free);this.oDialogMgr.oUIMgr._jf.Subscribe(this,ExpEvent.kCUIWorksheet_Busy);this.oDialogMgr.oUIMgr._qi.Subscribe(this,ExpEvent.kCUIMetadataTree_SelChange);var _Tc=this.oDialogMgr.oUIMgr._qi._ob;this._dP=_Tc.IsFunctionSupported(ExpAPIXml.kQosHierarchySrch);};CUISearchDlg.prototype.HandleKeyDown=function(e){if(e.keyCode==Dom.KeyCodes.Enter&&this._Y){this.DoSearch();}else{CUIManager.HandleCommonKeys(e);}};CUISearchDlg.prototype.IsSearching=function(){if(this._qu==CUISearchDlg.eStateBusy){return true;}return false;};CUISearchDlg.prototype.Display=function(_M3){var _MY=new Object();var _Ke=this.sAppName;var _Xf=Utilities.GenerateCallback(CUIManager.SafeDoHelpTopic,[_Ke,HelpConstants.kSearchLink]);_MY['IDS_HELP']=_Xf;if(!this._eq){if(_M3){CUISearchDlg.superclass.Display.call(this,'IDS_SEARCH_DLG_TITLE',_MY,null,'','IDS_SEARCH_DLG_INVALID_SELECTION');}else{CUISearchDlg.superclass.Display.call(this,'IDS_SEARCH_DLG_TITLE',_MY,null,'','IDS_SEARCH_DLG_NO_SELECTION');}}else{var _Co=this.oDialogMgr.oUIMgr.appobj.oResources;var _aze=this._dP?'IDS_SEARCH_INSTRUCTION':'IDS_SEARCH_INSTRUCTION_IMME_DESC';CUISearchDlg.superclass.Display.call(this,'IDS_SEARCH_DLG_TITLE',_MY,this._lq,_aze);}};CUISearchDlg.prototype.InitContextMenu=function(){CUIMetadataTree.SetBaseMemberXTabActionMenu(this.sAppName,this.oMemberSrchResultContextMenu);this.oMemberSrchResultContextMenu.SetChildrenComplete();CUIMetadataTree.SetMeasureContextMenu(this.sAppName,this.oMeasureSrchResultContextMenu);this.oMeasureSrchResultContextMenu.SetChildrenComplete();};CUISearchDlg.prototype.Create=function(_z9){if(!this._eq){return;}if(this._lq){if(this.IsSearching()){this.DoStopSearch();}this.ClearDlg();}var _zr=document.createElement('TABLE');_zr.className='dialogTable';var _Ke=this.sAppName;var _F0=document.createElement('TBODY');var _NH=document.createElement('TR');var _NM=this._l4.cloneNode(false);_NM.colSpan=2;COTStyle.SetWidth(_NM,50,'%');var _apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_SELECTION')+' ');_NM.appendChild(_apS);_NH.appendChild(_NM);var _An=document.createElement('SPAN');_An.className='infoLabel';_NM.appendChild(_An);var _awL=true;var _Oi=0;for(var i in this._o8){_Oi++;if(_Oi>1){_awL=false;}}if(_awL){var _QI=(this._eq.GetBreadCrumbText)?this._eq.GetBreadCrumbText():this.GetSearchContextLabel();var _afV=COTInputElementFactory.CreateToolTip(_QI);_apS=COTInputElementFactory.CreateLabel(this.GetSearchContextLabel());_afV.appendChild(_apS);_An.appendChild(_afV);}else{this._lF=new CUIListCtrl(this.oDialogMgr.oUIMgr);this._lF.iMaxHeight=150;this._lF.Init();this._lF.DisableHAutoScroll();var _Oi=0;var _aFI=null;for(var i in this._o8){var _LX=this._lF.AddItem('',this._o8[i]._p8,0,i,"",false);if(_Oi==0){_aFI=_LX;}_Oi++;}this._w8=new CUIComboBox(this.oDialogMgr.oUIMgr,this._lF);this._w8.DisableIcon();var _afs=_An.appendChild(this._w8.Init());COTStyle.SetWidth(_afs,90,'%');this._w8.SetValueFromListItem(_aFI,false);this._w8.Subscribe(this,ExpEvent.kCUIComboBox_OnSelChange);}this._eB=this.GetSearchContextLabel();this._eJ=this._l4.cloneNode(false);this._eJ.colSpan=2;COTStyle.SetWidth(this._eJ,50,'%');_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_RESULTS'));this._eJ.appendChild(_apS);_apS=COTInputElementFactory.CreateImage('tv_white.gif',8,16);this._eJ.appendChild(_apS);_NH.appendChild(this._eJ);_F0.appendChild(_NH);_NH=document.createElement('TR');_NM=this._l4.cloneNode(false);_NM.colSpan=2;_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_KEYWORD'));_NM.appendChild(_apS);_NH.appendChild(_NM);this._sn=document.createElement('TD');this._sn.className='srchDlgResultArea';this._sn.rowSpan=5;this._sn.colSpan=2;COTStyle.SetWidth(this._sn,50,'%');COTStyle.SetHeight(this._sn,100,'%');this._ko=document.createElement('DIV');this._ko.className='srchDlgResultDiv';this._sn.appendChild(this._ko);_NH.appendChild(this._sn);_F0.appendChild(_NH);_NH=document.createElement('TR');_NM=document.createElement('TD');_NM.colSpan=2;COTStyle.SetWidth(_NM,50,'%');var _2N=COTInputElementFactory.CreateTextBox(90,'%');_2N.id=Utilities.GenerateId();this.SetDefaultFocusId(_2N.id);this._ti=_2N;_NM.appendChild(this._ti);_NH.appendChild(_NM);_F0.appendChild(_NH);_NH=document.createElement('TR');_NM=_NH.appendChild(document.createElement('TD'));_NM.colSpan=2;var _abA=_NM.appendChild(document.createElement('TABLE'));COTStyle.SetWidth(_abA,90,'%');var _alj=_abA.appendChild(document.createElement('TBODY'));var _afQ=_alj.appendChild(document.createElement('TR'));var _afY=_afQ.appendChild(document.createElement('TD'));_afY.style.textAlign='right';var _Ke=this.sAppName;var _Zr=Utilities.GenerateCallback(this.DoStopSearch,[],this);this._t2=COTInputElementFactory.CreateButton(this.oRes.GetString('IDS_BUTTON_STOP'),this.oRes.GetString('IDS_BUTTON_STOP'),_Zr);this._t2.style.fontSize="70%";COTStyle.SetHeight(this._t2,21,'px');COTStyle.SetWidth(_afY,76,'%');this._t2.style.marginRight="5px";COTInputElementFactory.DisableInput(this._t2);COTInputElementFactory.SetButtonAnchorTextColor(this._t2,CUISearchDlg.sDisabledButtonAnchorColor);_afY.appendChild(this._t2);_afY=_afQ.appendChild(document.createElement('TD'));_afY.style.textAlign='right';_afY.style.marginRight='10px';var _Zr=Utilities.GenerateCallback(this.DoSearch,[],this);this._rH=COTInputElementFactory.CreateImgButton(this.oRes.GetString('IDS_BUTTON_SEARCH'),"action_search.gif",_Zr,false);if(_o.is_firefox){COTStyle.SetWidth(this._rH,80,'%');COTStyle.SetHeight(this._rH,19,'px');}else{COTStyle.SetHeight(this._rH,21,'px');}_afY.appendChild(this._rH);_F0.appendChild(_NH);_NH=document.createElement('TR');_NM=this._l4.cloneNode(false);_NM.colSpan=2;COTStyle.SetWidth(_NM,50,'%');_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_SRCH_OPTIONS'));_NM.appendChild(_apS);_NH.appendChild(_NM);_F0.appendChild(_NH);_NH=document.createElement('TR');_F0.appendChild(_NH);_NM=this._gM.cloneNode(false);COTStyle.SetWidth(_NM,25,'%');optSecDiv=document.createElement('DIV');optSecDiv.id='srchDlgOptSect';var _Tc=this.oDialogMgr.oUIMgr._qi._ob;var _aD8=document.createElement('TABLE');var _1S=document.createElement('TBODY');var _GW=false;for(i in this._ya){var _aGh=false;var _4F=false;switch(i){case ExpAPIXml.kBeginWith:_4F=_Tc.IsFunctionSupported(ExpAPIXml.kQosStartsWithSrch);break;case ExpAPIXml.kEndWith:_4F=_Tc.IsFunctionSupported(ExpAPIXml.kQosEndsWithSrch);break;case ExpAPIXml.kContain:_4F=_Tc.IsFunctionSupported(ExpAPIXml.kQosContainsSrch);break;case ExpAPIXml.kMatch:_4F=true;break;default:break;}if(!_GW&&_4F){_aGh=true;_GW=true;}var _1P=document.createElement('TR');var _1M=document.createElement('TD');_1P.appendChild(_1M);var _WY=COTInputElementFactory.CreateRadioButton('srchOpt',i,_aGh,!_4F);_1M.appendChild(_WY);_1M=document.createElement('TD');_1M.className="CheckBoxText";_1P.appendChild(_1M);_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString(this._ya[i]));_1M.appendChild(_apS);_1S.appendChild(_1P);}_aD8.appendChild(_1S);optSecDiv.appendChild(_aD8);_NM.appendChild(optSecDiv);_NH.appendChild(_NM);_NM=document.createElement('TD');_NM.className='srchDlgQoSOpt';_NH.appendChild(_NM);COTStyle.SetWidth(_NM,25,'%');var _acv=document.createElement('DIV');_acv.id='srchDlgQoSSect';_NM.appendChild(_acv);_aD8=document.createElement('TABLE');_acv.appendChild(_aD8);_1S=document.createElement('TBODY');_aD8.appendChild(_1S);_1P=document.createElement('TR');_1S.appendChild(_1P);_1M=document.createElement('TD');_1P.appendChild(_1M);var _aB8=Utilities.GenerateCallback(this.ToggleAllDescSearch,[],this);var _aw6=COTInputElementFactory.CreateCheckBox('alldescsearch',ExpAPIXml.kAllDescendants,false,_aB8,!this._dP);_1M.appendChild(_aw6);if(_z9==CDLAbsBlock.eTypeNested){_aw6.checked=true;this._bH=true;this.oDialogMgr.oUIMgr._qi._ob.Subscribe(this,ExpEvent.kCDLMetadata_WaitLineage);}_1M=document.createElement('TD');_1M.className="CheckBoxText";_1P.appendChild(_1M);_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_SEARCH_DLG_SRCH_ALL_DETAILS'));_1M.appendChild(_apS);_1P=document.createElement('TR');_1S.appendChild(_1P);_1M=document.createElement('TD');_1P.appendChild(_1M);var _aeQ=!_Tc.IsFunctionSupported(ExpAPIXml.kQosCaseInSensitiveSrch);_aw6=COTInputElementFactory.CreateCheckBox('caseinsensitive',ExpAPIXml.kCaseInSensitive,true,null,_aeQ);_1M.appendChild(_aw6);_1M=document.createElement('TD');_1M.className="CheckBoxText";_1P.appendChild(_1M);_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_SEARCH_DLG_CASE_IN_SENSITIVE'));_1M.appendChild(_apS);_NH=document.createElement('TR');_NM=this._gM.cloneNode(false);_NM.colSpan=2;_NH.appendChild(_NM);COTStyle.SetWidth(_NM,50,'%');_NM=this._gM.cloneNode(false);_NM.className="CheckBoxText";COTStyle.SetWidth(_NM,25,'%');var _ahU=Utilities.GenerateCallback(this.ToggleShowPath,[],this);_aw6=COTInputElementFactory.CreateCheckBox('showPath','show',false,_ahU);_NM.appendChild(_aw6);_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_SHOW_PATH'));_NM.appendChild(_apS);_NH.appendChild(_NM);this.drawSelectionLinks(_NH);this.SetAlternativeLabelForOKButton('IDS_BUTTON_CLOSE');this._Y=Utilities.GenerateCallback(this.CloseSearchDialog,[],this);this._hB=false;_F0.appendChild(_NH);_zr.appendChild(_F0);this._lq=_zr;};CUISearchDlg.prototype.CloseSearchDialog=function(){this.DoStopSearch();this.oDialogMgr.HideCurrentDialog();};CUISearchDlg.prototype.drawSelectionLinks=function(_NH){var _Ke=this.sAppName;_NM=this._gM.cloneNode(false);_NM.style.textAlign='right';COTStyle.SetWidth(_NM,25,'%');var _ab3=Utilities.GenerateCallback(this.SelectAllResult,[],this);var _apS=COTInputElementFactory.CreateLink(_ab3,this.oRes.GetString('IDS_SELECT_ALL'),true);_apS.id=Utilities.GenerateId();this._fG=_apS.id;_NM.appendChild(_apS);_apS=COTInputElementFactory.CreateLabel(" ");_NM.appendChild(_apS);var _4e=Utilities.GenerateCallback(this.DeselectAllResult,[],this);_apS=COTInputElementFactory.CreateLink(_4e,this.oRes.GetString('IDS_DE_SELECT_ALL'),true);_apS.style.whiteSpace="nowrap";_apS.id=Utilities.GenerateId();this._wH=_apS.id;_NM.appendChild(_apS);_NH.appendChild(_NM);};CUISearchDlg.prototype.SetSearchType=function(_Hx){this._fY=_Hx;};CUISearchDlg.prototype.SetSearchContext=function(_FZ){if(_FZ){for(var i in _FZ){this._eq=_FZ[i];break;}this._o8=_FZ;}else{this._o8=null;this._eq=null;}};CUISearchDlg.prototype.GetSearchContextLabel=function(){return this._eq._p8;};CUISearchDlg.MemberSrch=1;CUISearchDlg.DimSrch=2;CUISearchDlg.CubeSrch=3;CUISearchDlg.prototype.DoSearch=function(){if(this._qu==CUISearchDlg.eStateBusy){return;}else{if(this._ti.value==''){this.AddMsgToResultTable('IDS_NO_SRCH_CRITERIA',true);return;}/*@if(@bering_debug)@*/if(Debug.IsEnabled()){if(_r){_r.Unload();}if(_k){_k.Unload();_k=null;}_r=new PerfMonitor("Your last search performance");_r.StartGlobalTimer("Searching all descendants");}/*@end@*/this._wF=false;switch(this._fY){case ExpAPIXml.eMember:case ExpAPIXml.eMeasure:case CUIMeasure.kNonAggreMeasure:case ExpAPIXml.eDimRoot:this._wF=true;this._bk.push(this._eq);this.DoMemberSearch(this._eq);break;case ExpAPIXml.eRoot:this.DoCubeSearch();break;case ExpAPIXml.eDim:this.DoDimSearch(this._eq,true);break;case ExpAPIXml.eMeasureRoot:this.DoMeasureDimSearch(this._eq,true);break;case ExpAPIXml.eMeasureFolder:this.DoMeasureFolderSearch(this._eq,true);break;case ExpAPIXml.eFolder:case ExpAPIXml.eNamespace:this._sZ=new Array();this.DoDimFolderSearch(this._eq,true);break;case ExpAPIXml.eHierarchy:this.DoHierarchySearch(this._eq,true);break;default:Debug.Assert(false);break;}}};CUISearchDlg.prototype.DoCubeSearch=function(){var _Tc=this.oDialogMgr.oUIMgr.dataManager.metadata;if(this._dP){for(var i in _Tc._iR){var _Ni=_Tc._iR[i];this.DoDimSearch(_Ni);}}for(var j in _Tc._xV){this.DoMeasureDimSearch(_Tc._xV[j]);}this.FireSearch();};CUISearchDlg.prototype.DoDimSearch=function(_Ni,_Lp){for(var x in _Ni._j5){var _Ts=_Ni.GetHierarchy(x);this.DoHierarchySearch(_Ts);}if(_Lp){this.FireSearch();}};CUISearchDlg.prototype.DoHierarchySearch=function(_Ts,_DN){this._bk.push(_Ts);if(_DN){this.FireSearch();}};CUISearchDlg.prototype.DoMeasureDimSearch=function(_Ni,_Lp){this._bk.push(_Ni);if(_Lp){this.FireSearch();}};CUISearchDlg.prototype.HasDimNeverSearched=function(_Qk){for(var i=0;i<this._sZ.length;i++){if(_Qk==this._sZ[i]){return false;}}return true;};CUISearchDlg.prototype.DoDimFolderSearch=function(_UV,_NF){var _Tc=this.oDialogMgr.oUIMgr.dataManager.metadata;for(var i in _UV._sr){var _RJ=_UV._sr[i];if(_RJ instanceof CDLFolderObjDimension&&this.HasDimNeverSearched(_RJ._cH)){var _EZ=_Tc.GetDimById(_RJ._cH);this._sZ.push(_RJ._cH);this.DoDimSearch(_EZ);}else if(_RJ instanceof CDLFolderObjMeasureDim&&this.HasDimNeverSearched(_RJ._cH)){var _8a=_Tc.GetDataById(_RJ._cH);this._sZ.push(_RJ._cH);this.DoMeasureDimSearch(_8a);}else if(_RJ instanceof CDLFolderObjHierarchy){var _Ts=_Tc.GetHierarchyById(_RJ.GetObjPtr());this.DoHierarchySearch(_Ts);}else if(_RJ instanceof CDLFolder){this.DoDimFolderSearch(_RJ);}}if(_NF){this.FireSearch();}};CUISearchDlg.prototype.DoMeasureFolderSearch=function(_Sf,_AQ){this._bk.push(_Sf);if(_AQ){this.FireSearch();}};CUISearchDlg.prototype.FireSearch=function(){if(this._bk[0]!=null){this.DoMemberSearch(this._bk[0]);}else{this._qn=CUISearchDlg.eSrchResultStateComplete;}};CUISearchDlg.prototype.DoMemberSearch=function(_Jm){if(this._bH){this.FreezeShowPath();this.FreezeSearchType();}/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_r){g_oSrch=_r.CreateTimer("Search under"+this._bk[0].GetLabel());g_oSrch.StartTimer(true);}/*@end@*/var _O7=this.oDialogMgr.oUIMgr._qi;if(_Jm instanceof CDLAbsMember){_Jm.Subscribe(_O7,ExpEvent.kCDLMember_Merge);}_O7.SetLastSearchedMember(_Jm);this.UpdateSearchingPath(this.GetSearchingPath());this.SetSrchCreteria();this._rL=new CDLSearchResult(this.oDialogMgr.oUIMgr.dataManager);var _auX=ExpAPIXml.kSearch;var _axq=new CDLMathMLExprNode(_auX,false,false);var _Qs=this._bH?ExpAPIXml.kAllDescendants:ExpAPIXml.kImmediateDescendants;var _LW=ExpAPIXml.kSearchScope;this._rL.DefineSearchMemberSet(_axq,_Jm,_LW,_Qs);var _J9=COTInputElementFactory.GetRadioSelectionValue('srchOpt');if(_Jm instanceof CDLMeasure||_Jm instanceof CDLMeasureDim||_Jm instanceof CDLMeasureFolder){_Qs=ExpAPIXml.kMeasureCaption;this._rL._rJ=ExpAPIXml.eMeasure;}else{_Qs=ExpAPIXml.kMemberCaption;this._rL._rJ=ExpAPIXml.eMember;}_LW=ExpAPIXml.kPropertyName;var _D6=!(COTInputElementFactory.IsChecked('caseinsensitive',ExpAPIXml.kCaseInSensitive));this._rL.DefineStringConstraint(_axq,_J9,this._v9,_LW,_Qs,_D6);this._rL.AddConstraint(_axq);this._rL.Subscribe(this,ExpEvent.kCDLSearchResult_WaitingResp);this._rL.Subscribe(this,ExpEvent.kCDLSearchResult_Replace);this._rL.Subscribe(this,ExpEvent.kCDLSearchResult_FailedResponse);this._rL.RunRequest();this._me=this._rL;};CUISearchDlg.prototype.GetSearchingPath=function(){if(this._bk[0]){if(this._bk[0].GetBreadCrumbText){return this._bk[0].GetBreadCrumbText();}else{return this._bk[0].GetLabel();}}return '';};CUISearchDlg.prototype.UpdateSearchingPath=function(_QB){if(this._pt){var _BM=this.oRes.ReplaceParam('IDS_SEARCHDLG_CURRENT_SEARCH_SCOPE',1,_QB);Dom.ReplaceTextNode(this._pt,_BM);}};CUISearchDlg.prototype.SetSrchCreteria=function(){var _aHA=Utilities.HtmlEncode(this._ti.value);this._v9=_aHA;};CUISearchDlg.prototype.DoStopSearch=function(){if(this._qu==CUISearchDlg.eStateNormal){Utilities.DeleteAllFromArray(this._bk);if(this._sZ){Utilities.DeleteAllFromArray(this._sZ);}return;}if(!this._mB){Utilities.DeleteAllFromArray(this._bk);this.CancelSearchRequest();this.SetToReadyState();this._kS=false;}else{this._kS=true;}if(this._sZ){Utilities.DeleteAllFromArray(this._sZ);}};CUISearchDlg.prototype.CancelSearchRequest=function(){if(!this._me){return;}if(this._me.IsCancellable()){this._me.SendCancelRequest();}else{this._me.IgnoreResponse();}};CUISearchDlg.prototype.HandleFailedSearch=function(){if(this._bk.length>0){this._mB=true;this._gs.push(this._bk[0]);Utilities.DeleteNthFromArray(this._bk,0);this._mB=false;if(this._kS){this._me=null;this.DoStopSearch();return;}if(this._bk.length>0){this.FireSearch();}else{this.SetToReadyState();}}};CUISearchDlg.prototype.Subscribe=function(obj,_Dy){if(this._e6[_Dy]){for(var i=0;i<this._e6[_Dy].length;i++){if(this._e6[_Dy]==obj){return;}}this._e6[_Dy].push(obj);}};CUISearchDlg.prototype.Notify=function(event){if(this._e6[event]){for(var i in this._e6[event]){this._e6[event][i].Notify(event);}}if(event==ExpEvent.kCUIManager_Unload){this.Unload();}else if(event==ExpEvent.kCDLSearchResult_Replace){this.AddSearchResult();}else if(event==ExpEvent.kCDLSearchResult_Release){this._rL=null;}else if(event==ExpEvent.kCDLSearchResult_FailedResponse){this.HandleFailedSearch();}else if(event==ExpEvent.kCDLSearchResult_WaitingResp){this.SetToBusyState();}else if(event==ExpEvent.kCUIWorksheet_Free){this.updateWSContextMenuOptions(false);}else if(event==ExpEvent.kCUIWorksheet_Busy){this.updateWSContextMenuOptions(true);}else if(event==ExpEvent.kCUIMetadataTree_SelChange){if(!this._eq&&this._r3){var _akO=this.oDialogMgr.oUIMgr._qi.GetSearchData();if(_akO){if(_akO._ll){this.SetSearchContext(null);this.SetSearchType(null);this.Create();this.Display(true);}else{this.SetSearchContext(this.oDialogMgr.oUIMgr._qi.GetSearchData());this.SetSearchType(this.oDialogMgr.oUIMgr._qi.GetSearchType());this.Create();this.Display();}}}}else if(event==ExpEvent.kCDLMetadata_FullLineage){if(this._qu!=CUISearchDlg.eStateBusy){this._pm=true;if(this._r3){this.ActivateShowPath();}}this.oDialogMgr.oUIMgr._qi._ob.UnSubscribe(this,ExpEvent.kCDLMetadata_FullLineage);}else if(event==ExpEvent.kCDLMetadata_WaitLineage){if(this._r3){this._pm=false;this.oDialogMgr.oUIMgr._qi._ob.Subscribe(this,ExpEvent.kCDLMetadata_FullLineage);}}else if(event==ExpEvent.kCUIComboBox_OnSelChange){this._eq=this._o8[this._w8.GetValue()];var _agP=this.oRes.ReplaceParam('IDS_SEARCH_DLG_TITLE',1,this.oRes.GetString('IDS_DLG_TITLE_DETAIL_SEPSTR'));var _agP=this.oRes.ReplaceParam(_agP,2,this.GetSearchContextLabel());this._kC.Update(_agP);}else if(event==ExpEvent.kCDLAnalysis_Replace){this.ClearSelections();this.oDialogMgr.oUIMgr.dataManager._kX.UnSubscribe(this,ExpEvent.kCDLAnalysis_Replace);}};CUISearchDlg.prototype.updateWSContextMenuOptions=function(_KC){for(var i=0;i<this.oMemberSrchResultContextMenu.items.length;i++){this.oMemberSrchResultContextMenu.items[i]._eY=_KC;}if(this.oMemberSrchResultContextMenu.IsVisible()){this.ShowContextMenu();}for(var i=0;i<this.oMeasureSrchResultContextMenu.items.length;i++){this.oMeasureSrchResultContextMenu.items[i]._eY=_KC;}if(this.oMeasureSrchResultContextMenu.IsVisible()){this.ShowContextMenu();}};CUISearchDlg.prototype.Unload=function(){Dom.RemoveAllChildren(this._vO);CUISearchDlg.superclass.Unload.call(this);};CUISearchDlg.prototype.ClearDlg=function(){var _MU=this.GetDiv();Dom.RemoveAllChildren(_MU);this._sn=null;this._ko=null;this._ti=null;this._lq=null;this._pt=null;this._rH=null;this._t2=null;this._lY=false;this._bH=false;this._qu=CUISearchDlg.eStateNormal;this._qn=CUISearchDlg.eSrchResultStateIdle;if(this._lF){this._lF.Unload();this._lF=null;}if(this._w8){this._w8.Unload();this._w8=null;}if(this._tE){Dom.RemoveObject(this._tE);}this._tE=null;Utilities.DeleteAllFromArray(this._d7);if(this._jJ){Utilities.DeleteAllFromArray(this._jJ);}this._ux=true;this._co=null;this._pm=true;if(this.oDialogMgr&&this.oDialogMgr.oUIMgr){this.oDialogMgr.oUIMgr._qi._ob.UnSubscribe(this,ExpEvent.kCDLMetadata_FullLineage);this.oDialogMgr.oUIMgr._qi._ob.UnSubscribe(this,ExpEvent.kCDLMetadata_WaitLineage);}};CUISearchDlg.prototype.CreateResultTable=function(){this._tE=document.createElement('TABLE');this._tE.className='pagerCtrlTBL';COTStyle.SetWidth(this._tE,100,'%');this._ko.appendChild(this._tE);this._ed=document.createElement('TBODY');this._tE.appendChild(this._ed);var _1P=document.createElement('TR');this._ed.appendChild(_1P);var _ang=this._yk.cloneNode(false);_1P.appendChild(_ang);COTStyle.SetWidth(_ang,40,'%');var _apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_RESULTS_NAME'));_ang.appendChild(_apS);var _Ke=this.sAppName;var _adH=Utilities.GenerateCallback(this.ToggleSortByName,[],this);_apS=COTInputElementFactory.CreateImage('list_sort_no.gif',15,15,_adH);_apS.id=Utilities.GenerateId();this._l8=_apS.id;_ang.appendChild(_apS);_1M=this._xD.cloneNode(false);_1P.appendChild(_1M);COTStyle.SetWidth(_1M,60,'%');_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_RESULTS_PATH'));_1M.appendChild(_apS);var _aBT=Utilities.GenerateCallback(this.ToggleSortByPath,[],this);_apS=COTInputElementFactory.CreateImage('list_sort_no.gif',15,15,_aBT);_apS.id=Utilities.GenerateId();this._pq=_apS.id;_1M.appendChild(_apS);var _T6=COTStyle.GetDisplayOffsetHeight(this._sn);var _LV=COTStyle.GetVerticalPaddingHeight(this._sn);var _aDL=COTStyle.GetVerticalPaddingHeight(this._sn);COTStyle.SetHeight(this._ko,_T6-_LV-_aDL,'px');if(!this._lY){this.HidePath();}};CUISearchDlg.prototype.RemoveResultTable=function(){if(this._tE){Dom.RemoveObject(this._tE);this._tE=null;}};CUISearchDlg.ItemTypeImgArr=new Object();CUISearchDlg.ItemTypeImgArr[ExpAPIXml.eMember]='member.gif';CUISearchDlg.ItemTypeImgArr[ExpAPIXml.eMeasure]='measure.gif';CUISearchDlg.ItemTypeImgArr[CUISearchDlg.kNonAggreMeasure]='Non-aggregated_measure.gif';CUISearchDlg.prototype.AddMsgToResultTable=function(_BK,_PA){this.RemoveResultTable();Dom.RemoveAllChildren(this._ko);var _arg=document.createElement('SPAN');_arg.className='infoLabel';if(_PA){var _apS=COTInputElementFactory.CreateImage('state_warning.gif',11,16);_arg.appendChild(_apS);}_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString(_BK));_arg.appendChild(_apS);this._h1=_arg;this._ko.appendChild(_arg);};CUISearchDlg.prototype.ShowFailureDetails=function(){if(!this._h1){this._h1=document.createElement('SPAN');this._h1.className='infoLabel';}else{Dom.RemoveAllChildren(this._h1);}var _apS=COTInputElementFactory.CreateImage('state_warning.gif',11,16);this._h1.appendChild(_apS);if(this._gs.length==1){var _0T=this.oRes.ReplaceParam('IDS_FAILED_SRCH_IN_ONE_METAOBJ',1,this._gs[0].GetLabel());_apS=COTInputElementFactory.CreateLabel(_0T);}else{var _1t=new Array();for(var x=0;x<this._gs.length;x++){_1t[x]=this._gs[x].GetLabel();}var _0T=this.oRes.ReplaceParamList('IDS_FAILED_SRCH_IN_MULTI_METAOBJS',_1t);_0T=this.oRes.ReplaceParam('IDS_FAILED_SRCH_IN_ONE_METAOBJ',1,_0T);_apS=COTInputElementFactory.CreateLabel(_0T);}this._h1.appendChild(_apS);if(this._tE){this._ko.insertBefore(this._h1,this._tE);}else{this._ko.appendChild(this._h1);}};CUISearchDlg.prototype.ShowIncompleteSearchDetails=function(){if(!this._h1){this._h1=document.createElement('SPAN');this._h1.className='infoLabel';}else{Dom.RemoveAllChildren(this._h1);}var _apS=COTInputElementFactory.CreateImage('msg_information_16.gif',16,16);this._h1.appendChild(_apS);if(this._cF.length==1){var _0r=this.oRes.ReplaceParam('IDS_INCOMPLETE_SRCH_IN_ONE_METAOBJ',1,this._cF[0].GetLabel());_apS=COTInputElementFactory.CreateLabel(_0r);}else{var _1t=new Array();for(var x=0;x<this._cF.length;x++){_1t[x]=this._cF[x].GetLabel();}var _0r=this.oRes.ReplaceParamList('IDS_INCOMPLETE_SRCH_IN_MULTI_METAOBJS',_1t);_0r=this.oRes.ReplaceParam('IDS_INCOMPLETE_SRCH_IN_ONE_METAOBJ',1,_0r);_apS=COTInputElementFactory.CreateLabel(_0r);}this._h1.appendChild(_apS);if(this._tE){this._ko.insertBefore(this._h1,this._tE);}else{this._ko.appendChild(this._h1);}};CUISearchDlg.prototype.AddSearchResult=function(){this._mB=true;if(this._qn==CUISearchDlg.eSrchResultStateInit){this._fn=false;this._co=null;Dom.RemoveAllChildren(this._ko);this.CreateResultTable();this._qn=CUISearchDlg.eSrchResultStateContinue;if(this._d7){Utilities.DeleteAllFromArray(this._d7);}if(this._jJ){Utilities.DeleteAllFromArray(this._jJ);}this.ClearSelections();this._ux=true;this.EnableSelectAllLinks();}var _NH,_NM,_apS;if(this._qn==CUISearchDlg.eSrchResultStateContinue){var oMem;for(var i=0;i<this._rL._k8.length;i++){this._fn=true;oMem=this._rL._k8[i];_NH=this._o0.cloneNode(true);_NH.onmousedown=CUISearchDlg.SafeHandleMouseDown;Dom.SetObjRef(_NH,oMem,'oMem');if(oMem instanceof CDLMember){_NH.oMem._lW=ExpAPIXml.eMember;}else if(oMem instanceof CDLMeasure){_NH.oMem._lW=oMem.IsAggregateable()?ExpAPIXml.eMeasure:CUISearchDlg.kNonAggreMeasure;}if(this._ux){this._ux=this._co?COTValidation.MetaDataSelectValidation(oMem,this._co,this.oDialogMgr.oUIMgr._qi):true;this._co=oMem;if(!this._ux){this.DisableSelectAllLinks();}}Dom.SetObjRef(_NH,this,'oDialog');_NH.oncontextmenu=CUISearchDlg.SafeHandleContextMenu;this._d7[this._d7.length]=_NH;_apS=COTInputElementFactory.CreateLabel(oMem._p8);this.setTooltipForSearchResult(_NH.firstChild,oMem);var _azP=COTInputElementFactory.CreateImage(CUISearchDlg.ItemTypeImgArr[_NH.oMem._lW],16,16);_NH.firstChild.appendChild(_azP);_NH.firstChild.appendChild(_apS);if(!this._bH){var _CB=!this._wF;var _aB4='IDS_SEARCH_DLG_PATH_LIST';if(oMem._qR){var _Az=oMem._qR.GetBreadCrumbText(_CB,_aB4);}else{var _Az=(oMem instanceof CDLMember)?oMem._re.GetBreadCrumbText(_aB4):oMem.GetDim().GetLabel();}_apS=COTInputElementFactory.CreateLabel(_Az);_NH.lastChild.appendChild(_apS);}this._ed.appendChild(_NH);this._tE.appendChild(this._ed);}if(!this._rL._v1){this._cF.push(this._bk[0]);}this.Notify(ExpEvent.kCDLSearchResult_Release);if(this._bH||(!this._lY)){this.HidePath();}Utilities.DeleteNthFromArray(this._bk,0);this._mB=false;if(this._kS){this._me=null;this.DoStopSearch();return;}/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_r){g_oSrch.StopTimer();}/*@end@*/this.FireSearch();if(this._qn==CUISearchDlg.eSrchResultStateComplete){if(!this._fn){this.AddMsgToResultTable('IDS_NO_SRCH_RESULT');}if(this._cF.length>0){this.ShowIncompleteSearchDetails();}this.SetToReadyState();}}};CUISearchDlg.prototype.setTooltipForSearchResult=function(el,oMem){el.title=oMem.GetLabel();};CUISearchDlg.prototype.SetToReadyState=function(){if(this._qu!=CUISearchDlg.eStateNormal){this._qu=CUISearchDlg.eStateNormal;this.Notify(ExpEvent.kCUISearchDlg_StateChange);if(this._lY){if(this._pm){this.ActivateShowPath();}else{var _Tc=this.oDialogMgr.oUIMgr.dataManager.metadata;_Tc._h8=false;_Tc.ManageLineageRequests();this.SetRetrievingPathFeedback();}}else{this.ActivateShowPath();}if(this._dP){this.ActivateSearchType();}}var _9K=this._ti.value;_9K=Utilities.GetTruncatedString(_9K,40,this.oRes,true);var _asi='IDS_RESULTS_FOUND_IN';_asi=this.oRes.ReplaceParam(_asi,1,_9K);_asi=this.oRes.ReplaceParam(_asi,2,this.GetSearchContextLabel());Dom.ReplaceText(this._pt,_asi);this._v9='';COTInputElementFactory.ResetToBaseButtonStyle(this._t2);COTInputElementFactory.ResetToBaseImgButtonStyle(this._rH);COTInputElementFactory.DisableInput(this._t2);COTInputElementFactory.SetButtonAnchorTextColor(this._t2,CUISearchDlg.sDisabledButtonAnchorColor);COTInputElementFactory.EnableInput(this._rH);this._qn=CUISearchDlg.eSrchResultStateIdle;this._qF=CUISearchDlg.kSortByName;this._f8=CUISearchDlg.eSrchRSNoSortState;this._rG=CUISearchDlg.eSrchRSNoSortState;if(this._gs.length>0){this.ShowFailureDetails();}Utilities.DeleteAllFromArray(this._gs);Utilities.DeleteAllFromArray(this._cF);this._me=null;this.ClearSelections();/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_r){_r.StopGlobalTimer();}/*@end@*/};CUISearchDlg.prototype.SetRetrievingPathFeedback=function(){this._nU=true;this.FreezeShowPath();this._eJ.removeChild(this._pt);if(!this._i3){this._i3=document.createElement('SPAN');this._i3.className='srchDlgResultItem';var _apS=COTInputElementFactory.CreateImage('icon_loading.gif',16,16);this._i3.appendChild(_apS);_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_SEARCHDLG_RETRIEVING_PATH'));this._i3.appendChild(_apS);}this._eJ.appendChild(this._i3);};CUISearchDlg.prototype.RemoveRetrievingPathFeedback=function(){if(this._nU){this._eJ.removeChild(this._i3);if(this._pt){this._eJ.appendChild(this._pt);}this._nU=false;}};CUISearchDlg.prototype.SetToBusyState=function(){if(this._qu!=CUISearchDlg.eStateBusy){this._qu=CUISearchDlg.eStateBusy;this.Notify(ExpEvent.kCUISearchDlg_StateChange);COTInputElementFactory.ResetToBaseButtonStyle(this._t2);COTInputElementFactory.ResetToBaseImgButtonStyle(this._rH);COTInputElementFactory.EnableInput(this._t2);COTInputElementFactory.SetButtonAnchorTextColor(this._t2,CUISearchDlg.sButtonAnchorColor);COTInputElementFactory.DisableInput(this._rH);this._qn=CUISearchDlg.eSrchResultStateInit;if(this._tE){this.ClearResultTable();}this._pm=true;this.RemoveRetrievingPathFeedback();if(!this._pt){this._pt=document.createElement('SPAN');this._pt.className='srchDlgResultItem';var _apS=COTInputElementFactory.CreateImage('icon_loading.gif',16,16);this._pt.appendChild(_apS);_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_SEARCHDLG_SEARCHING'));this._pt.appendChild(_apS);this._eJ.appendChild(this._pt);}else{var _apS=COTInputElementFactory.CreateImage('icon_loading.gif',16,16);this._pt.insertBefore(_apS,this._pt.firstChild);this._pt.style.display='inline';}}};CUISearchDlg.SafeHandleMouseDown=function(e){try{this.oDialog.HandleMouseDown(e);}catch(excep){_f.HandleException(excep);}};CUISearchDlg.prototype.HandleMouseDown=function(e){if(!e){var e=window.event;}var _N9=Dom.GetEventTarget(e);while(_N9.tagName!='TR'){_N9=_N9.parentNode;}this._yn=false;var _RM=_N9._qD;var _73=this._hz[this._hz.length-1];var _aBL=_73?COTValidation.MetaDataSelectValidation(_N9.oMem,_73.oMem,this.oDialogMgr.oUIMgr._qi):false;if(e.ctrlKey){if(_RM){this.ClearSelections(_N9._jw);return;}if(!_aBL){this.ClearSelections();}this.SelectItem(_N9);}else if(e.shiftKey){if(_aBL){var _ai6=this._jJ?this._jJ:this._d7;var _aF7=Utilities.GetObjIndex(_ai6,_N9);var _ad7=Utilities.GetObjIndex(_ai6,_73);for(var i=Math.min(_aF7,_ad7);i<=Math.max(_aF7,_ad7);i++){this.SelectItem(_ai6[i]);}}else{this.ClearSelections();this.SelectItem(_N9);}}else{if(!_RM){this.ClearSelections();this.SelectItem(_N9);}if(this.oDialogMgr.oUIMgr._jf.AllowInteraction()){CUIDragDropSource.HandleMouseDown(e,_N9,this);}var _aHz=(e.button==CUIDragDrop.rightMouseDown)&&_RM;this.bClrOldSel=_aHz?false:true;this.oClkItem=_N9;}};CUISearchDlg.prototype.SelectItem=function(_PM){_PM.className='srchDlgResultItemSelected';_PM._qD=true;if(!Utilities.IsInArray(this._hz,_PM)){this._hz[this._hz.length]=_PM;}_PM._jw=this._hz.length-1;};CUISearchDlg.prototype.ClearSelections=function(_NU){if(_NU>-1){this._hz[_NU]._qD=false;this._hz[_NU].className='srchDlgResultItem';Utilities.DeleteNthFromArray(this._hz,_NU);for(var i=0;i<this._hz.length;i++){this._hz[i]._jw=i;}}else{for(var i=0;i<this._hz.length;i++){this._hz[i].className='srchDlgResultItem';this._hz[i]._qD=false;this._hz[i]=null;}this._hz.length=0;}};CUISearchDlg.prototype.ClearResultTable=function(){Dom.RemoveAllChildren(this._ko);this._tE=null;};CUISearchDlg.prototype.SelectAllResult=function(){if(this._ed){this.ClearSelections();var _aIX=this._ed.childNodes;for(var i=1;i<_aIX.length;i++){_aIX[i].className='srchDlgResultItemSelected';_aIX[i]._qD=true;this._hz[this._hz.length]=_aIX[i];_aIX[i]._jw=this._hz.length-1;}}};CUISearchDlg.prototype.DeselectAllResult=function(){this.ClearSelections();};CUISearchDlg.prototype.ToggleShowPath=function(){if(this._lY){this._lY=false;}else{this._lY=true;}if(this._lY){if(this._pm){this.ShowPath();}else{var _Tc=this.oDialogMgr.oUIMgr.dataManager.metadata;_Tc._h8=false;_Tc.ManageLineageRequests();this.SetRetrievingPathFeedback();}}else{this.HidePath();}};CUISearchDlg.prototype.ShowPath=function(){if(this._tE){var _aIX=this._ed.childNodes;for(var i=0;i<_aIX.length;i++){if(_aIX[i].lastChild.childNodes.length==0){var oMem=_aIX[i].oMem;var _CB=!this._wF;var _aB4='IDS_SEARCH_DLG_PATH_LIST';if(oMem._qR){var _Az=oMem._qR.GetBreadCrumbText(_CB,_aB4);}else{var _Az=(oMem instanceof CDLMember)?oMem._re.GetBreadCrumbText(_aB4):oMem.GetDim().GetLabel();}_apS=COTInputElementFactory.CreateLabel(_Az);_aIX[i].lastChild.appendChild(_apS);}_aIX[i].lastChild.style.display="";_aIX[i].firstChild.colSpan=1;if(this._gT){COTStyle.SetWidth(_aIX[i].firstChild,this._gT,'px');COTStyle.SetWidth(_aIX[i].lastChild,this._eD-this._gT,'px');}}}};CUISearchDlg.prototype.HidePath=function(){if(this._tE){var _aIX=this._ed.childNodes;for(var i=0;i<_aIX.length;i++){if(this._eD==null){this._eD=COTStyle.GetDisplayOffsetWidth(_aIX[i]);this._gT=COTStyle.GetDisplayOffsetWidth(_aIX[i].firstChild);}_aIX[i].lastChild.style.display='none';_aIX[i].firstChild.colSpan=2;COTStyle.SetWidth(_aIX[i].firstChild,this._eD,'px');}}};CUISearchDlg.prototype.FreezeShowPath=function(){var _anN=document.getElementsByName('showPath');Debug.Assert(_anN.length==1);var _aCs=_anN[0];COTInputElementFactory.DisableInput(_aCs);};CUISearchDlg.prototype.ActivateShowPath=function(){var _anN=document.getElementsByName('showPath');Debug.Assert(_anN.length==1);var _aCs=_anN[0];COTInputElementFactory.EnableInput(_aCs);if(this._lY){this.ShowPath();}this.RemoveRetrievingPathFeedback();};CUISearchDlg.prototype.ToggleAllDescSearch=function(){if(this._bH){this._bH=false;this.oDialogMgr.oUIMgr._qi._ob.UnSubscribe(this,ExpEvent.kCDLMetadata_WaitLineage);}else{this._bH=true;this.oDialogMgr.oUIMgr._qi._ob.Subscribe(this,ExpEvent.kCDLMetadata_WaitLineage);}};CUISearchDlg.prototype.FreezeSearchType=function(){var _anN=document.getElementsByName('alldescsearch');Debug.Assert(_anN.length==1);var _aCs=_anN[0];COTInputElementFactory.DisableInput(_aCs);};CUISearchDlg.prototype.ActivateSearchType=function(){var _anN=document.getElementsByName('alldescsearch');Debug.Assert(_anN.length==1);var _aCs=_anN[0];COTInputElementFactory.EnableInput(_aCs);};CUISearchDlg.prototype.DisableSelectAllLinks=function(){var _Cf=document.getElementById(this._fG);COTInputElementFactory.DisableLink(_Cf);_Cf=document.getElementById(this._wH);COTInputElementFactory.DisableLink(_Cf);};CUISearchDlg.prototype.EnableSelectAllLinks=function(){var _Cf=document.getElementById(this._fG);COTInputElementFactory.EnableLink(_Cf);_Cf=document.getElementById(this._wH);COTInputElementFactory.EnableLink(_Cf);};CUISearchDlg.prototype.UpdateSortingImage=function(){var _awH=document.getElementById(this._l8);var _aGo=document.getElementById(this._pq);var _34=Utilities.IMG_PATH;var _auj=(this._qF==CUISearchDlg.kSortByName)?this._f8:this._rG;switch(_auj){case CUISearchDlg.eSrchRSNoSortState:_34+='list_sort_no.gif';break;case CUISearchDlg.eSrchRSAscendSortState:_34+='list_sort_ascending.gif';break;case CUISearchDlg.eSrchRSDescendSortState:_34+='list_sort_descending.gif';break;}if(this._qF==CUISearchDlg.kSortByName){_aGo.src=Utilities.IMG_PATH+'list_sort_no.gif';this._rG=CUISearchDlg.eSrchRSNoSortState;_awH.src=_34;}else{_awH.src=Utilities.IMG_PATH+'list_sort_no.gif';this._f8=CUISearchDlg.eSrchRSNoSortState;_aGo.src=_34;}};CUISearchDlg.prototype.UpdateSortedResultTable=function(_Kc){this.UpdateSortingImage();for(var j=this._ed.childNodes.length-1;j>=1;j--){this._ed.removeChild(this._ed.childNodes[j]);}for(var i=0;i<_Kc.length;i++){this._ed.appendChild(_Kc[i]);}};CUISearchDlg.prototype.ToggleSortState=function(_At){var _acS=Utilities.GetObjIndex(CUISearchDlg.SortStateArray,_At);var _Bz=(_acS==(CUISearchDlg.SortStateArray.length-1))?0:_acS+1;return CUISearchDlg.SortStateArray[_Bz];};CUISearchDlg.prototype.SortByState=function(_Uc){if(this._qu!=CUISearchDlg.eStateNormal){return;}var _alA=new Array();var _abK=new Object();for(var i=0;i<this._d7.length;i++){var _BM='';if(this._qF==CUISearchDlg.kSortByName){_BM=this._d7[i].oMem.GetLabel();}else{var oMem=this._d7[i].oMem;if(!oMem.IsRootMember()){_BM=oMem._qR.GetBreadCrumbText();}else{_BM=(oMem instanceof CDLMember)?oMem._re.GetBreadCrumbText():oMem.GetDim().GetLabel();}}var _aqq=(_abK[_BM]!=null)?_abK[_BM]:new Array();_aqq.push(i);_abK[_BM]=_aqq;_alA[i]=_BM;}var _YY=new Array();var _acY=_alA;switch(_Uc){case CUISearchDlg.eSrchRSNoSortState:break;case CUISearchDlg.eSrchRSAscendSortState:var _aI2=new Array();var _acY=_alA.sort();break;case CUISearchDlg.eSrchRSDescendSortState:var _acY=_alA.sort(reverseSort);break;}for(var j=0;j<_acY.length;j++){var _aF6=_acY[j];var _ake=_abK[_aF6];Debug.Assert(_ake[0]!=null);_YY[j]=this._d7[_ake[0]];Utilities.DeleteNthFromArray(_ake,0);}this.UpdateSortedResultTable(_YY);if(this._jJ){Utilities.DeleteAllFromArray(this._jJ);}this._jJ=Utilities.CopyArray(_YY);};CUISearchDlg.prototype.IsResultInsertable=function(){return this._ux;};CUISearchDlg.prototype.ToggleSortByName=function(){this._qF=CUISearchDlg.kSortByName;this._f8=this.ToggleSortState(this._f8);this.SortByState(this._f8);};CUISearchDlg.prototype.ToggleSortByPath=function(){this._qF=CUISearchDlg.kSortByPath;this._rG=this.ToggleSortState(this._rG);var _ay9=false;this.SortByState(this._rG,_ay9);};CUISearchDlg.SafeDoToggleSortByName=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager.oDialogMgr._jg.ToggleSortByName();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUISearchDlg.SafeHandleContextMenu=function(e){try{if(!e){var e=window.event;}this.oDialog.ShowContextMenu(e,this);}catch(e){_f.HandleException(e);}};CUISearchDlg.prototype.ShowContextMenu=function(e,_Wp){if(_Wp){this.oLastSel=_Wp;}else{var _Wp=this.oLastSel;}if(e){this._iZ=Dom.CloneMouseEvent(e);}else{var e=this._iZ;}this.SelectItem(_Wp);var _Zw=_Wp.oMem;var _C9=new Array();for(var i=0;i<this._hz.length;i++){_C9.push(this._hz[i].oMem._ks);}var _FD=this.oDialogMgr.oUIMgr._jf.GetIncludeDetailFlag();if(_Zw instanceof CDLMember){for(var y=0;y<this.oMemberSrchResultContextMenu.items.length;y++){var _7t=this.oMemberSrchResultContextMenu.items[y];var _amV=_7t instanceof ContextItem;if(_amV){CUIMetadataTree.SetBaseMemCntxMenuParameters(this.sAppName,_7t,_Zw,_C9,_FD);}}this.oMemberSrchResultContextMenu.display(e);}else if(_Zw instanceof CDLMeasure){CUIMetadataTree.SetMeasureCntxMenuParameters(this.sAppName,this.oMeasureSrchResultContextMenu,_Zw,this.oDialogMgr.oUIMgr._jf,null,_C9);this.oMeasureSrchResultContextMenu.display(e);}};CUISearchDlg.prototype.OnDragStart=function(e){var _C9=new Array();var _Rv=new Array();var _Tc=this.oDialogMgr.oUIMgr._qi._ob;for(var i=0;i<this._hz.length;i++){var _HY=this._hz[i].oMem._ks;_C9.push(_HY);var _67=_Tc.GetOrphanAncestor(_HY);if(_67&&(!Utilities.IsInArray(_Rv,_67))){_Rv.push(_67);}}var _Lv=null;var _FD=this.oDialogMgr.oUIMgr._jf.GetIncludeDetailFlag();if(_C9.length==1){_Lv=new CUIDragDropMember(_C9[0],_FD);}else{_Lv=new CUIDragDropMemberList(_C9,false);}if(_Rv.length>0&&_Lv.SetOrphanAncestorArr){_Lv.SetOrphanAncestorArr(_Rv);}if(Utilities.GetObjArrayLength(this._hz)>1){this.oDialogMgr.oUIMgr._jf.DisableIncludeDetailFlag();}else{this.oDialogMgr.oUIMgr._jf.EnableIncludeDetailFlag();}this._yn=true;var _QX=new Array();var _Bu=new Array();for(var i=0;i<this._hz.length;i++){_QX.push(CUISearchDlg.ItemTypeImgArr[this._hz[i].oMem._lW]);_Bu.push(this._hz[i].oMem._p8);}CUIDragDrop.Start(this,this.oDialogMgr.oUIMgr,_Lv,CUIDragDrop.eEffectNone,e);CUIDragDrop.SetTooltipItems(_QX,_Bu);CUIDragDrop.ShowTooltip(e.clientX,e.clientY);};CUISearchDlg.prototype.OnDragEnd=function(e){if(!this._yn){if(this.bClrOldSel){this.ClearSelections();this.SelectItem(this.oClkItem);}}this._yn=false;};function CUIMissingSearchDlg(){this.base=CUISearchDlg;this.base();};CUIMissingSearchDlg.prototype=new CUISearchDlg;CUIMissingSearchDlg.superclass=CUISearchDlg.prototype;CUIMissingSearchDlg.prototype.OnDragStart=function(e){var _C9=new Array();for(var i=0;i<this._hz.length;i++){_C9.push(this._hz[i].oMem._ks);}var _Lv=null;var _FD=this.oDialogMgr.oUIMgr._jf.GetIncludeDetailFlag();if(_C9.length==1){_Lv=new CUIDragDropMember(_C9[0],_FD);}else{_Lv=new CUIDragDropMemberList(_C9,false);}if(Utilities.GetObjArrayLength(this._hz)>1){this.oDialogMgr.oUIMgr._jf.DisableIncludeDetailFlag();}else{this.oDialogMgr.oUIMgr._jf.EnableIncludeDetailFlag();}this._yn=true;var _QX=new Array();var _Bu=new Array();for(var i=0;i<this._hz.length;i++){_QX.push(CUISearchDlg.ItemTypeImgArr[this._hz[i].oMem._lW]);_Bu.push(this._hz[i].oMem._ks);}CUIDragDrop.Start(this,this.oDialogMgr.oUIMgr,_Lv,CUIDragDrop.eEffectNone,e);CUIDragDrop.SetTooltipItems(_QX,_Bu);CUIDragDrop.ShowTooltip(e.clientX,e.clientY);};CUIMissingSearchDlg.prototype.setTooltipForSearchResult=function(el,oMem){el.title=oMem.GetId();};CUIMissingSearchDlg.prototype.HandleMouseDown=function(e){if(!e){var e=window.event;}var _N9=Dom.GetEventTarget(e);while(_N9.tagName!='TR'){_N9=_N9.parentNode;}this._yn=false;var _RM=_N9._qD;var _73=this._hz[this._hz.length-1];var _aBL=false;if(e.ctrlKey){if(_RM){this.ClearSelections(_N9._jw);return;}if(!_aBL){this.ClearSelections();}this.SelectItem(_N9);}else if(e.shiftKey){if(_aBL){var _ai6=this._jJ?this._jJ:this._d7;var _aF7=Utilities.GetObjIndex(_ai6,_N9);var _ad7=Utilities.GetObjIndex(_ai6,_73);for(var i=Math.min(_aF7,_ad7);i<=Math.max(_aF7,_ad7);i++){this.SelectItem(_ai6[i]);}}else{this.ClearSelections();this.SelectItem(_N9);}}else{if(!_RM){this.ClearSelections();this.SelectItem(_N9);}CUIDragDropSource.HandleMouseDown(e,_N9,this);var _aHz=(e.button==CUIDragDrop.rightMouseDown)&&_RM;this.bClrOldSel=_aHz?false:true;this.oClkItem=_N9;}};CUIMissingSearchDlg.prototype.InitContextMenu=function(){CUIMissingMetadataTree.SetBaseMemberActionMenu(this.sAppName,this.oMemberSrchResultContextMenu,false,true);this.oMemberSrchResultContextMenu.SetChildrenComplete();CUIMissingMetadataTree.SetBaseMemberActionMenu(this.sAppName,this.oMeasureSrchResultContextMenu,false,false);this.oMeasureSrchResultContextMenu.SetChildrenComplete();};CUIMissingSearchDlg.prototype.ShowContextMenu=function(e,_Wp){if(_Wp){this.oLastSel=_Wp;}else{var _Wp=this.oLastSel;}if(e){this._iZ=Dom.CloneMouseEvent(e);}else{var e=this._iZ;}this.ClearSelections();this.SelectItem(_Wp);var _Zw=_Wp.oMem;var _C9=new Array();for(var i=0;i<this._hz.length;i++){if(this._hz[i].oMem!=_Zw){_C9.push(this._hz[i].oMem._ks);}}var _FD=this.oDialogMgr.oUIMgr._jf.GetIncludeDetailFlag();if(_Zw instanceof CDLMember){for(var y=0;y<this.oMemberSrchResultContextMenu.items.length;y++){var _7t=this.oMemberSrchResultContextMenu.items[y];var _amV=_7t instanceof ContextItem;if(_amV){CUIMissingMetadataTree.SetCntxMenuParameters(this.sAppName,_7t,_Zw,_C9,_FD);}}this.oMemberSrchResultContextMenu.display(e);}else if(_Zw instanceof CDLMeasure){CUIMissingMetadataTree.SetCntxMenuParameters(this.sAppName,this.oMeasureSrchResultContextMenu,_Zw,this.oDialogMgr.oUIMgr._jf,null,_C9);this.oMeasureSrchResultContextMenu.display(e);}};CUIMissingSearchDlg.prototype.drawSelectionLinks=function(_NH){};CUIMissingSearchDlg.prototype.DisableSelectAllLinks=function(){};CUIMissingSearchDlg.prototype.EnableSelectAllLinks=function(){};function reverseSort(a,b){if(a>b){return-1;}if(a<b){return 1;}return 0;};function CUIDescriptiveStatsDlg(_IC,_zz,_OA,_KW,_V7,_FK,_M3){this.base=CUIDialog;this.base();if(!_M3){_zz.SetSelection(_V7);}this.bInvalidSel=_M3;this.title=_zz.GetLabel();this.properties=_zz.GetProperties();this.oUIManager=_IC;this.kType=_OA;this.aOptions=_KW;this.CUIDescriptiveStatsObj=_zz;this._oEventTriggers=new Object();this._oEventTriggers[ExpEvent.kCUIComboBox_OnSelChange]=new Object();this._oEventTriggers[ExpEvent.kCUIComboBox_OnSelection]=new Object();this.Selection=_zz.selection;};CUIDescriptiveStatsDlg.prototype=new CUIDialog;CUIDescriptiveStatsDlg.superclass=CUIDialog.prototype;CUIDescriptiveStatsDlg.prototype.SyncValues=function(_zx,_DE){if(_zx=="text"){_DE['value']=_DE.elem.value;}else if(_zx=="boolean"){_DE['value']=_DE.elem.checked;}else if(_zx=="listview"){_DE['value']=(_DE.value)?(_DE.value):_DE.elem.checked;}else if(_zx=="list"){_DE['value']=_DE.elem.GetValue();var x=_DE.elem;}else if(_zx=="radio"){if(_DE.elem.checked){_DE['value']=true;}else{_DE['value']=false;}}};CUIDescriptiveStatsDlg.prototype.CheckDefaultValue=function(_PK){if(_PK.value){return _PK.value;}return false;};CUIDescriptiveStatsDlg.prototype.GenerateRequest=function(_Ke,_OA,_KW){for(var i=0;i<this.properties.length;i++){var _zx=this.properties[i].type;if(_zx=="listview"){var _alD=this.properties[i].listView.listItems.listItem;for(var j=0;j<_alD.length;j++){this.SyncValues(_zx,_alD[j]);}}else{this.SyncValues(_zx,this.properties[i]);}}CUIDialogMgr.SafeHideCurrentDialog(this.sAppName);CUIWorkSheet.SafeDescriptiveStatsRequest(_Ke,_OA,_KW);};CUIDescriptiveStatsDlg.prototype.SetSelection=function(_TX){var _ap4=this.oDialogMgr.oUIMgr._jf.GetUIAxesContainer();if(!_TX){Debug.Assert(_ap4._hL);this._rK=_ap4._hL._az;}else{this._rK=_TX;}this._tD=_ap4.GetOppositeAxis(this._rK.GetUIAxis());this._rB=this._rK._cu;this._mR=this.oDialogMgr.oUIMgr.dataManager.metadata;};CUIDescriptiveStatsDlg.prototype.Create=function(){var _Ke=this.sAppName;this.elTBL=document.createElement("table");COTStyle.SetHeight(this.elTBL,150);this.elTBL.className='dialogTable';var _F0=document.createElement("tbody");if(this.kType=="Curve Estimation"||this.kType=="Curve Estimation Independent"||this.kType=="Curve Estimation Cases"){this.createCurveEstimationDlg(_F0);}else if(this.kType=="Descriptive Statistics"){this.createDataDistributionDlg(_F0);}else{this.createDialog(_F0);}this._Y=Utilities.GenerateCallback(this.GenerateRequest,[_Ke,this.kType,this.aOptions],this);};CUIDescriptiveStatsDlg.prototype.createDataDistributionDlg=function(_F0){var _NH=document.createElement("tr");var _ab1=document.createElement("td");var _ai8=document.createElement("td");var _aAZ=document.createElement("td");var _aAq=document.createElement("td");var _ada=document.createElement("table");COTStyle.SetWidth(_ada,250);COTStyle.SetHeight(_ada,150);var _alv=document.createElement("tbody");var _asB=document.createElement("table");COTStyle.SetWidth(_asB,250);COTStyle.SetHeight(_asB,150);var _2Q=document.createElement("tbody");var _abl=document.createElement("table");COTStyle.SetWidth(_abl,250);var _axn=document.createElement("tbody");if(this.Selection){var _aph=document.createElement("table");COTStyle.SetWidth(_aph,100);var _ahH=document.createElement("tbody");}if(this.Selection){var td=this._l4.cloneNode(false);td.innerHTML="Selected Columns";var _ax2=document.createElement('tr');_ax2.appendChild(td);_ahH.appendChild(_ax2);var _ale=this.Selection._us;for(var c=0;c<_ale.length;c++){var _Eq=_ale[c];var _10=document.createElement("tr");var _Bj=_Eq._f1.GetLabel();var _13=document.createElement("td");var _avI=document.createElement("span");_avI.appendChild(document.createTextNode(_Bj));_13.className='infoLabel';_13.appendChild(_avI);_10.appendChild(_13);_ahH.appendChild(_10);}}var _adv=0;for(var i=0;i<this.properties.length;i++){var _zx=this.properties[i].type;var _adh=(this.properties[i].padding)?this.properties[i].padding:"0px";var _Cs=(this.properties[i].col)?this.properties[i].col:"right";if(_zx=="listview"){}else if(_zx=="label"){var tr=document.createElement("tr");var td=document.createElement("td");td.className='infoLabel';var _atI=document.createTextNode(this.properties[i].label);this.properties[i].elem=_atI;var _avI=document.createElement("span");_avI.appendChild(_atI);_avI.appendChild(document.createTextNode(this.properties[i].label));td.appendChild(_avI);if(_adh){_avI.style.paddingLeft=_adh;}tr.appendChild(td);if(_Cs=="left"){_alv.appendChild(tr);}else if(_Cs=="middle"){_2Q.appendChild(tr);}else{_axn.appendChild(tr);}}else if(_zx=="boolean"){var tr=document.createElement("tr");var td=document.createElement("td");td.className='infoLabel';var _aIK=Utilities.GenerateCallback(this.SyncValues,['boolean',this.properties[i]],this);var _6I=this.CheckDefaultValue(this.properties[i]);var _atI=COTInputElementFactory.CreateCheckBox(this.properties[i].name,this.properties[i].label,_6I,null);this.properties[i].elem=_atI;var _avI=document.createElement("span");_avI.appendChild(_atI);_avI.appendChild(document.createTextNode(this.properties[i].label));td.appendChild(_avI);if(_adh){_avI.style.paddingLeft=_adh;}tr.appendChild(td);if(_Cs=="left"){_alv.appendChild(tr);}else if(_Cs=="middle"){_2Q.appendChild(tr);}else{_axn.appendChild(tr);}}else if(_zx=="radio"){var tr=document.createElement("tr");var td=document.createElement("td");td.className='infoLabel';var _aIK=Utilities.GenerateCallback(this.SyncValues,['boolean',this.properties[i]],this);var _6I=this.CheckDefaultValue(this.properties[i]);var _atI=COTInputElementFactory.CreateRadioButton(this.properties[i].name,this.properties[i].label,_6I,null);this.properties[i].elem=_atI;var _avI=document.createElement("span");_avI.appendChild(_atI);_avI.appendChild(document.createTextNode(this.properties[i].label));if(_adh){_avI.style.paddingLeft=_adh;}td.appendChild(_avI);tr.appendChild(td);if(_Cs=="left"){_alv.appendChild(tr);}else if(_Cs=="middle"){_2Q.appendChild(tr);}else{_axn.appendChild(tr);}}else if(_zx=="text"){var _FT=this.CheckDefaultValue(this.properties[i]);this.properties[i].elem=COTInputElementFactory.CreateTextBox(25,'px',_FT,false,null,null,null,this);var _avI=document.createElement("span");_avI.appendChild(document.createTextNode(this.properties[i].label));_avI.appendChild(this.properties[i].elem);_avI.appendChild(document.createTextNode(" %"));if(_adh){_avI.style.paddingLeft=_adh;}td=document.createElement("td");td.className='infoLabel';td.colSpan=3;td.appendChild(_avI);tr=document.createElement("tr");tr.appendChild(td);if(_Cs=="left"){_alv.appendChild(tr);}else if(_Cs=="middle"){_2Q.appendChild(tr);}else{_axn.appendChild(tr);}}else if(_zx=="list"){var _FT=this.CheckDefaultValue(this.properties[i]);var _atI=document.createElement('div');var _alD=this.properties[i].listView.listItems.listItem;var oListCtrl=new CUIListCtrl(this.oUIManager);oListCtrl.iMaxHeight=150;oListCtrl.Init();var _RM=false;var _LX;for(var j=0;j<_alD.length;j++){if(_FT==_alD[j].value)_RM=true;_LX=oListCtrl.AddItem('',_alD[j].label,0,_alD[j].value,"",_RM);}var oComboBox=new CUIComboBox(this.oUIManager,oListCtrl);oComboBox.DisableIcon();this.properties[i].combobox=oComboBox;var _aHv=Utilities.GenerateCallback(this.SyncValues,['list',this.properties[i]],this);this._oEventTriggers[ExpEvent.kCUIComboBox_OnSelChange][oComboBox.GetId()]=_aHv;oComboBox.Subscribe(this,ExpEvent.kCUIComboBox_OnSelChange);_atI.appendChild(oComboBox.Init());if(_RM){oComboBox.SetValueFromListItem(_LX,true,true);}oComboBox.SetWidth(150,'px');this.properties[i].elem=oComboBox;var _avI=document.createElement("div");if(_adh){_avI.style.paddingLeft=_adh;}_avI.appendChild(document.createTextNode(this.properties[i].label));_avI.appendChild(_atI);td=document.createElement("td");td.className='infoLabel';td.colSpan=3;td.appendChild(_avI);tr=document.createElement("tr");tr.appendChild(td);if(_Cs=="left"){_alv.appendChild(tr);}else if(_Cs=="middle"){_2Q.appendChild(tr);}else{_axn.appendChild(tr);}}}if(this.Selection)_aph.appendChild(_ahH);_ada.appendChild(_alv);_asB.appendChild(_2Q);_abl.appendChild(_axn);_aAZ.className='infoLabel';_ab1.className='infoLabel';_ai8.className='infoLabel';_aAq.className='infoLabel';_aAZ.className+=' vAlign_top';_ab1.className+=' vAlign_top';_aAq.className+=' vAlign_top';_ai8.className+=" vAlign_top";_aAZ.appendChild(_ada);_ai8.appendChild(_asB);_ab1.appendChild(_abl);if(this.Selection)_aAq.appendChild(_aph);_NH.appendChild(_aAZ);_NH.appendChild(_ai8);_NH.appendChild(_ab1);if(this.Selection)_NH.appendChild(_aAq);_F0.appendChild(_NH);COTStyle.SetWidth(this.elTBL,50,'%');this.elTBL.appendChild(_F0);this._iG="IDS_BUTTON_OK";};CUIDescriptiveStatsDlg.prototype.createCurveEstimationDlg=function(_F0){var _NH=document.createElement("tr");var _ab1=document.createElement("td");var _aAZ=document.createElement("td");var _aAq=document.createElement("td");var _ada=document.createElement("table");COTStyle.SetWidth(_ada,350);COTStyle.SetHeight(_ada,150);var _alv=document.createElement("tbody");var _abl=document.createElement("table");COTStyle.SetWidth(_abl,200);var _axn=document.createElement("tbody");if(this.Selection){var _aph=document.createElement("table");COTStyle.SetWidth(_aph,100);var _ahH=document.createElement("tbody");}var td=this._l4.cloneNode(false);td.innerHTML="Models";td.colSpan=3;var _10=document.createElement('tr');_10.appendChild(td);_alv.appendChild(_10);var td=this._l4.cloneNode(false);td.innerHTML="Options";var _aoE=document.createElement('tr');_aoE.appendChild(td);_axn.appendChild(_aoE);if(this.Selection){var td=this._l4.cloneNode(false);td.innerHTML="Selected Columns";var _ax2=document.createElement('tr');_ax2.appendChild(td);_ahH.appendChild(_ax2);var _ale=this.Selection._us;for(var c=0;c<_ale.length;c++){var _Eq=_ale[c];var _10=document.createElement("tr");var _Bj=_Eq._f1.GetLabel();var _13=document.createElement("td");var _avI=document.createElement("span");_avI.appendChild(document.createTextNode(_Bj));_13.className='infoLabel';_13.appendChild(_avI);_10.appendChild(_13);_ahH.appendChild(_10);}}var _adv=0;for(var i=0;i<this.properties.length;i++){var _zx=this.properties[i].type;if(_zx=="listview"){var _alD=this.properties[i].listView.listItems.listItem;var _aos=Math.ceil(_alD.length/3);var _7P=0;for(var j=0;j<_aos;j++){var _10=document.createElement("tr");for(var k=0;k<3;k++){var l=_alD[_7P];if(l){var _13=document.createElement("td");var _aIK=Utilities.GenerateCallback(this.SyncValues,['listview',l],this);var _6I=this.CheckDefaultValue(l);var _atI=COTInputElementFactory.CreateCheckBox(l.name,l.label,_6I,_aIK);l['elem']=_atI;var _avI=document.createElement("span");_avI.appendChild(_atI);_avI.appendChild(document.createTextNode(l.label));_13.className='infoLabel';_13.appendChild(_avI);_13.id=l.label;_10.appendChild(_13);_7P++;}}_alv.appendChild(_10);}_ada.appendChild(_alv);}else if(_zx=="boolean"){var _aoE=document.createElement("tr");var td=document.createElement("td");td.className='infoLabel';var _aIK=Utilities.GenerateCallback(this.SyncValues,['boolean',this.properties[i]],this);var _6I=this.CheckDefaultValue(this.properties[i]);var _atI=COTInputElementFactory.CreateCheckBox(this.properties[i].name,this.properties[i].label,_6I,null);this.properties[i].elem=_atI;var _avI=document.createElement("span");_avI.appendChild(_atI);_avI.appendChild(document.createTextNode(this.properties[i].label));td.appendChild(_avI);_aoE.appendChild(td);_axn.appendChild(_aoE);}else if(_zx=="text"){var _FT=this.CheckDefaultValue(this.properties[i]);this.properties[i].elem=COTInputElementFactory.CreateTextBox(204,'px',_FT,false,null,null,null,this);var _avI=document.createElement("span");_avI.appendChild(document.createTextNode(this.properties[i].label));_avI.appendChild(this.properties[i].elem);_13=document.createElement("td");_13.className='infoLabel';_13.colSpan=3;_13.appendChild(_avI);_10=document.createElement("tr");_10.appendChild(_13);_alv.appendChild(_10);}}if(this.Selection)_aph.appendChild(_ahH);_abl.appendChild(_axn);_aAZ.className='infoLabel';_ab1.className='infoLabel';_aAq.className='infoLabel';_aAZ.className+=' vAlign_top';_ab1.className+=' vAlign_top';_aAq.className+=' vAlign_top';_aAZ.appendChild(_ada);_ab1.appendChild(_abl);if(this.Selection)_aAq.appendChild(_aph);_NH.appendChild(_aAZ);_NH.appendChild(_ab1);if(this.Selection)_NH.appendChild(_aAq);_F0.appendChild(_NH);COTStyle.SetWidth(this.elTBL,50,'%');this.elTBL.appendChild(_F0);this._iG="IDS_BUTTON_OK";};CUIDescriptiveStatsDlg.prototype.createDialog=function(_F0){for(var i=0;i<this.properties.length;i++){var _zx=this.properties[i].type;var _NH=document.createElement("tr");var _ab1=document.createElement("td");var _aAZ=document.createElement("td");COTStyle.SetWidth(_aAZ,30,'%');switch(_zx){case 'boolean':var _aIK=Utilities.GenerateCallback(this.SyncValues,['boolean',this.properties[i]],this);var _6I=this.CheckDefaultValue(this.properties[i]);this.properties[i].elem=COTInputElementFactory.CreateCheckBox(this.properties[i].name,this.properties[i].label,_6I,null);_aAZ.colSpan=2;_aAZ.appendChild(this.properties[i].elem);_aAZ.appendChild(document.createTextNode(this.properties[i].label));break;case 'text':var _FT=this.CheckDefaultValue(this.properties[i]);this.properties[i].elem=COTInputElementFactory.CreateTextBox(204,'px',_FT,false,null,null,null,this);_ab1.appendChild(this.properties[i].elem);_aAZ.appendChild(document.createTextNode(this.properties[i].label));break;case 'listview':var _FT=this.CheckDefaultValue(this.properties[i]);var _atI=document.createElement('div');var _alD=this.properties[i].listView.listItems.listItem;var oListCtrl=new CUIListCtrl(this.oUIManager);oListCtrl.iMaxHeight=150;oListCtrl.Init();for(var j=0;j<_alD.length;j++){var _RM=false;if(_FT==_alD[j].value)_RM=true;oListCtrl.AddItem('',_alD[j].label,0,_alD[j].value,"",_RM);}var oComboBox=new CUIComboBox(this.oUIManager,oListCtrl);this.properties[i].combobox=oComboBox;var _aHv=Utilities.GenerateCallback(this.SyncValues,['listview',this.properties[i]],this);this._oEventTriggers[ExpEvent.kCUIComboBox_OnSelChange][oComboBox.GetId()]=_aHv;oComboBox.Subscribe(this,ExpEvent.kCUIComboBox_OnSelChange);_atI.appendChild(oComboBox.Init());oComboBox.SetWidth(200,'px');this.properties[i].elem=_atI;_ab1.appendChild(this.properties[i].elem);_aAZ.appendChild(document.createTextNode(this.properties[i].label));break;default:break;}_aAZ.className='infoLabel';_ab1.className='infoLabel';_NH.appendChild(_aAZ);_NH.appendChild(_ab1);_F0.appendChild(_NH);COTStyle.SetWidth(this.elTBL,50,'%');this.elTBL.appendChild(_F0);this._iG="IDS_BUTTON_OK";}};CUIDescriptiveStatsDlg.SafeDoGenerateRequest=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager.oDialogMgr._jg.GenerateRequest();/*@if(!@bering_debug)@*/}catch(excep){_f.HandleException(excep);}/*@end@*/};CUIDescriptiveStatsDlg.prototype.DisplayError=function(){var _MY=new Object();CUIDescriptiveStatsDlg.superclass.Display.call(this,this.title,_MY,null,'IDS_USER_DEF_CALCU_INSTRUCTION','IDS_CALC_DLG_NO_VALID_SELECTION');};CUIDescriptiveStatsDlg.prototype.Display=function(){this.Create();if(this.bInvalidSel==true){this.DisplayError();return;}_BK=false;var _MY=new Object();var _Ku=(this.properties.length>1)?"Please select the options:":"There are no options for this Statistics. Click OK to inset it.";CUIDescriptiveStatsDlg.superclass.Display.call(this,this.title,_MY,this.elTBL,_Ku,null,null);};function CUISortDlg(_H8){this.base=CUIDialog;this.base();this._aN=true;this.oHostBlock=null;this._iP=_H8?true:false;this._sX=false;};CUISortDlg.prototype=new CUIDialog;CUISortDlg.superclass=CUIDialog.prototype;CUISortDlg.kScope="scope";CUISortDlg.kAttribute="attribute";CUISortDlg.kLabel="label";CUISortDlg.kDefaultScope="0";CUISortDlg.kDefaultMeasure="0";CUISortDlg.prototype.IsInSaveMode=function(){return this._iP;};CUISortDlg.prototype.Init=function(_Hy,_Sb){CUISortDlg.superclass.Init.call(this,_Hy,_Sb);this.oDialogMgr.oUIMgr._jf.Subscribe(this,ExpEvent.kCUIWorksheet_ChangedBlockSel);};CUISortDlg.prototype.SetHostObj=function(_FK){this.oHostBlock=_FK;this.SetScopeOpts(this._M);var _Q1=this.oDialogMgr.oUIMgr._jf.GetUIAxesContainer().GetUIAxis(this.oHostBlock.oAxis._l7);var _ar1=this.oRes.GetString('IDS_SORT_DLG_SCOPE_'+_Q1.GetResourceSuffix());Dom.ReplaceText(this._ay,_ar1);this.SetMeasureOpts(this._mq);this.SetPropertyOpts(this._xF);var _agH=COTInputElementFactory.SelectRadioItem('radioOrder',_FK.GetSortType());if(_FK.IsExplicitSort()){this._sX=true;}else{this._sX=false;}if(_FK.GetSortMeasureOrMeasureCalc()&&(_FK.GetSortMeasureOrMeasureCalc()!=DefaultConstants.kDefMeasure)){var _9B=this._ej.GetItemByValue(_FK.GetSortMeasureOrMeasureCalc().GetId());if(!_9B){var _at9=_FK.GetSortMeasureOrMeasureCalc();var _BM=_at9.GetLabel();_9B=this._mq.oListCtrl.AddItem('',_BM,0,_at9.GetId(),_BM);}}else{var _9B=this._ej.GetItemByIndex(0);}this._mq.SetValueFromListItem(_9B);if(this._aN){if(_FK.GetSortProperty()){var _aJe=this._iO.GetItemByValue(_FK.GetSortProperty().GetId());COTInputElementFactory.SelectRadioItem('radioScope',CUISortDlg.kAttribute);}else{var _aJe=this._iO.GetItemByIndex(0);}this._xF.SetValueFromListItem(_aJe);}else{if(!this._dq){COTInputElementFactory.DisableRadioItem('radioScope',CUISortDlg.kAttribute);this._xF.Disable();}}if(_FK.IsSortByLabel()){COTInputElementFactory.SelectRadioItem('radioScope',CUISortDlg.kLabel);}if(this._kC){var _agP='';this._eB=this.oHostBlock.GetLabel();_agP=this.oRes.ReplaceParam('IDS_SORT_DLG_TITLE_WITH_SEPSTR',1,this._eB);this._kC.Update(_agP);}};CUISortDlg.prototype.Display=function(_M3){if(this._iP){this._yi=Utilities.GenerateCallback(this.DoSubmitSort,[],this);}else{this._Y=Utilities.GenerateCallback(this.DoSubmitSort,[],this);}var _Co=this.oDialogMgr.oUIMgr.appobj.oResources;var _Ke=this.sAppName;var _MY=new Object();var _Xf=Utilities.GenerateCallback(CUIManager.SafeDoHelpTopic,[_Ke,HelpConstants.kCustomSortLink]);_MY['IDS_HELP']=_Xf;if(_M3){var _Li=this.oDialogMgr.oUIMgr.dataManager.GetCurrentDataMatrix();var _W7=_Li.GetAllBlocksArray();var _Nk=new Array();for(var i=0;i<_W7.length;i++){if(_W7[i].CanSort()){_Nk.push(_W7[i]);}}var _aJh=false;this.DisplayInvalidSelection('IDS_SORT_DLG_TITLE',_MY,_Nk,_Li,'SORT',_aJh);}else{CUISortDlg.superclass.Display.call(this,'IDS_SORT_DLG_TITLE',_MY,this._vO,"");var _F4=COTStyle.GetWidthFromOffset(this._vO);this._mq.SetWidthByPX(_F4*0.6*0.8);this._M.SetWidthByPX(_F4*0.6*0.8);if(this._aN){this._xF.SetWidthByPX(_F4*0.6*0.8);this._xF.ResetEventHandlers();}this._mq.ResetEventHandlers();this._M.ResetEventHandlers();var _Ke=this.sAppName;}};CUISortDlg.prototype.Draw=function(){var _Ke=this.sAppName;var _zr=document.createElement('TABLE');COTStyle.SetHeight(_zr,150);this._vO=_zr;_zr.className='dialogTable';var _F0=document.createElement('TBODY');var _Rs=document.createElement('TR');_F0.appendChild(_Rs);var _ayr=document.createElement('TD');_ayr.className='sortOrderArea';_ayr.vAlign="top";COTStyle.SetWidth(_ayr,40,'%');_Rs.appendChild(_ayr);var _YA=document.createElement('TABLE');_ayr.appendChild(_YA);COTStyle.SetWidth(_YA,100,'%');var _8t=document.createElement('TBODY');_YA.appendChild(_8t);var _NH=document.createElement('TR');_8t.appendChild(_NH);var _NM=this._l4.cloneNode(false);_NM.colSpan=2;_NH.appendChild(_NM);var _apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_SORT_DLG_SORT_ORDER'));_NM.appendChild(_apS);_NH=document.createElement('TR');_8t.appendChild(_NH);_NM=this._g5.cloneNode(false);COTStyle.SetWidth(_NM,25,'px');COTStyle.SetHeight(_NM,20);var _88=COTInputElementFactory.CreateRadioButton('radioOrder',ExpAPIXml.kEleAxisOpExprSorttypeDefault,false);_NM.appendChild(_88);_NH.appendChild(_NM);_NM=this._g5.cloneNode(false);_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_SORT_DLG_NONE'));_NM.appendChild(_apS);_NH.appendChild(_NM);_NH=document.createElement('TR');_8t.appendChild(_NH);_NM=this._g5.cloneNode(false);COTStyle.SetWidth(_NM,25,'px');COTStyle.SetHeight(_NM,20);var _5m=COTInputElementFactory.CreateRadioButton('radioOrder',ExpAPIXml.kEleAxisOpExprSorttypeBottom,false);_NM.appendChild(_5m);_NH.appendChild(_NM);_NM=this._g5.cloneNode(false);_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_SORT_DLG_ASC_NUM'));this._hn=_NM;_NM.appendChild(_apS);_NH.appendChild(_NM);_NH=document.createElement('TR');_8t.appendChild(_NH);_NM=this._g5.cloneNode(false);COTStyle.SetWidth(_NM,25,'px');COTStyle.SetHeight(_NM,20);var _3H=COTInputElementFactory.CreateRadioButton('radioOrder',ExpAPIXml.kEleAxisOpExprSorttypeTop,false);_NM.appendChild(_3H);_NH.appendChild(_NM);_NM=this._g5.cloneNode(false);_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_SORT_DLG_DESC_NUM'));this._qr=_NM;_NM.appendChild(_apS);_NH.appendChild(_NM);var _ayr=document.createElement('TD');_ayr.className='sortOptionsArea';COTStyle.SetWidth(_ayr,65,'%');_Rs.appendChild(_ayr);var _aJj=document.createElement('TABLE');_ayr.appendChild(_aJj);COTStyle.SetWidth(_aJj,75,'%');var _asF=document.createElement('TBODY');_aJj.appendChild(_asF);_NH=document.createElement('TR');_asF.appendChild(_NH);var _NM=this._l4.cloneNode(false);_NM.colSpan=2;var _apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_SORT_DLG_SORT_OPTIONS'));_NM.appendChild(_apS);_NH.appendChild(_NM);_NH=document.createElement('TR');_asF.appendChild(_NH);_NM=this._g5.cloneNode(false);COTStyle.SetWidth(_NM,25,'px');COTStyle.SetHeight(_NM,20);var _Ss=false;var _85=Utilities.EventCallback(this.OnRadioClick,[],this,true,false);var _6P=COTInputElementFactory.CreateRadioButton('radioScope',CUISortDlg.kLabel,false,_Ss,_85);_NM.appendChild(_6P);_NH.appendChild(_NM);_NM=this._g5.cloneNode(false);_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_SORT_DLG_LABEL_SORT'));_NM.appendChild(_apS);_NH.appendChild(_NM);_NH=document.createElement('TR');_asF.appendChild(_NH);var _NM=this._g5.cloneNode(false);COTStyle.SetWidth(_NM,25,'px');COTStyle.SetHeight(_NM,20);var _Ss=false;var _ar0=COTInputElementFactory.CreateRadioButton('radioScope',CUISortDlg.kScope,true,_Ss,_85);_NM.appendChild(_ar0);_NH.appendChild(_NM);var _NM=_NH.appendChild(this._g5.cloneNode(false));_NM.appendChild(document.createTextNode(this.oRes.GetString('IDS_SORT_DLG_SCOPE')));this._ay=_NM;var _aeu=document.createElement('TR');_NM=_aeu.appendChild(document.createElement('TD'));this._on=new CUIListCtrl(this.oDialogMgr.oUIMgr);this._on.iMaxHeight=150;this._on.Init();this._on.DisableHAutoScroll();_NM=_aeu.appendChild(document.createElement('TD'));this._M=new CUIComboBox(this.oDialogMgr.oUIMgr,this._on);this._M.DisableIcon();var _afs=_NM.appendChild(this._M.Init());COTStyle.SetHeight(_aeu,COTStyle.GetDisplayOffsetHeight(_afs));_asF.appendChild(_aeu);_NH=document.createElement('TR');_asF.appendChild(_NH);var _NM=_NH.appendChild(this._g5.cloneNode(false));var _NM=_NH.appendChild(this._g5.cloneNode(false));_NM.appendChild(document.createTextNode(this.oRes.GetString('IDS_SORT_DLG_MEASURE_SORT')));var _03=document.createElement('TR');_NM=_03.appendChild(document.createElement('TD'));this._ej=new CUIListCtrl(this.oDialogMgr.oUIMgr);this._ej.iMaxHeight=150;this._ej.Init();this._ej.DisableHAutoScroll();_NM=_03.appendChild(document.createElement('TD'));this._mq=new CUIComboBox(this.oDialogMgr.oUIMgr,this._ej);this._mq.DisableIcon();var _afs=_NM.appendChild(this._mq.Init());this.SetMeasureOpts(this._mq);COTStyle.SetHeight(_03,COTStyle.GetDisplayOffsetHeight(_afs));_asF.appendChild(_03);_NH=document.createElement('TR');_asF.appendChild(_NH);_NM=this._g5.cloneNode(false);COTStyle.SetWidth(_NM,25,'px');COTStyle.SetHeight(_NM,20);var _Ss=false;sortAttributeRadio=COTInputElementFactory.CreateRadioButton('radioScope',CUISortDlg.kAttribute,false,_Ss,_85);_NM.appendChild(sortAttributeRadio);_NH.appendChild(_NM);_NM=this._g5.cloneNode(false);_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_SORT_DLG_ATTRIBUTE_SORT'));_NM.appendChild(_apS);_NH.appendChild(_NM);var _WW=document.createElement('TR');_NM=_WW.appendChild(document.createElement('TD'));this._iO=new CUIListCtrl(this.oDialogMgr.oUIMgr);this._iO.iMaxHeight=150;this._iO.Init();this._iO.DisableHAutoScroll();_NM=_WW.appendChild(document.createElement('TD'));this._xF=new CUIComboBox(this.oDialogMgr.oUIMgr,this._iO);this._xF.DisableIcon();var _afs=_NM.appendChild(this._xF.Init());COTStyle.SetHeight(_WW,COTStyle.GetDisplayOffsetHeight(_afs));_asF.appendChild(_WW);this._om=2;_zr.appendChild(_F0);this._lq=_zr;};CUISortDlg.prototype.FetchPropertiesOnFly=function(_RJ,_Mf){this._dD=_Mf;_RJ.FetchProperties(this._ev.GetIncompletePropOwner());_RJ.Subscribe(this._ev,ExpEvent.kCDLMetadata_Merge_Properties);this._ev.Subscribe(this,ExpEvent.kCOTPropsLoadingMgr_Merge_Complete);};CUISortDlg.prototype.UpdateAttributeLoadingMenu=function(){this._dq=false;if(this._dD){if(this._dD._xG){if(this._dD.oLastEvent){this._dD.hideDropDown(this._dD.oLastEvent);}this.SetPropertyOpts(this._dD);if(this._aN){if(this._dD.oLastEvent){this._dD.ShowDropDown(this._dD.oLastEvent);}}else{this._dD.Disable();COTInputElementFactory.DisableRadioItem('radioScope',CUISortDlg.kAttribute);COTInputElementFactory.SelectRadioItem('radioScope',CUISortDlg.kScope);}}this._dD.RemoveCallbackOnShowDropDown();}};CUISortDlg.prototype.SetPropertyOpts=function(_MX){var oListCtrl=_MX.oListCtrl;oListCtrl.ClearAllItems();_MX.ClearValue();var _Bq=this.oRes.GetString('IDS_SORT_DLG_NONE_ATTRIBUTE_DROP_DOWN_ITEM');this._ev=this.oHostBlock.GetAllDistinctProps();var _RJ=this.oDialogMgr.oUIMgr.dataManager.metadata;if(!this._ev.IsAllPropsRetrieved()){this._dq=true;var _LX=oListCtrl.AddItem('',_Bq,0,ContextItem.kNoneValue,_Bq);var _aJu=Utilities.GenerateCallback(this.FetchPropertiesOnFly,[_RJ,_MX],this);_MX.SetValueFromListItem(_LX);_MX.SetCallbackOnShowDropDown(_aJu);}else{_MX.RemoveCallbackOnShowDropDown();this._dq=false;var _JP=this._ev.GetExistProps();if(Utilities.IsObjectEmpty(_JP)){var _LX=oListCtrl.AddItem('',_Bq,0,ContextItem.kNoneValue,_Bq);_MX.SetValueFromListItem(_LX);this._aN=false;}else{for(var i in _JP){_Bq=_JP[i].GetBreadCrumbText();var _LX=oListCtrl.AddItem('',_Bq,0,i,_Bq);}this._aN=true;}}};CUISortDlg.prototype.SetMeasureOpts=function(_MX){var _AT=this.oDialogMgr.oUIMgr.dataManager;_MX.PopulateMeasureOptions(_AT.metadata,_AT.GetCurrentDataMatrix(),true,false,true);_MX.SetupComboBoxForDragDrop(this.oDialogMgr.oUIMgr);};CUISortDlg.prototype.SetScopeOpts=function(_MX){_MX.oListCtrl.ClearAllItems();_MX.ClearValue();var _yv=true;var _6p=this.oHostBlock.GetOppositeAxis().GetNonMeasureNodeTuples(_yv,CDLAxisMember.CanBeUsedInSort);var _Ic=this.oRes.GetString('IDS_FLT_DLG_RULE_DEFAULT_SCOPE');var _UN=DefaultConstants.kDefScope;var _LX=_MX.oListCtrl.AddItem('',_Ic,0,_UN,_Ic);_MX.SetValueFromListItem(_LX);var _y5=null;var _ads=false;if(this.oHostBlock.HasSortMembers()){_y5=this.oHostBlock._qs;}else{if(this.oHostBlock.IsExplicitSort()&&(!this.oHostBlock.IsSortByLabel())){var _Ic=this.oRes.GetString('IDS_FLT_DLG_RULE_EMPTY_SCOPE');var _UN=CUIComboBox.kEmptyItem;var _LX=_MX.oListCtrl.AddItem('',_Ic,0,_UN,_Ic);_MX.SetValueFromListItem(_LX);}}for(var i=0;i<_6p.length;i++){_Ic=_6p[i].GetLabel();_UN=_6p[i];_LX=_MX.oListCtrl.AddItem('',_Ic,0,_UN.GetNodeHierarchy(),_Ic);if(_y5){if(_6p[i].IsEqualHierarchy(_y5)){_MX.SetValueFromListItem(_LX);_ads=true;}}}if(_y5&&!_ads){if(this.oHostBlock.IsDefaultSortMember()){}else{var _BM=CDLBlock.GetTupleMembersLabel(null,null,this.oHostBlock.oAxis._rk,_y5);var _auV=this._on.AddItemToFront('',_BM,0,_y5,null,true);_auV.SetDefaultStyle("SpecialListCtrlItem");_MX.SetValueFromListItem(_auV);}}};CUISortDlg.SafeDoContinueSubmitSort=function(oDialog){/*@if(!@bering_debug)@*/try{/*@end@*/oDialog.ContinueSubmitSort();CUIDialogMgr.SafeHideCurrentDialog(oDialog.sAppName);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUISortDlg.prototype.ContinueSubmitSort=function(){var _FK=this.oHostBlock;var _VI=new Array();_VI.push(_FK.SetProperty(ExpAPIXml.kEleAxisOpExprSorttype,ExpAPIXml.kEleAxisOpExprSorttypeDefault,true));var _ama=COTInputElementFactory.GetRadioSelectionValue("radioOrder");if(this._iP){_FK._mm=_ama;}else{_VI.push(_FK.SetProperty(ExpAPIXml.kEleAxisOpExprSorttype,_ama,true));}var _apN=COTInputElementFactory.GetRadioSelectionValue("radioScope");if(_apN==CUISortDlg.kScope){if(this._iP){_FK._fR=null;_FK._cc=false;}var _azM=this._mq.GetValue();if(_azM==ExpAPIXml.kEleDefault){_azM=new Array(DefaultConstants.kDefMeasure);}var _alw=this._M.GetValue();if(_alw==DefaultConstants.kDefScope){_alw=new Array(DefaultConstants.kDefScope);}else if(_alw==CUIComboBox.kEmptyItem){_alw=new Array();}if(this._iP){_FK._k2=_azM;}else{_VI.push(_FK.SetProperty(ExpAPIXml.kEleAxisOpExprSortMeasure,_azM,true));}if(this._iP){_FK._qs=_alw;}else{if(_alw.length>0){_VI.push(_FK.SetSortMembers(_alw,true));}}}else if(_apN==CUISortDlg.kAttribute){var _acO=this._xF.GetValue();if(this._iP){_FK._fR=_acO;_FK._qs=new Array();_FK._k2=null;_FK._cc=false;}else{_VI.push(_FK.SetProperty(ExpAPIXml.kEleAxisOpExprSortProperty,_acO,true));}}else if(_apN==CUISortDlg.kLabel){if(this._iP){_FK._fR=null;_FK._qs=new Array();_FK._k2=null;_FK._cc=true;}else{var _Le=true;_VI.push(_FK.SetProperty(ExpAPIXml.kEleAxisOpExprSortLabel,true,_Le));}}if(!this._iP&&(0!=_VI.length)){_FK.oAxis._rk.SendDMActionArray(_VI);}CUIDialogMgr.SafeHideCurrentDialog(this.sAppName);};CUISortDlg.prototype.DoSubmitSort=function(){var _aFL=COTInputElementFactory.GetRadioSelectionValue("radioScope");if((_aFL==CUISortDlg.kAttribute)&&(this._dq)){CUIDialogMgr._jD.SetSeverityType(CUIMessageBox.kInformation);CUIDialogMgr._jD.Display('IDS_SORT_DLG_CONFIRM_NO_ATTRIBUTE');}else{var _ama=COTInputElementFactory.GetRadioSelectionValue("radioOrder");if((_ama==ExpAPIXml.kEleAxisOpExprSorttypeDefault)&&(!this._sX)){CUIDialogMgr._U.SetCallBackFuntion(Utilities.ExecuteHoldingProcedure);CUIDialogMgr._U.Display('IDS_SORT_DLG_CONFIRM_NO_RULE','',CUIConfirmDlg._hw);Utilities.SetProcedureToHold(CUISortDlg.SafeDoContinueSubmitSort,[this]);}else{this.oDialogMgr.oUIMgr._jf.SetLastBlockSelectionId(this.oHostBlock.GetId());this.ContinueSubmitSort();}}};CUISortDlg.prototype.Unload=function(){var _aG8=document.getElementById(this._te);if(_aG8){Dom.RemoveObject(_aG8);}Dom.RemoveObject(this._vO);CUISortDlg.superclass.Unload.call(this);};CUISortDlg.prototype.OnRadioClick=function(el){if(el.value==CUISortDlg.kScope){Dom.ReplaceText(this._hn,this.oRes.GetString('IDS_SORT_DLG_ASC_NUM'));Dom.ReplaceText(this._qr,this.oRes.GetString('IDS_SORT_DLG_DESC_NUM'));}else if(el.value==CUISortDlg.kAttribute||el.value==CUISortDlg.kLabel){Dom.ReplaceText(this._hn,this.oRes.GetString('IDS_SORT_DLG_ASC_TEXT'));Dom.ReplaceText(this._qr,this.oRes.GetString('IDS_SORT_DLG_DESC_TEXT'));}};CUISortDlg.prototype.Notify=function(_Dy){if(_Dy==ExpEvent.kCUIManager_Unload){this.Unload();}else if(_Dy==ExpEvent.kCUIWorksheet_NoAxisSel){if(this._eB){this._eB=null;}var _M3=true;this.Display(_M3);}else if(_Dy==ExpEvent.kCUIWorksheet_ChangedBlockSel){if(this._r3){if(this._iP){this.oDialogMgr.HideCurrentDialog(true);return;}var _FK=this.oDialogMgr.oUIMgr._jf.GetSelectedBlock();if(_FK&&_FK.CanSort()){this.Draw();this.Display();var _abP=_FK;if(this._iP){_abP=_FK.oAxis._rk.GetBlockProxy(_FK);}this.SetHostObj(_abP);}else{if(this._eB){this._eB=null;}this.ClearDlg();var _M3=true;this.Display(_M3);}}}else if(_Dy==ExpEvent.kCOTPropsLoadingMgr_Merge_Complete){this.UpdateAttributeLoadingMenu();var _RJ=this.oDialogMgr.oUIMgr.dataManager.metadata;_RJ.UnSubscribe(this._ev,ExpEvent.kCDLMetadata_Merge_Properties);this._ev.UnSubscribe(this,ExpEvent.kCOTPropsLoadingMgr_Merge_Complete);}};CUISortDlg.prototype.SetSortTypeRadio=function(_So){COTInputElementFactory.SelectRadioItem('radioOrder',_So);};CUISortDlg.prototype.IsChanged=function(){if(!this.oHostBlock){return false;}var _ama=COTInputElementFactory.GetRadioSelectionValue("radioOrder");var _apN=COTInputElementFactory.GetRadioSelectionValue("radioScope");if(!this.oHostBlock.IsExplicitSort()){if(_ama!=ExpAPIXml.kEleAxisOpExprSorttypeDefault){return true;}if(_apN!=CUISortDlg.kScope){return true;}var _azM=this._mq.GetValue();var _alw=this._M.GetValue();if(_azM!=ExpAPIXml.kEleDefault||_alw!=DefaultConstants.kDefScope){return true;}return false;}if(_ama!=this.oHostBlock.GetSortType()){return true;}switch(_apN){case CUISortDlg.kLabel:if(!this.oHostBlock.IsSortByLabel()){return true;}break;case CUISortDlg.kAttribute:var _acO=this._xF.GetValue();if(_acO!=this.oHostBlock.GetSortProperty()){return true;}break;case CUISortDlg.kScope:var _azM=this._mq.GetValue();var _at9=this.oHostBlock.GetSortMeasureOrMeasureCalc();if(_at9==DefaultConstants.kDefMeasure){if(_azM!=ExpAPIXml.kEleDefault){return true;}}else if(_azM!=_at9.GetId()){return true;}var _alw=this._M.GetValue();if(this.oHostBlock.IsDefaultSortMember()){if(_alw!=DefaultConstants.kDefScope){return true;}}else{if(!Utilities.AreArrayContentsEqual(_alw,this.oHostBlock._qs)){return true;}}break;}return false;};CUISortDlg.prototype.ConfirmLossOfChanges=function(){if(this.IsChanged()){var _Ke=this.sAppName;var _aAS=Utilities.GenerateCallback(CUISortDlg.SafeDoClearUncommittedChanges,[_Ke]);var _anu=Utilities.GenerateCallback(CUIDialogMgr.SafeHideCurrentDialog,[_Ke]);var _aAo=Utilities.GenerateCallbackUnion([Utilities.SafeDoRemoveHoldingProcedure,_anu]);CUIDialogMgr._q5.SetCallBackFuntion(_aAS,_aAo);CUIDialogMgr._q5.Display('IDS_SORT_DLG_COMMIT_CHANGES','',CUIConfirmDlg._hw);return Utilities.eStateHold;}else{return Utilities.eStateContinue;}};CUISortDlg.SafeDoClearUncommittedChanges=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager.oDialogMgr._jg.ClearDlg();CUIDialogMgr.SafeHideCurrentDialog(_Ke);/*@if(!@bering_debug)@*/}catch(excep){_f.HandleException(excep);}/*@end@*/};CUISortDlg.prototype.ClearDlg=function(){if(this._vO){Dom.RemoveObject(this._vO);}this.oHostBlock=null;};function CUITopBottomDlg(_H8){this.base=CUIDialog;this.base();this._iP=_H8?true:false;this._na=false;};CUITopBottomDlg.prototype=new CUIDialog;CUITopBottomDlg.superclass=CUIDialog.prototype;CUITopBottomDlg.prototype.IsInSaveMode=function(){return this._iP;};CUITopBottomDlg.prototype.Init=function(_yt,_Sb){CUITopBottomDlg.superclass.Init.call(this,_yt,_Sb);this.oDialogMgr.oUIMgr._jf.Subscribe(this,ExpEvent.kCUIWorksheet_ChangedBlockSel);};CUITopBottomDlg.prototype.SetHostObj=function(_FK,_RC){this.oHostBlock=_FK;this.SetScopeOpts(this._M);var _Q1=this.oDialogMgr.oUIMgr._jf.GetUIAxesContainer().GetUIAxis(this.oHostBlock.oAxis._l7);var _ar1=this.oRes.GetString('IDS_TOPBOTTOM_DLG_SCOPE_'+_Q1.GetResourceSuffix());Dom.ReplaceText(this._gX,_ar1);this.SetMeasureOpts(this._mq);if(this.oHostBlock.HasTopBottomRule()){COTInputElementFactory.SelectRadioItem("TopBottomRadio",this.oHostBlock.GetSubset()._aK);var _agH=COTInputElementFactory.SelectRadioItem("TopBottomTypeRadio",this.oHostBlock.GetSubset()._sf);Debug.Assert(_agH!=null);if(this.oHostBlock.GetSubset()._sf!=ExpAPIXml.eSubsetTypeSubsVar){if(_agH){var _aHM=Dom.GetElementsByTagName(this._vO,"INPUT");for(var i=0;i<_aHM.length;i++){if(_aHM[i].type=="text"&&_aHM[i].idRadioToCheck==_agH.id){_aHM[i].value=this.oHostBlock.GetSubset()._uj;if(this.oHostBlock.GetSubset()._aK==_RC){_aHM[i].focus();}}}}}else{var _1h=this._kv.GetItemByValue(this.oHostBlock.GetSubset()._uj);this._aI.SetValueFromListItem(_1h);}var _9B;if(!this.oHostBlock.GetSubset().IsDefaultSortMeasure()){_9B=this._mq.AddMeasureToComboBox(this.oDialogMgr.oUIMgr.dataManager.metadata,this.oHostBlock.GetSubset()._sA);}else{_9B=this._ej.GetItemByIndex(0);}this._mq.SetValueFromListItem(_9B);this._na=true;}else{this._na=false;if(!_RC){COTInputElementFactory.SelectRadioItem("TopBottomRadio",-1);}else{COTInputElementFactory.SelectRadioItem("TopBottomRadio",_RC);this._oA.focus();}this._oA.value=CUITopBottomProperty.kDefaultSize;this._no.value=CUITopBottomProperty.kDefaultSize;this._fE.value=CUITopBottomProperty.kDefaultSize;if(this._aI){this._aI.SetValue(-1,this.oRes.GetString('IDS_TOPBOTTOM_DLG_NO_SUBS_VAR'));}var _ayS=this._ej.GetItemByIndex(0);this._mq.SetValueFromListItem(_ayS);}if(this._kC){var _agP='';this._eB=this.oHostBlock.GetLabel();_agP=this.oRes.ReplaceParam('IDS_TOPBOTTOM_DLG_TITLE_WITH_SEPSTR',1,this._eB);this._kC.Update(_agP);}};CUITopBottomDlg.prototype.ClearDlg=function(){if(this._vO){Dom.RemoveAllChildren(this._vO);}this.oHostBlock=null;};CUITopBottomDlg.prototype.Draw=function(){this.ClearDlg();var _zr=document.createElement('TABLE');this._vO=_zr;COTStyle.SetHeight(_zr,110);var _QA=this.oDialogMgr.oUIMgr.dataManager.metadata;if(_QA.SubsVarsExist()){COTStyle.SetHeight(_zr,125);}_zr.className='dialogTable';var _Ke=this.sAppName;var _RK=_zr.appendChild(document.createElement('TBODY'));this._xS=_RK;var _5u=document.createElement('TR');var _NM=_5u.appendChild(this._l4.cloneNode(false));COTStyle.SetWidth(_NM,30,'%');_NM.appendChild(document.createTextNode(this.oRes.GetString('IDS_TOPBOTTOM_DLG_TOPBOTTOM_SELECT')));var _NM=_5u.appendChild(this._l4.cloneNode(false));COTStyle.SetWidth(_NM,30,'%');_NM.appendChild(document.createTextNode(this.oRes.GetString('IDS_TOPBOTTOM_DLG_NO_OF_ITEMS')));var _NM=_5u.appendChild(this._l4.cloneNode(false));COTStyle.SetWidth(_NM,40,'%');_NM.appendChild(document.createTextNode(this.oRes.GetString('IDS_TOPBOTTOM_DLG_MEASURE_SELECT')));_RK.appendChild(_5u);var _atd=document.createElement('TR');var _R3=_atd.appendChild(this._g5.cloneNode(false));var _1G=COTInputElementFactory.CreateRadioButton("TopBottomRadio",-1,true,false);_R3.appendChild(_1G);var _aAw=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_TOPBOTTOM_DLG_NO_RULE'));_R3.appendChild(_aAw);var _aEU=Utilities.GenerateId();_1G.id=_aEU;var _R3=_atd.appendChild(this._g5.cloneNode(false));var _85=Utilities.EventCallback(this.OnRadioClick,[],this,true,false);var _1G=COTInputElementFactory.CreateRadioButton("TopBottomTypeRadio",ExpAPIXml.eSubsetTypeInteger,true,false,_85);_R3.appendChild(_1G);var _RB=COTInputElementFactory.CreateIntegerTextBox(this,4,CUITopBottomProperty.kDefaultSize,false,false,1);var _aEU=Utilities.GenerateId();_1G.id=_aEU;_RB.idRadioToCheck=_aEU;this._oA=_RB;_R3.appendChild(_RB);this._ej=new CUIListCtrl(this.oDialogMgr.oUIMgr);this._ej.iMaxHeight=150;this._ej.Init();this._ej.DisableHAutoScroll();_NM=_atd.appendChild(document.createElement('TD'));this._mq=new CUIComboBox(this.oDialogMgr.oUIMgr,this._ej);this._mq.DisableIcon();var _afs=_NM.appendChild(this._mq.Init());this.SetMeasureOpts(this._mq);COTStyle.SetHeight(_atd,COTStyle.GetDisplayOffsetHeight(_afs));this._mq.SetupComboBoxForDragDrop(this.oDialogMgr.oUIMgr);_RK.appendChild(_atd);var _5u=document.createElement('TR');var _auQ=_5u.appendChild(this._g5.cloneNode(false));var _1G=COTInputElementFactory.CreateRadioButton("TopBottomRadio",ExpAPIXml.kFLSortTop,false,false);_auQ.appendChild(_1G);var _aAw=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_TOPBOTTOM_DLG_TOP'));_auQ.appendChild(_aAw);var _aEU=Utilities.GenerateId();_1G.id=_aEU;var _aCc=_5u.appendChild(this._g5.cloneNode(false));_1G=COTInputElementFactory.CreateRadioButton("TopBottomTypeRadio",ExpAPIXml.eSubsetTypePercentage,false,false,_85);_aEU=Utilities.GenerateId();_1G.id=_aEU;_aCc.appendChild(_1G);var _Nw=new Array();_Nw.push(this.oRes.GetParameter(1));var _alq=this.oRes.ParseStringForOrder('IDS_TOP_BOTTOM_DLG_PERCENTAGE_INPUT',_Nw);Debug.Assert(_alq.length==1);if(_alq[0]){if(_alq[0]){if(_alq[0].sBefore.length>0){_aCc.appendChild(document.createTextNode(_alq[0].sBefore));}if(_alq[0].sElement==this.oRes.GetParameter(1)){this._no=COTInputElementFactory.CreateFloatTextBox(this,3,CUITopBottomProperty.kDefaultSize,false,false,0,100);_aCc.appendChild(this._no);this._no.idRadioToCheck=_aEU;}if(_alq[0].sAfter.length>0){_aCc.appendChild(document.createTextNode(_alq[0].sAfter));}}}var _NM=_5u.appendChild(this._l4.cloneNode(false));COTStyle.SetWidth(_NM,55,'%');this._gX=_NM;_NM.appendChild(document.createTextNode(""));_RK.appendChild(_5u);var _atd=document.createElement('TR');var _auF=_atd.appendChild(this._g5.cloneNode(false));var _1G=COTInputElementFactory.CreateRadioButton("TopBottomRadio",ExpAPIXml.kFLSortBottom,false,false);_auF.appendChild(_1G);var _aAw=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_TOPBOTTOM_DLG_BOTTOM'));_auF.appendChild(_aAw);var _aEU=Utilities.GenerateId();_1G.id=_aEU;var _aCc=_atd.appendChild(this._g5.cloneNode(false));var _asq=_aCc.appendChild(document.createElement('SPAN'));_asq.title=this.oRes.GetString('IDS_TOP_BOTTOM_DLG_SUM_TOOLTIP');_1G=COTInputElementFactory.CreateRadioButton("TopBottomTypeRadio",ExpAPIXml.eSubsetTypeSum,false,false,_85);_aEU=Utilities.GenerateId();_1G.id=_aEU;_asq.appendChild(_1G);_alq=this.oRes.ParseStringForParamOrder('IDS_TOP_BOTTOM_DLG_SUM_INPUT',2);for(var i=0;i<_alq.length;i++){if(_alq[i]){if(_alq[i].sBefore.length>0){_asq.appendChild(document.createTextNode(_alq[i].sBefore));}if(_alq[i].sElement==this.oRes.GetParameter(1)){_asq.appendChild(document.createTextNode('\u2211'));}else{this._fE=COTInputElementFactory.CreateFloatTextBox(this,7,CUITopBottomProperty.kDefaultSize,false,false,0);_asq.appendChild(this._fE);this._fE.idRadioToCheck=_aEU;}if(_alq[i].sAfter.length>0){_asq.appendChild(document.createTextNode(_alq[i].sAfter));}}}this._on=new CUIListCtrl(this.oDialogMgr.oUIMgr);this._on.iMaxHeight=150;this._on.Init();this._on.DisableHAutoScroll();_NM=_atd.appendChild(document.createElement('TD'));this._M=new CUIComboBox(this.oDialogMgr.oUIMgr,this._on);this._M.DisableIcon();var _afs=_NM.appendChild(this._M.Init());COTStyle.SetHeight(_atd,COTStyle.GetDisplayOffsetHeight(_afs));_RK.appendChild(_atd);var _QA=this.oDialogMgr.oUIMgr.dataManager.metadata;if(_QA.SubsVarsExist()){var _1g=document.createElement('TR');var _aec=_1g.appendChild(this._g5.cloneNode(false));var _aCc=_1g.appendChild(this._g5.cloneNode(false));var _asq=document.createElement('DIV');_asq.className+=" vAlign_middle";_asq.style.display="inline";_1G=COTInputElementFactory.CreateRadioButton("TopBottomTypeRadio",ExpAPIXml.eSubsetTypeSubsVar,false,false);_aEU=Utilities.GenerateId();_1G.id=_aEU;_aCc.appendChild(_1G);_aCc.appendChild(_asq);this._kv=new CUIListCtrl(this.oDialogMgr.oUIMgr);this._kv.SetMaxHeight(80);this._kv.Init();this._kv.DisableHAutoScroll();this._aI=new CUIComboBox(this.oDialogMgr.oUIMgr,this._kv);this._aI.SetArrowImageName("substitution_variables.gif");this._aI.SetArrowImageDisabledName("substitution_variables_disabled.gif");this._aI.DisableIcon();this._aI.SetArrowTDClassName("ComboBoxArrowWhite");var _RB=this._aI.Init();_RB.style.display="inline";this._aI.SetWidthByPX(150);this._aI.EnableHoverOverArrowEffect("ComboBoxArrowWhite_hover");this.PopulateSubsVars(_QA._gY,this._aI);_RB.idRadioToCheck=_aEU;this._pE=_RB;_asq.appendChild(_RB);_RK.appendChild(_1g);}this._om=2;if(this._iP){this._yi=Utilities.GenerateCallback(this.DoConstructTopBottomRule,[],this);}else{this._Y=Utilities.GenerateCallback(this.DoConstructTopBottomRule,[],this);}};CUITopBottomDlg.prototype.Display=function(_M3){var _Co=this.oDialogMgr.oUIMgr.appobj.oResources;var _Ke=this.sAppName;var _MY=new Object();var _Xf=Utilities.GenerateCallback(CUIManager.SafeDoHelpTopic,[_Ke,HelpConstants.kTopBottomLink]);_MY['IDS_HELP']=_Xf;if(_M3){var _Li=this.oDialogMgr.oUIMgr.dataManager.GetCurrentDataMatrix();var _W7=_Li.GetAllBlocksArray();var _Nk=new Array();for(var i=0;i<_W7.length;i++){if(_W7[i].CanApplyTopBottom()){_Nk.push(_W7[i]);}}var _aJh=true;this.DisplayInvalidSelection('IDS_TOPBOTTOM_DLG_TITLE',_MY,_Nk,_Li,'TOPBOTTOM',_aJh);}else{this.Draw();CUITopBottomDlg.superclass.Display.call(this,'IDS_TOPBOTTOM_DLG_TITLE',_MY,this._vO,'IDS_TOPBOTTOM_DLG_INSTRUCTION');var _F4=COTStyle.GetWidthFromOffset(this._vO);this._mq.SetWidthByPX(_F4*0.6*0.8);this._M.SetWidthByPX(_F4*0.6*0.8);this._mq.ResetEventHandlers();this._M.ResetEventHandlers();var _Ke=this.sAppName;}};CUITopBottomDlg.prototype.SetMeasureOpts=function(_MX){var _AT=this.oDialogMgr.oUIMgr.dataManager;_MX.PopulateMeasureOptions(_AT.metadata,_AT.GetCurrentDataMatrix(),true,false,true);};CUITopBottomDlg.prototype.SetScopeOpts=function(_MX,_MN){_MX.oListCtrl.ClearAllItems();_MX.ClearValue();var _yv=true;var _6p=this.oHostBlock.GetOppositeAxis().GetNonMeasureNodeTuples(_yv,CDLAxisMember.CanBeUsedInFilter);var _Ic=this.oRes.GetString('IDS_FLT_DLG_RULE_DEFAULT_SCOPE');var _UN=DefaultConstants.kDefScope;var _LX=_MX.oListCtrl.AddItem('',_Ic,0,_UN,_Ic);_MX.SetValueFromListItem(_LX);var _y5=null;var _ads=false;if(this.oHostBlock.GetSubset()&&(!this.oHostBlock.GetSubset().IsDefaultSortMember())){_y5=this.oHostBlock.GetSubset()._qs;}else{if(this.oHostBlock.GetSubset()&&(!this.oHostBlock.GetSubset().HasSortMembers())){var _Ic=this.oRes.GetString('IDS_FLT_DLG_RULE_EMPTY_SCOPE');var _UN=CUIComboBox.kEmptyItem;var _LX=_MX.oListCtrl.AddItem('',_Ic,0,_UN,_Ic);_MX.SetValueFromListItem(_LX);}}for(var i=0;i<_6p.length;i++){_Ic=_6p[i].GetLabel();_UN=_6p[i];_LX=_MX.oListCtrl.AddItem('',_Ic,0,_UN.GetNodeHierarchy(),_Ic);if(_y5){if(_6p[i].IsEqualHierarchy(_y5)){_MX.SetValueFromListItem(_LX);_ads=true;}}}if(_y5&&!_ads){var _BM=CDLBlock.GetTupleMembersLabel(null,null,this.oHostBlock.oAxis._rk,_y5);var _auV=this._on.AddItemToFront('',_BM,0,_y5,null,true);_auV.SetDefaultStyle("SpecialListCtrlItem");_MX.SetValueFromListItem(_auV);}};CUITopBottomDlg.SafeDoContinueConstructTopBottomRule=function(_VN,_SA){/*@if(!@bering_debug)@*/try{/*@end@*/_VN.ContinueConstructTopBottomRule(_SA);CUIDialogMgr.SafeHideCurrentDialog(_VN.sAppName);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUITopBottomDlg.prototype.ContinueConstructTopBottomRule=function(_SA){if(_SA.HasTopBottomRule()){_SA.DeleteTopBottom();}else{_0N=false;}if(!this._iP&&_0N){this.oDialogMgr.oUIMgr._jf.SetLastBlockSelectionId(this.oHostBlock.GetId());this.oHostBlock.SetProperty(ExpAPIXml.kEleSubset,_SA);}CUIDialogMgr.SafeHideCurrentDialog(this.sAppName);};CUITopBottomDlg.prototype.DoConstructTopBottomRule=function(){var _azM=this._mq.GetValue();if(_azM==ExpAPIXml.kEleDefault){_azM=DefaultConstants.kDefMeasure;}var _alw=this._M.GetValue();if(_alw==DefaultConstants.kDefScope){_alw=new Array(DefaultConstants.kDefScope);}else if(_alw==CUIComboBox.kEmptyItem){_alw=new Array();}var _Dk=COTInputElementFactory.GetRadioSelectionValue("TopBottomTypeRadio");var _EL=this._oA.value;if(_Dk==ExpAPIXml.eSubsetTypePercentage){_EL=this._no.value;}else if(_Dk==ExpAPIXml.eSubsetTypeSum){_EL=this._fE.value;}else if(_Dk==ExpAPIXml.eSubsetTypeSubsVar){_EL=this._aI.GetValue();if(_EL==-1){var _1h=this._kv.GetItemByIndex(0);this._aI.SetValueFromListItem(_1h);_EL=this._aI.GetValue();}}var _SA=null;if(this._iP){_SA=this.oHostBlock.GetSubset();if(!_SA){_SA=this.oHostBlock._mF=new CDLFilterExpr(this.oHostBlock.oAxis._rk._he);}}else if(this.oHostBlock.GetSubset()){_SA=this.oHostBlock.GetSubset().Clone(this.oHostBlock);}else{_SA=new CDLFilterExpr(this.oHostBlock.oAxis._rk._he);}var _0N=true;var _amW=Utilities.eStateContinue;if(COTInputElementFactory.GetRadioSelectionValue("TopBottomRadio")==-1){if(!this._na){_amW=Utilities.eStateHold;CUIDialogMgr._U.SetCallBackFuntion(Utilities.ExecuteHoldingProcedure);CUIDialogMgr._U.Display('IDS_TOPBOTTOM_DLG_CONFIRM_NO_RULE','',CUIConfirmDlg._hw);var _Ro=new Array(this,_SA);Utilities.SetProcedureToHold(CUITopBottomDlg.SafeDoContinueConstructTopBottomRule,_Ro);return;}if(_amW==Utilities.eStateContinue){if(_SA.HasTopBottomRule()){_SA.DeleteTopBottom();}else{_0N=false;}}}else{_SA.SetTopBottom(_EL,COTInputElementFactory.GetRadioSelectionValue("TopBottomRadio"),_azM,_alw,_Dk);}if(_amW==Utilities.eStateContinue){if(!this._iP&&_0N){this.oDialogMgr.oUIMgr._jf.SetLastBlockSelectionId(this.oHostBlock.GetId());this.oHostBlock.SetProperty(ExpAPIXml.kEleSubset,_SA);}CUIDialogMgr.SafeHideCurrentDialog(this.sAppName);}};CUITopBottomDlg.prototype.OnTextBoxSelect=function(_Ll){var _aHM=Dom.GetElementsByTagName(this._vO,"INPUT");for(var i=0;i<_aHM.length;i++){if(_aHM[i].type=="radio"&&_aHM[i].name=="TopBottomTypeRadio"){_aHM[i].checked=false;}}var _1G=document.getElementById(_Ll.idRadioToCheck);_1G.checked=true;};CUITopBottomDlg.prototype.OnRadioClick=function(_Fa){if(_Fa.name!='TopBottomTypeRadio'){return;}var _Dk=COTInputElementFactory.GetRadioSelectionValue("TopBottomTypeRadio");if(_Dk==ExpAPIXml.eSubsetTypeInteger&&this._oA){this._oA.focus();}else if(_Dk==ExpAPIXml.eSubsetTypePercentage&&this._no){this._no.focus();}else if(_Dk==ExpAPIXml.eSubsetTypeSum&&this._fE){this._fE.focus();}};CUITopBottomDlg.prototype.PopulateSubsVars=function(_SS,_MX){_MX.oListCtrl.ClearAllItems();var _LX;for(var i in _SS){_LX=_MX.oListCtrl.AddItem('',_SS[i]._xU,0,_SS[i]._bb,_SS[i]._xU);}this._aI.SetValue(-1,this.oRes.GetString('IDS_TOPBOTTOM_DLG_NO_SUBS_VAR'));};CUITopBottomDlg.prototype.Unload=function(){var _aG8=document.getElementById(this._te);if(_aG8){Dom.RemoveObject(_aG8);}this._oA.oOwner=null;this._no.oOwner=null;this._fE.oOwner=null;if(this._aI){this._aI.Unload();}Dom.RemoveObject(this._vO);CUITopBottomDlg.superclass.Unload.call(this);};CUITopBottomDlg.prototype.Notify=function(_Dy){CUITopBottomDlg.superclass.Notify.call(this,_Dy);if(_Dy==ExpEvent.kCUIWorksheet_ChangedBlockSel){if(this._r3){if(this._iP){this.oDialogMgr.HideCurrentDialog(true);return;}var _FK=this.oDialogMgr.oUIMgr._jf.GetSelectedBlock();if(_FK&&_FK.CanApplyTopBottom()){var _abP=_FK;if(this._iP){_abP=_FK.oAxis._rk.GetBlockProxy(_FK);}this.Display();this.SetHostObj(_abP);}else{if(this._eB){this._eB=null;}this.ClearDlg();var _M3=true;this.Display(_M3);}}}};CUITopBottomDlg.prototype.IsChanged=function(){if(!this.oHostBlock){return false;}var _Hx=COTInputElementFactory.GetRadioSelectionValue("TopBottomRadio");var _Dk=COTInputElementFactory.GetRadioSelectionValue("TopBottomTypeRadio");var _EL=this._oA.value;var _azM=this._mq.GetValue();var _alw=this._M.GetValue();var _9C=this.oHostBlock.GetSubset();if(!_9C){if(_Hx!=-1||_Dk!=ExpAPIXml.eSubsetTypeInteger||_EL!=CUITopBottomProperty.kDefaultSize||_azM!=ExpAPIXml.kEleDefault||_alw!=DefaultConstants.kDefScope){return true;}else{return false;}}if(_Hx!=_9C._aK){return true;}if(_Dk!=_9C._sf){return true;}switch(_Dk){case ExpAPIXml.eSubsetTypePercentage:_EL=this._no.value;break;case ExpAPIXml.eSubsetTypeSum:_EL=this._fE.value;break;case ExpAPIXml.eSubsetTypeSubsVar:_EL=this._aI.GetValue();break;}if(_EL!=_9C._uj){return true;}if(_9C.IsDefaultSortMeasure()){if(_azM!=ExpAPIXml.kEleDefault){return true;}}else if(_azM!=_9C._sA){return true;}if(_9C.IsDefaultSortMember()){if(_alw!=DefaultConstants.kDefScope){return true;}}else{if(!Utilities.AreArrayContentsEqual(_alw,_9C._qs)){return true;}}return false;};CUITopBottomDlg.prototype.ConfirmLossOfChanges=function(){if(this.IsChanged()){var _Ke=this.sAppName;var _aAS=Utilities.GenerateCallback(CUITopBottomDlg.SafeDoClearUncommittedChanges,[_Ke]);var _anu=Utilities.GenerateCallback(CUIDialogMgr.SafeHideCurrentDialog,[_Ke]);var _aAo=Utilities.GenerateCallbackUnion([Utilities.SafeDoRemoveHoldingProcedure,_anu]);CUIDialogMgr._q5.SetCallBackFuntion(_aAS,_aAo);CUIDialogMgr._q5.Display('IDS_TOPBOTTOM_DLG_COMMIT_CHANGES','',CUIConfirmDlg._hw);return Utilities.eStateHold;}else{return Utilities.eStateContinue;}};CUITopBottomDlg.SafeDoClearUncommittedChanges=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager.oDialogMgr._jg.ClearDlg();CUIDialogMgr.SafeHideCurrentDialog(_Ke);/*@if(!@bering_debug)@*/}catch(excep){_f.HandleException(excep);}/*@end@*/};function CUISuppressionDlg(){this.base=CUIDialog;this.base();this.oHostBlock=null;this._gK=null;this._pi=null;this._iU=null;this._n8="CUISuppressionDlg";};CUISuppressionDlg.prototype=new CUIDialog;CUISuppressionDlg.superclass=CUIDialog.prototype;CUISuppressionDlg.prototype.Init=function(_Hy,_Sb){CUISuppressionDlg.superclass.Init.call(this,_Hy,_Sb);this.oDialogMgr.oUIMgr._jf.Subscribe(this,ExpEvent.kCUIWorksheet_ChangedBlockSel);};CUISuppressionDlg.prototype.SetHostObj=function(_FK){this.oHostBlock=_FK;this.InitTupleList();};CUISuppressionDlg.prototype.InitTupleList=function(){this._gK=new Array();var _Q1=this.oDialogMgr.oUIMgr._jf.GetUIAxesContainer().GetUIAxis(this.oHostBlock.oAxis._l7);var _Co=this.oDialogMgr.oUIMgr.appobj.oResources;for(var i=0;i<_Q1._j8.length;i++){var _aHT=_Q1._j8[i];var oMem=_aHT[_aHT.length-1];if(oMem.GetDepth()==_Q1._eh.GetAxisDepth()-1){_S6=_Q1._eh.GetSelectedSuppressionTuple(i,_Q1._eh.GetAxisDepth()-1,true,CDLAxisMember.CanBeUsedInSuppression);var _aqc=new Array();if(_S6){var _PM=new CUISuppressionItem();_PM.oSuppressTuple=_S6;for(var j=0;j<_S6._cb.length;j++){_aqc.push(_Q1._eh._rk.GetNodeLabel(_S6._cb[j]._jU));}_PM.sLabel=this.oRes.ReplaceParamList('IDS_SUPPRESSION_TUPLE_LIST',_aqc);if(oMem){var _ave=oMem.GetAxisMember();if(_ave._un){;_PM.sSuppressId=_ave._un;_PM.bOrgSuppress=true;_PM.bSuppress=true;}this._gK[this._gK.length]=_PM;}}}}};CUISuppressionDlg.prototype.Display=function(_M3){var _Co=this.oDialogMgr.oUIMgr.appobj.oResources;var _Ke=this.sAppName;var _MY=new Object();var _Xf=Utilities.GenerateCallback(CUIManager.SafeDoHelpTopic,[_Ke,HelpConstants.kCustomSuppressLink]);_MY['IDS_HELP']=_Xf;this._hB=true;this.SetAlternativeLabelForOKButton('IDS_BUTTON_OK');this._Y=Utilities.GenerateCallback(this.DoSuppression,[_Ke],this);if(_M3){var _Li=this.oDialogMgr.oUIMgr.dataManager.GetCurrentDataMatrix();var _W7=_Li.GetAllBlocksArray();var _Nk=new Array();for(var i=0;i<_W7.length;i++){if(_W7[i].IsValidForCustomSuppress()){_Nk.push(_W7[i]);}}var _KP=_Co.GetString('IDS_SUPPRESSION_DLG_TITLE_ROWSORCOLS');var _aCe=this.oRes.GetString('IDS_SELECTION_DLG_MSG_ITEM_SUPPRESSION');this.DisplayInvalidSelection(_KP,_MY,_Nk,_Li,'SUPPRESSION',false,_aCe);}else{var _T7=false;if(this.oHostBlock&&this.oHostBlock.IsInsideRowAxis()){_T7=true;}var _KP=_T7?_Co.GetString('IDS_SUPPRESSION_DLG_TITLE_COLS'):_Co.GetString('IDS_SUPPRESSION_DLG_TITLE_ROWS');var _F3=_T7?_Co.GetString('IDS_SUPPRESSION_DLG_MSG_COLS'):_Co.GetString('IDS_SUPPRESSION_DLG_MSG_ROWS');CUISuppressionDlg.superclass.Display.call(this,_KP,_MY,this._vO,_F3);this.UpdateSelectAllCheckbox();}};CUISuppressionDlg.prototype.CloseSuppressionDialog=function(){this.oDialogMgr.HideCurrentDialog();};CUISuppressionDlg.prototype.Draw=function(){var _Ke=this.sAppName;var _zr=document.createElement('TABLE');COTStyle.SetHeight(_zr,200);this._vO=_zr;_zr.className='dialogTable';var _F0=document.createElement('TBODY');var _NH=document.createElement('TR');var _NM=document.createElement('TD');_NH.className='dialogText_bold';var _BM=_Co.GetString('IDS_SUPPRESSION_DLG_TUPLELIST_LABEL_COLS');if(this.oHostBlock&&this.oHostBlock.IsInsideRowAxis()){_BM=_Co.GetString('IDS_SUPPRESSION_DLG_TUPLELIST_LABEL_ROWS');}_NM.appendChild(document.createTextNode(_BM));_NH.appendChild(_NM);_F0.appendChild(_NH);var _Rs=document.createElement('TR');_F0.appendChild(_Rs);this._it=document.createElement('TD');this._it.className='suppressionDlgTuplesArea';COTStyle.SetWidth(this._it,80,'%');COTStyle.SetHeight(this._it,100,'%');this._cM=document.createElement('DIV');this._cM.className='suppressionDlgTuplesDiv';this._it.appendChild(this._cM);_Rs.appendChild(this._it);this.createTupleList();_zr.appendChild(_F0);};CUISuppressionDlg.prototype.CreateTupleListTable=function(){this._go=document.createElement('TABLE');this._go.className='pagerCtrlTBL';COTStyle.SetWidth(this._go,100,'%');this._cM.appendChild(this._go);this._mM=document.createElement('TBODY');this._go.appendChild(this._mM);};CUISuppressionDlg.prototype.createTupleList=function(){this.CreateTupleListTable();var _NH,_NM,_apS;_NH=document.createElement('TR');_NH.className='suppressionTupleItemTblHeader';_NM=document.createElement('TD');_NM.appendChild(COTInputElementFactory.CreateImage('blank.gif',12,12));COTStyle.SetWidth(_NM,14,'px');_NH.appendChild(_NM);_NM=document.createElement('TD');_NM.appendChild(document.createTextNode(_Co.GetString('IDS_SUPPRESSION_DLG_TUPLELIST_TBL_ITEM')));COTStyle.SetWidth(_NM,80,'%');_NM.className='suppressionTupleItemTblHeaderTD';_NH.appendChild(_NM);_NM=document.createElement('TD');this._fw=COTInputElementFactory.CreateCheckBox('','',true,null,false);Dom.SetObjRef(this._fw,this,'_oDlgObj');this._fw.className="dialogSmallCheckBox";this._fw.onclick=Utilities.EventCallback(this.SelectAll,[],this);_NM.appendChild(this._fw);_NM.appendChild(document.createTextNode(_Co.GetString('IDS_SUPPRESSION_DLG_TUPLELIST_TBL_SUPPRESS')));_NM.className='suppressionTupleItemTblHeaderTD';_NH.appendChild(_NM);this._mM.appendChild(_NH);this._pi=new Array();this._iU=new Array();for(var i=0;i<this._gK.length;i++){var _PM=this._gK[i];_NH=document.createElement('TR');_NH.className='suppressionDlgTupleItem';_NM=document.createElement('TD');if(_PM.bSuppress){var _ZS=COTInputElementFactory.CreateImage('icon_zero_12.gif',12,12);_NM.appendChild(_ZS);}else{var _ZS=COTInputElementFactory.CreateImage('blank.gif',12,12);_NM.appendChild(_ZS);}this._pi[this._pi.length]=_NM;_NH.appendChild(_NM);_NM=document.createElement('TD');var _4h=document.createElement('SPAN');_4h.title=_PM.sLabel;var _BM=Utilities.GetTruncatedString(_PM.sLabel,CUISuppressionItem.kItemTruncLength,this.oRes,true);_apS=COTInputElementFactory.CreateLabel(_BM);_4h.appendChild(_apS);_NM.appendChild(_4h);_NH.appendChild(_NM);_NM=document.createElement('TD');var _acm=COTInputElementFactory.CreateCheckBox('',i,_PM.bOrgSuppress,null,false);Dom.SetObjRef(_acm,this,'_oDlgObj');_acm.className="dialogSmallCheckBox";_acm.onclick=Utilities.EventCallback(this.ChangeSelection,[],this);this._iU[this._iU.length]=_acm;_NM.appendChild(_acm);_NH.appendChild(_NM);this._mM.appendChild(_NH);}};CUISuppressionDlg.prototype.UpdateSelectAllCheckbox=function(){var _Ng=true;for(var i=0;i<this._iU.length;i++){var _acm=this._iU[i];if(!_acm.checked){_Ng=false;break;}}this._fw.checked=_Ng;};CUISuppressionDlg.prototype.ChangeItemSelection=function(e,_SJ){var _PQ=_SJ.value;var _NM=this._pi[_PQ];Dom.RemoveAllChildren(_NM);if(_SJ.checked){var _ZS=COTInputElementFactory.CreateImage('icon_zero_12.gif',12,12);_NM.appendChild(_ZS);this._gK[_PQ].bSuppress=true;}else{var _ZS=COTInputElementFactory.CreateImage('blank.gif',12,12);_NM.appendChild(_ZS);this._gK[_PQ].bSuppress=false;}};CUISuppressionDlg.prototype.ChangeSelection=function(e,_SJ){this.ChangeItemSelection(e,_SJ);this.UpdateSelectAllCheckbox();};CUISuppressionDlg.prototype.SelectAll=function(e,_SJ){for(var i=0;i<this._iU.length;i++){var _acm=this._iU[i];_acm.checked=_SJ.checked;this.ChangeItemSelection(e,_acm);}};CUISuppressionDlg.prototype.DoSuppression=function(){var _Q1=this.oDialogMgr.oUIMgr._jf.GetUIAxesContainer().GetUIAxis(this.oHostBlock.oAxis._l7);var _QW=new Array();var _H4=new Array();var _PM;for(var i=0;i<this._gK.length;i++){_PM=this._gK[i];if(_PM.bOrgSuppress!=_PM.bSuppress){if(_PM.bOrgSuppress){_H4[_H4.length]=_PM.sSuppressId;}else{_QW[_QW.length]=_PM.oSuppressTuple;}}}if(_QW.length>0||_H4.length>0){_Q1._eh.SuppressMultiTuples(_QW,_H4);}CUIDialogMgr.SafeHideCurrentDialog(this.sAppName);};CUISuppressionDlg.prototype.Unload=function(){Dom.RemoveObject(this._vO);CUISuppressionDlg.superclass.Unload.call(this);};CUISuppressionDlg.prototype.Notify=function(_Dy){if(_Dy==ExpEvent.kCUIManager_Unload){this.Unload();}else if(_Dy==ExpEvent.kCUIWorksheet_NoAxisSel){var _M3=true;this.Display(_M3);}else if(_Dy==ExpEvent.kCUIWorksheet_ChangedBlockSel){if(this._r3){if(this._iP){this.oDialogMgr.HideCurrentDialog(true);return;}var _FK=this.oDialogMgr.oUIMgr._jf.GetSelectedBlock();if(_FK&&_FK.IsValidForCustomSuppress()){this.SetHostObj(_FK);this.Draw();this.Display();}else{var _M3=true;this.Display(_M3);}}}};CUISuppressionDlg.prototype.IsChanged=function(){if(this._gK){var _PM;for(var i=0;i<this._gK.length;i++){_PM=this._gK[i];if(_PM.bOrgSuppress!=_PM.bSuppress){return true;}}}return false;};CUISuppressionDlg.prototype.ConfirmLossOfChanges=function(){if(this.IsChanged()){var _Ke=this.sAppName;var _aAS=Utilities.GenerateCallback(CUISuppressionDlg.SafeDoClearUncommittedChanges,[_Ke]);var _anu=Utilities.GenerateCallback(CUIDialogMgr.SafeHideCurrentDialog,[_Ke]);var _aAo=Utilities.GenerateCallbackUnion([Utilities.SafeDoRemoveHoldingProcedure,_anu]);CUIDialogMgr._q5.SetCallBackFuntion(_aAS,_aAo);CUIDialogMgr._q5.Display('IDS_SUPPRESSION_DLG_COMMIT_CHANGES','',CUIConfirmDlg._hw);return Utilities.eStateHold;}else{return Utilities.eStateContinue;}};CUISuppressionDlg.SafeDoClearUncommittedChanges=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager.oDialogMgr._jg.ClearDlg();CUIDialogMgr.SafeHideCurrentDialog(_Ke);/*@if(!@bering_debug)@*/}catch(excep){_f.HandleException(excep);}/*@end@*/};CUISuppressionDlg.prototype.ClearDlg=function(){if(this._vO){Dom.RemoveObject(this._vO);}this.oHostBlock=null;Utilities.DeleteAllFromArray(this._gK);Utilities.DeleteAllFromArray(this._pi);Utilities.DeleteAllFromArray(this._iU);};CUISuppressionItem.kItemTruncLength=75;function CUISuppressionItem(){this.oSuppressTuple=null;this.sLabel=null;this.sSuppressId=null;this.bOrgSuppress=false;this.bSuppress=false;};CUICalculationDlg.ArithmeticCalc=0;CUICalculationDlg.PercentageCalc=1;CUICalculationDlg.StatisticCalc=2;CUICalculationDlg.RelativePositionCalc=3;CUICalculationDlg.ConstantCalc=4;CUICalculationDlg.RelPosCustomScope='customscope';CUICalculationDlg.RelPosSameAxis='sameaxis';CUICalculationDlg.RelPosOppositeAxis='oppositeaxis';CUICalculationDlg.ItemSeparator='contextmenuseparator';CUICalculationDlg.kDirectionNA='nodirection';CUICalculationDlg.kDupMeasure='dupmeasure';CUICalculationDlg.kSelectedMeasure='selectedmeasure';function CUICalculationDlg(){this.base=CUIDialog;this.base();this._rK=null;this._tD=null;this._lm=new Array();this._oEventTriggers=new Object();this._oEventTriggers[ExpEvent.kCUIComboBox_OnSelChange]=new Object();this._oEventTriggers[ExpEvent.kCUIComboBox_OnSelection]=new Object();CUICalculationDlg.OPTypeArr=new Object();this._gd=new Array();this._D=new Array();this._cU=false;this._jt=null;this._th=false;this._f5=null;this._j3=new Object();};CUICalculationDlg.prototype=new CUIDialog;CUICalculationDlg.superclass=CUIDialog.prototype;CUICalculationDlg.prototype.PopulateGlobalOperandsList=function(){var _Q1=this._rK.GetUIAxis();var _F7=_Q1.GetDLAxis().GetAllNodesInBlock(this._rB);for(var i=0;i<_F7.length;i++){var _aAW=null;var _Eq=_F7[i];if(_Eq instanceof CDLAxisMember){if(!_Eq.IsCalc()){_aAW=this.oDialogMgr.oUIMgr.dataManager.metadata.GetData(_Eq.GetMemberId());}else{_aAW=this.oDialogMgr.oUIMgr.dataManager._kX.GetCalculation(_Eq.GetMemberId());if(!_Eq.IsDynamicCalc()){_aAW=_aAW.Clone();}}}else if(_Eq instanceof CDLAbsMember){_aAW=_Eq;}if(_aAW&&!this._j3[_aAW.GetId()]){var _an2=new CUIOperand(_aAW);this._j3[_an2.GetAssociatedObjId()]=_an2;}}};CUICalculationDlg.prototype.GetOperandFromGlobalOperandsList=function(_Mo){if(this._j3[_Mo]){return this._j3[_Mo];}return null;};CUICalculationDlg.prototype.AddOperandIntoCurrentContext=function(_VH,_GD){var _azg=null;if(_VH instanceof CDLAxisCalc){if((!_VH.IsDynamicCalc())||(!_GD)){_azg=_VH.Clone();}}else if(_VH instanceof CTempCalc){_azg=_VH.Clone();}else if(_VH instanceof CUIAxisMember){if(_VH.IsCalc()){if((!_VH.IsDynamicCalc())||(!_GD)){var _aGq=this.oDialogMgr.oUIMgr.dataManager._kX.GetCalculation(_VH.GetMemberId());_azg=_aGq.Clone();}}else{_azg=this.oDialogMgr.oUIMgr.dataManager.metadata.GetData(_Eq.GetMemberId());}}else if(_VH instanceof CDLAbsMember){_azg=_VH;}else{Debug.Assert(false);}if(_azg&&!this._f5._ry[_azg.GetId()]){var _an2=new CUIOperand(_azg);this._f5._ry[_an2.GetAssociatedObjId()]=_an2;}};CUICalculationDlg.prototype.GetOperandFromCurrentContext=function(_Mo){if(this._f5){if(this._f5._ry[_Mo]){return this._f5._ry[_Mo];}}return null;};CUICalculationDlg.prototype.SetStartEditing=function(_Gr){this._th=_Gr;if(this._f5){this.ClearEditingCalcContext();}Utilities.ClearObjectArray(this._j3);this.PopulateGlobalOperandsList();};CUICalculationDlg.prototype.EditCalculation=function(_HO){var _aIJ=null;var _KR=null;var _Gy=this.GetOperandFromCurrentContext(_HO);if(_Gy){_KR=_Gy.GetAssociatedObj().GetMathMLExprNode();}else{var _aGq=this.oDialogMgr.oUIMgr.dataManager._kX.GetCalculation(_HO);Debug.Assert(_aGq);_KR=_aGq.GetMathMLExprNode();}Debug.Assert(_KR);var _J9=_KR.GetOperator();if(_J9==ExpAPIXml.kSingleItemFunc){_aIJ=new CUICalculationSingleItem(this,_HO);}else if(_J9==CUICalculationDlg.kStaticNumCalc){_aIJ=new CUICalculationStaticNumber(this,_HO);}else if(Utilities.IsInArray(CUIUserSelection.ExprMap[ExpUserSelection.Binary],_J9)){_aIJ=new CUICalculationBinary(this,_HO);}else if(Utilities.IsInArray(CUIUserSelection.ExprMap[ExpUserSelection.Uniary],_J9)){_aIJ=new CUICalculationUnary(this,_HO);}else if(Utilities.IsInArray(CUIUserSelection.ExprMap[ExpUserSelection.UniaryFactor],_J9)){_aIJ=new CUICalculationUnaryFactor(this,_HO);}else if(Utilities.IsInArray(CUIUserSelection.ExprMap[ExpUserSelection.UniaryScope],_J9)){_aIJ=new CUICalculationUnaryScope(this,_HO);}else if(Utilities.IsInArray(CUIUserSelection.ExprMap[ExpUserSelection.UniaryScopeFactor],_J9)){_aIJ=new CUICalculationUnaryScopeFactor(this,_HO);}else{_aIJ=new CUICalculationNary(this,_HO);}if(this._f5){_aIJ._mG=this._f5;Utilities.CloneObjArray(this._f5._ry,_aIJ._ry);this._f5=_aIJ;}else{this._f5=_aIJ;_aIJ._mG=null;if(this._th){var _E9=this.oDialogMgr.oUIMgr.dataManager._kX.GetCalculationList();for(var i in _E9){var _aGq=_E9[i];if(_aGq.GetBlockRefId()==this._rB.GetId()){this.AddOperandIntoCurrentContext(_aGq,true);}}}}_aIJ.PopulateContext();};CUICalculationDlg.prototype.Display=function(_M3){var _Co=this.oDialogMgr.oUIMgr.appobj.oResources;var _Ke=this.sAppName;var _MY=new Object();var _Xf=Utilities.GenerateCallback(CUIManager.SafeDoHelpTopic,[_Ke,HelpConstants.kUserDefCalcLink]);_MY['IDS_HELP']=_Xf;var _6Q=(this.IsInEditingMode()?'IDS_USER_EDIT_CALCU_INSTRUCTION':'IDS_USER_DEF_CALCU_INSTRUCTION');if(!_M3){CUICalculationDlg.superclass.Display.call(this,'IDS_CALCU_DLG_TITLE',_MY,this._lq,_6Q);}else{CUICalculationDlg.superclass.Display.call(this,'IDS_CALCU_DLG_TITLE',_MY,null,_6Q,'IDS_CALC_DLG_NO_VALID_SELECTION');}};CUICalculationDlg.prototype.SetUserSelection=function(_TX,_GP){var _ap4=this.oDialogMgr.oUIMgr._jf.GetUIAxesContainer();if(!_TX){Debug.Assert(_ap4._hL);this._rK=_ap4._hL._az;}else{this._rK=_TX;}this._tD=_ap4.GetOppositeAxis(this._rK.GetUIAxis());this._rB=this._rK._cu;this._mR=this.oDialogMgr.oUIMgr.dataManager.metadata;};CUICalculationDlg.prototype.SubscribeWSEvent=function(){var _UD=this.oDialogMgr.oUIMgr._jf;_UD.Subscribe(this,ExpEvent.kCUIWorksheet_NoAxisSel);_UD.Subscribe(this,ExpEvent.kCUIWorksheet_MultiAxisSel);_UD.Subscribe(this,ExpEvent.kCUIWorksheet_ChangedAxisSel);if(_UD.GetUIAxesContainer()){var _ap4=_UD.GetUIAxesContainer();_ap4.GetUIAxis(CUIDataMatrix.iRowIndex)._az.Subscribe(this,ExpEvent.kUserSelection_BlockChange);_ap4.GetUIAxis(CUIDataMatrix.iColIndex)._az.Subscribe(this,ExpEvent.kUserSelection_BlockChange);_ap4.GetUIAxis(CUIDataMatrix.iRowIndex)._az.Subscribe(this,ExpEvent.kUserSelection_MemberChange);_ap4.GetUIAxis(CUIDataMatrix.iColIndex)._az.Subscribe(this,ExpEvent.kUserSelection_MemberChange);}};CUICalculationDlg.prototype.ClearDlg=function(){Utilities.DeleteAllFromArray(this._lm);this._cU=false;if(this._rK&&this._rK._bC.length>0){Utilities.DeleteAllFromArray(this._rK._bC);}if(this._lq){Dom.RemoveObject(this._lq);}if(this._w4){this._pY.Unload();this._w4.Unload();this._pY=null;this._w4=null;}if(this._oOperatorSelBox){this._qe.Unload();this._oOperatorSelBox.Unload();this._qe=null;this._oOperatorSelBox=null;}if(this._wL){this._wL=null;}this._bc=null;this.ClearDynamicUIComponents();this._jZ=null;for(var i in this._oEventTriggers){for(var j in this._oEventTriggers[i]){delete this._oEventTriggers[i][j];}delete this._oEventTriggers[j];}this._lj=null;if(this._sF){this._sF.Clear();this._sF=null;}Utilities.DeleteAllFromArray(this._gd);Utilities.DeleteAllFromArray(this._D);this._rF=null;};CUICalculationDlg.prototype.InitOPTypeArr=function(){CUICalculationDlg.OPTypeArr[CUICalculationDlg.ArithmeticCalc]=this.oRes.GetString('IDS_CALCU_DLG_ARITHMETIC_OP');CUICalculationDlg.OPTypeArr[CUICalculationDlg.PercentageCalc]=this.oRes.GetString('IDS_CALCU_DLG_PERCENTAGE_OP');CUICalculationDlg.OPTypeArr[CUICalculationDlg.StatisticCalc]=this.oRes.GetString('IDS_CALCU_DLG_STATISTIC_OP');CUICalculationDlg.OPTypeArr[CUICalculationDlg.RelativePositionCalc]=this.oRes.GetString('IDS_CALCU_DLG_RELPOSITION_OP');CUICalculationDlg.OPTypeArr[CUICalculationDlg.ConstantCalc]=this.oRes.GetString('IDS_CALCU_DLG_CONSTANT_OP');this._tL=new Object();_QA=this.oDialogMgr.oUIMgr.dataManager.metadata;var _ak4=new Array(ExpAPIXml.kPlusFunc,ExpAPIXml.kMinusFunc,ExpAPIXml.kProdFunc,ExpAPIXml.kDividFunc,ExpAPIXml.kPowerFunc,ExpAPIXml.kAbsFunc,ExpAPIXml.kRoundFunc,ExpAPIXml.kRoundDownFunc,ExpAPIXml.kSquareRootFunc);this._tL[CUICalculationDlg.ArithmeticCalc]=new Array();for(i=0;i<_ak4.length;i++){if(_QA.IsFunctionSupported(_ak4[i])){this._tL[CUICalculationDlg.ArithmeticCalc].push(_ak4[i]);}}var _ajC=new Array(ExpAPIXml.kPercentFunc,ExpAPIXml.kPcntOfDiffFunc,CUICalculationDlg.ItemSeparator,ExpAPIXml.kPcntOfTotalFunc);this._tL[CUICalculationDlg.PercentageCalc]=new Array();for(i=0;i<_ajC.length;i++){if(_QA.IsFunctionSupported(_ajC[i])){this._tL[CUICalculationDlg.PercentageCalc].push(_ajC[i]);}}var _77=new Array(ExpAPIXml.kSumFunc,ExpAPIXml.kDiffFunc,ExpAPIXml.kAvgFunc,ExpAPIXml.kMaxFunc,ExpAPIXml.kMinFunc,ExpAPIXml.kMedianFunc,ExpAPIXml.kRollUpFunc);this._tL[CUICalculationDlg.StatisticCalc]=new Array();for(i=0;i<_77.length;i++){if(_QA.IsFunctionSupported(_77[i])){this._tL[CUICalculationDlg.StatisticCalc].push(_77[i]);}}var _asY=new Array(ExpAPIXml.kRankFunc,ExpAPIXml.kPercentileFunc,ExpAPIXml.kQuartileFunc,ExpAPIXml.kQuantile);this._tL[CUICalculationDlg.RelativePositionCalc]=new Array();for(i=0;i<_asY.length;i++){if(_QA.IsFunctionSupported(_asY[i])){this._tL[CUICalculationDlg.RelativePositionCalc].push(_asY[i]);}}var _aox=new Array(ExpAPIXml.kSingleItemFunc,CUICalculationDlg.kStaticNumCalc);this._tL[CUICalculationDlg.ConstantCalc]=new Array();for(i=0;i<_aox.length;i++){if(_QA.IsFunctionSupported(_aox[i])){this._tL[CUICalculationDlg.ConstantCalc].push(_aox[i]);}}};CUICalculationDlg.kApplyToSet='applytoset';CUICalculationDlg.kApplyToOperands='applytooperands';CUICalculationDlg.kCustomCalcName='customcalcname';CUICalculationDlg.kDefaultCalcName='defaultcalcname';CUICalculationDlg.kStaticNumCalc='staticnum';CUICalculationDlg.prototype.Create=function(){this.ClearDlg();var _Ke=this.sAppName;this._eB=this._rB.GetLabel();var _zr=document.createElement('TABLE');_zr.className='dialogTable';var _F0=document.createElement('TBODY');var _Rs=document.createElement('TR');_F0.appendChild(_Rs);var _NM=document.createElement('TD');_NM.className='calcExprEditArea';COTStyle.SetWidth(_NM,50,'%');_Rs.appendChild(_NM);var _ahN=document.createElement('TABLE');_NM.appendChild(_ahN);COTStyle.SetWidth(_ahN,95,'%');var _HC=document.createElement('TBODY');_ahN.appendChild(_HC);var _NH=document.createElement('TR');_HC.appendChild(_NH);var _NM=this._l4.cloneNode(false);_NM.colSpan=2;_NH.appendChild(_NM);var _apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_CALCU_DLG_OPERATION_TYPE'));_NM.appendChild(_apS);_NH=document.createElement('TR');_HC.appendChild(_NH);_NM=document.createElement('TD');_NH.appendChild(_NM);_NM.colSpan=2;this._pY=new CUIListCtrl(this.oDialogMgr.oUIMgr);this._pY.SetMaxHeight(80);this._pY.Init();this._pY.DisableHAutoScroll();this._w4=new CUIComboBox(this.oDialogMgr.oUIMgr,this._pY);this._w4.DisableIcon();_NM.appendChild(this._w4.Init());this._w4.SetWidthByPX(200);this._w4.Subscribe(this,ExpEvent.kCUIComboBox_OnSelChange);var _aHv=Utilities.GenerateCallback(this.OnSetOperatorSelBox,null,this);this._oEventTriggers[ExpEvent.kCUIComboBox_OnSelChange][this._w4.GetId()]=_aHv;this.SetOpTypeOpts(this._w4);_NH=document.createElement('TR');_HC.appendChild(_NH);_NM=this._l4.cloneNode(false);_NH.appendChild(_NM);_NM.colSpan=2;_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_CALCU_DLG_OPERATION'));_NM.appendChild(_apS);_NH=document.createElement('TR');_HC.appendChild(_NH);_NM=document.createElement('TD');_NH.appendChild(_NM);_NM.colSpan=2;this._qe=new CUIListCtrl(this.oDialogMgr.oUIMgr);this._qe.SetMaxHeight(150);this._qe.Init();this._qe.DisableHAutoScroll();this._oOperatorSelBox=new CUIComboBox(this.oDialogMgr.oUIMgr,this._qe);this._oOperatorSelBox.DisableIcon();_NM.appendChild(this._oOperatorSelBox.Init());this._oOperatorSelBox.SetWidthByPX(200);this._oOperatorSelBox.Subscribe(this,ExpEvent.kCUIComboBox_OnSelChange);var _aHv=Utilities.GenerateCallback(this.HandleOperatorSelection,[true],this);this._oEventTriggers[ExpEvent.kCUIComboBox_OnSelChange][this._oOperatorSelBox.GetId()]=_aHv;var _LI=true;this.SetOperatorOpts(this._oOperatorSelBox,null,null,_LI);if(this._oOperatorSelBox.GetValue()==ExpAPIXml.kSingleItemFunc){this.CreateConstantOpEditor(_HC);}else if(this._oOperatorSelBox.GetValue()==CUICalculationDlg.kStaticNumCalc){this.CreateConstantOpEditor(_HC,true);}else if(Utilities.IsInArray(CUIUserSelection.ExprMap[ExpUserSelection.Binary],this._oOperatorSelBox.GetValue())){this.CreateBinaryEditor(_HC);}else if(Utilities.IsInArray(CUIUserSelection.ExprMap[ExpUserSelection.Uniary],this._oOperatorSelBox.GetValue())){this.CreateUnaryEditor(_HC);}else if(Utilities.IsInArray(CUIUserSelection.ExprMap[ExpUserSelection.UniaryFactor],this._oOperatorSelBox.GetValue())){this.CreateUnaryEditor(_HC,true);}else if(Utilities.IsInArray(CUIUserSelection.ExprMap[ExpUserSelection.UniaryScope],this._oOperatorSelBox.GetValue())){this.CreateUnaryScopeEditor(_HC);}else{this.CreateNaryEditor(_HC);}_HC.id=Utilities.GenerateId();this._jZ=_HC.id;var _NM=document.createElement('TD');_NM.className='calcExprDisplay';COTStyle.SetWidth(_NM,50,'%');_Rs.appendChild(_NM);var _aJw=document.createElement('TABLE');_NM.appendChild(_aJw);COTStyle.SetWidth(_aJw,90,'%');var _ahE=document.createElement('TBODY');_aJw.appendChild(_ahE);_NH=document.createElement('TR');_ahE.appendChild(_NH);_NM=this._l4.cloneNode(false);_NM.colSpan=2;_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_CALCU_DLG_EXPRESSION'));_NM.appendChild(_apS);_NH.appendChild(_NM);_NH=document.createElement('TR');_ahE.appendChild(_NH);_NM=this._gM.cloneNode(true);_NM.colSpan=2;this._bc=COTInputElementFactory.CreateTextArea(8,50,'',false);this._bc.readOnly=true;this._bc.style.cursor="default";this._bc.style.fontSize='100%';_NM.appendChild(this._bc);_NH.appendChild(_NM);_NH=document.createElement('TR');_ahE.appendChild(_NH);_NM=document.createElement('TD');_NH.appendChild(_NM);COTStyle.SetWidth(_NM,18);this._wL=COTInputElementFactory.CreateImage('arrow_left.gif',16,16);_NM.appendChild(this._wL);_NM=document.createElement('TD');COTStyle.SetWidth(_NM,250);var _aCi=Utilities.GenerateCallback(this.DoAddOperands,[],this);this._uz=COTInputElementFactory.CreateLink(_aCi,this.oRes.GetString('IDS_CALCU_DLG_REUSE_AS_ITEM'),true);_NM.appendChild(this._uz);_NH.appendChild(_NM);_NH=document.createElement('TR');_ahE.appendChild(_NH);_NM=this._l4.cloneNode(false);_NM.colSpan=2;COTStyle.SetHeight(_NM,25);_NM.style.paddingTop='52px';_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_CALC_NAME'));_NM.appendChild(_apS);_NH.appendChild(_NM);_NH=document.createElement('TR');_ahE.appendChild(_NH);_NM=this._g5.cloneNode(false);COTStyle.SetWidth(_NM,25,'px');COTStyle.SetHeight(_NM,20);this._af=COTInputElementFactory.CreateRadioButton('calcName',CUICalculationDlg.kDefaultCalcName,true);_NM.appendChild(this._af);_NH.appendChild(_NM);_NM=this._g5.cloneNode(false);_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_USE_DEF_CALC_NAME'));_NM.appendChild(_apS);_NH.appendChild(_NM);_NH=document.createElement('TR');_ahE.appendChild(_NH);_NM=this._g5.cloneNode(false);COTStyle.SetWidth(_NM,25,'px');COTStyle.SetHeight(_NM,20);this._mf=COTInputElementFactory.CreateRadioButton('calcName',CUICalculationDlg.kCustomCalcName,false);_NM.appendChild(this._mf);_NH.appendChild(_NM);_NM=this._g5.cloneNode(false);this._jc=COTInputElementFactory.CreateTextBox(204,'px','',false,null,null,null,this);this._x5=this._jc.id;this._jc.style.fontSize='100%';_NM.appendChild(this._jc);_NH.appendChild(_NM);this._Y=Utilities.GenerateCallback(this.DoSubmitCalc,[],this);this._iG="IDS_BUTTON_OK";_zr.appendChild(_F0);this._lq=_zr;};CUICalculationDlg.prototype.SetOpTypeOpts=function(_MX,_RI){_MX.oListCtrl.ClearAllItems();_MX.ClearValue();var _LX;var _1W=CUICalculationDlg.ArithmeticCalc;if((this._rK.GetUnit()==ExpUserSelection.MemberUnit)&&(this._rK.GetType()==ExpUserSelection.Uniary)){var _ajs=this._rK._us[0];_1W=_ajs.IsCalc()?CUICalculationDlg.ConstantCalc:CUICalculationDlg.RelativePositionCalc;}for(var i in CUICalculationDlg.OPTypeArr){_LX=_MX.oListCtrl.AddItem('',CUICalculationDlg.OPTypeArr[i],0,i,CUICalculationDlg.OPTypeArr[i]);if(_RI){if(_RI==i){_MX.SetValueFromListItem(_LX,true,true);}}else if(_1W==i){_MX.SetValueFromListItem(_LX,true,true);}}};CUICalculationDlg.prototype.PopulateSubsVars=function(_SS,_MX){_MX.oListCtrl.ClearAllItems();var _LX;_LX=_MX.oListCtrl.AddItem('',this.oRes.GetString('IDS_USER_DEF_CALCU_NUMBER_SEL'),0,0,this.oRes.GetString('IDS_USER_DEF_CALCU_NUMBER_SEL'));for(var i in _SS){_LX=_MX.oListCtrl.AddItem('',_SS[i]._xU,0,_SS[i]._bb,_SS[i]._xU);}};CUICalculationDlg.prototype.OnSetOperatorSelBox=function(){this.SetOperatorOpts(this._oOperatorSelBox,true);};CUICalculationDlg.prototype.SetOperatorOpts=function(_MX,_DY,_KY,_LI){_MX.oListCtrl.ClearAllItems();_MX.ClearValue();var _adq=this._w4.GetValue();for(var i=0;i<this._tL[_adq].length;i++){if(this._tL[_adq][i]==CUICalculationDlg.ItemSeparator){_MX.oListCtrl.AddSeparator(30);continue;}var _42='';if(this._tL[_adq][i]in this._rK._rE){_42=this._rK._rE[this._tL[_adq][i]];}else{_42=this._rK._mS[this._tL[_adq][i]];}_LX=_MX.oListCtrl.AddItem('',_42,0,this._tL[_adq][i],_42);if(_KY){if(_KY==this._tL[_adq][i]){_MX.SetValueFromListItem(_LX,true,true);}}else if(i==0){_MX.SetValueFromListItem(_LX,true,true);}}if(!_LI){this.HandleOperatorSelection(_DY);}};CUICalculationDlg.prototype.SetOrderOpts=function(_MX){_MX.oListCtrl.ClearAllItems();_MX.ClearValue();var _J9=this._oOperatorSelBox.GetValue();var _Ct=this._lm;var _asy=this._rK.CreateExpression(_J9,_Ct);var _LX=_MX.oListCtrl.AddItem('',_asy.GetLabel(),0,_asy.GetId(),_asy.GetTooltip(),false);_LX._jb=true;_LX._at=_asy.GetId();var _91=new Array();for(var i=(this._lm.length-1);i>=0;i--){_91[_91.length]=this._lm[i];}var _awd=this._rK.CreateExpression(_J9,_91);var _8F=_MX.oListCtrl.AddItem('',_awd.GetLabel(),0,_awd.GetId(),_awd.GetTooltip(),false);_8F._jb=true;_8F._at=_awd.GetId();var _aqG=true;if(this._bc){_aqG=(this._bc.value!=_awd.GetLabel());}if(_aqG){_MX.SetValueFromListItem(_LX,false,true);}else{_MX.SetValueFromListItem(_8F,false,true);}return(_aqG?_asy:_awd);};CUICalculationDlg.prototype.addOperand=function(oMem,_Kj,_Q5,_Qn){var _aBF=(oMem instanceof CUIOperand)||(oMem instanceof CUICalculationExpr)||(oMem.IsValidCalcOperand());var _Rz='';var _aAV=false;var _26=true;if(_aBF){if(oMem instanceof CUIOperand){_99=oMem.GetAssociatedObjLabel(this.oDialogMgr.oUIMgr.dataManager.metadata,this._rK,this._f5._ry);_abe=oMem.GetAssociatedObj().GetId();_Rz=_99;_aAV=oMem.IsTempCalcOperand();_26=oMem.IsValidOperand();}else if(oMem instanceof CUIAxisMember){_99=oMem.GetLabel();_abe=oMem.GetMemberId();_Rz=_99;}else if(oMem instanceof CUICalculationExpr){_99=oMem.GetLabel();_abe=oMem.GetId();_Rz=oMem.GetTooltip();}if(this.IsInEditingMode()){if(!_26){_Rz=gResource.ReplaceParam('IDS_CALC_INVALID_WARNING',1,_Rz);}var _LX=_Kj.AddItem('',_99,0,_abe,_Rz,_Qn);_LX._vg=this.oDialogMgr.oUIMgr.dataManager.metadata.GetData(_abe)?false:true;_LX._fO=_aAV;_LX._ar=(!_26);if(_Q5&&_Qn){_Q5.SetValueFromListItem(_LX,true,true);}}else{var _3r=false;if((!this._cU)&&(!_Qn)){for(var i=0;i<this._rK._us.length;i++){if(oMem.GetMemberId()==this._rK._us[i].GetMemberId()){_3r=true;break;}}}var _LX=_Kj.AddItem('',_99,0,_abe,_Rz,_3r);_LX._vg=this.oDialogMgr.oUIMgr.dataManager.metadata.GetData(_abe)?false:true;if(_Q5){if(_3r){_Q5.SetValueFromListItem(_LX,true,true);_Qn=true;}else if((!_Qn)&&(this._cU)){_Q5.SetValueFromListItem(_LX,true,true);_Qn=true;}}}}return _Qn;};CUICalculationDlg.prototype.IsAddTempOperands=function(){for(var i=this._D.length;i>0;i--){for(var j=0;j<this._f5._hl.length;j++){if(this._D[i-1].value!=this._f5._hl[j]){return true;}}}return false;};CUICalculationDlg.prototype.SetBaseOperands=function(_Kj,_Q5,_IZ){_Kj.ClearAllItems();if(_Q5){_Q5.ClearValue();}var _Qn=false;if(_IZ&&_Q5){_Q5.SetValue(CUIComboBox.kDummyItem,this.oRes.GetString('IDS_CALCU_DLG_OPERANDS_EMPTY_ITEM'),null,true);_Qn=true;}for(var i=this._D.length;i>0;i--){this._D[i-1]._qD=false;if((!this.IsInEditingMode())||this.IsAddTempOperands()){_Kj._wj.push(this._D[i-1]);}if(!_Qn){if(_Q5){_Q5.SetValueFromListItem(this._D[i-1],true,true);this._lm.push(this._D[i-1]);_Qn=true;}}}var _Q1=this._rK.GetUIAxis();var oMem=_Q1.GetUIMember(this._rB.GetFirstNode());if(this.IsInEditingMode()){var _3d=this._f5.GetCalcOperandId();for(var i=0;i<this._f5._hl.length;i++){var _Gy=this.GetOperandFromCurrentContext(this._f5._hl[i]);this.addOperand(_Gy,_Kj,_Q5,(!this.IsAddTempOperands()));}if(_Q5){_Kj.AddSeparator(46);}else{_Kj.AddSeparator(70);}for(var i in this._j3){var _Gy=this._j3[i];var _aBb=this.GetOperandFromCurrentContext(_Gy.GetAssociatedObjId());var _ab0=(_aBb?_aBb:_Gy);if(Utilities.IsInArray(this._f5._hl,_Gy.GetAssociatedObjId())||_3d==_Gy.GetAssociatedObjId()){continue;}else if(_ab0.IsReferencingCalc(_3d,this._f5._ry)){continue;}else{this.addOperand(_ab0,_Kj,_Q5,false);}}}else{var _F7=_Q1.GetDLAxis().GetAllNodesInBlock(this._rB);var _aHx=this._rB.IsGroupedDescendantsAtDepth();for(var i=0;i<_F7.length;i++){if(_aHx&&_F7[i].IsDynamicCalc()){continue;}if(_Q1.GetUIMember(_F7[i])){_Qn=this.addOperand(_Q1.GetUIMember(_F7[i]),_Kj,_Q5,_Qn);}}}_Kj.DisableHAutoScroll();if(!_Q5){_Kj.Show();}};CUICalculationDlg.prototype.SetPreSelections=function(){if(this._kq){this._kq.PreSelItems();}this.SyncExpression(true);};CUICalculationDlg.prototype.UpdateExpressionText=function(_UN,_Dt,_CM){if(this._bc){if(this._bc.value==_UN){return;}this._bc.value=_UN;if(this._bc._J){Dom.RemoveAllChildren(this._bc._J);if(this.IsInEditingMode()&&_Dt){var _aGi=_Dt.GetLabelDiv();if(_CM&&_aGi){this._bc._J.appendChild(_aGi);}else{this._bc._J.appendChild(document.createTextNode(this._bc.value));}}else{this._bc._J.appendChild(document.createTextNode(this._bc.value));}}}if(!this._bc.value||this._bc.value==""){this._uz.disabled=true;this._uz.className="disabled_link";this._wL.src=Utilities.IMG_PATH+"arrow_left_grey.gif";}else{this._uz.disabled=false;this._uz.className="dialogFunctionLink";this._wL.src=Utilities.IMG_PATH+"arrow_left.gif";}};CUICalculationDlg.prototype.GenerateFullExpr=function(_BM){var _aBl=_BM;if(this.IsInEditingMode()&&(_BM)){var _aBi=this._f5;var _aB3=_aBi._mG;var _agZ=null;var _aHU=_aBi.GetCalcOperandId();while(_aB3){_agZ=_aB3;_aB3=_aB3._mG;}if(_agZ){var _atG=this.GetOperandFromCurrentContext(_agZ.GetCalcOperandId()).Clone();var _aAE=new Object();Utilities.CloneObjArray(_aBi._ry,_aAE);var _Gy=_aAE[_aHU];var _aww=_Gy.GetAssociatedObj();var _QA=this.oDialogMgr.oUIMgr.dataManager.metadata;_aww._p8=_BM;_aww._nh=_aww._p8;for(var i in _aAE){_Gy=_aAE[i];if(_Gy.IsReferencingCalc(_aHU,_aAE)){var _9S=_Gy.GetAssociatedObj();var _3Z=_9S._gV.GenerateExpressionLabel(_QA,this._rK,_aAE);if(_9S.UseDefaultName()){_9S._p8=_3Z;}_9S._nh=_3Z;}}_aBl=_aAE[_agZ.GetCalcOperandId()].GetAssociatedObj().GetLabel();}}return _aBl;};CUICalculationDlg.prototype.HandleOperatorSelection=function(_NN){var _J9=this._oOperatorSelBox.GetValue();var _aH5=this._rF?this._rF:null;if(this._rF==_J9){return;}var _acF=false;if(_aH5){for(var i in CUIUserSelection.ExprMap){_acF=Utilities.IsInSameArray(_aH5,_J9,CUIUserSelection.ExprMap[i]);if(_acF){if(Utilities.IsInSameArray(_aH5,_J9,CUICalculationDlg.OPTypeArr)){break;}else{_acF=false;}}}}this._lj=null;if(this._sF){this._sF.Clear();this._sF=null;}this._rF=_J9;if(!_acF){if(this._bc){this.UpdateExpressionText('');}if(this._rK._ni){this._rK._ni.Clear();}if(_NN){this.DoUpdateExprEditor();}if(this._kq){this.SetSelItemRangeRule();if(_NN){this._kq.ClearSelections();Utilities.DeleteAllFromArray(this._lm);}}if(this._ef){if(_NN){this._ef.checked=false;}}}else{this.SyncExpression();}};CUICalculationDlg.prototype.SetSelItemRangeRule=function(){var _J9=this._oOperatorSelBox.GetValue();if(this._kq){if(Utilities.IsInArray(CUIUserSelection.ExprMap[ExpUserSelection.Uniary],_J9)||Utilities.IsInArray(CUIUserSelection.ExprMap[ExpUserSelection.UniaryFactor],_J9)||Utilities.IsInArray(CUIUserSelection.ExprMap[ExpUserSelection.UniaryScope],_J9)||Utilities.IsInArray(CUIUserSelection.ExprMap[ExpUserSelection.UniaryScopeFactor],_J9)){this._kq.SetSelItemNumRange(1,1);}else if(Utilities.IsInArray(CUIUserSelection.ExprMap[ExpUserSelection.Binary],_J9)){this._kq.SetSelItemNumRange(2,2);}else{this._kq.SetSelItemNumRange(2,CUIListCtrl.NoNumRestriction);}}};CUICalculationDlg.prototype.CreateNaryEditor=function(_HC){var _Ke=this.sAppName;var _NH=document.createElement('TR');_HC.appendChild(_NH);this._gd.push(_NH);var _NM=this._l4.cloneNode(false);_NM.colSpan=2;if(Utilities.bUnlimitedCalcEnabled){var _apg=_NM.appendChild(COTInputElementFactory.CreateImage('drag_drop.gif',17,13));_NM.title=this.oRes.GetString('IDS_CALCU_DLG_DROP_EXT_OPERANDS_TOOLTIP');_apg.style.marginRight='5px';}_NH.appendChild(_NM);var _apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_CALCU_DLG_OPERANDS'));_NM.appendChild(_apS);_NH=document.createElement('TR');_HC.appendChild(_NH);this._gd.push(_NH);_NM=document.createElement('TD');_NM.colSpan=2;this._kq=new CUIListCtrl(this.oDialogMgr.oUIMgr);this._kq.SetMaxHeight(80);this._kq.SetMaxWidth(290);var _agW=_NM.appendChild(this._kq.Init());this._kq.EnableMultiSelect();this._kq.Subscribe(this,ExpEvent.kCUIListCtrl_OnKeyDown);this._kq.Subscribe(this,ExpEvent.kCUIListCtrl_OnSelChange);this._kq.oDlgObj=this;if(Utilities.bUnlimitedCalcEnabled){var _Zz=[this._rB,this._mR];this._kq.SetupListCtrlForDragDrop(this.oDialogMgr.oUIMgr,CUICalculationDlg.CanDropTreeData,_Zz);this._kq.Subscribe(this,ExpEvent.kCUIListCtrl_OnExternalDataDrop);}_NH.appendChild(_NM);this.SetBaseOperands(this._kq);if(this.IsInEditingMode()){this.SetSelItemRangeRule();}else{this.HandleOperatorSelection();}_NH=document.createElement('TR');_HC.appendChild(_NH);this._gd.push(_NH);_NM=this._g5.cloneNode(false);var _aIK=Utilities.GenerateCallback(this.SyncExpression,[true],this);var _6I=this.HasNumberFactor();this._ef=COTInputElementFactory.CreateCheckBox('numFactor','numFactor',_6I,_aIK);this._ef.className+=' vAlign_middle';_NM.style.whiteSpace='nowrap';_NM.appendChild(this._ef);if(this._mR.SubsVarsExist()){_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_USER_DEF_CALCU_VALUE'));}else{_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_USER_DEF_CALCU_NUM'));}_NM.appendChild(_apS);_NH.appendChild(_NM);_NM=document.createElement('TD');COTStyle.SetWidth(_NM,100,'%');if(this._mR.SubsVarsExist()){this._qe=new CUIListCtrl(this.oDialogMgr.oUIMgr);this._qe.SetMaxHeight(80);this._qe.Init();this._qe.DisableHAutoScroll();this._aI=new CUIComboBox(this.oDialogMgr.oUIMgr,this._qe);this._aI.Subscribe(this,ExpEvent.kCUIComboBox_OnSelection);this._aI.Subscribe(this,ExpEvent.kCUIComboBox_OnBlurTextBox);var _aHv=Utilities.GenerateCallback(this.HandleSubsVarChange,null,this);this._oEventTriggers[ExpEvent.kCUIComboBox_OnSelection][this._aI.GetId()]=_aHv;this._aI.SetArrowImageName("substitution_variables.gif");this._aI.SetArrowImageDisabledName("substitution_variables_disabled.gif");this._aI.AllowTextEdit();this._aI.DisableIcon();this._aI.SetArrowTDClassName("ComboBoxArrowWhite");var _afs=_NM.appendChild(this._aI.Init());this._aI.SetWidthByPX(150);this._aI.EnableHoverOverArrowEffect("ComboBoxArrowWhite_hover");this.PopulateSubsVars(this._mR._gY,this._aI);}else{this._xu=COTInputElementFactory.CreateFloatTextBox(this,20,'',false,false);this._xu.className+=' vAlign_middle';_NM.appendChild(this._xu);}_NH.appendChild(_NM);};CUICalculationDlg.prototype.CreateBinaryEditor=function(_HC){var _NH=document.createElement('TR');this._gd.push(_NH);_HC.appendChild(_NH);var _NM=this._l4.cloneNode(false);_NM.colSpan=2;if(Utilities.bUnlimitedCalcEnabled){var _apg=_NM.appendChild(COTInputElementFactory.CreateImage('drag_drop.gif',17,13));_NM.title=this.oRes.GetString('IDS_CALCU_DLG_DROP_EXT_OPERANDS_TOOLTIP');_apg.style.marginRight='5px';}var _apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_CALCU_DLG_OPERANDS'));_NM.appendChild(_apS);_NH.appendChild(_NM);_NH=document.createElement('TR');_HC.appendChild(_NH);this._gd.push(_NH);_NM=document.createElement('TD');_NM.colSpan=2;this._kq=new CUIListCtrl(this.oDialogMgr.oUIMgr);this._kq.SetMaxHeight(80);this._kq.SetMaxWidth(290);var _agW=_NM.appendChild(this._kq.Init());this._kq.EnableMultiSelect();this._kq.Subscribe(this,ExpEvent.kCUIListCtrl_OnKeyDown);this._kq.Subscribe(this,ExpEvent.kCUIListCtrl_OnSelChange);this._kq.oDlgObj=this;if(Utilities.bUnlimitedCalcEnabled){var _Zz=[this._rB,this._mR];this._kq.SetupListCtrlForDragDrop(this.oDialogMgr.oUIMgr,CUICalculationDlg.CanDropTreeData,_Zz);this._kq.Subscribe(this,ExpEvent.kCUIListCtrl_OnExternalDataDrop);}_NH.appendChild(_NM);this.SetBaseOperands(this._kq);if(this.IsInEditingMode()){this.SetSelItemRangeRule();}else{this.HandleOperatorSelection();}_NH=document.createElement('TR');_HC.appendChild(_NH);this._gd.push(_NH);_NM=this._g5.cloneNode(false);var _Ke=this.sAppName;var _aIK=Utilities.GenerateCallback(this.SyncBinNumCombineExpression,[true],this);var _6I=this.HasNumberFactor();this._ef=COTInputElementFactory.CreateCheckBox('numFactor','numFactor',_6I,_aIK);this._ef.className+=' vAlign_middle';_NM.style.whiteSpace='nowrap';_NM.appendChild(this._ef);if(this._mR.SubsVarsExist()){_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_USER_DEF_CALCU_VALUE'));}else{_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_USER_DEF_CALCU_NUM'));}_NM.appendChild(_apS);_NH.appendChild(_NM);_NM=document.createElement('TD');_NM=this._g5.cloneNode(false);COTStyle.SetWidth(_NM,100,'%');if(this._mR.SubsVarsExist()){this._qe=new CUIListCtrl(this.oDialogMgr.oUIMgr);this._qe.SetMaxHeight(80);this._qe.Init();this._qe.DisableHAutoScroll();this._aI=new CUIComboBox(this.oDialogMgr.oUIMgr,this._qe);this._aI.Subscribe(this,ExpEvent.kCUIComboBox_OnSelection);this._aI.Subscribe(this,ExpEvent.kCUIComboBox_OnBlurTextBox);var _aHv=Utilities.GenerateCallback(this.HandleSubsVarChange,null,this);this._oEventTriggers[ExpEvent.kCUIComboBox_OnSelection][this._aI.GetId()]=_aHv;this._aI.SetArrowImageName("substitution_variables.gif");this._aI.SetArrowImageDisabledName("substitution_variables_disabled.gif");this._aI.AllowTextEdit();this._aI.DisableIcon();this._aI.SetArrowTDClassName("ComboBoxArrowWhite");var _afs=_NM.appendChild(this._aI.Init());this._aI.SetWidthByPX(150);this._aI.EnableHoverOverArrowEffect("ComboBoxArrowWhite_hover");this.PopulateSubsVars(this._mR._gY,this._aI);}else{this._xu=COTInputElementFactory.CreateFloatTextBox(this,20,'',false,false);this._xu.className+=' vAlign_middle';_NM.appendChild(this._xu);}_NH.appendChild(_NM);_NH=document.createElement('TR');_HC.appendChild(_NH);this._gd.push(_NH);_NM=this._l4.cloneNode(false);_NM.colSpan=2;var _apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_CALCU_DLG_ORDER'));_NM.appendChild(_apS);_NH.appendChild(_NM);_NH=document.createElement('TR');this._gd.push(_NH);_HC.appendChild(_NH);_NM=document.createElement('TD');_NH.appendChild(_NM);_NM.colSpan=2;this._ci=new CUIListCtrl(this.oDialogMgr.oUIMgr);this._ci.SetMaxHeight(80);this._ci.Init();this._ci.DisableHAutoScroll();this._i6=new CUIComboBox(this.oDialogMgr.oUIMgr,this._ci);this._i6.DisableIcon();_NM.appendChild(this._i6.Init());this._i6.SetWidthByPX(200);this._i6.Subscribe(this,ExpEvent.kCUIComboBox_OnSelChange);var _aHv=Utilities.GenerateCallback(this.UseAlternativeExpr,null,this);this._oEventTriggers[ExpEvent.kCUIComboBox_OnSelChange][this._i6.GetId()]=_aHv;};CUICalculationDlg.prototype.CreateSingleOperandSelBox=function(_HC){var _NH=document.createElement('TR');this._gd.push(_NH);_HC.appendChild(_NH);var _NM=this._l4.cloneNode(false);_NM.colSpan=2;if(Utilities.bUnlimitedCalcEnabled){var _apg=_NM.appendChild(COTInputElementFactory.CreateImage('drag_drop.gif',17,13));_NM.title=this.oRes.GetString('IDS_CALCU_DLG_DROP_EXT_OPERANDS_TOOLTIP');_apg.style.marginRight='5px';}var _apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_CALCU_DLG_OPERANDS'));_NM.appendChild(_apS);_NH.appendChild(_NM);_NH=document.createElement('TR');_HC.appendChild(_NH);this._gd.push(_NH);_NM=document.createElement('TD');_NH.appendChild(_NM);_NM.colSpan=2;this._e5=new CUIListCtrl(this.oDialogMgr.oUIMgr);this._e5.SetMaxHeight(80);this._e5.Init();this._e5.DisableHAutoScroll();this._ul=new CUIComboBox(this.oDialogMgr.oUIMgr,this._e5);this._ul.DisableIcon();_NM.appendChild(this._ul.Init());this._ul.SetWidthByPX(200);this._ul.Subscribe(this,ExpEvent.kCUIComboBox_OnSelChange);if(Utilities.bUnlimitedCalcEnabled){var _Zz=[this._rB,this._mR];this._ul.SetupComboBoxForDragDrop(this.oDialogMgr.oUIMgr,CUICalculationDlg.CanDropTreeData,_Zz,true);this._e5.Subscribe(this,ExpEvent.kCUIListCtrl_OnExternalDataDrop);}var _aFc=Utilities.GenerateCallback(this.SyncExpression,[true],this);var _3Y=Utilities.GenerateCallback(this.UpdateUnaryScopeLabels,null,this);var _aHv=Utilities.GenerateCallbackUnion([_aFc,_3Y]);this._oEventTriggers[ExpEvent.kCUIComboBox_OnSelChange][this._ul.GetId()]=_aHv;this.SetBaseOperands(this._e5,this._ul);};CUICalculationDlg.prototype.CreateConstantOpEditor=function(_HC,_DS){if(!_DS){this.CreateSingleOperandSelBox(_HC);}else{this._jE=document.createElement('TR');_HC.appendChild(this._jE);this._gd.push(this._jE);var _NM=this._l4.cloneNode(false);_NM.style.whiteSpace='nowrap';this._jE.appendChild(_NM);var _apS;if(this._mR.SubsVarsExist()){_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_USER_DEF_CALCU_VALUE'));}else{_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_USER_DEF_CALCU_NUM'));}_NM.appendChild(_apS);var _apS=COTInputElementFactory.CreateLabel(this.oRes.GetString(' '));_NM.appendChild(_apS);_NM=document.createElement('TD');COTStyle.SetWidth(_NM,100,'%');if(this._mR.SubsVarsExist()){this._qe=new CUIListCtrl(this.oDialogMgr.oUIMgr);this._qe.SetMaxHeight(80);this._qe.Init();this._qe.DisableHAutoScroll();this._aI=new CUIComboBox(this.oDialogMgr.oUIMgr,this._qe);this._aI.Subscribe(this,ExpEvent.kCUIComboBox_OnSelection);this._aI.Subscribe(this,ExpEvent.kCUIComboBox_OnBlurTextBox);var _aHv=Utilities.GenerateCallback(this.HandleSubsVarChange,null,this);this._oEventTriggers[ExpEvent.kCUIComboBox_OnSelection][this._aI.GetId()]=_aHv;this._aI.SetArrowImageName("substitution_variables.gif");this._aI.SetArrowImageDisabledName("substitution_variables_disabled.gif");this._aI.AllowTextEdit();this._aI.DisableIcon();this._aI.SetArrowTDClassName("ComboBoxArrowWhite");var _afs=_NM.appendChild(this._aI.Init());this._aI.SetWidthByPX(150);this._aI.EnableHoverOverArrowEffect("ComboBoxArrowWhite_hover");this.PopulateSubsVars(this._mR._gY,this._aI);}else{this._xu=COTInputElementFactory.CreateFloatTextBox(this,20,'',false,false);this._xu.className+=' vAlign_middle';_NM.appendChild(this._xu);if(this.IsInEditingMode()){this.SetNumbFactorByCurrCalc();}}this._jE.appendChild(_NM);}};CUICalculationDlg.prototype.CreateUnaryEditor=function(_HC,_Vs){this.CreateSingleOperandSelBox(_HC);if(_Vs){var _NH=document.createElement('TR');_HC.appendChild(_NH);this._gd.push(_NH);var _NM=this._g5.cloneNode(false);_NH.appendChild(_NM);_NM.style.whiteSpace='nowrap';var _apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_USER_DEF_CALCU_NUM'));_NM.appendChild(_apS);_NH=document.createElement('TR');_HC.appendChild(_NH);this._gd.push(_NH);_NM=this._g5.cloneNode(false);_NH.appendChild(_NM);this._xu=COTInputElementFactory.CreateFloatTextBox(this,20,'',false,false);this._xu.className+=' vAlign_middle';_NM.appendChild(this._xu);}};CUICalculationDlg.prototype.CreateUnaryScopeEditor=function(_HC,_Vs){this.CreateSingleOperandSelBox(_HC);var _aEp=this._tD.GetDLAxis().HasHAMCMeasureBlocksOnly();var _avC=this._rB.oAxis._rk.GetCurrentMeasureId()?true:false;var _ast=this._rB.oAxis._rk.HasMeasureBlock();this._lN=this._rB.HasMeasures();if(_Vs){var _NH=document.createElement('TR');_HC.appendChild(_NH);this._gd.push(_NH);var _NM=this._l4.cloneNode(false);_NM.colSpan=2;_NH.appendChild(_NM);var _apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_USER_DEF_CALCU_QUANTILE_NUM'));_NM.appendChild(_apS);this._xu=COTInputElementFactory.CreateIntegerTextBox(this,10,'',false,false,0,null,false,true,true,10);this._xu.className+=' vAlign_middle';_NM.appendChild(this._xu);}var _85=Utilities.EventCallback(this.OnRadioClick,[],this,true,false);if(!this._rB.HasMeasures()){var _NH=document.createElement('TR');this._gd.push(_NH);_HC.appendChild(_NH);var _NM=this._l4.cloneNode(false);_NM.colSpan=2;var _apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_CALCU_DLG_MEASURE_SELECT'));_NM.appendChild(_apS);_NH.appendChild(_NM);_NH=document.createElement('TR');_HC.appendChild(_NH);this._gd.push(_NH);_NM=this._g5.cloneNode(false);var _amD=(!_avC)&&(!this._rB.oAxis._rk.HasMeasureBlock());var _aIf=(this.IsEditingUnaryScope())?(this.UsingCurrentMeasure()):(!_amD);var _ay3=COTInputElementFactory.CreateRadioButton('applicablemeasure',ExpAPIXml.kEleCurrentMeasure,_aIf,_amD,_85);COTStyle.SetWidth(_ay3,20,'px');_NM.appendChild(_ay3);_NH.appendChild(_NM);_NM=this._g5.cloneNode(false);_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_CALC_EXPR_APPLICABLE_MEASURE'));_NM.appendChild(_apS);_NH.appendChild(_NM);_NH=document.createElement('TR');_HC.appendChild(_NH);this._gd.push(_NH);_NM=this._g5.cloneNode(false);var _2f=COTInputElementFactory.CreateRadioButton('applicablemeasure',CUICalculationDlg.kSelectedMeasure,!_aIf,false,_85);COTStyle.SetWidth(_2f,20,'px');_NM.appendChild(_2f);_NH.appendChild(_NM);_NM=document.createElement('TD');_NH.appendChild(_NM);this._kP=new CUIListCtrl(this.oDialogMgr.oUIMgr);this._kP.SetMaxHeight(80);this._kP.Init();this._kP.DisableHAutoScroll();this._eg=new CUIComboBox(this.oDialogMgr.oUIMgr,this._kP);this._eg.DisableIcon();_NM.appendChild(this._eg.Init());this._eg.SetWidthByPX(200);this._eg.Subscribe(this,ExpEvent.kCUIComboBox_OnSelChange);var _aHv=Utilities.GenerateCallback(this.SyncExpression,[true],this);this._oEventTriggers[ExpEvent.kCUIComboBox_OnSelChange][this._eg.GetId()]=_aHv;this._eg.Subscribe(this,ExpEvent.kCUIComboBox_OnSelection);_aHv=Utilities.GenerateCallback(this.SetSelectMeasureRadio,null,this);this._oEventTriggers[ExpEvent.kCUIComboBox_OnSelection][this._eg.GetId()]=_aHv;var _axv=_avC;var _zd=false;var _AT=this.oDialogMgr.oUIMgr.dataManager;this._eg.PopulateMeasureOptions(_AT.metadata,_AT.GetCurrentDataMatrix(),_axv,_zd,false,true);var _LX=this._eg.oListCtrl.GetItemByIndex(0);this._eg.SetValueFromListItem(_LX,false);if(this.IsInEditingMode()&&(!_aIf)){_LX=this._eg.oListCtrl.GetItemByValue(this.GetRankMeasure());if(_LX){this._eg.SetValueFromListItem(_LX,false);}}this._eg.SetupComboBoxForDragDrop(this.oDialogMgr.oUIMgr);}_NH=document.createElement('TR');_HC.appendChild(_NH);this._gd.push(_NH);_NM=this._l4.cloneNode(false);_NH.appendChild(_NM);_NM.colSpan=2;var _aII=CUIUserSelection.aResSuffixMap[this._oOperatorSelBox._gx.GetValue()];var _Np=this.oRes.GetString('IDS_RELATIVE_POSITION_CALC_SCOPE_CTRL_LABEL_'+_aII);_apS=COTInputElementFactory.CreateLabel(_Np);_NM.appendChild(_apS);_NH.appendChild(_NM);_NH=document.createElement('TR');_HC.appendChild(_NH);this._gd.push(_NH);_NM=this._g5.cloneNode(false);var _afF=(this._tD.GetDepth()==0)?true:false;if(!_afF){var _J9=this._oOperatorSelBox.GetValue();if(_aEp&&(_J9==ExpAPIXml.kPcntOfTotalFunc)){_afF=true;}}var _43=(this.IsEditingUnaryScope())?(this.UsingDefaultScope()):(!_afF);this._ai=COTInputElementFactory.CreateRadioButton('scope',CUICalculationDlg.RelPosOppositeAxis,_43,_afF,_85);COTStyle.SetWidth(this._ai,20,'px');_NM.appendChild(this._ai);var _Bb=this._rK.GetUIAxis().IsRowAxis()?'rank_row_all_values.gif':'rank_column_all_values.gif';_apS=COTInputElementFactory.CreateImage(_Bb,20,20);if(_o.is_firefox){_NM.style.minWidth="49px";}_NM.appendChild(_apS);_NH.appendChild(_NM);this._aR=this._g5.cloneNode(false);var _aC0=this._ul._gx.GetLabel();_Np=this.oRes.ReplaceParam('IDS_RELATIVE_POSITION_CALC_ON_DEFAULT_SCOPE',1,_aC0);var _aCa=COTInputElementFactory.CreateLabel(_Np);this._aR.appendChild(_aCa);_NH.appendChild(this._aR);_NH=document.createElement('TR');_HC.appendChild(_NH);this._gd.push(_NH);_NM=this._g5.cloneNode(false);var _Ss=this._lN?true:false;var _apW=(this.IsEditingUnaryScope())?(this.UsingSameAxisScope()):(_afF&&(!_Ss));this._qz=COTInputElementFactory.CreateRadioButton('scope',CUICalculationDlg.RelPosSameAxis,_apW,_Ss,_85);COTStyle.SetWidth(this._qz,20,'px');_NM.appendChild(this._qz);_Bb=this._rK.GetUIAxis().IsRowAxis()?'rank_row_each_column.gif':'rank_column_each_row.gif';_apS=COTInputElementFactory.CreateImage(_Bb,20,20);_NM.appendChild(_apS);_NH.appendChild(_NM);this._pC=this._g5.cloneNode(false);_Np=this.oRes.ReplaceParam('IDS_RELATIVE_POSITION_CALC_ON_SAME_AXIS',1,_aC0);_Np=this.oRes.ReplaceParam(_Np,2,this._rB.GetLabel());var _5b=COTInputElementFactory.CreateLabel(_Np);this._pC.appendChild(_5b);_NH.appendChild(this._pC);_NH=document.createElement('TR');_HC.appendChild(_NH);this._gd.push(_NH);_NM=this._g5.cloneNode(false);var _aIu=(this.IsEditingUnaryScope())?(this.UsingCustomScope()):(false);this._gj=COTInputElementFactory.CreateRadioButton('scope',CUICalculationDlg.RelPosCustomScope,_aIu,false,_85);COTStyle.SetWidth(this._gj,20,'px');_NM.appendChild(this._gj);_NH.appendChild(_NM);_NM=this._g5.cloneNode(false);var _Np=this.oRes.GetString('IDS_RELATIVE_POSITION_CALC_CUSTOM_SCOPE');var _Ke=this.sAppName;var _ab9=Utilities.GenerateCallback(this.OpenCustomDlg,[],this);this._pK=COTInputElementFactory.CreateLink(_ab9,_Np,true);_NM.appendChild(this._pK);_NH.appendChild(_NM);};CUICalculationDlg.prototype.UpdateUnaryScopeLabels=function(){if(this._oOperatorSelBox){if(Utilities.IsInArray(CUIUserSelection.ExprMap[ExpUserSelection.UniaryScope],this._oOperatorSelBox.GetValue())||Utilities.IsInArray(CUIUserSelection.ExprMap[ExpUserSelection.UniaryScopeFactor],this._oOperatorSelBox.GetValue())){var _aC0=this._ul._gx.GetLabel();if(this._aR){_Np=this.oRes.ReplaceParam('IDS_RELATIVE_POSITION_CALC_ON_DEFAULT_SCOPE',1,_aC0);Dom.ReplaceText(this._aR,_Np);}if(this._pC){_Np=this.oRes.ReplaceParam('IDS_RELATIVE_POSITION_CALC_ON_SAME_AXIS',1,_aC0);_Np=this.oRes.ReplaceParam(_Np,2,this._rB.GetLabel());Dom.ReplaceText(this._pC,_Np);}}}};CUICalculationDlg.prototype.ClearDynamicUIComponents=function(){Utilities.DeleteAllFromArray(this._lm);for(var i=0;i<this._gd.length;i++){Dom.RemoveObject(this._gd[i]);}Utilities.DeleteAllFromArray(this._gd);if(this._ul){this._e5.Unload();this._ul.Unload();this._e5=null;this._ul=null;}if(this._xu){this._xu=null;this._ef=null;}if(this._i6){this._ci.Unload();this._i6.Unload();this._ci=null;this._i6=null;}if(this._kq){this._kq.ClearSelections();this._kq.Unload();this._kq=null;}if(this._eg){this._kP.Unload();this._eg.Unload();this._kP=null;this._eg=null;}if(this._jE){this._jE=null;}this._lN=false;this._c8=null;};CUICalculationDlg.prototype.UpdateOperandList=function(){if(this._kq){this.SetBaseOperands(this._kq);}else if(this._e5){this.SetBaseOperands(this._e5,this._ul,true);}};CUICalculationDlg.prototype.DoUpdateExprEditor=function(_Fp){var _HC=document.getElementById(this._jZ);this.ClearDynamicUIComponents();var _J9=this._oOperatorSelBox.GetValue();if(_J9==ExpAPIXml.kSingleItemFunc){this.CreateConstantOpEditor(_HC);if(!_Fp){this.SyncExpression(true);}}else if(_J9==CUICalculationDlg.kStaticNumCalc){this.CreateConstantOpEditor(_HC,true);}else if(Utilities.IsInArray(CUIUserSelection.ExprMap[ExpUserSelection.Binary],_J9)){this.CreateBinaryEditor(_HC);}else if(Utilities.IsInArray(CUIUserSelection.ExprMap[ExpUserSelection.Uniary],_J9)){this.CreateUnaryEditor(_HC);this.SyncExpression(true);}else if(Utilities.IsInArray(CUIUserSelection.ExprMap[ExpUserSelection.UniaryFactor],_J9)){this.CreateUnaryEditor(_HC,true);this.SyncExpression(true);}else if(Utilities.IsInArray(CUIUserSelection.ExprMap[ExpUserSelection.UniaryScope],_J9)){this.CreateUnaryScopeEditor(_HC);if(Utilities.IsInArray(CUIUserSelection.ExprMap[ExpUserSelection.PcntBasedUniaryScope],_J9)){this._c8=CUICalculationDlg.kDirectionNA;}else{this._c8=ExpAPIXml.kDefaultOrdiDirection;}this.SyncExpression(true);}else if(Utilities.IsInArray(CUIUserSelection.ExprMap[ExpUserSelection.UniaryScopeFactor],_J9)){this.CreateUnaryScopeEditor(_HC,true);this.SyncExpression(true);}else{this.CreateNaryEditor(_HC);}};CUICalculationDlg.prototype.SafeDoUpdateOperandsArr=function(){this._pN=false;var _J9=this._oOperatorSelBox.GetValue();Utilities.DeleteAllFromArray(this._lm);if(this._kq){for(var i=0;i<this._kq._aG.length;i++){this._lm.push(this._kq._aG[i]);}}else if(this._ul){if(Utilities.IsInArray(CUIUserSelection.ExprMap[ExpUserSelection.UniaryScope],_J9)||Utilities.IsInArray(CUIUserSelection.ExprMap[ExpUserSelection.UniaryScopeFactor],_J9)){var _UN=COTInputElementFactory.GetRadioSelectionValue('scope');if(!_UN&&this.IsEditingUnaryScope()){_UN=this.GetRankScopeUIOperation();}if(!_UN){return;}if(this._lN){var _at6=this.oRes.GetString('IDS_CALC_EXPR_CURRENT_MEASURE');var _aqj=new COTLiteralOperands(ExpAxisObjType.Measure,CUICalculationDlg.kDupMeasure,_at6);this._lm.push(_aqj);}else{var _aeP=COTInputElementFactory.GetRadioSelectionValue('applicablemeasure');if(!_aeP&&this.IsEditingUnaryScope()){_aeP=this.GetRankMeasure();}if(_aeP==ExpAPIXml.kEleCurrentMeasure){var _aqj=new COTLiteralOperands(ExpAxisObjType.Measure,ExpAPIXml.kEleCurrentMeasure,ExpAPIXml.kEleCurrentMeasure);this._lm.push(_aqj);}else{this._lm.push(this._eg._gx);}}this._lm.push(this._ul._gx);if(_UN==CUICalculationDlg.RelPosCustomScope){if(this._c8!=CUICalculationDlg.kDirectionNA){var _Yz=new COTOrdinalOperands(ExpAPIXml.kOrdinalDirection,this._c8);this._lm[this._lm.length]=_Yz;}else{this._lm[this._lm.length]=CUICalculationDlg.kDirectionNA;}var _aqP=false;var _Yv=this._jt;if((!_Yv||_Yv.length==0)&&this.IsEditingUnaryScope()){_Yv=new Object();var _ajU=this.GetSegmentItems();for(var i=0;_ajU&&i<_ajU.length;i++){_Yv[this.GetSegmentBlock(i)]=_ajU[i];}}for(var i in _Yv){var dm=this.oDialogMgr.oUIMgr.dataManager.GetCurrentDataMatrix();var _FK=dm.GetBlock(i);if(!_FK){Utilities.DeleteAllFromArray(this._lm);return;}var _aBE=_FK.GetLabel();var _Ck=_Yv[i];var _DP=CUICustomScopeDialog.SegmentOpts[_Ck]+'_DESC';var _akj=new COTSegmentOperand(i,_aBE,_Ck,_DP);this._lm.push(_akj);_aqP=true;}if(!_aqP){this._lm.push(this._tD);}this._pN=true;}else{if(this._c8==CUICalculationDlg.kDirectionNA){this._lm[this._lm.length]=CUICalculationDlg.kDirectionNA;}else{var _Yz=new COTOrdinalOperands(ExpAPIXml.kOrdinalDirection,ExpAPIXml.kDefaultOrdiDirection);this._lm.push(_Yz);}var _7X=(_UN==CUICalculationDlg.RelPosSameAxis)?this._rK.GetUIAxis():this._tD;this._lm.push(_7X);}}else if(this._jE){this._lm.push(this._ul._gx);if(this._ul._gx&&(this._ul._gx.GetValue()==CUICalculationDlg.kStaticNumCalc)){this._jE.style.display='block';}else{this._jE.style.display='none';}}else{this._lm.push(this._ul._gx);}}};CUICalculationDlg.prototype.DoAddOperands=function(){var _ahp=true;this.DoAddExpression(_ahp);};CUICalculationDlg.prototype.OperandsValidation=function(_Ct,_J9){if(Utilities.IsInArray(CUIUserSelection.ExprMap[ExpUserSelection.Binary],_J9)){return(_Ct.length==2);}return((!this._kq)||_Ct.length>=this._kq.GetMinSelItemNum());};CUICalculationDlg.prototype.GetConstantValue=function(){if(this._xu){return Decimal.GetExpressionNum(this._xu.value);}else if(this._aI){return this._aI.GetValue();}};CUICalculationDlg.prototype.GetConstantLabel=function(){if(this._xu){return this._xu.value;}else if(this._aI){return this._aI.GetLabel();}};CUICalculationDlg.prototype.GetCurrentOperandsList=function(){if(this._kq){return this._kq;}if(this._e5){return this._e5;}};CUICalculationDlg.prototype.DoAddExpression=function(_LD,_S5,_CM){var _J9=this._oOperatorSelBox.GetValue();this._rK._ni=new CDLMathMLExprNode(_J9,true,true);if(_J9==CUICalculationDlg.kStaticNumCalc){this.UpdateExpressionText(this.GetConstantLabel());this._rK._ni.SetOperator(ExpAPIXml.kSingleItemFunc);var _aFl;if(this._mR.SubsVarsExist()&&this._mR.GetSubsVar(this.GetConstantValue())){_aFl=ExpAPIXml.kEleSubsVar;}else{_aFl=ExpAPIXml.kNumberOperands;}var _aAN=new COTLiteralOperands(_aFl,this.GetConstantValue(),this.GetConstantLabel());this._rK.GenerateMathMLExpr(_J9,new Array(_aAN),this._rK._ni);return;}if(_J9==ExpAPIXml.kSingleItemFunc){if(this._lm.length!=1){return;}else{var _Gy=this._lm[0];if(_Gy._jb){var _axD=this._rK._e4[_Gy.GetValue()];this._rK._ni.SetOperator(_axD._s4);this._rK.GenerateMathMLExpr(_axD._s4,_axD._fL,this._rK._ni);this.UpdateExpressionText(_axD.GetLabel());this.UnwrapTempSingleItem();return;}else if(this._bc){this.UpdateExpressionText(_Gy.GetLabel());this._rK.GenerateMathMLExpr(_J9,new Array(_Gy.GetValue()),this._rK._ni);this.UnwrapTempSingleItem();return;}}}var _6b=Utilities.IsInArray(CUIUserSelection.ExprMap[ExpUserSelection.Uniary],_J9)||Utilities.IsInArray(CUIUserSelection.ExprMap[ExpUserSelection.UniaryScope],_J9);if(Utilities.IsInArray(CUIUserSelection.ExprMap[ExpUserSelection.UniaryFactor],_J9)||Utilities.IsInArray(CUIUserSelection.ExprMap[ExpUserSelection.UniaryScopeFactor],_J9)){if(this.GetConstantValue()==''||this.GetConstantValue()==null){this.UpdateExpressionText('');this._rK._ni.Clear();return;}else{var _aFl;if(Utilities.IsInArray(CUIUserSelection.ExprMap[ExpUserSelection.UniaryScopeFactor],_J9)){_aFl=ExpAPIXml.kQuantNum;}else if(this._mR.SubsVarsExist()&&this._mR.GetSubsVar(this.GetConstantValue())){_aFl=ExpAPIXml.kEleSubsVar;}else{_aFl=ExpAPIXml.kNumberOperands;}var _aIp=new COTLiteralOperands(_aFl,this.GetConstantValue(),this.GetConstantLabel());if(Utilities.IsInArray(CUIUserSelection.ExprMap[ExpUserSelection.UniaryFactor],_J9)){this._lm[1]=_aIp;}else{this._lm[this._lm.length]=_aIp;}}_6b=true;}else{if(this._ef&&this._ef.checked){var _aJK=false;var _7u=(_J9==ExpAPIXml.kDividFunc||_J9==ExpAPIXml.kProdFunc||_J9==ExpAPIXml.kPercentFunc||_J9==ExpAPIXml.kPcntOfDiffFunc)?1:0;var _akR=((this.GetConstantValue()=='')||(this.GetConstantValue()==null))?_7u:this.GetConstantValue();for(var x=0;x<this._lm.length;x++){if((this._lm[x]instanceof COTLiteralOperands)&&(this._lm[x].GetType()==ExpAPIXml.kNumberOperands)){var _aFl;if(this._mR.SubsVarsExist()&&this._mR.GetSubsVar(this.GetConstantValue())){_aFl=ExpAPIXml.kEleSubsVar;}else{_aFl=ExpAPIXml.kNumberOperands;}this._lm[x]=new COTLiteralOperands(_aFl,_akR,this.GetConstantLabel());_aJK=true;break;}}if(Utilities.IsInArray(CUIUserSelection.ExprMap[ExpUserSelection.Binary],_J9)){if(!_aJK){if(this._lm.length>0){var _aER=this._lm.pop();Utilities.DeleteAllFromArray(this._lm);this._lm.push(_aER);}var _aFl;if(this._mR.SubsVarsExist()&&this._mR.GetSubsVar(this.GetConstantValue())){_aFl=ExpAPIXml.kEleSubsVar;}else{_aFl=ExpAPIXml.kNumberOperands;}var _aIp=new COTLiteralOperands(_aFl,_akR,this.GetConstantLabel());this._lm[this._lm.length]=_aIp;}}else{if(!_aJK){var _aFl;if(this._mR.SubsVarsExist()&&this._mR.GetSubsVar(this.GetConstantValue())){_aFl=ExpAPIXml.kEleSubsVar;}else{_aFl=ExpAPIXml.kNumberOperands;}var _aIp=new COTLiteralOperands(_aFl,_akR,this.GetConstantLabel());this._lm[this._lm.length]=_aIp;}}}}var _Ct=this._lm;var _7k=_6b||this.OperandsValidation(_Ct,_J9);if(_7k&&(_Ct.length>0)){var _Dt;if(this._i6){_Dt=this.SetOrderOpts(this._i6);}else{_Dt=this._rK.CreateExpression(_J9,_Ct);}if(_LD){var _Kj=this.GetCurrentOperandsList();_Kj.ClearSelections();var _LX=_Kj.AddItemToFront('',_Dt.GetLabel(),0,_Dt.GetId(),_Dt.GetTooltip(),false);_LX._fO=true;_LX._jb=true;_LX._at=_Dt.GetId();this._D.push(_LX);this.UpdateOperandList();if(this._bc){this.UpdateExpressionText('');}this._rK._ni.Clear();}if(_S5){this._rK._ni=this._rK.GenerateMathMLExpr(_J9,_Dt._fL,this._rK._ni);if(this._bc){this.UpdateExpressionText(_Dt.GetLabel(),_Dt,_CM);}}if(this._pN){if(!this._bE){this._lj=_Dt;this._sF=this._rK._ni;}else{if(this._bc){this.UpdateExpressionText('');}this._rK._ni.Clear();}}}else{if(this._bc){this.UpdateExpressionText('');}this._rK._ni.Clear();}};CUICalculationDlg.prototype.DoDelOperands=function(){this._kq.RemoveItems(true,this._lm);this.SafeDoUpdateOperandsArr();};CUICalculationDlg.SafeDoDelOperands=function(_Ke){try{FindApp(_Ke).uiManager.oDialogMgr._jg.DoDelOperands();}catch(excep){_f.HandleException(excep);}};CUICalculationDlg.prototype.DoSubmitCalc=function(){if(this._rK.GetUnit()==ExpUserSelection.BlockUnit){this.oDialogMgr.oUIMgr._jf.SetLastBlockSelectionId(this._rB.GetId());}var _Fe='';if(this._mf.checked){_Fe=this._jc.value;}else{_Fe=this._bc.value;}if(this._bc.value!=''){if(this._mR.SubsVarsExist()&&this._aI){if(isNaN(this.GetConstantValue())&&!this._aI.oListCtrl.GetItemByValue(this.GetConstantValue())){CUIDialogMgr.DisplayMessageBox(CUIMessageBox.kWarning,'IDS_CALCU_DLG_INVALID_VALUE_WARNING');return;}}this._rB.CreateMathMLCalcExpr(this._bc.value,this._rK._ni,_Fe);if(this.IsInEditingMode()){this.ClearEditingCalcContext();}CUIDialogMgr.SafeHideCurrentDialog(this.sAppName);}else{CUIDialogMgr.DisplayMessageBox(CUIMessageBox.kWarning,'IDS_CALCU_DLG_NO_EXPR_WARNING');}};CUICalculationDlg.prototype.AutomaticExpressionFixUp=function(){if(this._lm.length==1){this._rK._ni=new CDLMathMLExprNode(ExpAPIXml.kSingleItemFunc,true,true);var _Gy=this._lm[0];if(_Gy._jb){var _axD=this._rK._e4[_Gy.GetValue()];this._rK._ni.SetOperator(_axD._s4);this._rK.GenerateMathMLExpr(_axD._s4,_axD._fL,this._rK._ni);this.UpdateExpressionText(_axD.GetLabel());this.UnwrapTempSingleItem();}else if(this._bc){this.UpdateExpressionText(_Gy.GetLabel());this._rK.GenerateMathMLExpr(ExpAPIXml.kSingleItemFunc,new Array(_Gy.GetValue()),this._rK._ni);this.UnwrapTempSingleItem();}}};CUICalculationDlg.prototype.DoSubmitEditingCalc=function(){if(this.IsInEditingMode()&&this._bc.value!=''){this.RecoverTempCalc();this.CreateMathMLCalcEditRequest();this.ClearEditingCalcContext();CUIDialogMgr.SafeHideCurrentDialog(this.sAppName);}else{CUIDialogMgr.DisplayMessageBox(CUIMessageBox.kWarning,'IDS_CALCU_DLG_NO_EXPR_WARNING');}};CUICalculationDlg.prototype.HandleCalcBlockChange=function(_Gy,_L7){var _VI=new Array();var _J3=null;var _UU=null;var _J3=this._rB.GetDeleteAction();_J3.AddSource(_Gy.GetAssociatedObjId(),ExpAPIXml.kEleCalc);if(_J3){_VI.push(_J3);}var _KR=_Gy.GetAssociatedObj().GetMathMLExprNode();var _alE=_Gy.GetAssociatedObj().GetLabel();var _azy=_Gy.GetAssociatedObj().GetDescription();_UU=this._rB.CreateMathMLCalcExpr(_alE,_KR,_azy,0,true);if(_UU){_VI.push(_UU);}if(_VI.length>0){this._rB.oAxis._rk.SendDMActionArray(_VI);}};CUICalculationDlg.prototype.CreateMathMLCalcEditRequest=function(){var _Jj=this._rB.oAxis._rk.GetDMAction();_Jj.type=ExpAPIXml.kActionModify;for(var i in this._f5._ry){var _Gy=this._f5._ry[i];if(_Gy&&_Gy._rg){var _KR=_Gy.GetAssociatedObj().GetMathMLExprNode();if(this._rB.IsGroupedDescendantsAtDepth()){var _ayy=this._rB.GetLogicalCalcPosition(_KR._sy);if(_ayy&&_ayy.tgtBlkId!=this._rB.sExprId){this.HandleCalcBlockChange(_Gy,_ayy.tgtBlkId);return;}}var _Lh=_c.CreateElement(ExpAPIXml.kEleObjectPtr,_Gy.GetAssociatedObjId());_Lh+=_c.CreateElement(ExpAPIXml.kEleCalcName,_Gy.GetAssociatedObj().GetLabel());_Lh+=_c.CreateElement(ExpAPIXml.kEleCalcLabel,_Gy.GetAssociatedObj().GetDescription());_Lh+=_c.CreateElement(ExpAPIXml.kEleAxisOpExprCalcExpr,_KR.WriteToXML(),true);var _Eq=this.getLastOperandNode(_KR);var _aE9=_Eq?_Eq.GetBlock().IsGroupedDescendantsAtDepth():false;if(this._rB.IsGroupedDescendantsAtDepth()||_aE9){var _VW=this._rB.GetCalcParent(_KR._sy);if(_VW){var _RJ=this._rB.oAxis._rk._he.metadata;var _BX=_VW.GetMemberId();_Hx=_VW.IsCalc()?ExpAPIXml.kEleCalc:(_RJ.GetMember(_BX)?ExpAPIXml.kEleMember:ExpAPIXml.kEleMeasure);var _PM=new CDLItem(_VW._uT,_Hx);_Lh+=_c.CreateElement(ExpAPIXml.kCalcParent,_PM.GetAsXMLString(),true);}var _74=this._rB.GetLowestSDNBlock();if(_74){var _6J=this.getLastOperandNode(_KR);var _Q1=this._rK.GetUIAxis();var _O0=_Q1.GetDLAxis();var _Ib=_O0.GetDataObj();if(_6J&&_O0&&_Ib){var _apj=_Ib.GetNodeTupleByNode(_6J);if(_apj){var _aIM=_apj.GetNodeHierarchy();var _aJx=null;var _F7=_Q1.GetDLAxis().GetAllNodesInBlock(this._rB);for(var i=0;i<_F7.length;i++){var _Eq=_F7[i];if(Utilities.IsInArray(_aIM,_Eq._uT)){_aJx=_Eq;break;}}}}var _RJ=this.oDialogMgr.oUIMgr.dataManager;if(_aJx){var _alV=_aJx._uT;var _Hx=ExpAPIXml.kEleMeasure;if(_aJx instanceof CDLAxisMember){if(_aJx.IsCalc()){_Hx=ExpAPIXml.kEleCalc;}else{_Hx=ExpAPIXml.kEleMember;}}var _PM=new CDLItem(_alV,_Hx);_Lh+=_c.CreateElement(ExpAPIXml.kCalcSibling,_PM.GetAsXMLString(),true);}}}var _aq3=_c.CreateElement(ExpAPIXml.kEleAxisOpExprCalc,_Lh,true);_Jj.AddParameter(new CDLParameter(ExpAPIXml.kCalculation,_aq3,CDLParameter.XMLType()));}}_Jj.AddTargetItem(this._rB.oAxis._ks,ExpAPIXml.kEleAxis);_Jj.AddTargetItem(this._rB.sExprId,ExpAPIXml.kEleAxisOpExpression);this._rB.oAxis._rk.SendDMAction(_Jj);};CUICalculationDlg.prototype.getLastOperandNode=function(_KR){var _LF=null;for(var i=_KR._sy.length-1;i>=0;i--){var _aHk=_KR._sy[i]._jU;_LF=this.getOperandNode(_aHk);if(_LF){break;}}return _LF;};CUICalculationDlg.prototype.getOperandNode=function(_Jg){var _Q1=this._rK.GetUIAxis();var _O0=_Q1.GetDLAxis();for(var _Lx in _O0._rR){var _FK=_O0._rR[_Lx];var _F7=_O0.GetAllNodesInBlock(_FK);for(var i=0;i<_F7.length;i++){var _Eq=_F7[i];if(_Eq._uT==_Jg){return _Eq;}}}return null;};CUICalculationDlg.prototype.RecoverTempCalc=function(){for(var i in this._f5._ry){var _Gy=this._f5._ry[i];if(_Gy&&_Gy.IsTempCalcOperand()){_Gy._rg=false;}if(_Gy&&_Gy._rg){var _KR=_Gy.GetAssociatedObj().GetMathMLExprNode();this.RecoverTempCalcOperand(_KR);}}};CUICalculationDlg.prototype.RecoverTempCalcOperand=function(_KR){if((!_KR)||(!_KR._sy)){return;}for(var j=0;j<_KR._sy.length;j++){exprOperand=_KR._sy[j];if(exprOperand){if((exprOperand instanceof CDLMathMLOperands)&&(exprOperand._ja==ExpAxisObjType.TempCalc)){var _awO=this.GetOperandFromCurrentContext(exprOperand._jU);_KR._sy[j]=_awO.GetAssociatedObj().GetMathMLExprNode();this.RecoverTempCalcOperand(_KR._sy[j]);}else if(exprOperand instanceof CDLMathMLExprNode){this.RecoverTempCalcOperand(exprOperand);}}}};CUICalculationDlg.prototype.UnwrapTempSingleItem=function(){if(this._rK._ni&&this._rK._ni._s4==ExpAPIXml.kSingleItemFunc){var _aom=this._rK._ni._sy;if(_aom&&_aom[0]){var _9c=_aom[0];if(_9c._ja==ExpAxisObjType.TempCalc){var _an2=this.GetOperandFromCurrentContext(_9c._jU);if(_an2){var _aah=_an2.GetAssociatedObj();this._rK._ni._s4=_aah.GetMathMLExprNode()._s4;Utilities.DeleteAllFromArray(this._rK._ni._sy);this._rK._ni._sy=Utilities.CopyArray(_aah.GetMathMLExprNode()._sy);}}}}};CUICalculationDlg.prototype.SetCurrentTrigger=function(_Mu){this._oCurrTrigger=_Mu;};CUICalculationDlg.prototype.HandleCustomRanking=function(){if(this._lj){this.UpdateExpressionText(this._lj.GetLabel());this._rK._ni=this._sF;this._bE=false;}else{this.UpdateExpressionText('');if(this._rK._ni){this._rK._ni.Clear();this._rK._ni=null;}this._bE=true;}};CUICalculationDlg.prototype.OnRadioClick=function(_Fa){if(_Fa.name=='applicablemeasure'){this.SyncExpression(true);}else if(_Fa.name=='scope'){var _UN=COTInputElementFactory.GetRadioSelectionValue('scope');if(CUICalculationDlg.RelPosCustomScope==_UN){this.HandleCustomRanking();}else{this.SyncExpression(true);}}};CUICalculationDlg.prototype.SetSelectMeasureRadio=function(){COTInputElementFactory.SelectRadioItem('applicablemeasure',CUICalculationDlg.kSelectedMeasure);this.SyncExpression(true);};CUICalculationDlg.SafeDoClearUncommittedChanges=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager.oDialogMgr._jg.ClearUncommittedChanges();CUIDialogMgr.SafeHideCurrentDialog(_Ke);/*@if(!@bering_debug)@*/}catch(excep){_f.HandleException(excep);}/*@end@*/};CUICalculationDlg.prototype.ClearUncommittedChanges=function(){if(this.IsInEditingMode()){this.ClearEditingCalcContext();Utilities.ClearObjectArray(this._j3);this.ClearDlg();CUIDialogMgr.SafeHideCurrentDialog(this.sAppName);}else{this.ClearDlg();}};CUICalculationDlg.prototype.ConfirmLossOfChanges=function(){if(this.IsInEditingMode()||(this._bc&&this._bc.value!='')){var _Ke=this.sAppName;var _aAS=Utilities.GenerateCallback(CUICalculationDlg.SafeDoClearUncommittedChanges,[_Ke]);var _anu=Utilities.GenerateCallback(CUIDialogMgr.SafeHideCurrentDialog,[_Ke]);var _aAo=Utilities.GenerateCallbackUnion([Utilities.SafeDoRemoveHoldingProcedure,_anu]);CUIDialogMgr._q5.SetCallBackFuntion(_aAS,_aAo);CUIDialogMgr._q5.Display('IDS_CALC_DLG_COMMIT_CHANGES','',CUIConfirmDlg._hw);return Utilities.eStateHold;}else{return Utilities.eStateContinue;}};CUICalculationDlg.prototype.Notify=function(event){if(event==ExpEvent.kCUIManager_Unload){this.Unload();}else if(event==ExpEvent.kCUIListCtrl_OnKeyDown){}else if(event==ExpEvent.kCUIListCtrl_OnSelChange){this._cU=true;this.SyncExpression(true);}else if(event==ExpEvent.kCUIComboBox_OnSelChange){this._cU=true;this._oEventTriggers[ExpEvent.kCUIComboBox_OnSelChange][this._oCurrTrigger.GetId()]();}else if(event==ExpEvent.kCUIComboBox_OnSelection){this._cU=true;this._oEventTriggers[ExpEvent.kCUIComboBox_OnSelection][this._oCurrTrigger.GetId()]();}else if(event==ExpEvent.kUserSelection_BlockChange||event==ExpEvent.kUserSelection_MemberChange){if(this._r3){this.Create();if(this.oDialogMgr.oUIMgr._jf.HasValidCalcSelection()){if(!this._rK){var _K9=this.oDialogMgr.oUIMgr._jf._wa;if(_K9 instanceof CDLBlock){var _aA6=this.oDialogMgr.oUIMgr._jf.GetUIAxesContainer().GetUIAxis(CUIDataMatrix.iRowIndex);_aA6=_aA6.GetDLAxis().GetBlock(_K9.GetId())?_aA6:this.oDialogMgr.oUIMgr._jf.GetUIAxesContainer().GetUIAxis(CUIDataMatrix.iColIndex);_K9=_aA6._az;}this.SetUserSelection(_K9);}this.Display();if(this._rK&&this._rK.GetUnit()==ExpUserSelection.MemberUnit){this.SetPreSelections();}}else{var _M3=true;this.Display(_M3);}}}else if(event==ExpEvent.kCUIWorksheet_MultiAxisSel){if(this._r3){this.ClearDlg();var _M3=true;this.Display(_M3);}}else if(event==ExpEvent.kCUIWorksheet_NoAxisSel){if(this._r3){if(this._eB){this._eB=null;}this.ClearDlg();var _M3=true;this.Display(_M3);}}else if(event==ExpEvent.kCUIWorksheet_ChangedAxisSel){if(this._r3){this.ClearDlg();this.SetUserSelection(null,false);this.Create();if(this.oDialogMgr.oUIMgr._jf.HasValidCalcSelection()){this.Display();if(this._rK&&this._rK.GetUnit()==ExpUserSelection.MemberUnit){this.SetPreSelections();}}else{var _M3=true;this.Display(_M3);}}}else if(event==ExpEvent.kCUIComboBox_OnBlurTextBox){this.SyncExpression(true);}else if(event==ExpEvent.kCUIListCtrl_OnExternalDataDrop){this.PersisteExternalData();}};CUICalculationDlg.prototype.PersisteExternalData=function(){var _Kj=this.GetCurrentOperandsList();for(var i=0;i<_Kj.GetNewExternalDataCount();i++){var _att=_Kj.GetItemByIndex(i);if(_att){this._D.push(_att);}}};CUICalculationDlg.prototype.UnLoad=function(){Dom.RemoveAllChildren(this._lq);CUICalculationDlg.superclass.Unload.call(this);};CUICalculationDlg.prototype.HandleSubsVarChange=function(){if(this._aI._kH.value==this.oRes.GetString('IDS_USER_DEF_CALCU_NUMBER_SEL')&&!isNaN(Decimal.GetNumericDecimal(this._aI.GetPrevText()))){var _LX=this._aI.oListCtrl.GetItemByValue(this._aI.GetPrevText());if(_LX){this._aI.SetValueFromListItem(_LX,false);}else{this._aI.SetValue(0,this._aI.GetPrevText());}this._aI._kH.select();}else if(this._aI._kH.value==this.oRes.GetString('IDS_USER_DEF_CALCU_NUMBER_SEL')){this._aI.SetValue('','');this._aI._kH.focus();}this.SyncExpression();};CUICalculationDlg.prototype.SyncExpression=function(_Wh,_CM){if(this._ul&&this._ul._N){CUIDialogMgr.DisplayMessageBox(CUIMessageBox.kWarning,this.oRes.GetString('IDS_DLG_REQUIRE_INPUT_WARNING'));return;}if(_Wh){this.SafeDoUpdateOperandsArr();}this.DoAddExpression(false,true,_CM);};CUICalculationDlg.prototype.SyncBinNumCombineExpression=function(_Wh){if(this._kq){if(this._ef.checked){if(this._kq._aG.length>1){this._kq.ClearSelections(1);}this._kq.SetSelItemNumRange(1,1);}else{this._kq.SetSelItemNumRange(2,2);this._i6.oListCtrl.ClearAllItems();this._i6.ClearValue();}}this.SyncExpression(true);};CUICalculationDlg.prototype.OpenCustomDlg=function(_Ke){if(this._ul&&this._ul._N){CUIDialogMgr.DisplayMessageBox(CUIMessageBox.kWarning,'IDS_CALCU_DLG_NO_SELECTION_WARNING');return;}this._jt=null;this._c8=null;COTInputElementFactory.SelectRadioItem('scope',CUICalculationDlg.RelPosCustomScope);this.HandleCustomRanking();if(!this._mv){this._mv=new CUICustomScopeDialog(this);this._mv.Init(this.oDialogMgr);this._mv.SetModalState();}this.oDialogMgr.ActivateModalDlgTemplate();this.oDialogMgr.SetModalDlgWidth(CUIDialogMgr.iInteractMDlgPcntOfTWidth);var _J9=this._oOperatorSelBox._gx.GetLabel();var _Ao=this._oOperatorSelBox._gx.GetValue();var _B9=Utilities.IsInArray(CUIUserSelection.ExprMap[ExpUserSelection.PcntBasedUniaryScope],_Ao)?CUICustomScopeDialog.kPercentBased:CUICustomScopeDialog.kRelativePosition;var _aC0=this._ul._gx.GetLabel();var _BE=this._rK.GetUIAxis();this._mv.SetInitParameter(_J9,_Ao,_aC0,_BE,this._tD,_B9,this._rB);var _Hq='IDS_RELATIVE_POSITION_CUSTOM_SCOPE_DLG_TITLE_'+CUIUserSelection.aResSuffixMap[_Ao];_KP=this.oRes.ReplaceParam(_Hq,2,_aC0);this._mv.Display(_KP);};CUICalculationDlg.prototype.UseAlternativeExpr=function(){var _Dt=this._rK._e4[this._i6.GetValue()];this._rK._ni.Clear();this._rK._ni.SetOperator(_Dt._s4);this._rK.GenerateMathMLExpr(_Dt._s4,_Dt._fL,this._rK._ni);this.UpdateExpressionText(_Dt.GetLabel());};CUICalculationDlg.prototype.OnFocusTextBox=function(_A4){if(this._x5==_A4.id){this._mf.checked=true;}else if(this._ef){this._ef.checked=true;this.SyncExpression();}};CUICalculationDlg.prototype.OnTextBoxKeyUp=function(_A4){if(this._x5!=_A4.id){this.SyncExpression();}};CUICalculationDlg.prototype.OnTextBoxValueChange=function(_Ce,_Pw){if(this._x5!=_Ce){this.SyncExpression();}};CUICalculationDlg.prototype.ProcessSegmentData=function(_Ab,_yJ){this._jt=_Ab;if(_yJ){this._c8=_yJ;}else{this._c8=CUICalculationDlg.kDirectionNA;}this.SyncExpression(true);};CUICalculationDlg.prototype.IsInEditingMode=function(){return(this._th&&this._f5);};CUICalculationDlg.SafeDoCancelCalcEditing=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager.oDialogMgr._jg.DoCancelCalcEditing();/*@if(!@bering_debug)@*/}catch(excep){_f.HandleException(excep);}/*@end@*/};CUICalculationDlg.SafeDoEditCalc=function(_Ke,_Fo){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager.oDialogMgr._jg.DoEditCalc(_Fo);/*@if(!@bering_debug)@*/}catch(excep){_f.HandleException(excep);}/*@end@*/};CUICalculationDlg.SafeDoSaveCalcEditing=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager.oDialogMgr._jg.DoSaveCalcEditing();/*@if(!@bering_debug)@*/}catch(excep){_f.HandleException(excep);}/*@end@*/};CUICalculationDlg.prototype.ClearEditingCalcContext=function(){if(this.IsInEditingMode()){this._f5.Clear();this._f5=null;}};CUICalculationDlg.prototype.DoCancelCalcEditing=function(){if(this.IsInEditingMode()&&this._f5._mG){this._f5=this._f5._mG;this.RenderCalcDlg();this.Display();}else{this.ClearEditingCalcContext();Utilities.ClearObjectArray(this._j3);CUIDialogMgr.SafeHideCurrentDialog(this.sAppName);}};CUICalculationDlg.prototype.DoEditCalc=function(_Fo){this.EditCalculation(_Fo);this.RenderCalcDlg();this.Display();};CUICalculationDlg.prototype.DoSaveCalcEditing=function(){var _Fe=null;if(this._mf.checked&&this._jc.value!=""){_Fe=this._jc.value;}if(this._bc&&this._bc.value==''){this.AutomaticExpressionFixUp();}if(this._f5._mG){if(this._bc.value!=''){this._f5.UpdateCalcOperandList(this._rK._ni,this._f5.GetCalcOperandId(),_Fe);var _2D=this._f5._mG;Utilities.CloneObjArray(this._f5._ry,_2D._ry);this._f5=_2D;this.RenderCalcDlg();this.Display();}else{CUIDialogMgr.DisplayMessageBox(CUIMessageBox.kWarning,'IDS_CALCU_DLG_NO_EXPR_WARNING');}}else{this._f5.UpdateCalcOperandList(this._rK._ni,this._f5.GetCalcOperandId(),_Fe);this.DoSubmitEditingCalc();}};CUICalculationDlg.prototype.RenderCalcDlg=function(){this.ClearDlg();var _Ke=this.sAppName;this._eB=this._rB.GetLabel();var _zr=document.createElement('TABLE');_zr.className='dialogTable';var _F0=document.createElement('TBODY');var _Rs=document.createElement('TR');_F0.appendChild(_Rs);this.CreateDlgContentByCurrCalc(_Rs);this.CreateDlgDescByCurrCalc(_Rs);if(this.IsInEditingMode()){if(this._f5._mG){this._iG="IDS_BUTTON_APPLY";}else{this._iG="IDS_BUTTON_OK";}this._Y=Utilities.GenerateCallback(CUICalculationDlg.SafeDoSaveCalcEditing,[_Ke]);this._of=Utilities.GenerateCallback(CUICalculationDlg.SafeDoCancelCalcEditing,[_Ke]);this._gl=Utilities.GenerateCallback(CUICalculationDlg.SafeDoCancelCalcEditing,[_Ke]);}_zr.appendChild(_F0);this._lq=_zr;this.SetNumbFactorByCurrCalc();this.SyncExpression(true,true);};CUICalculationDlg.prototype.CreateDlgContentByCurrCalc=function(_Rs){var _NM=document.createElement('TD');_NM.className='calcExprEditArea';COTStyle.SetWidth(_NM,50,'%');_Rs.appendChild(_NM);var _ahN=document.createElement('TABLE');_NM.appendChild(_ahN);COTStyle.SetWidth(_ahN,95,'%');var _HC=document.createElement('TBODY');_ahN.appendChild(_HC);var _NH=document.createElement('TR');_HC.appendChild(_NH);var _NM=this._l4.cloneNode(false);_NM.colSpan=2;_NH.appendChild(_NM);var _apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_CALCU_DLG_OPERATION_TYPE'));_NM.appendChild(_apS);_NH=document.createElement('TR');_HC.appendChild(_NH);_NM=document.createElement('TD');_NH.appendChild(_NM);_NM.colSpan=2;this._pY=new CUIListCtrl(this.oDialogMgr.oUIMgr);this._pY.SetMaxHeight(80);this._pY.Init();this._pY.DisableHAutoScroll();this._w4=new CUIComboBox(this.oDialogMgr.oUIMgr,this._pY);this._w4.DisableIcon();_NM.appendChild(this._w4.Init());this._w4.SetWidthByPX(200);this._w4.Subscribe(this,ExpEvent.kCUIComboBox_OnSelChange);var _aHv=Utilities.GenerateCallback(this.OnSetOperatorSelBox,null,this);this._oEventTriggers[ExpEvent.kCUIComboBox_OnSelChange][this._w4.GetId()]=_aHv;this.SetOpTypeOpts(this._w4,this.GetCnxtOperatorType());_NH=document.createElement('TR');_HC.appendChild(_NH);_NM=this._l4.cloneNode(false);_NH.appendChild(_NM);_NM.colSpan=2;_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_CALCU_DLG_OPERATION'));_NM.appendChild(_apS);_NH=document.createElement('TR');_HC.appendChild(_NH);_NM=document.createElement('TD');_NH.appendChild(_NM);_NM.colSpan=2;this._qe=new CUIListCtrl(this.oDialogMgr.oUIMgr);this._qe.SetMaxHeight(150);this._qe.Init();this._qe.DisableHAutoScroll();this._oOperatorSelBox=new CUIComboBox(this.oDialogMgr.oUIMgr,this._qe);this._oOperatorSelBox.DisableIcon();_NM.appendChild(this._oOperatorSelBox.Init());this._oOperatorSelBox.SetWidthByPX(200);this._oOperatorSelBox.Subscribe(this,ExpEvent.kCUIComboBox_OnSelChange);var _aHv=Utilities.GenerateCallback(this.HandleOperatorSelection,[true],this);this._oEventTriggers[ExpEvent.kCUIComboBox_OnSelChange][this._oOperatorSelBox.GetId()]=_aHv;var _LI=true;this.SetOperatorOpts(this._oOperatorSelBox,null,this.GetCnxtOperator(),_LI);if(this._oOperatorSelBox.GetValue()==ExpAPIXml.kSingleItemFunc){this.CreateConstantOpEditor(_HC,false,true);}else if(this._oOperatorSelBox.GetValue()==CUICalculationDlg.kStaticNumCalc){this.CreateConstantOpEditor(_HC,true,true);}else if(Utilities.IsInArray(CUIUserSelection.ExprMap[ExpUserSelection.Binary],this._oOperatorSelBox.GetValue())){this.CreateBinaryEditor(_HC,true);}else if(Utilities.IsInArray(CUIUserSelection.ExprMap[ExpUserSelection.Uniary],this._oOperatorSelBox.GetValue())){this.CreateUnaryEditor(_HC);}else if(Utilities.IsInArray(CUIUserSelection.ExprMap[ExpUserSelection.UniaryFactor],this._oOperatorSelBox.GetValue())){this.CreateUnaryEditor(_HC,true);}else if(Utilities.IsInArray(CUIUserSelection.ExprMap[ExpUserSelection.UniaryScope],this._oOperatorSelBox.GetValue())){this.CreateUnaryScopeEditor(_HC);var _yJ=this.GetOrdinalDirection();this._c8=(this.IsEditingUnaryScope()&&_yJ)?_yJ:CUICalculationDlg.kDirectionNA;}else if(Utilities.IsInArray(CUIUserSelection.ExprMap[ExpUserSelection.UniaryScopeFactor],this._oOperatorSelBox.GetValue())){this.CreateUnaryScopeEditor(_HC,true);}else{this.CreateNaryEditor(_HC,true);}_HC.id=Utilities.GenerateId();this._jZ=_HC.id;};CUICalculationDlg.prototype.CreateDlgDescByCurrCalc=function(_Rs){var _NM=document.createElement('TD');_NM.className='calcExprDisplay';COTStyle.SetWidth(_NM,50,'%');_Rs.appendChild(_NM);var _aJw=document.createElement('TABLE');_NM.appendChild(_aJw);COTStyle.SetWidth(_aJw,90,'%');var _ahE=document.createElement('TBODY');_aJw.appendChild(_ahE);_NH=document.createElement('TR');_ahE.appendChild(_NH);_NM=this._l4.cloneNode(false);_NM.colSpan=2;_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_CALCU_DLG_EXPRESSION'));_NM.appendChild(_apS);_NH.appendChild(_NM);if(this._f5._mG){var _aku=Utilities.GenerateCallback(CUICalculationDlg.SafeShowFullSyntax,[this.sAppName]);this._bi=COTInputElementFactory.CreateLink(_aku,this.oRes.GetString('IDS_CALCU_FULL_SYNTAX_LINK_LABEL'),false,'calcFullSyntax');_NM.appendChild(this._bi);}_NH=document.createElement('TR');_ahE.appendChild(_NH);_NM=this._gM.cloneNode(true);_NM.colSpan=2;this._bc=new CUICalcExprBoard(this);this._bc.Init();_NM.appendChild(this._bc._J);_NH.appendChild(_NM);_NH=document.createElement('TR');_ahE.appendChild(_NH);_NM=document.createElement('TD');_NH.appendChild(_NM);COTStyle.SetWidth(_NM,18);this._wL=COTInputElementFactory.CreateImage('arrow_left.gif',16,16);_NM.appendChild(this._wL);_NM=document.createElement('TD');COTStyle.SetWidth(_NM,250);var _aCi=Utilities.GenerateCallback(this.DoAddOperands,[],this);this._uz=COTInputElementFactory.CreateLink(_aCi,this.oRes.GetString('IDS_CALCU_DLG_REUSE_AS_ITEM'),true);_NM.appendChild(this._uz);_NH.appendChild(_NM);_NH=document.createElement('TR');_ahE.appendChild(_NH);_NM=this._l4.cloneNode(false);_NM.colSpan=2;COTStyle.SetHeight(_NM,25);_NM.style.paddingTop='48px';_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_CALC_NAME'));_NM.appendChild(_apS);_NH.appendChild(_NM);_NH=document.createElement('TR');_ahE.appendChild(_NH);_NM=this._g5.cloneNode(false);COTStyle.SetWidth(_NM,25,'px');COTStyle.SetHeight(_NM,20);this._af=COTInputElementFactory.CreateRadioButton('calcName',CUICalculationDlg.kDefaultCalcName,this._f5._yj);_NM.appendChild(this._af);_NH.appendChild(_NM);_NM=this._g5.cloneNode(false);_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_USE_DEF_CALC_NAME'));_NM.appendChild(_apS);_NH.appendChild(_NM);_NH=document.createElement('TR');_ahE.appendChild(_NH);_NM=this._g5.cloneNode(false);COTStyle.SetWidth(_NM,25,'px');COTStyle.SetHeight(_NM,20);this._mf=COTInputElementFactory.CreateRadioButton('calcName',CUICalculationDlg.kCustomCalcName,(!this._f5._yj));_NM.appendChild(this._mf);_NH.appendChild(_NM);_NM=this._g5.cloneNode(false);this._jc=COTInputElementFactory.CreateTextBox(204,'px','',false,null,null,null,this);this._x5=this._jc.id;this._jc.style.fontSize='100%';_NM.appendChild(this._jc);_NH.appendChild(_NM);if(!this._f5._yj){this._jc.value=this._f5._sU;}var _an2=this.GetOperandFromCurrentContext(this._f5.GetCalcOperandId());if(_an2&&_an2.IsTempCalcOperand()){this._jc.disabled=true;this._mf.disabled=true;}else{this._jc.disabled=false;this._mf.disabled=false;}};CUICalculationDlg.prototype.HasNumberFactor=function(){if(this.IsInEditingMode()){return(this._f5._bM&&this._f5._im&&this._f5._im!="");}return false;};CUICalculationDlg.prototype.GetCnxtNumberValue=function(){if(this.IsInEditingMode()){return this._f5._im;}return "";};CUICalculationDlg.prototype.GetCnxtOperator=function(){if(this.IsInEditingMode()){var _an2=this.GetOperandFromCurrentContext(this._f5.GetCalcOperandId());Debug.Assert(_an2);var _KR=_an2.GetAssociatedObj().GetMathMLExprNode();var _J9=_KR.GetOperator();if(_J9==ExpAPIXml.kSingleItemFunc){if(_KR._sy[0]._lW==CDLMathMLOperands.CNOperand){return CUICalculationDlg.kStaticNumCalc;}else{return _J9;}}else{return _J9;}}return null;};CUICalculationDlg.prototype.GetCnxtOperatorType=function(){if(this.IsInEditingMode()){return this._f5._u;}return 0;};CUICalculationDlg.prototype.SetNumbFactorByCurrCalc=function(){if(this.IsEditingUnaryScopeFactor()){if(this._xu){this._xu.value=this.GetUnaryScopeNumber();}}else{var _awD=this.GetCnxtNumberValue();if(this._xu&&(this._f5._aM==ExpAPIXml.kNumberOperands)){this._xu.value=_awD;}else if(this._aI){if(this._f5._aM==ExpAPIXml.kEleSubsVar){var _LX=this._aI.oListCtrl.GetItemByValue(_awD);this._aI.SetValueFromListItem(_LX,false);}else if(this._f5._aM==ExpAPIXml.kNumberOperands){var _LX=this._aI.oListCtrl.GetItemByValue(this.oRes.GetString('IDS_USER_DEF_CALCU_NUMBER_SEL'));this._aI.SetValueFromListItem(_LX,false);this._aI.SetValue(0,_awD);}}}};CUICalculationDlg.prototype.IsEditingUnaryScope=function(){return(this.IsInEditingMode()&&(this._f5 instanceof CUICalculationUnaryScope));};CUICalculationDlg.prototype.UsingCurrentMeasure=function(){if(this.IsEditingUnaryScope()){return(this._f5._vC==ExpAPIXml.kEleCurrentMeasure);}return false;};CUICalculationDlg.prototype.GetRankMeasure=function(){if(this.IsEditingUnaryScope()){return(this._f5._vC);}return;};CUICalculationDlg.prototype.UsingDefaultScope=function(){if(this.IsEditingUnaryScope()){return(this._f5._a2==ExpAPIXml.kOppositeAxis);}return false;};CUICalculationDlg.prototype.UsingSameAxisScope=function(){if(this.IsEditingUnaryScope()){return(this._f5._a2==ExpAPIXml.kCurrentAxis);}return false;};CUICalculationDlg.prototype.UsingCustomScope=function(){if(this.IsEditingUnaryScope()){return((this._f5._a2!=ExpAPIXml.kOppositeAxis)&&(this._f5._a2!=ExpAPIXml.kCurrentAxis));}return false;};CUICalculationDlg.prototype.GetRankScopeUIOperation=function(){if(this.IsEditingUnaryScope()){if(this.UsingDefaultScope()){return CUICalculationDlg.RelPosOppositeAxis;}else if(this.UsingSameAxisScope()){return CUICalculationDlg.RelPosSameAxis;}else{return CUICalculationDlg.RelPosCustomScope;}}return;};CUICalculationDlg.prototype.GetSegmentItems=function(){if(this.IsEditingUnaryScope()){if(this._f5._uy){return this._f5._uy;}}return;};CUICalculationDlg.prototype.GetSegmentItem=function(_TG){if(this.IsEditingUnaryScope()){if(this._f5._uy){return this._f5._uy[_TG];}}return;};CUICalculationDlg.prototype.GetSegmentBlock=function(_TG){if(this.IsEditingUnaryScope()){if(this._f5._ur){return this._f5._ur[_TG];}}return;};CUICalculationDlg.prototype.GetOrdinalDirection=function(){if(this.IsEditingUnaryScope()){return(this._f5._lM);}return;};CUICalculationDlg.prototype.IsEditingUnaryScopeFactor=function(){return(this.IsInEditingMode()&&(this._f5 instanceof CUICalculationUnaryScopeFactor));};CUICalculationDlg.prototype.GetUnaryScopeNumber=function(){if(this.IsEditingUnaryScopeFactor()&&this._f5._bM){return(this._f5._bh);}return;};CUICalculationDlg.SafeShowFullSyntax=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager.oDialogMgr._jg.ShowFullSyntax();/*@if(!@bering_debug)@*/}catch(excep){_f.HandleException(excep);}/*@end@*/};CUICalculationDlg.prototype.ShowFullSyntax=function(){if(!this._hX){this._hX=new CUIFullSyntaxDialog();this._hX.Init(this.oDialogMgr);this._hX.SetModalState();}this.oDialogMgr.ActivateModalDlgTemplate();this.oDialogMgr.SetModalDlgWidth(CUIDialogMgr.iInteractMDlgPcntOfTWidth);this._hX.Display(this.oRes.GetString('IDS_CALCU_FULL_SYNTAX_DLG_TITLE'),this.GetFullSyntax());};CUICalculationDlg.prototype.GetFullSyntax=function(){var _aBl=null;if(this._mf&&this._mf.checked&&this._jc&&this._jc.value!=""){_aBl=this.GenerateFullExpr(this._jc.value);}else{_aBl=this.GenerateFullExpr(this._bc.value);}return _aBl;};CUICalculationDlg.CanDropTreeData=function(_Lv,_FK,_RJ){var _atr=false;if((_Lv instanceof CUIDragDropMemberList)||(_Lv instanceof CUIDragDropMember)){var _auY=_RJ.IsFunctionSupported(ExpAPIXml.kQosMultiMeasureDimCalc);if(_auY){return true;}var _alH=_RJ.IsFunctionSupported(ExpAPIXml.kQosMultiHierOfSameDimCalc);var _Li=_FK.oAxis._rk;var _arr=_alH?_Lv.GetDimId(_RJ,_Li):_Lv.GetHierOrDimId(_RJ,_Li);var _aaw=_alH?_FK.GetDimId():_FK.GetHierarchyOrDimId();_atr=(_arr==_aaw);}return _atr;};function COTLiteralOperands(_zx,_UN,_Ic){this._lW=_zx;this._jU=_UN;this._p8=_Ic?_Ic:_UN;};COTLiteralOperands.prototype.GetValue=function(){return this._jU;};COTLiteralOperands.prototype.GetType=function(){return this._lW;};COTLiteralOperands.prototype.GetLabel=function(){return this._p8;};function COTOrdinalOperands(_zx,_UN,_Ic){this.base=COTLiteralOperands;this.base(_zx,_UN,_Ic);};COTOrdinalOperands.prototype=new COTLiteralOperands;COTOrdinalOperands.prototype.GetResSuffix=function(){if(this._jU==ExpAPIXml.kDefaultOrdiDirection){return "";}else if(this._jU==ExpAPIXml.kLowestOrdiDirection){return "_LOW";}else{return "_HIGH";}};function COTSegmentOperand(_HP,_Ld,_Ck,_DP){this._hK=_Ld;this._uA=_DP;this._s3=_Ck;this._eI=_HP;};COTSegmentOperand.prototype.GetSegValue=function(){return this._s3;};COTSegmentOperand.prototype.GetSegObjId=function(){return this._eI;};COTSegmentOperand.prototype.GetLabel=function(_Co){var _3B=_Co.ReplaceParam(this._uA,1,this._hK);return _3B;};function CUIRenameCalcDlg(){this.base=CUIDialog;this.base();this._rK=null;};CUIRenameCalcDlg.prototype=new CUIDialog;CUIRenameCalcDlg.superclass=CUIDialog.prototype;CUIRenameCalcDlg.prototype.Display=function(_BK){var _Co=this.oDialogMgr.oUIMgr.appobj.oResources;var _Ke=this.sAppName;var _MY=new Object();var _Xf=Utilities.GenerateCallback(CUIManager.SafeDoHelpTopic,[_Ke,HelpConstants.kUserDefCalcLink]);_MY['IDS_HELP']=_Xf;if(!_BK){CUIRenameCalcDlg.superclass.Display.call(this,'IDS_RENAME_CALCU_DLG_TITLE',_MY,this._lq,null);}else{CUIRenameCalcDlg.superclass.Display.call(this,'IDS_RENAME_CALCU_DLG_TITLE',_MY,null,null,_BK);}};CUIRenameCalcDlg.prototype.SetUserSelection=function(_TX,_GP){var oCrosstab=this.oDialogMgr.oUIMgr._jf.GetUICrosstab();if(!_TX){Debug.Assert(oCrosstab._hL);this._rK=oCrosstab._hL._az;}else{this._rK=_TX;}};CUIRenameCalcDlg.prototype.SubscribeWSEvent=function(){};CUIRenameCalcDlg.prototype.ClearDlg=function(){};CUIRenameCalcDlg.prototype.Create=function(){this.ClearDlg();var _Ke=this.sAppName;this._rB=this._rK._cu;this._a4=this._rK._us[0];var _aJL=this._a4.GetLabel();var _abb=this._a4.GetDefaultCalcLabel();var _am9=(_aJL==_abb)?true:false;var _zr=document.createElement('TABLE');_zr.className='dialogTable';var _F0=document.createElement('TBODY');_NH=document.createElement('TR');_F0.appendChild(_NH);_NM=this._l4.cloneNode(false);_NM.colSpan=2;_NM.style.paddingTop='10px';_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_CALC_NAME'));_NM.appendChild(_apS);_NH.appendChild(_NM);_NH=document.createElement('TR');_F0.appendChild(_NH);_NM=this._g5.cloneNode(false);COTStyle.SetWidth(_NM,25,'px');COTStyle.SetHeight(_NM,20);this._af=COTInputElementFactory.CreateRadioButton('calcName',CUICalculationDlg.kDefaultCalcName,_am9);_NM.appendChild(this._af);_NH.appendChild(_NM);_NM=this._g5.cloneNode(false);_apS=COTInputElementFactory.CreateLabel(this.oRes.ReplaceParam('IDS_USE_DEF_CALC_NAME_SHOW_EXPR',1,_abb));_NM.appendChild(_apS);_NH.appendChild(_NM);_NH=document.createElement('TR');_F0.appendChild(_NH);_NM=this._g5.cloneNode(false);COTStyle.SetWidth(_NM,25,'px');COTStyle.SetHeight(_NM,20);this._a4=this._rK._us[0];this._mf=COTInputElementFactory.CreateRadioButton('calcName',CUICalculationDlg.kCustomCalcName,!_am9);_NM.appendChild(this._mf);_NH.appendChild(_NM);_NM=this._g5.cloneNode(false);var _aAx=_am9?'':_aJL;this._jc=COTInputElementFactory.CreateTextBox(204,'px',_aAx,false,null,null,null,this);this._x5=this._jc.id;this._jc.style.fontSize='100%';_NM.appendChild(this._jc);_NH.appendChild(_NM);this._Y=Utilities.GenerateCallback(CUIRenameCalcDlg.SafeDoSubmitCalc,[_Ke]);this._iG="IDS_BUTTON_OK";_zr.appendChild(_F0);this._lq=_zr;};CUIRenameCalcDlg.SafeDoSubmitCalc=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager.oDialogMgr._jg.DoSubmitCalc();/*@if(!@bering_debug)@*/}catch(excep){_f.HandleException(excep);}/*@end@*/};CUIRenameCalcDlg.prototype.OnFocusTextBox=function(_A4){this._mf.checked=true;};CUIRenameCalcDlg.prototype.DoSubmitCalc=function(){var _Fe=null;if(this._mf.checked){_Fe=this._jc.value;if(_Fe==''){CUIDialogMgr.DisplayMessageBox(CUIMessageBox.kWarning,'IDS_RENAME_CALCU_DLG_NO_NAME_WARNING');return;}}var _Bs=this.CreateRenameOperandsList(this._a4.GetMemberId(),_Fe);this.CreateCalcRenameRequest(_Bs);CUIDialogMgr.SafeHideCurrentDialog(this.sAppName);};CUIRenameCalcDlg.prototype.CreateOperandsList=function(){var _Bs=new Object();var _azg=null;var _E9=this.oDialogMgr.oUIMgr.dataManager._kX.GetCalculationList();for(var i in _E9){var _aGq=_E9[i];if(_aGq.GetBlockRefId()==this._rB.GetId()){_azg=_aGq.Clone();if(_azg&&!_Bs[_azg.GetId()]){var _an2=new CUIOperand(_azg);_Bs[_an2.GetAssociatedObjId()]=_an2;}}}return _Bs;};CUIRenameCalcDlg.prototype.CreateRenameOperandsList=function(_Fo,_Fe){var _Bs=this.CreateOperandsList();var _Gy=_Bs[_Fo];_Gy._rg=true;var _aa8=_Gy.GetAssociatedObj();if(_Gy.IsDynamicCalcOperand()){_aa8._p8=_Fe?_Fe:_aa8._nh;}else{var _auR=_aa8.GetMathMLExprNode().GenerateExpressionLabel(this.oDialogMgr.oUIMgr.dataManager.metadata,this._rK,_Bs);_aa8._p8=(_Fe?_Fe:_auR);_aa8._nh=_auR;}for(var i in _Bs){_Gy=_Bs[i];if(_Gy.IsReferencingCalc(_Fo,_Bs)){_Gy._rg=true;_aa8=_Gy.GetAssociatedObj();var _WA=_aa8.GetMathMLExprNode().GenerateExpressionLabel(this.oDialogMgr.oUIMgr.dataManager.metadata,this._rK,_Bs);if(_aa8.UseDefaultName()){_aa8._p8=_WA;}_aa8._nh=_WA;}}return _Bs;};CUIRenameCalcDlg.prototype.CreateCalcRenameRequest=function(_Bs){var _Jj=this._rB.oAxis._rk.GetDMAction();_Jj.type=ExpAPIXml.kActionModify;for(var i in _Bs){var _Gy=_Bs[i];if(_Gy&&_Gy._rg){var _Lh=_c.CreateElement(ExpAPIXml.kEleObjectPtr,_Gy.GetAssociatedObjId());_Lh+=_c.CreateElement(ExpAPIXml.kEleCalcName,_Gy.GetAssociatedObj().GetLabel());_Lh+=_c.CreateElement(ExpAPIXml.kEleCalcLabel,_Gy.GetAssociatedObj().GetDescription());var _aq3=_c.CreateElement(ExpAPIXml.kEleAxisOpExprCalc,_Lh,true);_Jj.AddParameter(new CDLParameter(ExpAPIXml.kCalculation,_aq3,CDLParameter.XMLType()));}}_Jj.AddTargetItem(this._rB.oAxis._ks,ExpAPIXml.kEleAxis);_Jj.AddTargetItem(this._rB.sExprId,ExpAPIXml.kEleAxisOpExpression);this._rB.oAxis._rk.SendDMAction(_Jj);};CUICustomScopeDialog.kPercentBased='percentbased';CUICustomScopeDialog.kRelativePosition='relativeposition';function CUICustomScopeDialog(_Fl){this.base=CUIDialog;this.base(true);this._vx=_Fl;this._s4='';this._iL='';this._kA=null;this._cE=null;this._wl=null;};CUICustomScopeDialog.prototype=new CUIDialog;CUICustomScopeDialog.superclass=CUIDialog.prototype;CUICustomScopeDialog.OrdinalOpts=new Object();CUICustomScopeDialog.OrdinalOpts[ExpAPIXml.kHighestOrdiDirection]='IDS_ORDINAL_NUMBER_START_VALUE_HIGH';CUICustomScopeDialog.OrdinalOpts[ExpAPIXml.kLowestOrdiDirection]='IDS_ORDINAL_NUMBER_START_VALUE_LOW';CUICustomScopeDialog.SegmentOpts=new Object();CUICustomScopeDialog.SegmentOpts[ExpAPIXml.kIncludedSegment]='IDS_INCLUDED_SEGMENT';CUICustomScopeDialog.SegmentOpts[ExpAPIXml.kVisibleSegment]='IDS_VISIBLE_SEGMENT';CUICustomScopeDialog.SegmentOpts[ExpAPIXml.kAllSegment]='IDS_ALL_SEGMENT';CUICustomScopeDialog.SegmentOpts[ExpAPIXml.kIndividualMemSegment]='IDS_INDIVIDUAL_MEMBER';CUICustomScopeDialog.prototype.Display=function(_KP){var _Co=this.oDialogMgr.oUIMgr.appobj.oResources;var _Ke=this.sAppName;var _MY=new Object();var _Xf=Utilities.GenerateCallback(CUIManager.SafeDoHelpTopic,[_Ke,HelpConstants.kCustomRankLink]);_MY['IDS_HELP']=_Xf;this.Create();CUICalculationDlg.superclass.Display.call(this,_KP,_MY,this._lq);};CUICustomScopeDialog.prototype.ClearDlg=function(){};CUICustomScopeDialog.prototype.SetInitParameter=function(_J9,_Ao,_Ic,_BE,_NT,_B9,_CZ){this._s4=_J9;this._vJ=_Ao;this._iL=_Ic;this._kA=_BE;this._cE=_NT;this._wl=_B9;this._rD=_CZ;this._r0=new Object();this._c8=null;};CUICustomScopeDialog.prototype.Create=function(){this.ClearDlg();var _Ke=this.sAppName;var _zr=document.createElement('TABLE');_zr.className='dialogTable';var _F0=document.createElement('TBODY');var _NH=document.createElement('TR');_F0.appendChild(_NH);var _NM=this._l4.cloneNode(false);_NH.appendChild(_NM);_NM.colSpan=2;var _Np=this._s4;var _aII=CUIUserSelection.aResSuffixMap[this._vJ];var _Np=this.oRes.GetString('IDS_RELATIVE_POSITION_CALC_SCOPE_CTRL_LABEL_'+_aII);var _apS=COTInputElementFactory.CreateLabel(_Np);_NM.appendChild(_apS);_NM=this._l4.cloneNode(false);_NH.appendChild(_NM);_Np=this.oRes.GetString('IDS_CUSTOM_SCOPE_SEGMENTING_'+CUIUserSelection.aResSuffixMap[this._vJ]);var _apS=COTInputElementFactory.CreateLabel(_Np);_NM.appendChild(_apS);_NH=document.createElement('TR');_F0.appendChild(_NH);_NM=this._g5.cloneNode(false);var _afF=!(this._cE.GetDLAxis().CanSupportCurrentOperation(this._vJ));var _43=this.IsOppoAxisSegment();var _85=Utilities.EventCallback(this.OnRadioClick,[],this,true,true);this._bI=COTInputElementFactory.CreateRadioButton('axisopts',CUICalculationDlg.RelPosOppositeAxis,_43,_afF,_85);COTStyle.SetWidth(this._bI,20,'px');_NM.appendChild(this._bI);var _Bb=this._kA.IsRowAxis()?'rank_row_all_values.gif':'rank_column_all_values.gif';_apS=COTInputElementFactory.CreateImage(_Bb,20,20);if(_o.is_firefox){_NM.style.minWidth="49px";}_NM.appendChild(_apS);_NH.appendChild(_NM);_NM=this._g5.cloneNode(false);var _aC0=this._iL;_Np=this.oRes.ReplaceParam('IDS_RELATIVE_POSITION_CALC_ON_OPPO_AXIS',1,_aC0);_apS=COTInputElementFactory.CreateLabel(_Np);_NM.appendChild(_apS);_NH.appendChild(_NM);this._dQ=document.createElement('TD');if(this._wl==CUICustomScopeDialog.kRelativePosition){this._dQ.rowSpan=5;}else{this._dQ.rowSpan=3;}this._dQ.className=' vAlign_top';COTStyle.SetWidth(this._dQ,50,'%');_NH.appendChild(this._dQ);_NH=document.createElement('TR');_F0.appendChild(_NH);_NM=this._g5.cloneNode(false);_NH.appendChild(_NM);this._qz=COTInputElementFactory.CreateRadioButton('axisopts',CUICalculationDlg.RelPosSameAxis,!_43,false,_85);COTStyle.SetWidth(this._qz,20,'px');_NM.appendChild(this._qz);_Bb=this._kA.IsRowAxis()?'rank_row_each_column.gif':'rank_column_each_row.gif';_apS=COTInputElementFactory.CreateImage(_Bb,20,20);_NM.appendChild(_apS);_NM=this._g5.cloneNode(false);var _anT=this._kA.GetResourceSuffix();if(this._kA.GetDLAxis().HasUnion()){_Np=this.oRes.ReplaceParam('IDS_RELATIVE_POSITION_CALC_ON_UNIONED_SAME_AXIS',1,_aC0);_Np=this.oRes.ReplaceParam(_Np,2,this._rD.GetLabel());}else{_Np=this.oRes.ReplaceParam('IDS_RELATIVE_POSITION_CALC_ON_SAME_AXIS_'+_anT,1,_aC0);}_apS=COTInputElementFactory.CreateLabel(_Np);_NM.appendChild(_apS);_NH.appendChild(_NM);if(this._wl==CUICustomScopeDialog.kRelativePosition){_NH=document.createElement('TR');_F0.appendChild(_NH);var _acM=(this._vJ==ExpAPIXml.kRankFunc);var _3T=_acM?'IDS_RANK_ORDINAL_DIRECTION':'IDS_OTHER_REL_POS_CAL_ORDINAL_DIRECTION_';var _aCY=this.oRes.GetString(_3T);if(!_acM){_NM=document.createElement('TD');_NM.style.paddingTop='15px';_NH.appendChild(_NM);_apS=COTInputElementFactory.CreateImage('msg_information_16.gif',16,16);_NM.appendChild(_apS);_NM=this._g5.cloneNode(false);_NM.style.paddingTop='15px';_aCY=this.oRes.GetString(_3T+CUIUserSelection.aResSuffixMap[this._vJ]);_apS=COTInputElementFactory.CreateLabel(_aCY);_NM.appendChild(_apS);_NH.appendChild(_NM);}else{_NM=this._l4.cloneNode(false);_NM.colSpan=2;_NM.style.paddingTop='15px';_apS=COTInputElementFactory.CreateLabel(_aCY);_NM.appendChild(_apS);_NH.appendChild(_NM);_NH=document.createElement('TR');_F0.appendChild(_NH);_NM=document.createElement('TD');_NH.appendChild(_NM);_NM.colSpan=2;this._gf=new CUIListCtrl(this.oDialogMgr.oUIMgr);this._gf.SetMaxHeight(50);this._gf.Init();this._gf.DisableHAutoScroll();this._ls=new CUIComboBox(this.oDialogMgr.oUIMgr,this._gf);this._ls.DisableIcon();_NM.appendChild(this._ls.Init());this._ls.SetWidthByPX(200);this.SetOrdinalOpts(this._ls);}}var _NH=document.createElement('TR');var _NM=_NH.appendChild(document.createElement('TD'));Dom.ReplaceText(_NM," ");COTStyle.SetHeight(_NM,5,'%');var _NM=_NH.appendChild(document.createElement('TD'));_NM.innerHTML=' ';COTStyle.SetHeight(_NM,5,'%');_F0.appendChild(_NH);this.PopulateBlockSegmentingOptions();_zr.appendChild(_F0);this._Y=Utilities.GenerateCallback(CUICustomScopeDialog.SafeDoSetScope,[_Ke]);this._iG="IDS_BUTTON_OK";this._lq=_zr;};CUICustomScopeDialog.prototype.GetExpressionNodeSegments=function(){var _Yv=new Array();var _IP=this._vx._rK._ni;if(_IP&&_IP._sy){if(_IP._s4!=ExpAPIXml.kPcntOfTotalFunc){for(var i=0;i<_IP._sy.length;i++){var _Gy=_IP._sy[i];if(_Gy&&_Gy._s4==ExpAPIXml.kSegmentFunc){_Yv[_Yv.length]=_Gy;}}}else{for(var i=0;i<_IP._sy.length;i++){var _Gy=_IP._sy[i];if(_Gy&&_Gy._s4==ExpAPIXml.kSegmentSumFunc){_Yv[_Yv.length]=_Gy;}}}}return _Yv;};CUICustomScopeDialog.prototype.IsOppoAxisSegment=function(){var _aBl=true;var _WX=this.GetExpressionNodeSegments();var _aDf=_WX?_WX[0]:null;if(_aDf&&_aDf._sy){for(var i=0;i<_aDf._sy.length;i++){var _NK=_aDf._sy[i];if(_NK._ja==ExpAPIXml.kBlock){var _Ti=_NK._jU;_aBl=(this._vx._rK._qw.GetBlock(_Ti)==null);break;}}}return _aBl;};CUICustomScopeDialog.prototype.SetOrdinalOpts=function(_MX){_MX.oListCtrl.ClearAllItems();_MX.ClearValue();var _az4=0;var _LX;for(var i in CUICustomScopeDialog.OrdinalOpts){var _BM=this.oRes.GetString(CUICustomScopeDialog.OrdinalOpts[i]);_LX=_MX.oListCtrl.AddItem('',_BM,0,i,_BM);if(_az4==0){_MX.SetValueFromListItem(_LX,true,true);}_az4++;}var _IP=this._vx._rK._ni;if(_IP&&_IP._sy){for(var i=0;i<_IP._sy.length;i++){var _Gy=_IP._sy[i];if(_Gy&&_Gy._ja==ExpAPIXml.kOrdinalDirection){_LX=_MX.oListCtrl.GetItemByValue(_Gy._jU);if(_LX){_MX.SetValueFromListItem(_LX,false);}break;}}}};CUICustomScopeDialog.prototype.SetSegmentOpts=function(_MX,_AL,_EY,_RO,_Lx){_MX.oListCtrl.ClearAllItems();_MX.ClearValue();var _az4=0;var _LX;for(var i in CUICustomScopeDialog.SegmentOpts){if((_EY)&&(i==ExpAPIXml.kIncludedSegment)){continue;}if(_AL&&(i==ExpAPIXml.kVisibleSegment)){continue;}if((_AL&&_EY)&&(i==ExpAPIXml.kAllSegment)){continue;}if(_RO&&(i==ExpAPIXml.kIndividualMemSegment)){continue;}var _BM=this.oRes.GetString(CUICustomScopeDialog.SegmentOpts[i]);_LX=_MX.oListCtrl.AddItem('',_BM,0,i,_BM);if(_az4==0){_MX.SetValueFromListItem(_LX,true,true);}_az4++;}var _WX=this.GetExpressionNodeSegments();var _aDf=null;if(_Lx&&_WX){var _2b=false;for(var i=0;i<_WX.length;i++){_aDf=_WX[i];if(_aDf&&_aDf._sy){var _8M=_aDf._sy;for(var j=0;j<_8M.length;j++){var _NK=_8M[j];if(_NK._ja==ExpAPIXml.kBlock&&_NK._jU==_Lx){_2b=true;break;}}}if(_2b){break;}}}else{_aDf=(_WX?_WX[0]:null);}if(_aDf&&_aDf._sy){for(var i=0;i<_aDf._sy.length;i++){var _NK=_aDf._sy[i];if(_NK._ja==ExpAPIXml.kAttrSegment){_LX=_MX.oListCtrl.GetItemByValue(_NK._jU);if(_LX){_MX.SetValueFromListItem(_LX,false);}break;}}}};CUICustomScopeDialog.prototype.CreateSingleBlockSegmentOption=function(_FK,_Ij,_Wu,_Lx){if(_FK){var _aBE=this.oRes.ReplaceParam(_Wu,1,_FK.GetLabel());var _Ti=_FK.GetId();var _apS=COTInputElementFactory.CreateLabel(_aBE);_Ij.appendChild(_apS);var _act=new CUIListCtrl(this.oDialogMgr.oUIMgr);_act.SetMaxHeight(80);_act.Init();_act.DisableHAutoScroll();var _2o=new CUIComboBox(this.oDialogMgr.oUIMgr,_act);_2o.DisableIcon();_Ij.appendChild(_2o.Init());_2o.SetWidthByPX(200);var _AL=_FK.IsHAMC();var _DV=_FK.HasMeasures();var _RO=_FK.IsGroupedDescendantsAtDepth();this.SetSegmentOpts(_2o,_AL,_DV,_RO,_Lx);this._r0[_Ti]=_2o;}};CUICustomScopeDialog.prototype.ClearOldSegmentOptions=function(){Dom.RemoveAllChildren(this._dQ);for(var i in this._r0){var _acf=this._r0[i];_acf.oListCtrl.Unload();_acf.Unload();}Utilities.ClearObjectArray(this._r0);};CUICustomScopeDialog.prototype.PopulateBlockSegmentingOptions=function(){this.ClearOldSegmentOptions();var _UN=this._bI.checked?CUICalculationDlg.RelPosOppositeAxis:CUICalculationDlg.RelPosSameAxis;var _Ib=null;var _aaK=false;if(CUICalculationDlg.RelPosOppositeAxis==_UN){_Ib=this._cE.GetDLAxis();}else{_Ib=this._kA.GetDLAxis();_aaK=true;}var _aen=_Ib.GetAxisDepth();var _Ij=document.createElement('DIV');var _ayL=_Ib.HasUnion();var _I3=_Ib.GetAllBlocksStartFromInnerMost();if(!_ayL){var _aE5=(_aen>1)?true:false;_Ij.className=_aE5?'nestedBlockSegmentDiv':'singleBlockSegmentDiv';this._dQ.appendChild(_Ij);if(!_aE5){this.CreateSingleBlockSegmentOption(_Ib.GetSingleBlock(),_Ij,'IDS_SINGLE_SET');}else{var _aup=0;if(!_aaK){this.CreateSingleBlockSegmentOption(_I3[0],_Ij,'IDS_INNER_SET',_I3[_aup].sExprId);_aup++;}else{this.CreateSingleBlockSegmentOption(this._rD,_Ij,'IDS_CURRENT_SET');if(this._kA.GetDLAxis().CanSupportCurrentOperation(this._vJ)){_aup=Utilities.GetObjIndex(_I3,this._rD)+1;}else{return;}}for(var x=_aup;x<_I3.length;x++){this.CreateSingleBlockSegmentOption(_I3[x],_Ij,'IDS_OUTER_SET',_I3[x].sExprId);}}}else{_Ij.className='singleBlockSegmentDiv';if(_aaK){this._dQ.appendChild(_Ij);this.CreateSingleBlockSegmentOption(this._rD,_Ij,'IDS_CURRENT_SET');}else{if(this._cE.IsRowAxis()){var _ass=this.oRes.GetString('IDS_NONE_CUSTOM_SEGMENT_ON_UNIONED_ROW_AXIS');}else{var _ass=this.oRes.GetString('IDS_NONE_CUSTOM_SEGMENT_ON_UNIONED_COL_AXIS');}_apS=COTInputElementFactory.CreateLabel(_ass);var _XU=document.createElement('DIV');_XU.appendChild(_apS);_Ij.appendChild(_XU);this._dQ.appendChild(_Ij);}}};CUICustomScopeDialog.prototype.OnRadioClick=function(){this.PopulateBlockSegmentingOptions();};CUICustomScopeDialog.prototype.SetSegmentingForExpr=function(){var _Ab=new Object();var _aCf=new Array();for(var i in this._r0){_aCf.push(i);}if(_aCf.length>0){for(var x=_aCf.length-1;x>=0;x--){_Ab[_aCf[x]]=this._r0[_aCf[x]].GetValue();}}var _agu=null;if(this._wl==CUICustomScopeDialog.kRelativePosition){if(this._ls){_agu=this._ls.GetValue();}else{_agu=ExpAPIXml.kHighestOrdiDirection;}}this.oDialogMgr._jg._bE=false;this.oDialogMgr._jg.ProcessSegmentData(_Ab,_agu);};CUICustomScopeDialog.prototype.UnLoad=function(){Dom.RemoveAllChildren(this._lq);CUICustomScopeDialog.superclass.Unload.call(this);};CUICustomScopeDialog.SafeDoSetScope=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/var _Hy=FindApp(_Ke).uiManager.oDialogMgr;_Hy._H.SetSegmentingForExpr();CUIDialogMgr.SafeHideCurrentDialog(_Ke);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};function CTempCalc(_KR,id){if(!id){this._ve=Utilities.GenerateId();}else{this._ve=id;}this._gV=_KR;this._p8="";this._kT=this._gV.IsValidExpr();this._b6=this._gV.IsEditable();};CTempCalc.prototype.GetId=function(){return this._ve;};CTempCalc.prototype.GetLabel=function(_RJ,_NI,_UW){if(!this._p8){this._p8=this._gV.GenerateExpressionLabel(_RJ,_NI,_UW);}return this._p8;};CTempCalc.prototype.UseDefaultName=function(){return true;};CTempCalc.prototype.GetDescription=function(){return this._p8;};CTempCalc.prototype.GetMathMLExprNode=function(){return this._gV;};CTempCalc.prototype.IsValid=function(){return this._kT;};CTempCalc.prototype.IsEditable=function(){return this._b6;};CTempCalc.prototype.Clone=function(){var _aB1=this._gV.Clone();var _ax7=new CTempCalc(_aB1,this._ve);_ax7._p8=this._p8;_ax7._kT=this._kT;return _ax7;};function CUIOperand(_zQ){Debug.Assert(_zQ instanceof CDLAxisCalc||_zQ instanceof CTempCalc||_zQ instanceof CDLAbsMember);this._sk=_zQ;this._oB=_zQ.GetId();this._rg=false;};CUIOperand.prototype.Clone=function(){var _zQ=this.GetAssociatedObj();if(_zQ instanceof CDLAxisCalc||_zQ instanceof CTempCalc){var _aBl=new CUIOperand(_zQ.Clone());_aBl._rg=this._rg;return _aBl;}else{return new CUIOperand(_zQ);}};CUIOperand.prototype.GetAssociatedObjId=function(){return this._oB;};CUIOperand.prototype.GetAssociatedObj=function(){return this._sk;};CUIOperand.prototype.IsCalcOperand=function(){return(this._sk instanceof CDLAxisCalc||this._sk instanceof CTempCalc);};CUIOperand.prototype.IsDynamicCalcOperand=function(){return(this._sk instanceof CDLAxisCalc&&this._sk.IsDynamicCalc());};CUIOperand.prototype.IsTempCalcOperand=function(){return(this._sk instanceof CTempCalc);};CUIOperand.prototype.IsValidOperand=function(){if(this._sk instanceof CDLAxisCalc){return this._sk.IsValid();}return true;};CUIOperand.prototype.IsModified=function(){return this._rg;};CUIOperand.prototype.NeedUpdateLabel=function(){if(this.IsCalcOperand()){return(this.IsTempCalcOperand()||this._sk.UseDefaultName());}return false;};CUIOperand.prototype.GetAssociatedObjLabel=function(_RJ,_NI,_UW){var _aBl='';if(this.IsTempCalcOperand()){_aBl=this.GetAssociatedObj().GetLabel(_RJ,_NI,_UW);}else{_aBl=this.GetAssociatedObj().GetLabel();}return _aBl;};CUIOperand.prototype.IsReferencingCalc=function(_HO,_E9){if(this.IsCalcOperand()){var _KR=this._sk.GetMathMLExprNode();if(!_KR){return false;}else{return _KR.IsReferencingItem(_HO,_E9);}}return false;};function CUIAbsCalculationConext(_Q7,_zI){this._r9=_Q7;this._vH=_zI;this._u="";this._s4="";this._yj=true;this._sU="";this._bM=false;this._aM="";this._im="";this._f3="";this._hl=new Array();this._ry=new Object();};CUIAbsCalculationConext.prototype.Clear=function(){Utilities.ClearObjectArray(this._ry);Utilities.DeleteAllFromArray(this._hl);Utilities.RemoveAllChildObjects(this);};CUIAbsCalculationConext.prototype.GetCalcOperandId=function(){return this._vH;};CUIAbsCalculationConext.prototype.UpdateCalcOperandList=function(_IP,_Fo,_Fe){var _Gy=this._ry[_Fo];_Gy._rg=true;_Gy.GetAssociatedObj()._gV=_IP.Clone();_Gy.GetAssociatedObj()._nh=_IP.GenerateExpressionLabel(this._r9.oDialogMgr.oUIMgr.dataManager.metadata,this._r9._rK,this._ry);_Gy.GetAssociatedObj()._p8=(_Fe?_Fe:_Gy.GetAssociatedObj()._nh);for(var i in this._ry){_Gy=this._ry[i];if(_Gy.IsReferencingCalc(_Fo,this._ry)){_Gy._rg=true;var _3Z=_Gy.GetAssociatedObj()._gV.GenerateExpressionLabel(this._r9.oDialogMgr.oUIMgr.dataManager.metadata,this._r9._rK,this._ry);if(_Gy.GetAssociatedObj().UseDefaultName()){_Gy.GetAssociatedObj()._p8=_3Z;}_Gy.GetAssociatedObj()._nh=_3Z;}}};CUIAbsCalculationConext.prototype.PopulateContext=function(){var _an2=this._r9.GetOperandFromCurrentContext(this.GetCalcOperandId());if(!_an2){return;}var _aGq=_an2.GetAssociatedObj();Debug.Assert(_aGq);var _KR=_aGq.GetMathMLExprNode();Debug.Assert(_KR!=null);this._s4=_KR.GetOperator();this._u="";for(var iType in CUICalculationDlg.OPTypeArr){for(var i=0;!this._u&&i<this._r9._tL[iType].length;i++){if(this._s4==this._r9._tL[iType][i]){this._u=iType;break;}}if(this._u!=""){break;}}this._sU=_aGq.GetLabel();this._yj=_aGq.UseDefaultName();this.PopulateTopOperands();};CUIAbsCalculationConext.prototype.PopulateTempOperand=function(_KR,_TG){var _zQ=new CTempCalc(_KR);this._r9._rK.AddTempCalc(_zQ);var _alC=_zQ.GetId();this._r9.AddOperandIntoCurrentContext(_zQ);var _Yg=new CDLMathMLOperands(_alC,_KR.GenerateExpressionLabel(this._r9.oDialogMgr.oUIMgr.dataManager.metadata,this._r9._rK,this._ry),CDLMathMLOperands.CIOperand,ExpAxisObjType.TempCalc);var op=this._r9.GetOperandFromCurrentContext(_alC);op.GetAssociatedObj()._p8=_Yg._p8;var _ahu=this._r9.GetOperandFromCurrentContext(this.GetCalcOperandId());var _aq9=_ahu.GetAssociatedObj();_aq9.GetMathMLExprNode().ReplaceOperand(_TG,_Yg);this._hl.push(_alC);};CUIAbsCalculationConext.prototype.PopulateTopOperands=function(){var _an2=this._r9.GetOperandFromCurrentContext(this.GetCalcOperandId());var _aGq=_an2.GetAssociatedObj();Debug.Assert(_aGq);var _KR=_aGq.GetMathMLExprNode();Debug.Assert(_KR!=null);for(var i=0;i<_KR._sy.length;i++){var _Gy=_KR._sy[i];if(_Gy instanceof CDLMathMLOperands){var _aJz=_Gy._jU;var _alC="";var _zQ=null;if(_Gy._lW==CDLMathMLOperands.CNOperand){this._aM=ExpAPIXml.kNumberOperands;this._im=_aJz;}else if(_Gy._lW==CDLMathMLOperands.CIOperand){switch(_Gy._ja){case ExpAxisObjType.Member:case ExpAxisObjType.Measure:_zQ=this._r9._mR.GetMemberOrMeasure(_aJz);_alC=_zQ.GetId();break;case ExpAxisObjType.Calc:_zQ=this._r9.oDialogMgr.oUIMgr.dataManager._kX.GetCalculation(_aJz);_alC=_zQ.GetId();break;case ExpAxisObjType.TempCalc:this._hl.push(_aJz);break;case ExpAPIXml.kEleSubsVar:this._aM=ExpAPIXml.kEleSubsVar;this._im=_aJz;break;}if(_alC&&_zQ){this._r9.AddOperandIntoCurrentContext(_zQ);this._hl.push(_alC);}}}else if(_Gy instanceof CDLMathMLExprNode){this.PopulateTempOperand(_Gy,i);}}};function CUICalculationSingleItem(_Q7,_zI){this.base=CUIAbsCalculationConext;this.base(_Q7,_zI);};CUICalculationSingleItem.prototype=new CUIAbsCalculationConext;CUICalculationSingleItem.superclass=CUIAbsCalculationConext.prototype;function CUICalculationStaticNumber(_Q7,_zI){this.base=CUIAbsCalculationConext;this.base(_Q7,_zI);};CUICalculationStaticNumber.prototype=new CUIAbsCalculationConext;CUICalculationStaticNumber.superclass=CUIAbsCalculationConext.prototype;function CUICalculationUnary(_Q7,_zI){this.base=CUIAbsCalculationConext;this.base(_Q7,_zI);};CUICalculationUnary.prototype=new CUIAbsCalculationConext;CUICalculationUnary.superclass=CUIAbsCalculationConext.prototype;function CUICalculationUnaryFactor(_Q7,_zI){this.base=CUICalculationUnary;this.base(_Q7,_zI);this._bM=true;};CUICalculationUnaryFactor.prototype=new CUICalculationUnary;CUICalculationUnaryFactor.superclass=CUICalculationUnary.prototype;function CUICalculationUnaryScope(_Q7,_zI){this.base=CUICalculationUnary;this.base(_Q7,_zI);this._vC="";this._a2="";this._lM="";this._ur=new Array();this._uy=new Array();this._bh="";};CUICalculationUnaryScope.prototype=new CUICalculationUnary;CUICalculationUnaryScope.superclass=CUICalculationUnary.prototype;CUICalculationUnaryScope.prototype.PopulateTopOperands=function(){var _an2=this._r9.GetOperandFromCurrentContext(this.GetCalcOperandId());var _aGq=_an2.GetAssociatedObj();Debug.Assert(_aGq);var _KR=_aGq.GetMathMLExprNode();Debug.Assert(_KR!=null);for(var i=0;i<_KR._sy.length;i++){var _Gy=_KR._sy[i];var _aJz=_Gy._jU;var _alC="";var _zQ=null;if(_Gy._lW==CDLMathMLOperands.CIOperand){switch(_Gy._ja){case ExpAxisObjType.Measure:this._vC=_Gy._jU;break;case ExpAxisObjType.Calc:_zQ=this._r9.oDialogMgr.oUIMgr.dataManager._kX.GetCalculation(_aJz);_alC=_zQ.GetId();break;case ExpAxisObjType.TempCalc:this._hl.push(_aJz);break;case ExpAxisObjType.Member:_zQ=this._r9._mR.GetMember(_aJz);_alC=_zQ.GetId();break;case ExpAPIXml.kOrdinalDirection:this._lM=_Gy._jU;break;case ExpAPIXml.kAxis:this._a2=_Gy._jU;break;case ExpAPIXml.kQuantNum:this._bh=_Gy._jU;break;}if(_alC&&_zQ){this._r9.AddOperandIntoCurrentContext(_zQ);this._hl.push(_alC);}}else if(_Gy instanceof CDLMathMLExprNode){var _IP=_Gy;if(_IP._s4==ExpAPIXml.kSegmentFunc||_IP._s4==ExpAPIXml.kSegmentSumFunc){for(var j=0;j<_IP._sy.length;j++){var _aw4=_IP._sy[j];if(_aw4._ja==ExpAPIXml.kAttrSegment){this._uy.push(_aw4._jU);}else if(_aw4._ja==ExpAPIXml.kBlock){this._ur.push(_aw4._jU);}}}else{this.PopulateTempOperand(_Gy,i);}}else{Debug.Assert(false);}}if(this._hl.length==0&&this._vC){if(_zQ){this._r9.AddOperandIntoCurrentContext(_zQ);}else{var _NS=this._r9._mR.GetMeasure(this._vC);this._r9.AddOperandIntoCurrentContext(_NS);}this._hl.push(this._vC);this._vC="";}};function CUICalculationUnaryScopeFactor(_Q7,_zI){this.base=CUICalculationUnaryScope;this.base(_Q7,_zI);this._bM=true;};CUICalculationUnaryScopeFactor.prototype=new CUICalculationUnaryScope;CUICalculationUnaryScopeFactor.superclass=CUICalculationUnaryScope.prototype;function CUICalculationBinary(_Q7,_zI){this.base=CUIAbsCalculationConext;this.base(_Q7,_zI);this._bM=true;this._l7="";};CUICalculationBinary.prototype=new CUIAbsCalculationConext;CUICalculationBinary.superclass=CUIAbsCalculationConext.prototype;function CUICalculationNary(_Q7,_zI){this.base=CUIAbsCalculationConext;this.base(_Q7,_zI);this._bM=true;};CUICalculationNary.prototype=new CUIAbsCalculationConext;CUICalculationNary.superclass=CUIAbsCalculationConext.prototype;function CUICalcExprBoard(_Fl){this._E=_Fl;this._J=null;this.value=null;};CUICalcExprBoard.prototype.Init=function(){this._J=document.createElement('DIV');this._J.className="calcExprBoardDiv";COTStyle.SetHeight(this._J,120);COTStyle.SetWidth(this._J,300);};function CUIFullSyntaxDialog(){this.base=CUIDialog;this.base(true);this._F='';};CUIFullSyntaxDialog.prototype=new CUIDialog;CUIFullSyntaxDialog.superclass=CUIDialog.prototype;CUIFullSyntaxDialog.prototype.SetFullSyntax=function(_Vb){this._F=_Vb;};CUIFullSyntaxDialog.prototype.Display=function(_KP,_Qt){this.SetFullSyntax(_Qt);this.Create();CUICalculationDlg.superclass.Display.call(this,_KP,null,this._lq);};CUIFullSyntaxDialog.prototype.ClearDlg=function(){};CUIFullSyntaxDialog.prototype.Create=function(){this.ClearDlg();var _zr=document.createElement('TABLE');_zr.className='dialogTable';var _F0=document.createElement('TBODY');var _NH=document.createElement('TR');_F0.appendChild(_NH);var _NM=this._l4.cloneNode(false);_NM.className="calcFullSyntaxContent";_NH.appendChild(_NM);_NM.style.whiteSpace='normal';var _apS=COTInputElementFactory.CreateLabel(this._F);_NM.appendChild(_apS);_zr.appendChild(_F0);this._lq=_zr;this._gp="IDS_BUTTON_CLOSE";this._t9=false;};function CUIContentManager(_Hk){this._j1=_Hk;this._lJ=null;this._mz=null;this._hq=null;this._aQ=null;this._l5=null;this._rA=_Hk.dataManager._dE;this._rA.Subscribe(this,ExpEvent.kCDLCMFolder_Replace);this._e6=new Array();this._e6[ExpEvent.kCUICMRoot_Update]=new Array();};CUIContentManager.prototype.Subscribe=function(obj,_Dy){if(this._e6[_Dy]){for(var i=0;i<this._e6[_Dy].length;i++){if(this._e6[_Dy]==obj){return;}}this._e6[_Dy].push(obj);}};CUIContentManager.prototype.Notify=function(_Dy){if(_Dy==ExpEvent.kCDLCMFolder_Replace){this.HandleRootReplace();_Dy=ExpEvent.kCUICMRoot_Update;}var _alZ=this._e6[_Dy];for(var i=0;_alZ&&i<_alZ.length;i++){_alZ[i].Notify(_Dy);}};CUIContentManager.prototype.HandleRootReplace=function(){var _acB=this._rA._ih;for(var i in _acB){if(_acB[i]._tF==ExpAPIXml.eCMRootPublicFolder){this._lJ=new CUICMFolderTree(this._j1,_acB[i]);}else if(_acB[i]._tF==ExpAPIXml.eCMRootMyFolder){this._mz=new CUICMFolderTree(this._j1,_acB[i]);}}if(this._lJ._tU!=null){this._hq=this._lJ;}else{this._hq=this._mz;}if(this._hq._tU){this._aQ=this._hq._iN.GetNode(this._hq._tU._ks);;}this._l5=null;this._hq.Notify(ExpEvent.kCDLCMFolder_Replace);};CUIContentMgrDlg.dlgTypeSaveAs=0;CUIContentMgrDlg.dlgTypeOpen=1;CUIContentMgrDlg.dlgTypeReportTemplate=2;function CUIContentMgrDlg(){this.base=CUIDialog;this.base();this._mT=false;this._mc=false;this._e6=new Array();this._e6[ExpEvent.kCDLCMAnalysis_GetRoutingServerGroupDone]=new Array();};CUIContentMgrDlg.prototype=new CUIDialog;CUIContentMgrDlg.superclass=CUIDialog.prototype;CUIContentMgrDlg.prototype.Init=function(_yt,_Ri,_Hc){if(!this._mc){CUIContentMgrDlg.superclass.Init.call(this,_yt,false,true);this._mc=true;}this._lW=_Ri;this._Y=_Hc;this._fM=_yt.oUIMgr._fM;if(!this._fM._hq){this._fM.Subscribe(this,ExpEvent.kCUICMRoot_Update);this._fM._rA.RunGetCMRoot();}else if(!this._fM._aQ){var _2X=this._fM._hq;var _6i=_2X._iN._vp;_2X.GetChildren(_6i);this._fM._aQ=_6i;this._fM._lJ.Subscribe(this,ExpEvent.kCUICMFolderTree_Update);this._fM._mz.Subscribe(this,ExpEvent.kCUICMFolderTree_Update);this.Draw(_Hc);}else{this._fM._hq.GetChildren(this._fM._aQ,true);this._fM._lJ.Subscribe(this,ExpEvent.kCUICMFolderTree_Update);this._fM._mz.Subscribe(this,ExpEvent.kCUICMFolderTree_Update);this.Draw(_Hc);}};CUIContentMgrDlg.prototype.Draw=function(_Hc){var _zr=document.createElement('TABLE');this._vO=_zr;_zr.style.marginTop="10px";_zr.className='dialogTable';var _Ke=this.sAppName;var _RK=_zr.appendChild(document.createElement('TBODY'));this._xS=_RK;var _Xv;if(this._lW==CUIContentMgrDlg.dlgTypeSaveAs){_Xv="IDS_SAVE_DLG_SAVE_IN";this.SetAlternativeLabelForOKButton('IDS_SAVE_DLG_BUTTON_SAVE');}else{_Xv="IDS_OPEN_DLG_LOOK_IN";this.SetAlternativeLabelForOKButton('IDS_OPEN_DLG_BUTTON_OPEN');}var _FW=_RK.appendChild(document.createElement('TR'));var _NM=_FW.appendChild(this._l4.cloneNode(false));COTStyle.SetWidth(_NM,15,'%');_NM.appendChild(document.createTextNode(this.oRes.GetString(_Xv)));this._xk=new CUIListCtrl(this.oDialogMgr.oUIMgr);this._xk.iMaxHeight=150;this._xk.Init();_NM=_FW.appendChild(document.createElement('TD'));this._s6=new CUIComboBox(this.oDialogMgr.oUIMgr,this._xk);this._s6.SetIconSize(16);var _afs=_NM.appendChild(this._s6.Init());this._s6.Subscribe(this,ExpEvent.kCUIComboBox_OnSelChange);COTStyle.SetWidth(_NM,45,'%');_NM=_FW.appendChild(document.createElement('TD'));COTStyle.SetWidth(_NM,40,'%');this._oY=new CUIToolBar(this.oDialogMgr.oUIMgr,_NM,"dialog_toolbar");this._oY.aToolGroups.push(new CUIToolGroup(this._oY));this._hT=this._oY.aToolGroups[0].AddButton("tool_updir.gif","tool_updir_disabled.gif",'IDS_UP_DIRECTORY',CUIContentMgrDlg.SafeHandleUpDir,false);if(this._lW!=CUIContentMgrDlg.dlgTypeReportTemplate){this._oY.aToolGroups.push(new CUIToolGroup(this._oY));this._eM=this._oY.aToolGroups[1].AddButton("tool_main_delete.gif","tool_main_delete_disabled.gif",'IDS_TOOLBAR_DELETE',CUIContentMgrDlg.SafeHandleDelete,false);this._oY.aToolGroups[1].AddButton("create_new_folder.gif","create_new_folder.gif",'IDS_NEW_FOLDER',CUIContentMgrDlg.SafeHandleNew,false);this._oY.aToolGroups.push(new CUIToolGroup(this._oY));this.oRenameButton=this._oY.aToolGroups[2].AddButton("tool_rename.gif","tool_rename_disabled.gif",'IDS_RENAME',CUIContentMgrDlg.SafeHandleRename,false);this._oY.aToolGroups[2].AddButton("tool_refresh.gif","tool_refresh.gif",'IDS_REFRESH',CUIContentMgrDlg.SafeHandleRefresh,false);}this._oY.Draw();var _aHP=(this._fM._hq._jp==ExpAPIXml.eCMRootPublicFolder);this._vV=_RK.appendChild(document.createElement('TR'));var _8Y=this._fM._lJ._qO._p8;this._uE=this._vV.appendChild(this._gM.cloneNode(false));var _ajo=Utilities.GenerateCallback(this.DoSetRootToPublicFolder,[],this);this._se=COTInputElementFactory.CreateImgButton(_8Y,'publicfolder_32x32.gif',_ajo,false,false,true,32,32);COTStyle.SetWidth(this._uE,COTInputElementFactory.kImgButtonMinWidth+COTInputElementFactory.kImgButtonHPadding);this._uE.appendChild(this._se);this._gF=_RK.appendChild(document.createElement('TR'));var _9q=this._fM._mz._qO._p8;this._uG=this._gF.appendChild(this._gM.cloneNode(false));_ajo=Utilities.GenerateCallback(this.DoSetRootToMyFolder,[],this);this._sd=COTInputElementFactory.CreateImgButton(_9q,'myfolder_32x32.gif',_ajo,false,false,true,32,32);this._uG.appendChild(this._sd);_NM=this._vV.appendChild(document.createElement('TD'));this._s0=new CUIListCtrl(this.oDialogMgr.oUIMgr);this._s0.SetMaxHeight(100);this._s0.SetMaxWidth(99,'%');var _agk=_NM.appendChild(this._s0.Init());this.updateListDir();this._s0.Subscribe(this,ExpEvent.kCUIListCtrl_OnItemDblClick);this._s0.Subscribe(this,ExpEvent.kCUIListCtrl_OnSelChange);_NM.colSpan=2;_NM.rowSpan=2;this._ty=_RK.appendChild(document.createElement('TR'));var _NM=this._ty.appendChild(document.createElement('TD'));var _arJ=this._ty.appendChild(this._l4.cloneNode(false));_arJ.appendChild(document.createTextNode(this.oRes.GetString('IDS_ANALYSIS_NAME')));_arJ.colSpan=2;var _FW=_RK.appendChild(document.createElement('TR'));var _NM=_FW.appendChild(document.createElement('TD'));var _anW=_FW.appendChild(document.createElement('TD'));this._jx=_anW.appendChild(COTInputElementFactory.CreateTextBox(100,'%'));_anW.colSpan=2;if(this._lW==CUIContentMgrDlg.dlgTypeOpen){Dom.HideObject(this._ty);Dom.HideObject(_FW);}else{_arJ.style.paddingTop="10px";_anW.style.paddingBottom="10px";}this._Y=_Hc;this._om=2;this._fM._lJ.Subscribe(this,ExpEvent.kCUICMFolderTree_Update);this._fM._mz.Subscribe(this,ExpEvent.kCUICMFolderTree_Update);this._mT=true;};CUIContentMgrDlg.prototype.Display=function(_Jt,_EN,_TO,_Uy,_Hc){var _Co=this.oDialogMgr.oUIMgr.appobj.oResources;var _Ke=this.sAppName;var _MY=new Object();var _Xf=Utilities.GenerateCallback(CUIManager.SafeDoHelpTopic,[_Ke,_Uy]);_MY['IDS_HELP']=_Xf;var _Qa=this.oDialogMgr.oUIMgr.dataManager.GetCurrentWorkSheet();this._jx.value="";if(!_Qa.IsDefaultName()){this._jx.value=_Qa.GetAnalysisName();}if(this._lW==CUIContentMgrDlg.dlgTypeSaveAs){this._jx.focus();}this._jx.tabIndex=1;if(_Hc){CUIContentMgrDlg.superclass.Display.call(this,_Jt,_MY,this._vO,_EN,_Hc);}else{CUIContentMgrDlg.superclass.Display.call(this,_Jt,_MY,this._vO,_EN);}if(_TO){this._fM._hq.GetChildren(this._fM._aQ,true);}this.updateListDir();this.updateDropDown();this.updateToolBarButtons();this._s6.ResetEventHandlers();COTInputElementFactory.ResetImgButtonAction(this._se);COTInputElementFactory.ResetImgButtonAction(this._sd);var _aHP=(this._fM._hq._jp==ExpAPIXml.eCMRootPublicFolder);if(_aHP){COTInputElementFactory.SelectImgButton(this._se);COTInputElementFactory.ResetToBaseImgButtonStyle(this._sd);}else{COTInputElementFactory.SelectImgButton(this._sd);COTInputElementFactory.ResetToBaseImgButtonStyle(this._se);}this._oY.Draw();COTInputElementFactory.ResetTextBoxHandlers(this._jx,false);var _au9=this._se.offsetWidth;var _aep=this._sd.offsetWidth;var _aar=Math.max(_au9,_aep);if(_aar>(COTInputElementFactory.kImgButtonMinWidth+COTInputElementFactory.kImgButtonHPadding)){COTStyle.SetWidth(this._se,_aar-COTInputElementFactory.kImgButtonHPadding);COTStyle.SetWidth(this._sd,_aar-COTInputElementFactory.kImgButtonHPadding);}};CUIContentMgrDlg.prototype.Unload=function(){Dom.RemoveObject(this._vO);CUIContentMgrDlg.superclass.Unload.call(this);};CUIContentMgrDlg.prototype.DoSetRootToPublicFolder=function(){var _2X=this._fM._hq;var _acH=this._fM._lJ._iN._vp._ks;if(_2X._jp==ExpAPIXml.eCMRootMyFolder){this._s6.SetValueFromListItem(this._fM._l5,true);COTInputElementFactory.SelectImgButton(this._se);COTInputElementFactory.ResetToBaseImgButtonStyle(this._sd);}else if(this._s6.GetValue()!=_acH){var _aAg=this._s6.oListCtrl.GetItemByValue(_acH);this._s6.SetValueFromListItem(_aAg,true);}};CUIContentMgrDlg.prototype.DoSetRootToMyFolder=function(){var _2X=this._fM._hq;var _aqa=this._fM._mz._iN._vp._ks;if(_2X._jp==ExpAPIXml.eCMRootPublicFolder){this._s6.SetValueFromListItem(this._fM._l5,true);COTInputElementFactory.ResetToBaseImgButtonStyle(this._se);COTInputElementFactory.SelectImgButton(this._sd);}else if(this._s6.GetValue()!=_aqa){var _aAg=this._s6.oListCtrl.GetItemByValue(_aqa);this._s6.SetValueFromListItem(_aAg,true);}};CUIContentMgrDlg.prototype.Notify=function(_Dy){var _2X=this._fM._hq;if(_Dy==ExpEvent.kCUIComboBox_OnSelChange){this._fM._aQ=_2X._iN.GetNode(this._s6._gx.sValue);if(!this._fM._aQ){if(_2X._jp==ExpAPIXml.eCMRootPublicFolder){this._fM._hq=this._fM._mz;COTInputElementFactory.ResetToBaseImgButtonStyle(this._se);COTInputElementFactory.SelectImgButton(this._sd);}else{this._fM._hq=this._fM._lJ;COTInputElementFactory.SelectImgButton(this._se);COTInputElementFactory.ResetToBaseImgButtonStyle(this._sd);}}this._fM._aQ=this._fM._hq._iN.GetNode(this._s6._gx.sValue);this._fM._hq.GetChildren(this._fM._aQ,true);this.updateListDir();this.updateDropDown();this.updateToolBarButtons();}else if(_Dy==ExpEvent.kCUIListCtrl_OnItemDblClick){var _akK=_2X._iN.GetNode(this._s0.GetSelection().sValue);if(_akK._lW!=ExpAPIXml.eCMAnalysis&&_akK._lW!=ExpAPIXml.eCMReportTemplate){this._fM._aQ=_akK;_2X.GetChildren(this._fM._aQ);this.updateListDir();this.updateDropDown();this.updateToolBarButtons();}else{if(this._lW==CUIContentMgrDlg.dlgTypeOpen){this.OnOpen(this.sAppName);}else if(this._lW==CUIContentMgrDlg.dlgTypeSaveAs){CUISaveDlg.SafeOnSave(this.sAppName);}else if(this._lW==CUIContentMgrDlg.dlgTypeReportTemplate){this.OnOpen(this.sAppName);}else{Debug.Assert(false);return;}}}else if(_Dy==ExpEvent.kCUIListCtrl_OnSelChange){this.updateToolBarButtons();var _akK=_2X._iN.GetNode(this._s0.GetSelection().sValue);if(_akK._lW==ExpAPIXml.eCMAnalysis||_akK._lW==ExpAPIXml.eCMReportTemplate){this._jx.value=_akK._p8;}else{return;}}else if(_Dy==ExpEvent.kCUICMFolderTree_Update){if(this.oDialogMgr._jg==this&&this._fM._hq.GetLastLoadedNode()==this._fM._aQ){this.updateListDir();this.updateToolBarButtons();if(this._lW==CUIContentMgrDlg.dlgTypeSaveAs)this._jx.focus();}}else if(_Dy==ExpEvent.kCUICMRoot_Update){this.Draw(this._Y);this.Display(false);}else if(_Dy==ExpEvent.kCDLCMAnalysis_GetRoutingServerGroupDone){this.OnOpen(this.sAppName);return;}CUIContentMgrDlg.superclass.Notify.call(this,_Dy);};CUIContentMgrDlg.prototype.updateCurrentDropDown=function(){var _2X=this._fM._hq;var _F7=_2X._iN.GetAncestorNodes(this._fM._aQ);_F7.reverse();for(var i=0;i<_F7.length;i++){var _1j=_2X.GetImageByNodeType(_F7[i]);this._xk.AddItem(_1j,_F7[i]._p8,_F7[i]._ta,_F7[i]._oa);}var _1j=this._fM._hq.GetImageByNodeType(this._fM._aQ);var _aGp=this._xk.AddItem(_1j,this._fM._aQ._p8,this._fM._aQ._ta,this._fM._aQ._oa);return _aGp;};CUIContentMgrDlg.prototype.updateTheOtherDropDown=function(){var _2X=this._fM._hq;var _9N=this._fM._lJ._iN._vp;if(_2X._jp==ExpAPIXml.eCMRootPublicFolder){_9N=this._fM._mz._iN._vp;}var _1j=_2X.GetImageByNodeType(_9N);this._fM._l5=this._xk.AddItem(_1j,_9N._p8,_9N._ta,_9N._oa);};CUIContentMgrDlg.prototype.updateToolBarButtons=function(){if(this._hT){if(!this._fM._aQ._qR){this._hT.Disable();}else{this._hT.Enable();}}if(this._eM&&this.oRenameButton){var _Vh=false;var _7j=this._s0.GetSelection();if(_7j){var _Tl=this._fM._hq._iN.GetNode(_7j.sValue);if(_Tl&&(_Tl._lW==ExpAPIXml.eCMRegularFolder||_Tl._lW==ExpAPIXml.eCMAnalysis)){_Vh=true;}}if(_Vh){this._eM.Enable();this.oRenameButton.Enable();}else{this._eM.Disable();this.oRenameButton.Disable();}}};CUIContentMgrDlg.prototype.updateDropDown=function(){this._xk.ClearAllItems();var _aGp;var _2X=this._fM._hq;if(_2X._jp==ExpAPIXml.eCMRootPublicFolder){_aGp=this.updateCurrentDropDown();this.updateTheOtherDropDown();}else{this.updateTheOtherDropDown();_aGp=this.updateCurrentDropDown();}this._s6.SetValueFromListItem(_aGp);return _aGp;};CUIContentMgrDlg.prototype.updateListDir=function(){this._s0.ClearAllItems();var _abV=(this._lW==CUIContentMgrDlg.dlgTypeReportTemplate);for(var i=0;i<this._fM._aQ._g1.length;i++){var _adY=this._fM._hq._iN.GetNode(this._fM._aQ._g1[i]);if((!_abV&&_adY._lW!=ExpAPIXml.eCMReportTemplate)||(_abV&&_adY._lW!=ExpAPIXml.eCMAnalysis)){var _1j=this._fM._hq.GetImageByNodeType(_adY);this._s0.AddItem(_1j,_adY._p8,0,_adY._oa);}}this._s0.Show();};CUIContentMgrDlg.prototype.DoValidateFileName=function(){this._jx.value=Utilities.trim(this._jx.value);if(this._jx.value!=""){return this._jx.value;}else{CUIDialogMgr.DisplayMessageBox(CUIMessageBox.kWarning,'IDS_BAD_NAME');}return null;};CUIContentMgrDlg.prototype.GetFolderChoice=function(){return this._fM._aQ._oa;};CUIContentMgrDlg.prototype.UpDir=function(){if(this._fM._aQ._qR){this._fM._aQ=this._fM._aQ._qR;this._fM._hq.GetChildren(this._fM._aQ,true);this.updateListDir();this.updateDropDown();}};CUIContentMgrDlg.SafeHandleUpDir=function(_Ke,e){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager.oDialogMgr._jg.UpDir();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIContentMgrDlg.prototype.HandleDelete=function(){var _7j=this._s0.GetSelection();if(_7j){var _Tl=this._fM._hq._iN.GetNode(_7j.sValue);Debug.Assert(_Tl&&(_Tl._lW==ExpAPIXml.eCMRegularFolder||_Tl._lW==ExpAPIXml.eCMAnalysis));var _aBt='IDS_CONFIRM_DELETE';_aBt=this.oRes.ReplaceParam(_aBt,1,_Tl._p8);var _Ke=this.sAppName;var _anu=Utilities.GenerateCallback(CUIDialogMgr.SafeHideCurrentDialog,[_Ke]);var _9o=Utilities.GenerateCallback(CUICMFolderTree.SafeDoDeleteNode,[_Ke,_Tl]);var _aAS=Utilities.GenerateCallbackUnion([_9o,_anu]);CUIDialogMgr._U.SetCallBackFuntion(_aAS);CUIDialogMgr._U.Display(_aBt,'',CUIConfirmDlg._hw);}};CUIContentMgrDlg.SafeHandleDelete=function(_Ke,e){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager.oDialogMgr._jg.HandleDelete();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIContentMgrDlg.SafeDoCreateSubFolder=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/var _ano=FindApp(_Ke).uiManager.oDialogMgr._jg;var _agQ=_ano._fM;var _afh=_agQ._hq;var _al7=CUIDialogMgr._sQ.GetPromptValue();if(_ano.ValidatePromptName(_al7)){_afh.CreateSubFolder(_agQ._aQ,_al7);CUIDialogMgr.SafeHideCurrentDialog(_Ke);}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIContentMgrDlg.prototype.HandleNew=function(){var _G3=Utilities.GenerateCallback(CUIContentMgrDlg.SafeDoCreateSubFolder,[this.sAppName]);CUIDialogMgr._sQ.SetCallBackFuntion(_G3);CUIDialogMgr._sQ.Display('IDS_NEW_FOLDER_NAME','','IDS_NEW_FOLDER');};CUIContentMgrDlg.SafeHandleNew=function(_Ke,e){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager.oDialogMgr._jg.HandleNew();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIContentMgrDlg.prototype.HandleRefresh=function(){var _yA=true;this._fM._hq.GetChildren(this._fM._aQ,_yA);this.updateListDir();this.updateDropDown();};CUIContentMgrDlg.SafeHandleRefresh=function(_Ke,e){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager.oDialogMgr._jg.HandleRefresh();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIContentMgrDlg.prototype.ValidatePromptName=function(_HM){_HM=Utilities.trim(_HM);CUIDialogMgr._sQ.SetPromptValue(_HM);if(_HM==null||_HM==""){this.oDialogMgr.SetMultiModalDlg(CUIDialogMgr._sQ);CUIDialogMgr.DisplayMessageBox(CUIMessageBox.kWarning,'IDS_BAD_NAME');return false;}else{var _BU=this.oDialogMgr.oUIMgr.dataManager._kE[this._fM._aQ._oa];Debug.Assert(_BU!=null);if(_BU.ChildExist(_HM)){this.oDialogMgr.SetMultiModalDlg(CUIDialogMgr._sQ);var _ahj=this.oRes.ReplaceParam('IDS_OBJECT_EXISTS',1,_HM);CUIDialogMgr.DisplayMessageBox(CUIMessageBox.kWarning,_ahj);return false;}}return true;};CUIContentMgrDlg.prototype.HandleRename=function(){var _7j=this._s0.GetSelection();if(_7j){var _Tl=this._fM._hq._iN.GetNode(_7j.sValue);Debug.Assert(_Tl&&(_Tl._lW==ExpAPIXml.eCMRegularFolder||_Tl._lW==ExpAPIXml.eCMAnalysis));var _Ke=this.sAppName;var _G3=Utilities.GenerateCallback(CUIContentMgrDlg.SafeDoRenameObject,[_Ke,_Tl]);CUIDialogMgr._sQ.SetCallBackFuntion(_G3);CUIDialogMgr._sQ.Display('IDS_NEW_FOLDER_NAME',_Tl._p8,'IDS_RENAME');}};CUIContentMgrDlg.SafeDoRenameObject=function(_Ke,_Tl){/*@if(!@bering_debug)@*/try{/*@end@*/var _ano=FindApp(_Ke).uiManager.oDialogMgr._jg;var _agQ=_ano._fM;var _afh=_agQ._hq;var _al7=CUIDialogMgr._sQ.GetPromptValue();if(_ano.ValidatePromptName(_al7)){_afh.RenameObject(_Tl,_al7);CUIDialogMgr.SafeHideCurrentDialog(_Ke);}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIContentMgrDlg.SafeHandleRename=function(_Ke,e){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager.oDialogMgr._jg.HandleRename();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};function CUISaveDlg(){this.base=CUIContentMgrDlg;this.base();};CUISaveDlg.prototype=new CUIContentMgrDlg;CUISaveDlg.superclass=CUIContentMgrDlg.prototype;CUISaveDlg.prototype.Display=function(_TO,_Vf,_Ep){if(_Ep){var _Ke=this.sAppName;var _aC7=Utilities.GenerateCallback(CUISaveDlg.SafeOnSave,[_Ke,'',_Vf]);this._Y=_aC7;CUISaveDlg.superclass.Display.call(this,'IDS_SAVE_DLG_TITLE','',_TO,HelpConstants.kSaveAnsLink,_aC7);}else{CUISaveDlg.superclass.Display.call(this,'IDS_SAVE_DLG_TITLE','',_TO,HelpConstants.kSaveAnsLink);}};CUISaveDlg.prototype.Init=function(_yt,_Vf){var _Ke=_yt.oUIMgr.appobj.appname;var _aC7=function(){CUISaveDlg.SafeOnSave(_Ke,'',_Vf);};return CUISaveDlg.superclass.Init.call(this,_yt,CUIContentMgrDlg.dlgTypeSaveAs,_aC7);};CUISaveDlg.SafeDoConfirmSave=function(_Ke,_EQ,_Cw,_Ii,_Vf){/*@if(!@bering_debug)@*/try{/*@end@*/var _auf=FindApp(_Ke);var _AT=_auf.dataManager;var ws=_AT.GetCurrentWorkSheet();var _aD2=null;var _avc=null;if(_Vf){if(_auf.HasDefaultAnalysis()){_aD2=Utilities.GenerateCallback(ws.DoNewFromDefault,[],ws);}else{_aD2=Utilities.GenerateCallback(ws.DoNew,[],ws);}}ws.Save(_EQ,_Cw,_Ii,_aD2,_avc);CUIDialogMgr.SafeHideCurrentDialog(_Ke);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUISaveDlg.SafeOnSave=function(_Ke,_Om,_Vf){/*@if(!@bering_debug)@*/try{/*@end@*/var _Uk=FindApp(_Ke).uiManager;var _adG=_Uk.oDialogMgr._jg;var _EQ=_Om?_Om:_adG.DoValidateFileName();if(_EQ!=null){_adG._jx.value=_EQ;var _Hy=_Uk.oDialogMgr;var _Cw=_adG.GetFolderChoice();var _PM=null;for(var i=0;i<_adG._s0._wj.length;i++){_PM=_adG._s0._wj[i];var _Tl=_adG._fM._hq._iN.GetNode(_PM.sValue);if(_Tl&&_Tl._p8.toUpperCase()==_EQ.toUpperCase()){if(!this._rX){this._rX=new CUIConfirmOverwriteDlg();this._rX.Init(_Hy);this._rX.SetModalState();}_Hy.ActivateModalDlgTemplate();_Hy.SetModalDlgWidth(CUIDialogMgr.iInteractMDlgPcntOfTWidth);this._rX.SetInitParam(_EQ,_Cw,_Vf);this._rX.Display();return;}}CUISaveDlg.SafeDoConfirmSave(_Ke,_EQ,_Cw,ExpAPIXml.eUpdateOptFail,_Vf);}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};function CUIOpenDlg(){this.base=CUIContentMgrDlg;this.base();};CUIOpenDlg.prototype=new CUIContentMgrDlg;CUIOpenDlg.superclass=CUIContentMgrDlg.prototype;CUIOpenDlg.prototype.Display=function(_TO){CUIOpenDlg.superclass.Display.call(this,'IDS_OPEN_DLG_TITLE','',_TO,HelpConstants.kOpenAnsLink);};CUIOpenDlg.prototype.Init=function(_yt){var _Ke=_yt.oUIMgr.appobj.appname;var _amI=Utilities.GenerateCallback(this.OnOpen,[_Ke],this);return CUIOpenDlg.superclass.Init.call(this,_yt,CUIContentMgrDlg.dlgTypeOpen,_amI);};CUIOpenDlg.prototype.OnOpen=function(_Ke){var _auf=FindApp(_Ke);var _Hk=_auf.uiManager;var _AT=_auf.dataManager;var _7j=this._s0.GetSelection();if(_7j){var _anL=this._fM._hq._iN.GetNode(_7j.sValue);if(_anL&&_anL._lW==ExpAPIXml.eCMAnalysis){var _EQ=this.DoValidateFileName();var _Cw=this.GetFolderChoice();var _ap1=_AT._kE[_anL._oa];if(this._vA==null){_auf.clearRequestTracking();_auf.commManager.SearchRoutingServerGroup(_ap1._qI);}else{_AT.GetCurrentWorkSheet().Load(_ap1._qI,this._vA);this.clearRoutingServerGroupCache();_Hk.oDialogMgr.HideCurrentDialog();}}}};CUIOpenDlg.prototype.cacheRoutingServerGroup=function(_I6){this._vA=_I6;this.Notify(ExpEvent.kCDLCMAnalysis_GetRoutingServerGroupDone);};CUIOpenDlg.prototype.clearRoutingServerGroupCache=function(){this._vA=null;};function CUIConfirmOverwriteDlg(){this.base=CUIDialog;this.base();this._du='';this._jF='';};CUIConfirmOverwriteDlg.prototype=new CUIDialog;CUIConfirmOverwriteDlg.superclass=CUIDialog.prototype;CUIConfirmOverwriteDlg.prototype.SetInitParam=function(_EQ,_Cw,_Vf){this._du=_EQ;this._jF=_Cw;this._el=_Vf;};CUIConfirmOverwriteDlg.prototype.Display=function(){this.Create();CUIConfirmOverwriteDlg.superclass.Display.call(this,ExpMiscStr.kProductName,null,this._lq);};CUIConfirmOverwriteDlg.kReplace='replace';CUIConfirmOverwriteDlg.kNewName='newname';CUIConfirmOverwriteDlg.prototype.Create=function(){var _Ke=this.sAppName;var _zr=document.createElement('TABLE');_zr.className='dialogTable';var _F0=document.createElement('TBODY');_zr.appendChild(_F0);var _NH=document.createElement('TR');var _NM=document.createElement('TD');_NM.rowSpan=5;var _Bb='msg_warning.gif';var _agf=COTInputElementFactory.CreateImage(_Bb,32,32,null,true,true);_NM.appendChild(_agf);_NH.appendChild(_NM);COTStyle.SetWidth(_NM,10,'%');_NM=this._g5.cloneNode(false);_NM.colSpan=2;var _apS=document.createTextNode(this.oRes.ReplaceParam('IDS_CONFIRM_OVERWRITE',1,this._du));_NM.appendChild(_apS);_NH.appendChild(_NM);_F0.appendChild(_NH);_NH=document.createElement('TR');_F0.appendChild(_NH);_NM=this._g5.cloneNode(false);COTStyle.SetWidth(_NM,5,'%');COTStyle.SetHeight(_NM,20);_apS=COTInputElementFactory.CreateRadioButton('dupSolution',CUIConfirmOverwriteDlg.kReplace,true,false);_NM.appendChild(_apS);_NH.appendChild(_NM);_NM=this._g5.cloneNode(false);_apS=document.createTextNode(this.oRes.GetString('IDS_REPLACE_EXISITNG_ENTRY'));_NM.appendChild(_apS);_NH.appendChild(_NM);_NH=document.createElement('TR');_F0.appendChild(_NH);_NM=this._g5.cloneNode(false);COTStyle.SetWidth(_NM,5,'%');COTStyle.SetHeight(_NM,20);_apS=COTInputElementFactory.CreateRadioButton('dupSolution',CUIConfirmOverwriteDlg.kNewName,false,false);_NM.appendChild(_apS);_NH.appendChild(_NM);_NM=this._g5.cloneNode(false);_apS=document.createTextNode(this.oRes.GetString('IDS_ENTER_NEW_NAME'));_NM.appendChild(_apS);_NH.appendChild(_NM);_NH=document.createElement('TR');_F0.appendChild(_NH);_NM=document.createElement('TD');COTStyle.SetWidth(_NM,5,'%');_NH.appendChild(_NM);_NM=this._g5.cloneNode(false);_NH.appendChild(_NM);_apS=COTInputElementFactory.CreateTextBox(204,'px','',false,null,null,null,this);this._hO=_apS.id;_apS.style.fontSize='100%';_NM.appendChild(_apS);_NH=document.createElement('TR');_F0.appendChild(_NH);_NM=this._g5.cloneNode(false);_NM.colSpan=2;_apS=document.createTextNode(this.oRes.GetString('IDS_CONFIRM_CONTINUE'));_NM.appendChild(_apS);_NH.appendChild(_NM);this._Y=Utilities.GenerateCallback(this.DoUpdateSaveParam,[this.sAppName,this._el],this);this._lq=_zr;};CUIConfirmOverwriteDlg.prototype.DoUpdateSaveParam=function(_Ke,_Vf){var _Z4=COTInputElementFactory.GetRadioSelectionValue('dupSolution');var _EQ=this._du;var _Cw=this._jF;if(_Z4==CUIConfirmOverwriteDlg.kNewName){_EQ=Utilities.trim(document.getElementById(this._hO).value);if(_EQ==""){document.getElementById(this._hO).value="";this.oDialogMgr.SetMultiModalDlg(this);CUIDialogMgr.DisplayMessageBox(CUIMessageBox.kWarning,'IDS_BAD_NAME');return;}else{CUIDialogMgr.SafeHideCurrentDialog(_Ke);CUISaveDlg.SafeOnSave(_Ke,_EQ,_Vf);return;}}CUISaveDlg.SafeDoConfirmSave(_Ke,_EQ,_Cw,ExpAPIXml.eUpdateOptReplace,_Vf);CUIDialogMgr.SafeHideCurrentDialog(_Ke);};CUIConfirmOverwriteDlg.prototype.OnFocusTextBox=function(_A4){COTInputElementFactory.SelectRadioItem('dupSolution',CUIConfirmOverwriteDlg.kNewName);};function CUIReportTemplateDlg(_TN){this.base=CUIContentMgrDlg;this.base();this._sB=_TN;};CUIReportTemplateDlg.prototype=new CUIContentMgrDlg;CUIReportTemplateDlg.superclass=CUIContentMgrDlg.prototype;CUIReportTemplateDlg.prototype.Display=function(_TO){CUIReportTemplateDlg.superclass.Display.call(this,'IDS_REPORT_TEMPLATE_DLG_TITLE','',_TO,HelpConstants.kOpenAnsLink);};CUIReportTemplateDlg.prototype.Init=function(_yt){var _Ke=_yt.oUIMgr.appobj.appname;var _amI=Utilities.GenerateCallback(this.OnOpen,[_Ke],this);this._fj=_yt;return CUIReportTemplateDlg.superclass.Init.call(this,_yt,CUIContentMgrDlg.dlgTypeReportTemplate,_amI);};CUIReportTemplateDlg.prototype.OnOpen=function(_Ke){var _AT=this._fj.oUIMgr.dataManager;var _7j=this._s0.GetSelection();if(_7j){var _anL=this._fM._hq._iN.GetNode(_7j.sValue);if(_anL&&_anL._lW==ExpAPIXml.eCMReportTemplate){var _EQ=this.DoValidateFileName();var _Cw=this.GetFolderChoice();var _ap1=_AT._kE[_anL._oa];this.SetReportTemplate(_ap1._qI);CUIDialogMgr.SafeHideCurrentDialog(_Ke);}}};CUIReportTemplateDlg.prototype.SetReportTemplate=function(_Az){this._sB.GetNewAnalysisObj().SetReportTemplate(_Az);};CUIReportTemplateDlg.prototype.CanStackPreviousDlg=function(){return true;};CUISetMaxDisplayNumDlg.kAllScope=1;CUISetMaxDisplayNumDlg.kInclChildScope=2;CUISetMaxDisplayNumDlg.kCurntItemScope=3;function CUISetMaxDisplayNumDlg(){this.base=CUIDialog;this.base();this._tC=null;this._vF=-1;this._xe=new Object();};CUISetMaxDisplayNumDlg.prototype=new CUIDialog;CUISetMaxDisplayNumDlg.superclass=CUIDialog.prototype;CUISetMaxDisplayNumDlg.prototype.Display=function(){var _Co=this.oDialogMgr.oUIMgr.appobj.oResources;var _Ke=this.sAppName;var _MY=new Object();var _Xf=Utilities.GenerateCallback(CUIManager.SafeDoHelpTopic,[_Ke,HelpConstants.kSetMaxLink]);_MY['IDS_HELP']=_Xf;CUISetMaxDisplayNumDlg.superclass.Display.call(this,'IDS_SET_MAX_NUM_DLG_TITLE',_MY,this._lq);};CUISetMaxDisplayNumDlg.prototype.ClearDlg=function(){};CUISetMaxDisplayNumDlg.prototype.SetDefaultValue=function(_Td){this._vF=_Td;};CUISetMaxDisplayNumDlg.prototype.SetHostObj=function(_Oa){this._tC=_Oa;this.SetDefaultValue(this._tC._v3);};CUISetMaxDisplayNumDlg.prototype.SetMaxEntry=function(_Qi){this._v4=_Qi;};CUISetMaxDisplayNumDlg.prototype.SetScopeOpts=function(){this._xe[CUISetMaxDisplayNumDlg.kCurntItemScope]=this.oRes.GetString('IDS_CRNT_ITEM_SCOPE');this._xe[CUISetMaxDisplayNumDlg.kInclChildScope]=this.oRes.GetString('IDS_INCL_CHILD_SCOPE');this._xe[CUISetMaxDisplayNumDlg.kAllScope]=this.oRes.GetString('IDS_ALL_SCOPE');};CUISetMaxDisplayNumDlg.prototype.Create=function(){this.ClearDlg();var _Ke=this.sAppName;var _zr=document.createElement('TABLE');_zr.className='dialogTable';COTStyle.SetHeight(_zr,140);var _F0=document.createElement('TBODY');var _NH=document.createElement('TR');var _NM=this._l4.cloneNode(false);_NM.colSpan=2;COTStyle.SetWidth(_NM,100,'%');var _apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_MAX_NUM'));_NM.appendChild(_apS);_NH.appendChild(_NM);_F0.appendChild(_NH);var _NH=document.createElement('TR');var _NM=this._g5.cloneNode(false);_NM.colSpan=2;COTStyle.SetWidth(_NM,100,'%');var _78=this._v4;var _aHY=this.oRes.ReplaceParam('IDS_MAX_TREE_DISPLAY_NUM_DLG_MAX_ENTRY',1,_78);var _apS=COTInputElementFactory.CreateLabel(_aHY);_NM.appendChild(_apS);_NH.appendChild(_NM);_F0.appendChild(_NH);_NH=document.createElement('TR');_NM=this._gM.cloneNode(false);COTStyle.SetWidth(_NM,3,'%');this._xu=COTInputElementFactory.CreateIntegerTextBox(this,2,this._vF,false,false,1,_78);this._xu.style.fontSize='100%';this._xu.oDlgObj=this;_NM.appendChild(this._xu);_NH.appendChild(_NM);_NM=this._gM.cloneNode(false);COTStyle.SetWidth(_NM,97,'%');var _4v=Utilities.GenerateCallback(CUISetMaxDisplayNumDlg.SafeDoReset,[_Ke]);_apS=COTInputElementFactory.CreateLink(_4v,this.oRes.ReplaceParam('IDS_MAX_TREE_DISPLAY_NUM_DLG_RESET_DEF_MAX_ENTRY',1,ExpAPIXml.defaultMaxChildNum),true);_apS.id=Utilities.GenerateId();this._iD=_apS.id;_NM.appendChild(_apS);_NH.appendChild(_NM);_F0.appendChild(_NH);_NH=document.createElement('TR');_NM=_NH.appendChild(document.createElement('TD'));_F0.appendChild(_NH);_NH=document.createElement('TR');_NM=this._l4.cloneNode(false);_NM.colSpan=2;COTStyle.SetWidth(_NM,100,'%');var _apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_APPLY_SCOPE'));_NM.appendChild(_apS);_NM.style.paddingTop="10px";_NH.appendChild(_NM);_F0.appendChild(_NH);_NH=document.createElement('TR');_NM=this._gM.cloneNode(false);_NM.colSpan=2;this._on=new CUIListCtrl(this.oDialogMgr.oUIMgr);this._on.iMaxHeight=150;this._on.Init();this._on.DisableHAutoScroll();var _aCZ=null;for(var i in this._xe){var _PM=this._on.AddItem('',this._xe[i],0,i,"",false);if(!_aCZ){_aCZ=_PM;}}this._M=new CUIComboBox(this.oDialogMgr.oUIMgr,this._on);this._M.DisableIcon();var _afs=_NM.appendChild(this._M.Init());this._M.SetWidth(35,'%');this._M.SetValueFromListItem(_aCZ,false);_NM.style.paddingBottom="10px";_NH.appendChild(_NM);_F0.appendChild(_NH);this._Y=Utilities.GenerateCallback(this.ApplyNumber,[],this);this._om=2;_zr.appendChild(_F0);this._lq=_zr;};CUISetMaxDisplayNumDlg.prototype.ApplyNumber=function(){this.oDialogMgr.oUIMgr._qi.ApplyMaxDisplayNum(this._tC,parseInt(this._xu.value),this._M.GetValue());CUIDialogMgr.SafeHideCurrentDialog(this.sAppName);};CUISetMaxDisplayNumDlg.SafeDoReset=function(_Ke){try{FindApp(_Ke).uiManager.oDialogMgr._jg.ResetDefaultValue();}catch(excep){_f.HandleException(excep);}};CUISetMaxDisplayNumDlg.prototype.ResetDefaultValue=function(){this._xu.value=ExpAPIXml.defaultMaxChildNum;};CUISetMaxDisplayNumDlg.prototype.OnTextBoxMaxExceeded=function(id,_Mu){if(_Mu.id==this._iD){this.ResetDefaultValue();}else{var _78=this._v4;var _BM=this.oRes.ReplaceParam('IDS_MAX_TREE_DISPLAY_NUM_REACHED',1,_78);CUIDialogMgr.DisplayMessageBox(CUIMessageBox.kInformation,_BM);}};function CUISetDefaultBlockSizeDlg(){this.base=CUIDialog;this.base();this._vF=-1;this._v4=9999;};CUISetDefaultBlockSizeDlg.prototype=new CUIDialog;CUISetDefaultBlockSizeDlg.superclass=CUIDialog.prototype;CUISetDefaultBlockSizeDlg.prototype.Display=function(){var _Co=this.oDialogMgr.oUIMgr.appobj.oResources;var _Ke=this.sAppName;var _MY=new Object();var _Xf=Utilities.GenerateCallback(CUIManager.SafeDoHelpTopic,[_Ke,HelpConstants.kSetDefBlockSizeLink]);_MY['IDS_HELP']=_Xf;CUISetDefaultBlockSizeDlg.superclass.Display.call(this,'IDS_SET_DEF_BLOCK_SIZE_DLG_TITLE',_MY,this._lq,'IDS_SET_DEF_BLOCK_SIZE_DLG_INSTR_TEXT');};CUISetDefaultBlockSizeDlg.prototype.SetDefaultValue=function(_Td){this._vF=_Td;};CUISetDefaultBlockSizeDlg.prototype.SetMaxEntry=function(_Qi){this._v4=_Qi;};CUISetDefaultBlockSizeDlg.prototype.ClearDlg=function(){var _MU=this.GetDiv();Dom.RemoveAllChildren(_MU);this._xu=null;this._lq=null;};CUISetDefaultBlockSizeDlg.prototype.Create=function(){this.ClearDlg();var _Ke=this.sAppName;var _zr=document.createElement('TABLE');_zr.className='dialogTable';var _F0=document.createElement('TBODY');var _NH=document.createElement('TR');var _NM=this._l4.cloneNode(false);_NM.colSpan=2;COTStyle.SetWidth(_NM,100,'%');_NM.style.paddingTop="20px";var _apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_DEF_NUM'));_NM.appendChild(_apS);_NH.appendChild(_NM);_F0.appendChild(_NH);_NH=document.createElement('TR');_NM=this._gM.cloneNode(false);_NM.style.paddingBottom="20px";COTStyle.SetWidth(_NM,3,'%');this._xu=COTInputElementFactory.CreateIntegerTextBox(this,2,this._vF,false,false,1,this._v4);this._xu.style.fontSize='100%';this._xu.oDlgObj=this;_NM.appendChild(this._xu);_NH.appendChild(_NM);_NM=this._gM.cloneNode(false);COTStyle.SetWidth(_NM,97,'%');var _4v=Utilities.GenerateCallback(CUISetMaxDisplayNumDlg.SafeDoReset,[_Ke]);_apS=COTInputElementFactory.CreateLink(_4v,this.oRes.ReplaceParam('IDS_RESET_DEF_NUM',1,ExpAPIXml.originDefBlockSize),true);_apS.id=Utilities.GenerateId();this._iD=_apS.id;_NM.appendChild(_apS);_NM.style.paddingBottom="20px";_NH.appendChild(_NM);_F0.appendChild(_NH);this._Y=Utilities.GenerateCallback(this.ApplyNumber,[],this);this._om=1;_zr.appendChild(_F0);this._lq=_zr;};CUISetDefaultBlockSizeDlg.prototype.ApplyNumber=function(){var _RJ=this.oDialogMgr.oUIMgr.dataManager.metadata;_RJ.ChangeDefBlockSize(this._xu.value);CUIDialogMgr.SafeHideCurrentDialog(this.sAppName);};CUISetDefaultBlockSizeDlg.SafeDoReset=function(_Ke){try{FindApp(_Ke).uiManager.oDialogMgr._jg.ResetDefaultValue();}catch(excep){_f.HandleException(excep);}};CUISetDefaultBlockSizeDlg.prototype.ResetDefaultValue=function(){this._xu.value=ExpAPIXml.originDefBlockSize;};CUISetDefaultBlockSizeDlg.prototype.OnTextBoxMaxExceeded=function(id,_Mu){if(_Mu.id==this._iD){this.ResetDefaultValue();}else{var _78=this._v4;var _BM=this.oRes.ReplaceParam('IDS_MAX_TREE_DISPLAY_NUM_REACHED',1,_78);CUIDialogMgr.DisplayMessageBox(CUIMessageBox.kInformation,_BM);}};function CUISaveCustomSetDlg(){this.base=CUIDialog;this.base();this._tC=null;};CUISaveCustomSetDlg.prototype=new CUIDialog;CUISaveCustomSetDlg.superclass=CUIDialog.prototype;CUISaveCustomSetDlg.iDefaultNameIdx=1;CUISaveCustomSetDlg.getDefaultNameIdx=function(){var _Lx=String(CUISaveCustomSetDlg.iDefaultNameIdx);return _Lx;};CUISaveCustomSetDlg.prototype.GetDefaultLabel=function(){var _BM=this.oRes.ReplaceParam('IDS_CUSTOM_SET_DEFAULT_NAME',1,CUISaveCustomSetDlg.getDefaultNameIdx());return _BM;};CUISaveCustomSetDlg.prototype.Init=function(_yt){CUISaveCustomSetDlg.superclass.Init.call(this,_yt);this.oDialogMgr.oUIMgr._jf.Subscribe(this,ExpEvent.kCUIWorksheet_ChangedBlockSel);this.oDialogMgr.oUIMgr._jf.Subscribe(this,ExpEvent.kCUIWorksheet_NoAxisSel);var _aDg=this.oDialogMgr.oUIMgr._jf.GetUIAxesContainer().GetUIAxis(CUIDataMatrix.iRowIndex);_aDg._az.Subscribe(this,ExpEvent.kUserSelection_MemberChange);_aDg._az.Subscribe(this,ExpEvent.kUserSelection_BlockChange);var _ZP=this.oDialogMgr.oUIMgr._jf.GetUIAxesContainer().GetUIAxis(CUIDataMatrix.iColIndex);_ZP._az.Subscribe(this,ExpEvent.kUserSelection_MemberChange);_ZP._az.Subscribe(this,ExpEvent.kUserSelection_BlockChange);};CUISaveCustomSetDlg.prototype.Display=function(_M3){var _Co=this.oDialogMgr.oUIMgr.appobj.oResources;var _Ke=this.sAppName;var _MY=new Object();var _Xf=Utilities.GenerateCallback(CUIManager.SafeDoHelpTopic,[_Ke,HelpConstants.kCustomSetLink]);_MY['IDS_HELP']=_Xf;if(_M3){var _Li=this.oDialogMgr.oUIMgr.dataManager.GetCurrentDataMatrix();var _W7=_Li.GetAllBlocksArray();var _Nk=new Array();for(var i=0;i<_W7.length;i++){if(_W7[i].CanSaveAsCustomSet()){_Nk=_Nk.concat(_W7[i]);}}var _aJh=false;this.DisplayInvalidSelection('IDS_SAVE_CUSTOM_SET_DLG_TITLE',_MY,_Nk,_Li,'CUSTOMSET',_aJh);}else{CUISaveCustomSetDlg.superclass.Display.call(this,'IDS_SAVE_CUSTOM_SET_DLG_TITLE',_MY,this._lq,'IDS_SAVE_CUSTOM_SET_INSTRUCT');var _3F=false;COTInputElementFactory.ResetTextAreaHandlers(this._wg,_3F);COTInputElementFactory.ResetTextBoxHandlers(this._c4,_3F);this._c4.value=this.GetDefaultLabel();this._wg.value="";this.SetExistCSList();this._c4.focus();}};CUISaveCustomSetDlg.prototype.ClearDlg=function(){};CUISaveCustomSetDlg.prototype.SetHostObj=function(_Oa){this._tC=_Oa;};CUISaveCustomSetDlg.prototype.SetSelectedMembers=function(_ES){this._wZ=_ES;};CUISaveCustomSetDlg.prototype.SetExistCSList=function(){this._wu.ClearAllItems();var _agq=this.oDialogMgr.oUIMgr._np._ey;for(var i in _agq){if(_agq[i]._ia.IsFromOtherAnalysis()){continue;}var _1j='Custom_set.gif';this._wu.AddItem(_1j,_agq[i]._ia._p8,0,_agq[i]._ia._ks,_agq[i]._ia._d0);}var _U4=3;this._wu.Show(_U4);};CUISaveCustomSetDlg.prototype.Create=function(){this.ClearDlg();var _Ke=this.sAppName;var _zr=document.createElement('TABLE');_zr.className='dialogTable';var _F0=document.createElement('TBODY');var _NH=document.createElement('TR');var _NM=this._l4.cloneNode(false);COTStyle.SetWidth(_NM,50,'%');var _apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_CUSTOM_SET_NAME'));_NM.appendChild(_apS);_NH.appendChild(_NM);_NM=this._l4.cloneNode(false);COTStyle.SetWidth(_NM,50,'%');_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_EXIST_CUSTOM_SET'));_NM.appendChild(_apS);_NH.appendChild(_NM);_F0.appendChild(_NH);_NH=document.createElement('TR');_NM=document.createElement('TD');COTStyle.SetWidth(_NM,50,'%');this._c4=COTInputElementFactory.CreateTextBox(200,'px',"",false,false,1);_NM.appendChild(this._c4);_NH.appendChild(_NM);_NM=document.createElement('TD');_NM.rowSpan=3;COTStyle.SetWidth(_NM,50,'%');this._wu=new CUIListCtrl(this.oDialogMgr.oUIMgr);this._wu.iMaxHeight=150;var _agW=_NM.appendChild(this._wu.Init());this.SetExistCSList();this._wu.Subscribe(this,ExpEvent.kCUIListCtrl_OnSelChange);COTStyle.SetWidth(_agW,90,'%');_NH.appendChild(_NM);_F0.appendChild(_NH);_NH=document.createElement('TR');_NM=this._l4.cloneNode(false);COTStyle.SetWidth(_NM,50,'%');_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_EDIT_CS_ANNOTATION'));_NM.appendChild(_apS);_NH.appendChild(_NM);_F0.appendChild(_NH);_NH=document.createElement('TR');_NM=document.createElement('TD');COTStyle.SetWidth(_NM,50,'%');var _U4=2;this._wg=COTInputElementFactory.CreateTextArea(8,50,null,null,null,_U4);_NM.appendChild(this._wg);_NH.appendChild(_NM);_F0.appendChild(_NH);COTInputElementFactory.SetTextAreaEnterEventHandler(this._wg);this._Y=Utilities.GenerateCallback(this.DoSave,[],this);this._om=4;_zr.appendChild(_F0);this._lq=_zr;};CUISaveCustomSetDlg.SafeDoContinueReplaceCS=function(_VN,_DC){/*@if(!@bering_debug)@*/try{/*@end@*/_VN.ContinueReplaceCS(_DC);CUIDialogMgr.SafeHideCurrentDialog(_VN.sAppName);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUISaveCustomSetDlg.prototype.ContinueReplaceCS=function(_DC){this.OverwriteCustomSet(_DC);if(this._tC){this.oDialogMgr.oUIMgr._jf.SetLastBlockSelectionId(this._tC.GetId());}this.oDialogMgr.oUIMgr.OnCustomSetDlgClose();CUIDialogMgr.SafeHideCurrentDialog(this.sAppName);};CUISaveCustomSetDlg.prototype.DoSave=function(){if(this._c4.value==""){CUIDialogMgr.DisplayMessageBox(CUIMessageBox.kWarning,'IDS_CUSTOM_SET_DLG_BAD_NAME');return;}var _agc=false;var _DC=null;var _amW=Utilities.eStateContinue;for(var i in this.oDialogMgr.oUIMgr._np._ey){var _8V=this.oDialogMgr.oUIMgr._np._ey[i]._ia;if(_8V.IsFromOtherAnalysis()){continue;}_DC=_8V._ks;if(this._c4.value==_8V._p8){_amW=Utilities.eStateHold;CUIDialogMgr._U.SetCallBackFuntion(Utilities.ExecuteHoldingProcedure);var _aBt=this.oRes.ReplaceParam('IDS_CUSTOM_SET_DLG_CONFIRM_OVERWRITE',1,this._c4.value);CUIDialogMgr._U.Display(_aBt,'',CUIConfirmDlg._hw);var _Ro=new Array(this,_DC);Utilities.SetProcedureToHold(CUISaveCustomSetDlg.SafeDoContinueReplaceCS,_Ro);return;}}if(_amW==Utilities.eStateContinue){if(_agc){this.OverwriteCustomSet(_DC);}else{this.AddAsCustomSet();}CUISaveCustomSetDlg.iDefaultNameIdx++;if(this._tC){this.oDialogMgr.oUIMgr._jf.SetLastBlockSelectionId(this._tC.GetId());}CUIDialogMgr.SafeHideCurrentDialog(this.sAppName);this.oDialogMgr.oUIMgr.OnCustomSetDlgClose();}};CUISaveCustomSetDlg.prototype.AddAsCustomSet=function(){var _atJ=this.oDialogMgr.oUIMgr.dataManager._kX;if(this._wZ&&this._wZ.length>0){_atJ.SendCreateCustomSetFromSelectedMembersReq(this._wZ,this._c4.value,this._wg.value);}else if(this._tC){_atJ.SendCreateCustomSetReq(this._tC.oAxis._rk._ks,this._tC.oAxis._ks,this._tC.sExprId,this._c4.value,this._wg.value);}};CUISaveCustomSetDlg.prototype.OverwriteCustomSet=function(_Rf){var _atJ=this.oDialogMgr.oUIMgr.dataManager._kX;if(this._wZ&&this._wZ.length>0){_atJ.OverwriteCustomSetFromSelectedMembers(this._wZ,_Rf,this._wg.value);}else if(this._tC){_atJ.OverwriteCustomSet(this._tC.oAxis._rk._ks,this._tC.oAxis._ks,this._tC.sExprId,_Rf,this._wg.value);}};CUISaveCustomSetDlg.prototype.SetSelectedName=function(){this._c4.value=this._wu.GetSelection().GetLabel();this._wg.value=this._wu.GetSelection().GetToolTip();};CUISaveCustomSetDlg.prototype.Notify=function(event){if(event==ExpEvent.kCUIManager_Unload){this.UnLoad();}else if(this._r3){if(event==ExpEvent.kCUIListCtrl_OnSelChange){this.SetSelectedName();}else if(event==ExpEvent.kCUIWorksheet_ChangedBlockSel){var _avG=this.oDialogMgr.oUIMgr._jf.GetSelectedBlock();if(_avG&&_avG.CanSaveAsCustomSet()){this.SetHostObj(_avG);this.SetSelectedMembers(null);this.Display();}}else if(event==ExpEvent.kUserSelection_MemberChange||event==ExpEvent.kUserSelection_BlockChange){var _O0=this.oDialogMgr.oUIMgr._jf.GetUIAxesContainer().GetSelectedAxis();if(_O0&&_O0.CanHamcizeSelectedMembers()){var _C9=new Array();for(id in _O0._hb){var _aiQ=_O0._hb[id];if(_aiQ){_C9.push(_aiQ.GetMemberId());}}this.SetHostObj(null);this.SetSelectedMembers(_C9);this.Display();}else{var _M3=true;this.Display(_M3);}}else if(event==ExpEvent.kCUIWorksheet_NoAxisSel){var _M3=true;this.Display(_M3);}}};CUISaveCustomSetDlg.prototype.UnLoad=function(){Dom.RemoveAllChildren(this._vO);CUISaveCustomSetDlg.superclass.Unload.call(this);};function CUIRenameCustomSetDlg(_CR,_KM){this.base=CUIDialog;this.base();this._hs='';this._k7='';};CUIRenameCustomSetDlg.prototype=new CUIDialog;CUIRenameCustomSetDlg.superclass=CUIDialog.prototype;CUIRenameCustomSetDlg.prototype.Display=function(){var _MY=new Object();var _Ke=this.sAppName;var _Xf=Utilities.GenerateCallback(CUIManager.SafeDoHelpTopic,[_Ke,HelpConstants.kCustomSetLink]);_MY['IDS_HELP']=_Xf;CUICalculationDlg.superclass.Display.call(this,'IDS_RENAME_CS_DLG_TITLE',_MY,this._lq,'IDS_RENAME_CS_INSTRUCT');};CUIRenameCustomSetDlg.prototype.SetCustomSet=function(id,_Ic,_z0){this._hs=id;this._k7=_Ic;this._nP=_z0;};CUIRenameCustomSetDlg.prototype.Create=function(){var _Ke=this.sAppName;var _zr=document.createElement('TABLE');_zr.className='dialogTable';var _F0=document.createElement('TBODY');var _NH=document.createElement('TR');var _NM=this._l4.cloneNode(false);COTStyle.SetWidth(_NM,100,'%');var _apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_CUSTOM_SET_NAME'));_NM.appendChild(_apS);_NH.appendChild(_NM);_F0.appendChild(_NH);_NH=document.createElement('TR');_NM=document.createElement('TD');this._c4=COTInputElementFactory.CreateTextBox(200,'px',this._k7,false);_NM.appendChild(this._c4);_NH.appendChild(_NM);_F0.appendChild(_NH);var _NH=document.createElement('TR');var _NM=this._l4.cloneNode(false);COTStyle.SetWidth(_NM,100,'%');var _apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_EDIT_CS_ANNOTATION'));_NM.appendChild(_apS);_NH.appendChild(_NM);_F0.appendChild(_NH);_NH=document.createElement('TR');_NM=document.createElement('TD');COTStyle.SetWidth(_NM,70,'%');this._wg=COTInputElementFactory.CreateTextArea(7,100,this._nP);_NM.appendChild(this._wg);_NH.appendChild(_NM);_F0.appendChild(_NH);COTInputElementFactory.SetTextAreaEnterEventHandler(this._wg);this._Y=Utilities.GenerateCallback(CUIRenameCustomSetDlg.SafeDoRename,[_Ke]);this._om=1;_zr.appendChild(_F0);this._lq=_zr;};CUIRenameCustomSetDlg.SafeDoRename=function(_Ke){try{var _yt=FindApp(_Ke).uiManager.oDialogMgr;var _aCJ=_yt._jg;if(_aCJ._k7!=_aCJ._c4.value&&_yt.oUIMgr._np.CustomSetNameExists(_aCJ._c4.value)){var _ahj=_aCJ.oRes.ReplaceParam('IDS_OBJECT_EXISTS',1,_aCJ._c4.value);CUIDialogMgr.DisplayMessageBox(CUIMessageBox.kWarning,_ahj);}else{_yt._jg.DoRename();}}catch(excep){_f.HandleException(excep);}};CUIRenameCustomSetDlg.prototype.DoRename=function(_V0){this.oDialogMgr.oUIMgr.dataManager._kX.SendRenameCSReq(this._hs,this._c4.value,this._wg.value);CUIDialogMgr.SafeHideCurrentDialog(this.sAppName);};CUIRenameCustomSetDlg.prototype.Notify=function(event){if(event==ExpEvent.kCUIManager_Unload){this.UnLoad();}};CUIRenameCustomSetDlg.prototype.UnLoad=function(){Dom.RemoveAllChildren(this._vO);CUIRenameCustomSetDlg.superclass.Unload.call(this);};CUIUserDefFilterDlg.kGT='gt';CUIUserDefFilterDlg.kLT='lt';CUIUserDefFilterDlg.kGTORE='geq';CUIUserDefFilterDlg.kLTORE='leq';CUIUserDefFilterDlg.kEQU='eq';CUIUserDefFilterDlg.kNE='neq';CUIUserDefFilterDlg.kISNULL='isnull';CUIUserDefFilterDlg.kISNOTNULL='isnotnull';CUIUserDefFilterDlg.FLTOprKeyMap=new Object();CUIUserDefFilterDlg.FLTOprTTMap=new Object();CUIUserDefFilterDlg.FLTOprSymbolKeyMap=new Object();CUIUserDefFilterDlg.FLTAlphanumericOprKeyMap=new Object();CUIUserDefFilterDlg.kAnd='and';CUIUserDefFilterDlg.kOr='or';CUIUserDefFilterDlg.FLTRuleRelArr=new Object();CUIUserDefFilterDlg.FLTRuleRelDetailArr=new Object();CUIUserDefFilterDlg.ComboArrowWidth=13;CUIUserDefFilterDlg.ComboArrowHeight=12;function CUIUserDefFilterDlg(_H8){this.base=CUIDialog;this.base();this._tC=null;this._kn=null;this._eS=new Object();this._h6=new Object();this._eZ=new Object();this._i2=new Object();this._lK=new Object();this._uc=document.createElement('TD');this._uc.className="pagerCtrlTBLHeader";this._xD=document.createElement('TD');this._xD.className="pagerCtrlTBLHeaderLastColumn";this._iP=_H8?true:false;this._nR=null;};CUIUserDefFilterDlg.prototype=new CUIDialog;CUIUserDefFilterDlg.superclass=CUIDialog.prototype;CUIUserDefFilterDlg.prototype.IsInSaveMode=function(){return this._iP;};CUIUserDefFilterDlg.prototype.GetOpener=function(){if(this.IsInSaveMode()){if(this._oC&&this._th){return this._oC;}else{return this.oDialogMgr.oUIMgr.oBlockPropsPane;}}return null;};CUIUserDefFilterDlg.prototype.GetRootOpener=function(){if(this.IsInSaveMode()){var _aAh=null;var opener=this;while(opener.GetOpener&&opener.GetOpener()){opener=opener.GetOpener();}_aAh=opener;return _aAh;}return null;};CUIUserDefFilterDlg.prototype.Display=function(_M3){var _Ke=this.sAppName;this._fs=false;if(!this._iP){this._Y=Utilities.GenerateCallback(this.DoSubmitFilterRule,[],this);}else{this._yi=Utilities.GenerateCallback(this.DoSubmitFilterRule,[],this);}this._of=Utilities.GenerateCallback(this.DoCancel,[_Ke],this);this._gl=Utilities.GenerateCallback(this.DoCancel,[_Ke],this);var _MY=new Object();var _Co=this.oDialogMgr.oUIMgr.appobj.oResources;var _Xf=Utilities.GenerateCallback(CUIManager.SafeDoHelpTopic,[_Ke,HelpConstants.kUserDefFilterLink]);_MY['IDS_HELP']=_Xf;this._jM=false;if(!_M3){var _Xf=Utilities.GenerateCallback(CUIUserDefFilterDlg.SafeOpenCombineFilterDlg,[_Ke]);_MY['IDS_COMBINE_FLT_DLG']=_Xf;if(this._th){CUIUserDefFilterDlg.superclass.Display.call(this,'IDS_USER_DEF_FLT_DLG_TITLE',_MY,this._lq,'IDS_EDIT_COMBINED_FLT_RULES');}else{CUIUserDefFilterDlg.superclass.Display.call(this,'IDS_USER_DEF_FLT_DLG_TITLE',_MY,this._lq,'IDS_USER_DEF_FLT_DLG_INSTRUCT');}}else{var _Li=this.oDialogMgr.oUIMgr.dataManager.GetCurrentDataMatrix();var _W7=_Li.GetAllBlocksArray();var _Nk=new Array();for(var i=0;i<_W7.length;i++){if(_W7[i].CanApplyUserDefFilter()){_Nk.push(_W7[i]);}}var _aJh=true;this.DisplayInvalidSelection('IDS_USER_DEF_FLT_DLG_TITLE',_MY,_Nk,_Li,'FILTER',_aJh);this._jM=true;return;}this.ScrollBarDisplayChecking();};CUIUserDefFilterDlg.prototype.ScrollBarDisplayChecking=function(){if(this._tT){var _aqK=document.getElementById(this._tT).offsetHeight;var _ZG=this._pR.offsetHeight;this._g6=document.getElementById(this._tT).offsetWidth;this._qp=this._g6-18;this._gy=this._lq.offsetWidth;if(_aqK<_ZG){if(!this._xT){COTStyle.SetWidth(this._pR,this._qp);this._xT=true;}}else{if(this._xT){COTStyle.SetWidth(this._pR,100,'%');this._xT=false;}}}};CUIUserDefFilterDlg.prototype.ClearDlg=function(){if(this._lq){this._lq._oDlgObj=null;}var _JA=true;if(Utilities.GetObjArrayLength(this._i2)>0){this.DoDelRule(_JA);}this._xT=null;this._tT=null;this._nR=null;};CUIUserDefFilterDlg.prototype.Unload=function(){this.ClearCachedSettings();this.ClearDlg();CUIUserDefFilterDlg.superclass.Unload.call(this);};CUIUserDefFilterDlg.prototype.SetInitFilterExpr=function(_Gd){this._kn=_Gd;this._kh=_Gd?_Gd.Clone():null;};CUIUserDefFilterDlg.prototype.RetrieveFLTRules=function(_F0){this._i2=Utilities.ClearObjectArray(this._i2);if(this._v8){Dom.RemoveObject(this._v8);this._v8=null;}var _arC=null;var _KR=this._kn.GetExprNode();var _1T=_KR.GetOperator();for(var i=0;i<_KR._sy.length;i++){var _ZB=_KR._sy[i];var _Sg=(i==0)?_1T:null;var _3q=this.TransferToUIFLTRule(_ZB,_Sg,_F0,_arC);_arC=_3q;}};CUIUserDefFilterDlg.prototype.SetHostObj=function(_Oa){this._tC=_Oa;};CUIUserDefFilterDlg.prototype.InitFLTRuleOptions=function(){this._eS[ExpAPIXml.kEleMeasure]=this.oRes.GetString('IDS_FLT_BY_MEASURE');this._eS[ExpAPIXml.kEleItemName]=this.oRes.GetString('IDS_FLT_BY_NAME');this._eS[ExpAPIXml.kEleProperty]=this.oRes.GetString('IDS_FLT_BY_ATTR');this._eZ[ExpAPIXml.kEleMeasure]='measure.gif';this._eZ[ExpAPIXml.kEleItemName]='name_icon.gif';this._eZ[ExpAPIXml.kEleProperty]='metadata_attribute.gif';if(Utilities.GetObjArrayLength(CUIUserDefFilterDlg.FLTOprKeyMap)==0){CUIUserDefFilterDlg.SetRuleOperators(this.oRes);};};CUIUserDefFilterDlg.SetRuleOperators=function(_Co){CUIUserDefFilterDlg.FLTOprKeyMap[CUIUserDefFilterDlg.kGT]=_Co.GetString('IDS_COMPARE_OP_GT');CUIUserDefFilterDlg.FLTOprKeyMap[CUIUserDefFilterDlg.kLT]=_Co.GetString('IDS_COMPARE_OP_LT');CUIUserDefFilterDlg.FLTOprKeyMap[CUIUserDefFilterDlg.kGTORE]=_Co.GetString('IDS_COMPARE_OP_GTEQU');CUIUserDefFilterDlg.FLTOprKeyMap[CUIUserDefFilterDlg.kLTORE]=_Co.GetString('IDS_COMPARE_OP_LTEQU');CUIUserDefFilterDlg.FLTOprKeyMap[CUIUserDefFilterDlg.kEQU]=_Co.GetString('IDS_COMPARE_OP_EQU');CUIUserDefFilterDlg.FLTOprKeyMap[CUIUserDefFilterDlg.kNE]=_Co.GetString('IDS_COMPARE_OP_NEQU');CUIUserDefFilterDlg.FLTOprKeyMap[CUIUserDefFilterDlg.kISNULL]=_Co.GetString('IDS_COMPARE_OP_ISNULL');CUIUserDefFilterDlg.FLTOprKeyMap[CUIUserDefFilterDlg.kISNOTNULL]=_Co.GetString('IDS_COMPARE_OP_ISNOTNULL');CUIUserDefFilterDlg.FLTOprTTMap[CUIUserDefFilterDlg.kGT]=_Co.GetString('IDS_COMPARE_OP_GT_TT');CUIUserDefFilterDlg.FLTOprTTMap[CUIUserDefFilterDlg.kLT]=_Co.GetString('IDS_COMPARE_OP_LT_TT');CUIUserDefFilterDlg.FLTOprTTMap[CUIUserDefFilterDlg.kGTORE]=_Co.GetString('IDS_COMPARE_OP_GTEQU_TT');CUIUserDefFilterDlg.FLTOprTTMap[CUIUserDefFilterDlg.kLTORE]=_Co.GetString('IDS_COMPARE_OP_LTEQU_TT');CUIUserDefFilterDlg.FLTOprTTMap[CUIUserDefFilterDlg.kEQU]=_Co.GetString('IDS_COMPARE_OP_EQU_TT');CUIUserDefFilterDlg.FLTOprTTMap[CUIUserDefFilterDlg.kNE]=_Co.GetString('IDS_COMPARE_OP_NEQU_TT');CUIUserDefFilterDlg.FLTOprTTMap[CUIUserDefFilterDlg.kISNULL]=_Co.GetString('IDS_COMPARE_OP_ISNULL_TT');CUIUserDefFilterDlg.FLTOprTTMap[CUIUserDefFilterDlg.kISNOTNULL]=_Co.GetString('IDS_COMPARE_OP_ISNOTNULL_TT');CUIUserDefFilterDlg.FLTRuleRelArr[CUIUserDefFilterDlg.kAnd]=_Co.GetString('IDS_RULE_REL_AND');CUIUserDefFilterDlg.FLTRuleRelArr[CUIUserDefFilterDlg.kOr]=_Co.GetString('IDS_RULE_REL_OR');CUIUserDefFilterDlg.FLTRuleRelDetailArr[CUIUserDefFilterDlg.kAnd]=_Co.GetString('IDS_RULE_REL_AND_WITH_DETAIL');CUIUserDefFilterDlg.FLTRuleRelDetailArr[CUIUserDefFilterDlg.kOr]=_Co.GetString('IDS_RULE_REL_OR_WITH_DETAIL');CUIUserDefFilterDlg.FLTAlphanumericOprKeyMap[ExpAPIXml.kContain]=_Co.GetString('IDS_COMPARE_OP_CONTAIN');CUIUserDefFilterDlg.FLTAlphanumericOprKeyMap[ExpAPIXml.kBeginWith]=_Co.GetString('IDS_COMPARE_OP_BEGINWITH');CUIUserDefFilterDlg.FLTAlphanumericOprKeyMap[ExpAPIXml.kEndWith]=_Co.GetString('IDS_COMPARE_OP_ENDWITH');CUIUserDefFilterDlg.FLTAlphanumericOprKeyMap[ExpAPIXml.kMatch]=_Co.GetString('IDS_COMPARE_OP_MATCH');CUIUserDefFilterDlg.FLTAlphanumericOprKeyMap[ExpAPIXml.kNotContain]=_Co.GetString('IDS_COMPARE_OP_NOT_CONTAIN');CUIUserDefFilterDlg.FLTAlphanumericOprKeyMap[ExpAPIXml.kNotBeginWith]=_Co.GetString('IDS_COMPARE_OP_NOT_BEGINWITH');CUIUserDefFilterDlg.FLTAlphanumericOprKeyMap[ExpAPIXml.kNotEndWith]=_Co.GetString('IDS_COMPARE_OP_NOT_ENDWITH');CUIUserDefFilterDlg.FLTAlphanumericOprKeyMap[ExpAPIXml.kNotMatch]=_Co.GetString('IDS_COMPARE_OP_NOT_MATCH');};CUIUserDefFilterDlg.prototype.SubscribeWSEvent=function(){this.oDialogMgr.oUIMgr._jf.Subscribe(this,ExpEvent.kCUIWorksheet_ChangedBlockSel);};CUIUserDefFilterDlg.prototype.Create=function(){this.ClearDlg();var _Ke=this.sAppName;var _zr=document.createElement('TABLE');_zr.className='dialogTable';_zr.onclick=CUIUserDefFilterDlg.SafeHandleClick;var _F0=document.createElement('TBODY');this._eB=this._tC.GetLabel();var _NH=document.createElement('TR');var _NM=document.createElement('TD');_NM.colSpan=4;var _agx=document.createElement('DIV');_agx.className='userDefFLTDlgRuleDiv';_agx.id=Utilities.GenerateId();this._tT=_agx.id;this._pR=document.createElement('TABLE');this._pR.className='pagerCtrlTBL';COTStyle.SetWidth(this._pR,100,'%');var _1S=document.createElement('TBODY');_1S.appendChild(this.CreateRuleTBLHeader());if(this._kn){this.RetrieveFLTRules(_1S);}else{_1S.appendChild(this.DrawEmptyFilterLine());}this._pR.appendChild(_1S);_agx.appendChild(this._pR);_NM.appendChild(_agx);_NH.appendChild(_NM);_F0.appendChild(_NH);if(!this._th){_NH=document.createElement('TR');_NM=this._l4.cloneNode(false);var _apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_FLT_DLG_RULE_REL_OPTIONS'));_NM.appendChild(_apS);_NH.appendChild(_NM);_NM=this._K.cloneNode(false);_NM.colSpan=3;var _anl=Utilities.GenerateCallback(CUIUserDefFilterDlg.SafeDoAddNewRule,[_Ke]);this._u5=COTInputElementFactory.CreateLink(_anl,this.oRes.GetString('IDS_FLT_RULE_ADD'),true);_NM.appendChild(this._u5);_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString(' '));_NM.appendChild(_apS);var _6X=Utilities.GenerateCallback(CUIUserDefFilterDlg.SafeDoDelRule,[_Ke]);this._aT=COTInputElementFactory.CreateLink(_6X,this.oRes.GetString('IDS_FLT_RULE_DEL'),true);_NM.appendChild(this._aT);_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString(' '));_NM.appendChild(_apS);var _ajJ=Utilities.GenerateCallback(CUIUserDefFilterDlg.SafeDoDelRule,[_Ke,true]);this._wQ=COTInputElementFactory.CreateLink(_ajJ,this.oRes.GetString('IDS_FLT_DLG_DEL_ALL_RULES'),true);_NM.appendChild(this._wQ);_NH.appendChild(_NM);_F0.appendChild(_NH);_NH=document.createElement('TR');_F0.appendChild(_NH);_NM=document.createElement('TD');_NH.appendChild(_NM);_NM.colSpan=4;var _8N=document.createElement('TABLE');_NM.appendChild(_8N);var _aub=document.createElement('TBODY');_8N.appendChild(_aub);_NH=document.createElement('TR');_aub.appendChild(_NH);_NM=this._g5.cloneNode(false);COTStyle.SetWidth(_NM,30,'px');var _aeo=true;if(this._kn){var _adm=this._kn.GetExprNode().GetOperator();_aeo=(_adm&&_adm==CUIUserDefFilterDlg.kOr)?false:true;}this._kF=COTInputElementFactory.CreateRadioButton('ruleRel',CUIUserDefFilterDlg.kAnd,_aeo);_NM.appendChild(this._kF);_NH.appendChild(_NM);_NM=this._g5.cloneNode(false);COTStyle.SetWidth(_NM,200,'px');_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_FLT_DLG_AND_RULE_REL'));_NM.appendChild(_apS);_NH.appendChild(_NM);_NM=this._g5.cloneNode(false);COTStyle.SetWidth(_NM,30,'px');this._aS=COTInputElementFactory.CreateRadioButton('ruleRel',CUIUserDefFilterDlg.kOr,!_aeo);_NM.appendChild(this._aS);_NH.appendChild(_NM);_NM=this._g5.cloneNode(false);COTStyle.SetWidth(_NM,500,'px');_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_FLT_DLG_OR_RULE_REL'));_NM.appendChild(_apS);_NH.appendChild(_NM);}_zr.appendChild(_F0);this._lq=_zr;Dom.SetObjRef(this._lq,this,'_oDlgObj');};CUIUserDefFilterDlg.prototype.CreateRuleTBLHeader=function(){var _NH=document.createElement('TR');var _NM=this._uc.cloneNode(false);COTStyle.SetWidth(_NM,1,'%');_NH.appendChild(_NM);_NM=this._uc.cloneNode(false);_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_FLT_DLG_FLT_OBJ_TYPE'));_NM.appendChild(_apS);_NH.appendChild(_NM);_NM=this._uc.cloneNode(false);_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_FLT_DLG_RULE_ITEM'));_NM.appendChild(_apS);_NH.appendChild(_NM);_NM=this._uc.cloneNode(false);_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_RULE_CONDITION'));_NM.appendChild(_apS);_NH.appendChild(_NM);_NM=this._uc.cloneNode(false);_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_RULE_VALUE'));_NM.appendChild(_apS);_NH.appendChild(_NM);_NM=this._xD.cloneNode(false);var _Q1=this.oDialogMgr.oUIMgr._jf.GetUIAxesContainer().GetUIAxis(this._tC.oAxis._l7);var _ar1=this.oRes.GetString('IDS_FLT_DLG_RULE_SCOPE_'+_Q1.GetResourceSuffix());var _apS=COTInputElementFactory.CreateLabel(_ar1);_NM.appendChild(_apS);_NH.appendChild(_NM);return _NH;};CUIUserDefFilterDlg.prototype.SetMeasureOpts=function(_MX,_MN){var _axv=false;if(this._tC.oAxis._rk.GetCurrentMeasureId()){_axv=true;}var _AT=this.oDialogMgr.oUIMgr.dataManager;_MX.PopulateMeaureOptionsWithFilter(_AT.metadata,_AT.GetCurrentDataMatrix(),_axv,false,true);_MX.SetupComboBoxForDragDrop(this.oDialogMgr.oUIMgr);var _aDl=null;if(_MN&&_MN._sy[0]._jU){_aDl=_MN._sy[0]._jU;}if(_aDl){_LX=_MX.oListCtrl.GetItemByValue(_aDl);if(!_LX){var _Yu=_AT._kX.GetCalculation(_MN._sy[0]._jU);if(_Yu){var _BM=_Yu.GetLabel();_LX=_MX.oListCtrl.AddItem('',_BM,0,_aDl,_BM);}else{_LX=_MX.AddMeasureToComboBox(_AT.metadata,_aDl);}}_MX.SetValueFromListItem(_LX,true);}else{_LX=_MX.oListCtrl.GetItemByIndex(0);_MX.SetValueFromListItem(_LX,true);}};CUIUserDefFilterDlg.prototype.SetScopeOpts=function(_MX,_MN){_MX.oListCtrl.ClearAllItems();_MX.ClearValue();var _yv=true;var _6p=this._tC.GetOppositeAxis().GetNonMeasureNodeTuples(_yv,CDLAxisMember.CanBeUsedInFilter);var _Ic=this.oRes.GetString('IDS_FLT_DLG_RULE_DEFAULT_SCOPE');var _UN=DefaultConstants.kDefScope;var _LX=_MX.oListCtrl.AddItem('',_Ic,0,_UN,_Ic);var _9U=false;var _2b=false;if(_MN&&_MN.GetScope()==CUIComboBox.kEmptyItem){var _Ic=this.oRes.GetString('IDS_FLT_DLG_RULE_EMPTY_SCOPE');var _UN=CUIComboBox.kEmptyItem;var _LX=_MX.oListCtrl.AddItem('',_Ic,0,_UN,_Ic);_MX.SetValueFromListItem(_LX);_2b=true;}else if((!_MN)||(_MN.GetScope()==DefaultConstants.kDefScope)){_MX.SetValueFromListItem(_LX,true);_9U=true;_2b=true;}for(var i=0;i<_6p.length;i++){_Ic=_6p[i].GetLabel();_UN=_6p[i].GetNodeHierarchy();_LX=_MX.oListCtrl.AddItem('',_Ic,0,_UN,_Ic);if(!_9U){if(_6p[i].IsEqualHierarchy(_MN.GetScope())){_MX.SetValueFromListItem(_LX);_2b=true;}}}if(!_2b){_UN=_MN.GetScope();_Ic=CDLBlock.GetTupleMembersLabel(null,null,this._tC.oAxis._rk,_UN);_LX=_MX.oListCtrl.AddItemToFront('',_Ic,0,_UN,_Ic);_LX.SetDefaultStyle("SpecialListCtrlItem");_MX.SetValueFromListItem(_LX,true);}};CUIUserDefFilterDlg.prototype.SetAttributeOpts=function(_MX,_MN){_MX.oListCtrl.ClearAllItems();_MX.ClearValue();var _aEO=this._tC.GetAllDistinctProps();Debug.Assert(_aEO.IsAllPropsRetrieved());var _JP=_aEO.GetExistProps();var _Tc=this.oDialogMgr.oUIMgr.dataManager.metadata;var _az4=0;var _LX;var _adN;for(var i in _JP){_adN=_JP[i];if(!this.CanUseAsFilter(_adN.GetDataType())){continue;}var _Bq=_adN.GetBreadCrumbText();_LX=_MX.oListCtrl.AddItem('',_Bq,0,i,_Bq);if(_az4==0){_MX.SetValueFromListItem(_LX,true);}_az4++;}if(_MN){var _WG=_MN._sy[0]._jU;_LX=_MX.oListCtrl.GetItemByValue(_WG);if(_LX){_MX.SetValueFromListItem(_LX,true);}else{var oProp=_Tc.GetPropertyById(_WG);var _Bq=oProp.GetBreadCrumbText();_LX=_MX.oListCtrl.AddItem('',_Bq,0,_WG,_Bq);_MX.SetValueFromListItem(_LX,true);}}};CUIUserDefFilterDlg.prototype.ClearRuleSelection=function(){for(var i in this._lK){this._lK[i].bSelected=false;this._lK[i].SetStyle();delete this._lK[i];}};CUIUserDefFilterDlg.SafeHandleClick=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}var _SJ=Dom.GetEventTarget(e);if(_SJ.tagName=='A'){return;}while(_SJ.tagName!='TABLE'){_SJ=_SJ.parentNode;}var _5r=_SJ._oDlgObj;if(_5r){_5r.ClearRuleSelection();}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIUserDefFilterDlg.prototype.SetPreSelection=function(_ME){var _5e=null;for(var i in this._i2){if(this._i2[i]._ow&&(this._i2[i]._ow._ve==_ME)){_5e=this._i2[i];break;}}if(_5e){_5e.HandleRuleSelection(false);}};CUIUserDefFilterDlg.prototype.DoCancel=function(_Ke){if(this._oC&&this._th){this.oDialogMgr.HideCurrentModalessDialog(true);this._oC.SetHostObj(this._tC);if(this._oC.copyWithoutNewLine){if(this._oC.copyWithoutNewLine!=CUICombineFilterDlg.kBrandNew){var _atf=this._oC.copyWithoutNewLine.bNeedWrap;this._oC.SetInitFilterExpr(this._oC.copyWithoutNewLine.Clone(_atf));}else{this._oC.SetInitFilterExpr(null);}}else{var _OX=(Utilities.GetObjArrayLength(this._i2)==1);this._oC.SetInitFilterExpr(this._yg.Clone(_OX));}if(this._yg){this._yg.ClearExpr();this._yg=null;}this._oC.Create();this._oC.Display();this._oC=null;}if(!this._th){CUIDialogMgr.SafeHideCurrentDialog(_Ke);if(this._w1){this._w1.ClearExpr();this._w1=null;}}};CUIUserDefFilterDlg.prototype.GenerateFilterExpression=function(){var _ayB=CUIUserDefFilterDlg.kAnd;var _6s=(Utilities.GetObjArrayLength(this._i2)>0);var _Tc=this.oDialogMgr.oUIMgr.dataManager.metadata;if(!this._th){_ayB=this._aS.checked?CUIUserDefFilterDlg.kOr:CUIUserDefFilterDlg.kAnd;}if(this._w1){var _SA=this._w1;Utilities.DeleteAllFromArray(_SA.GetExprNode()._sy);}else{var _SA=new CDLUserDefFilterExpr(this._tC.oAxis._rk._he,_ayB);}var _KR=_SA.GetExprNode();if(_6s&&(Utilities.GetObjArrayLength(this._i2)==1)){_KR._s4=null;}else{_KR._s4=_ayB;}var _aof=true;this._dd=false;for(var i in this._i2){var _5e=this._i2[i];var _J9=_5e._vM.GetValue();if(_J9!=CUIUserDefFilterDlg.kISNULL&&_J9!=CUIUserDefFilterDlg.kISNOTNULL){var _awD=_5e.GetNumberValue();if(_awD==''||_awD==null||(_5e._aI&&isNaN(_awD)&&!_5e._aI.oListCtrl.GetItemByValue(_awD))){if(this._th){_5e._xu.focus();this._dd=true;return;}else{continue;}}}if(_aof){_aof=false;}var _asl=null;var _ar2=null;var _aa6=_5e._vk._jU;if(_5e._vk._jU==ExpAPIXml.kEleMeasure){if(_5e._sg.GetValue()!=CUIComboBox.kEmptyItem){_asl=_5e._sg.GetValue();_ar2=_5e._sg.GetLabel();var _ay4=_5e._hx.GetValue();_aa6=(_Tc.GetMeasure(_ay4)||ExpAPIXml.kEleDefault==_ay4)?ExpAPIXml.kEleMeasure:ExpAxisObjType.Calc;}}var _Vj=this.oRes.GetString('IDS_FLT_BY_NAME');if(_5e._ow){var _8I=_5e._ow;_8I._s4=_5e._vM.GetValue();Utilities.DeleteAllFromArray(_8I._sy);}else{var _8I=new CDLMathMLExprNode(_5e._vM.GetValue(),true,true);}var _Zk=2;if(_5e._hx){_8I.AddOperands(_5e._hx.GetValue(),_5e._hx.GetLabel(),CDLMathMLOperands.CIOperand,0,_aa6);}else{_8I.AddOperands(ExpAPIXml.kEleFilterCaption,_Vj,CDLMathMLOperands.CIOperand,0,_aa6);}if(_5e.GetNumberValue()){var _UN=_5e.GetNumberValue();var nodeType=CDLMathMLOperands.CNOperand;var _aDa='';if(_Tc.SubsVarsExist()&&_Tc.GetSubsVar(_5e.GetNumberValue())){_aDa=ExpAPIXml.kEleSubsVar;nodeType=CDLMathMLOperands.CIOperand;}else{_aDa=_5e._xu._mi;}if(_aDa==ExpAPIXml.kDataTypeFloat){_UN=Decimal.GetExpressionNum(_UN);}_8I.AddOperands(_UN,_5e.GetNumberLabel(),nodeType,1,_aDa);}else{_Zk=1;}if(_asl){_8I._lb=false;_8I.AddOperands(_asl,_ar2,CDLMathMLOperands.TupleOperand,_Zk);}_KR.AddOperands(_8I,null,CDLMathMLOperands.Apply);}if((!_6s)||(_aof)){_SA=null;}return _SA;};CUIUserDefFilterDlg.prototype.DoSubmitFilterRule=function(_PP){var _SA=this.GenerateFilterExpression();if(this._dd){return;}var _OX=(Utilities.GetObjArrayLength(this._i2)==1);if(_PP){this.OpenCombineFilterDlg(_SA);return;}else if(this._iP){if(this._oC instanceof CUICombineFilterDlg){this.OpenCombineFilterDlg(_SA);return;}else{if(_SA!=null){_SA._lW=ExpAPIXml.kEleBasicFilterExpr;_SA._nt=_OX;}this._tC._vG=_SA;}}else{this.oDialogMgr.oUIMgr._jf.SetLastBlockSelectionId(this._tC.GetId());if(_SA!=null){_SA._lW=ExpAPIXml.kEleBasicFilterExpr;_SA._nt=_OX;}this._tC.SetProperty(ExpAPIXml.kEleUserDefFilter,_SA);if(this._w1){this._w1.ClearExpr();this._w1=null;}}CUIDialogMgr.SafeHideCurrentDialog(this.sAppName);};CUIUserDefFilterDlg.SafeDoAddNewRule=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager.oDialogMgr._jg.DoAddNewRule(_Ke);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIUserDefFilterDlg.prototype.DoAddNewRule=function(_Ke){var _49=Utilities.GetObjArrayLength(this._i2);var _F0=Dom.GetImmediateChildByName(this._pR,'TBODY');if(this._v8){Dom.RemoveObject(this._v8);this._v8=null;}var _5e=new CUIFilterExpr(this);var _avY=_5e.GetId();this._i2[_avY]=_5e;var _aAU=this._i2[_avY].Create();_F0.appendChild(_aAU);if(!this._xT){this.ScrollBarDisplayChecking();}else{COTStyle.SetWidth(this._pR,this._qp);COTStyle.SetWidth(document.getElementById(this._tT),this._g6-2);}};CUIUserDefFilterDlg.prototype.TransferToUIFLTRule=function(_MN,_Sg,_F0,_Ah){var _5e=new CUIFilterExpr(this);var _avY=_5e.GetId();this._i2[_avY]=_5e;var _aqW=this._i2[_avY].Create(_MN,_Sg);_5e._ow=_MN;_F0.appendChild(_aqW);return this._i2[_avY];};CUIUserDefFilterDlg.SafeDoDelRule=function(_Ke,_JA){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager.oDialogMgr._jg.DoDelRule(_JA);/*@if(!@bering_debug)@*/}catch(excep){_f.HandleException(excep);}/*@end@*/};CUIUserDefFilterDlg.prototype.DoDelRule=function(_JA){var _ahs=_JA?this._i2:this._lK;for(var i in _ahs){var _Hz=_ahs[i];_Hz._uw.oUIRuleObj=null;_Hz._vk.oUIRuleObj=null;Dom.RemoveObject(_Hz._uw);Utilities.RemoveAllChildObjects(_Hz);delete this._lK[i];delete this._i2[i];}if((Utilities.GetObjArrayLength(this._i2)==0)&&(!this._v8)){var _F0=Dom.GetImmediateChildByName(this._pR,'TBODY');_F0.appendChild(this.DrawEmptyFilterLine());}if(_JA){this._xT=false;}else{if(this._xT){this.ScrollBarDisplayChecking();}}};CUIUserDefFilterDlg.prototype.DrawEmptyFilterLine=function(){this._v8=document.createElement('TR');var _NM=document.createElement('TD');this._v8.appendChild(_NM);_NM=this._g5.cloneNode(false);_NM.colSpan=5;var _apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_FLT_DLG_NON_FLT'));_NM.appendChild(_apS);var _anl=Utilities.GenerateCallback(CUIUserDefFilterDlg.SafeDoAddNewRule,[this.sAppName]);var _O3=COTInputElementFactory.CreateLink(_anl,this.oRes.GetString('IDS_FLT_RULE_ADD'),true);_NM.appendChild(_O3);this._v8.appendChild(_NM);return this._v8;};CUIUserDefFilterDlg.prototype.ClearCachedSettings=function(){if(this._kn){this._kn.ClearExpr();this._kn=null;}if(this._w1){this._w1.ClearExpr();this._w1=null;}if(this._oC){if(this._yg){this._yg.ClearExpr();this._yg=null;}this._oC=null;}if(this._kh){this._kh.ClearExpr();this._kh=null;}this._fs=true;};CUIUserDefFilterDlg.prototype.HasBeenChanged=function(){if(this._jM||this._fs){return false;}var _aAY=this.GenerateFilterExpression();if(this._th){_aAY=this._yg;}var _aDJ=this._kh;if(this._th){_aDJ=this._tC.GetUserDefFLT();}if((_aAY==null)&&(_aDJ==null)){return false;}else if((_aAY!=null)&&(_aDJ!=null)){var _U5=!CDLBlockTransaction.IsUserDefFLTExprEqual(_aAY,_aDJ);return _U5;}else{return true;}};CUIUserDefFilterDlg.SafeDoClearUncommittedChanges=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager.oDialogMgr._jg.ClearUncommittedChanges();/*@if(!@bering_debug)@*/}catch(excep){_f.HandleException(excep);}/*@end@*/};CUIUserDefFilterDlg.prototype.ClearUncommittedChanges=function(){this.ClearCachedSettings();this.ClearDlg();this.oDialogMgr.HideCurrentDialog();};CUIUserDefFilterDlg.prototype.ConfirmLossOfChanges=function(){if(this.HasBeenChanged()){var _Ke=this.sAppName;var _anu=Utilities.GenerateCallback(CUIDialogMgr.SafeHideCurrentDialog,[_Ke]);var _aAS=Utilities.GenerateCallback(CUIUserDefFilterDlg.SafeDoClearUncommittedChanges,[_Ke]);var _aAo=Utilities.GenerateCallbackUnion([Utilities.SafeDoRemoveHoldingProcedure,_anu]);CUIDialogMgr._q5.SetCallBackFuntion(_aAS,_aAo);CUIDialogMgr._q5.Display('IDS_FLT_DLG_ONLY_COMMIT_CHANGES','',CUIConfirmDlg._hw);return Utilities.eStateHold;}else{return Utilities.eStateContinue;}};CUIUserDefFilterDlg.prototype.CanUseAsFilter=function(_V4){switch(_V4){case ExpAPIXml.kEleInt16Property:case ExpAPIXml.kEleInt32Property:case ExpAPIXml.kEleInt64Property:case ExpAPIXml.kEleDecimalProperty:case ExpAPIXml.kEleNumericProperty:case ExpAPIXml.kEleFloatProperty:case ExpAPIXml.kEleFloat16Property:case ExpAPIXml.kEleFloat32Property:case ExpAPIXml.kEleFloat64Property:case ExpAPIXml.kEleCharacterProperty:case ExpAPIXml.kEleCharacter16Property:case ExpAPIXml.kEleCharacter32Property:case ExpAPIXml.kEleCharProperty:case ExpAPIXml.kEleVarCharProperty:case ExpAPIXml.kEleMunliteralProperty:return true;case ExpAPIXml.kEleDateProperty:case ExpAPIXml.kEleDate2Property:case ExpAPIXml.kEleTimeProperty:case ExpAPIXml.kEleTime2Property:case ExpAPIXml.kEleDatetimeProperty:case ExpAPIXml.kEleDatetime2Property:case ExpAPIXml.kEleIntervalProperty:case ExpAPIXml.kEleInterval2Property:case ExpAPIXml.kEleIntervalYMProperty:return false;default:return false;}};CUIUserDefFilterDlg.prototype.Notify=function(_Dy){if(_Dy==ExpEvent.kCUIManager_Unload){this.Unload();}else if(_Dy==ExpEvent.kCUIWorksheet_ChangedBlockSel){this.ClearCachedSettings();if(this._r3){if(this._iP){if(!this.oDialogMgr.IsModalDialogDisplayed()){this.oDialogMgr.HideCurrentDialog(true);}return;}var _FK=this.oDialogMgr.oUIMgr._jf.GetSelectedBlock();if(_FK&&_FK.CanApplyUserDefFilter()){var _abP=_FK;if(this._iP&&(!this._th)){_abP=_FK.oAxis._rk.GetBlockProxy(_FK);}var _axc=_FK.GetUserDefFLT()?_FK.GetUserDefFLT().Clone():null;if(_axc&&_axc._lW&&_axc._lW==ExpAPIXml.kEleCombineFilterExpr){CUIDialogMgr.SafeHideCurrentDialog(this.sAppName);CUIWorkSheet.SafeOpenFilterDlg(this.sAppName);}else{this.SetHostObj(_abP);this.SetInitFilterExpr(_axc);this.Create();this.Display();}}else{if(this._eB){this._eB=null;}this.ClearDlg();var _M3=true;this.Display(_M3);}}}};CUIFilterExpr.kChangedRel=1;CUIFilterExpr.kChangedFltObjectType=2;CUIFilterExpr.kShowRel=3;CUIFilterExpr.kShowFltObjectType=4;CUIFilterExpr.kIntNumericProp=1;CUIFilterExpr.kFloatNumericProp=2;CUIFilterExpr.kAlphanumericProp=3;CUIFilterExpr.kDateProp=4;CUIFilterExpr.kTimeProp=5;CUIFilterExpr.kDatetimeProp=6;CUIFilterExpr.kIntervalProp=7;function CUIFilterExpr(_VN,id){this._pP=_VN;this._ve=Utilities.GenerateId();this._vk=null;this._hx=null;this._vM=null;this._xu=null;this._uN=null;this._ts=null;this._aU=new Object();this._uw=null;this._fi='prop_dropdown_arrow';this._wt='ComboBoxArrow.gif';this.bSelected=false;this._mR=this._pP.oDialogMgr.oUIMgr.dataManager.metadata;};CUIFilterExpr.prototype.GetId=function(){return this._ve;};CUIFilterExpr.prototype.Create=function(_MN,_Sg){var _NH=document.createElement('TR');_NH.className='pagerCtrlTBLItem';var _NM=document.createElement('TD');COTStyle.SetWidth(_NM,1,'%');this._xB=COTInputElementFactory.CreateImage('filter_row_selector.gif',16,16);this._xB.className+=' dlg_img_in_pageCtrlTBL link_image';var _Co=this._pP.oDialogMgr.oUIMgr.appobj.oResources;var _Rz=_Co.GetString('IDS_FLT_SELECT_LINE');this._xB.title=_Rz;this._xB.alt=_Rz;_NM.appendChild(this._xB);_NH.appendChild(_NM);this._vk=document.createElement('TD');this._vk._ve=Utilities.GenerateId();this._aU[this._vk._ve]=CUIFilterExpr.kShowFltObjectType;var _FT=ExpAPIXml.kEleMeasure;var _6R=this._pP._eZ[_FT];if(_MN){var _9z=_MN._sy[0]._ja;switch(_9z){case ExpAPIXml.kEleProperty:case ExpAPIXml.kEleItemName:case ExpAPIXml.kEleMeasure:_FT=_9z;break;}_6R=this._pP._eZ[_FT];}COTInputElementFactory.CreateDropdownEle(this._vk,'dlg_dropdown',this,_6R,_FT,null);Dom.SetObjRef(this._vk,this,'oUIRuleObj');_NH.appendChild(this._vk);this._r6=this._pP._g5.cloneNode(false);this._r6.align='center';this.AddFLTObjOpts(_MN);_NH.appendChild(this._r6);_NM=document.createElement('TD');COTStyle.SetWidth(_NM,150,'px');this._qe=new CUIListCtrl(this._pP.oDialogMgr.oUIMgr);this._qe.SetMaxHeight(150);this._qe.Init();this._qe.DisableHAutoScroll();this._vM=new CUIComboBox(this._pP.oDialogMgr.oUIMgr,this._qe);this._vM.DisableIcon();var _afs=_NM.appendChild(this._vM.Init());this._vM.Subscribe(this,ExpEvent.kCUIComboBox_OnSelChange);if(this._vk._jU==ExpAPIXml.kEleMeasure){this.SetNumericOperatorOpts(this._vM,_MN);}else if(this._vk._jU==ExpAPIXml.kEleProperty){if(!this._pP._nR){this._pP._nR=true;}this.SetPropFltOperatorOpts(this._hx.GetValue(),_MN);}else{this.SetAlphanumericOperatorOpts(this._vM,_MN);}_NH.appendChild(_NM);_NM=document.createElement('TD');_NH.appendChild(_NM);_NM.id=Utilities.GenerateId();this._kV=_NM.id;var _N8="";if(_MN&&_MN._s4!=CUIUserDefFilterDlg.kISNULL&&_MN._s4!=CUIUserDefFilterDlg.kISNOTNULL){_N8=_MN._sy[1]._jU;}if(this._vk._jU==ExpAPIXml.kEleProperty){this.CreatePropertyValueInputEle(this._hx.GetValue(),_NM,_N8);}else if(this._vk._jU==ExpAPIXml.kEleMeasure){this.CreateMeasureValueInputEle(_N8,_NM);}else if(this._vk._jU==ExpAPIXml.kEleItemName){this._xu=COTInputElementFactory.CreateTextBox(80,'px',_N8,false);_NM.appendChild(this._xu);}this._fm=document.createElement('TD');var _Ke=this._pP.sAppName;COTStyle.SetWidth(this._fm,200,'px');if(this._vk._jU==ExpAPIXml.kEleMeasure){this.AddScope(_MN);}else if(this._vk._jU==ExpAPIXml.kEleProperty){var _apS=COTInputElementFactory.CreateLabel(this._pP.oRes.GetString('IDS_FLT_DLG_RULE_SCOPE_NA'));this._fm.appendChild(_apS);}_NH.appendChild(this._fm);this._uw=_NH;this._uw.onclick=CUIFilterExpr.SafeHandleRuleSelection;Dom.SetObjRef(this._uw,this,'oUIRuleObj');return _NH;};CUIFilterExpr.prototype.PopulateSubsVars=function(_SS,_MX){_MX.oListCtrl.ClearAllItems();var _LX;_LX=_MX.oListCtrl.AddItem('',this._pP.oRes.GetString('IDS_USER_DEF_CALCU_NUMBER_SEL'),0,0,this._pP.oRes.GetString('IDS_USER_DEF_CALCU_NUMBER_SEL'));for(var i in _SS){_LX=_MX.oListCtrl.AddItem('',_SS[i]._xU,0,_SS[i]._bb,_SS[i]._xU);}};CUIFilterExpr.prototype.SetAlphanumericOperatorOpts=function(_MX,_MN){_MX.oListCtrl.ClearAllItems();_MX.ClearValue();var _az4=0;var _LX;for(var i in CUIUserDefFilterDlg.FLTAlphanumericOprKeyMap){var _4F=false;switch(i){case ExpAPIXml.kBeginWith:case ExpAPIXml.kNotBeginWith:_4F=this._mR.IsFunctionSupported(ExpAPIXml.kQosStartsWithSrch);break;case ExpAPIXml.kEndWith:case ExpAPIXml.kNotEndWith:_4F=this._mR.IsFunctionSupported(ExpAPIXml.kQosEndsWithSrch);break;case ExpAPIXml.kContain:case ExpAPIXml.kNotContain:_4F=this._mR.IsFunctionSupported(ExpAPIXml.kQosContainsSrch);break;case ExpAPIXml.kMatch:case ExpAPIXml.kNotMatch:_4F=true;break;default:break;}if(_4F){_LX=_MX.oListCtrl.AddItem('',CUIUserDefFilterDlg.FLTAlphanumericOprKeyMap[i],0,i,CUIUserDefFilterDlg.FLTAlphanumericOprKeyMap[i]);if(_MN&&_MN._s4){if(_MN._s4==i){_MX.SetValueFromListItem(_LX,true);}}else{if(_az4==0){_MX.SetValueFromListItem(_LX,true);}}_az4++;}}};CUIFilterExpr.prototype.SetNumericOperatorOpts=function(_MX,_MN){_MX.oListCtrl.ClearAllItems();_MX.ClearValue();var _az4=0;var _LX;for(var i in CUIUserDefFilterDlg.FLTOprKeyMap){var _BM;if(i==CUIUserDefFilterDlg.kGTORE||i==CUIUserDefFilterDlg.kLTORE||i==CUIUserDefFilterDlg.kNE){_BM=this._pP.oRes.ReplaceParam(CUIUserDefFilterDlg.FLTOprKeyMap[i],1,CDLFilterExpr.operatorResStrMap[i]);}else{_BM=CUIUserDefFilterDlg.FLTOprKeyMap[i];}var _akD=CUIUserDefFilterDlg.FLTOprTTMap[i];_LX=_MX.oListCtrl.AddItem('',_BM,0,i,_akD);if(_MN&&_MN._s4){if(_MN._s4==i){_MX.SetValueFromListItem(_LX,true);}}else{if(_az4==0){_MX.SetValueFromListItem(_LX,true);}}_az4++;}};CUIFilterExpr.prototype.ChangeFLTObjType=function(){this._vk.firstChild.src=Utilities.IMG_PATH+this._pP._eZ[this._vk._jU];var _af1=document.getElementById(this._kV);Debug.Assert(_af1);if(this._aI){this._kv.Unload();this._aI.Unload();this._kv=null;this._aI=null;}Dom.RemoveObject(this._xu);if(this._vk._jU==ExpAPIXml.kEleProperty){this.AddFLTObjOpts();this.SetPropFltOperatorOpts(this._hx.GetValue());this.CreatePropertyValueInputEle(this._hx.GetValue(),_af1);this.RemoveScope();}else if(this._vk._jU==ExpAPIXml.kEleMeasure){this.AddFLTObjOpts();this.SetNumericOperatorOpts(this._vM);this._xu=null;this.CreateMeasureValueInputEle('',_af1);this.AddScope();}else if(this._vk._jU==ExpAPIXml.kEleItemName){this.RemoveFLTObjOpts(this._hx);this.SetAlphanumericOperatorOpts(this._vM);Dom.RemoveAllChildren(_af1);this._xu=COTInputElementFactory.CreateTextBox(78,'px','',false);_af1.appendChild(this._xu);this.RemoveScope();}};CUIFilterExpr.SafeDoUpdateRule=function(_Ke,_Ja,_zx){var _3M=FindApp(_Ke).uiManager.oDialogMgr._jg._iw;if(_3M){var _U5=(_3M._jU!=_Ja);if(_U5){var _5e=_3M.oUIRuleObj;_3M._jU=_Ja;if(_zx==CUIFilterExpr.kShowFltObjectType){_5e.ChangeFLTObjType();}}}};CUIFilterExpr.prototype.FetchPropertiesOnFly=function(){this._mR.FetchProperties(this._pP._ev.GetIncompletePropOwner());this._mR.Subscribe(this._pP._ev,ExpEvent.kCDLMetadata_Merge_Properties);this._pP._ev.Subscribe(this,ExpEvent.kCOTPropsLoadingMgr_Merge_Complete);};CUIFilterExpr.prototype.UpdateAttributeLoadingMenu=function(){this._pP._m6=false;var _Kk=this._kt;if(_Kk&&_Kk.IsVisible()){var _Yy=this._kt._nd;if(_Yy>-1){var _aqU=this._kt.items[_Yy];var _F3=this._pP._eS[ExpAPIXml.kEleProperty];var _JP=this._pP._ev.GetExistProps();this._pP._nR=false;for(var _WG in _JP){_adN=_JP[_WG];if(this._pP.CanUseAsFilter(_adN.GetDataType())){this._pP._nR=true;_aqU.SetEnabled(true);break;}}if(!this._pP._nR){_F3=this._pP.oRes.GetString("IDS_FLT_BY_ATTR_NONE");}_aqU._ny=_F3;_Kk.display(_Kk.oLastEvent,true,null,_Kk.iLastYPos);}}this._kt=null;};CUIFilterExpr.prototype.ShowDropdown=function(e,x,y,_Pn){var _Kk=new CUIContextMenu(this._pP.sAppName,0,this);var _Jj=CUIFilterExpr.SafeDoUpdateRule;this._pP._iw=this._vk;if(this._pP._nR==null){this._pP._ev=this._pP._tC.GetAllDistinctProps();if(!this._pP._ev.IsAllPropsRetrieved()){this._pP._m6=true;}else{this._pP._m6=false;_JP=this._pP._ev.GetExistProps();for(var _WG in _JP){_adN=_JP[_WG];if(this._pP.CanUseAsFilter(_adN.GetDataType())){this._pP._nR=true;break;}}}}for(var i in this._pP._eS){var _AG=new Array(this._pP.sAppName,i,CUIFilterExpr.kShowFltObjectType);var _abm=this._pP._eS[i];if((i==ExpAPIXml.kEleProperty)){if(this._pP._m6){_abm=this._pP.oRes.GetString("IDS_FLT_BY_ATTR_LOADING");}else if(!this._pP._nR){_abm=this._pP.oRes.GetString("IDS_FLT_BY_ATTR_NONE");}}var _PM=new ContextItem(this._pP._eZ[i],_abm,_Jj,false,_AG,_Kk);if((i==ExpAPIXml.kEleProperty)&&this._pP._m6){this._kt=_Kk;_Kk.oLastEvent=Dom.CloneMouseEvent(e);_Kk.iLastYPos=y;_Kk._nd=2;this.FetchPropertiesOnFly();}if((i==ExpAPIXml.kEleProperty)&&!this._pP._nR){_PM.SetEnabled(false);}_PM.SetSkipUncomitChangesChecking();}_Kk.SetChildrenComplete();_Kk.display(e,true,null,y);};CUIFilterExpr.prototype.AddScope=function(_MN){if(!this._lz){Dom.RemoveAllChildren(this._fm);this._lz=new CUIListCtrl(this._pP.oDialogMgr.oUIMgr);this._lz.SetMaxHeight(150);this._lz.Init();this._lz.DisableHAutoScroll();this._sg=new CUIComboBox(this._pP.oDialogMgr.oUIMgr,this._lz);this._sg.DisableIcon();var _afs=this._fm.appendChild(this._sg.Init());this._sg.SetWidthByPX(200);this._pP.SetScopeOpts(this._sg,_MN);}};CUIFilterExpr.prototype.RemoveScope=function(){if(this._lz){this._lz.Unload();this._sg.Unload();this._lz=null;this._sg=null;Dom.RemoveAllChildren(this._fm);var _apS=COTInputElementFactory.CreateLabel(this._pP.oRes.GetString('IDS_FLT_DLG_RULE_SCOPE_NA'));this._fm.appendChild(_apS);COTStyle.SetWidth(this._fm,200);}};CUIFilterExpr.prototype.AddFLTObjOpts=function(_MN){if(this._gS){this._r8.Unload();this._hx.Unload();this._r8=null;this._hx=null;}Dom.RemoveAllChildren(this._r6);if(this._aI){this._kv.Unload();this._aI.Unload();this._kv=null;this._aI=null;}if(this._vk._jU==ExpAPIXml.kEleItemName){var _apS=COTInputElementFactory.CreateLabel(this._pP.oRes.GetString('IDS_FLT_BY_NAME'));this._r6.appendChild(_apS);}else{this._r8=new CUIListCtrl(this._pP.oDialogMgr.oUIMgr);this._r8.SetMaxHeight(150);this._r8.Init();this._r8.DisableHAutoScroll();this._hx=new CUIComboBox(this._pP.oDialogMgr.oUIMgr,this._r8);this._hx.DisableIcon();var _afs=this._r6.appendChild(this._hx.Init());this._ip=null;if(this._vk._jU==ExpAPIXml.kEleProperty){this._pP._ev=this._pP._tC.GetAllDistinctProps();if(!this._pP._ev.IsAllPropsRetrieved()){this.FetchPropertiesOnFly();this._kn=_MN;}this._pP.SetAttributeOpts(this._hx,_MN);this._hx.Subscribe(this,ExpEvent.kCUIComboBox_OnSelChange);this._ip=this._hx.GetId();this._hx.KeepPrevValue();}else if(this._vk._jU==ExpAPIXml.kEleMeasure){this._pP.SetMeasureOpts(this._hx,_MN);}}};CUIFilterExpr.prototype.RemoveFLTObjOpts=function(){if(this._hx){this._r8.Unload();this._hx.Unload();this._r8=null;this._hx=null;Dom.RemoveAllChildren(this._r6);var _apS=COTInputElementFactory.CreateLabel(this._pP.oRes.GetString('IDS_FLT_BY_NAME'));this._r6.appendChild(_apS);}};CUIFilterExpr.prototype.DetermineDataTypeControl=function(_V4){var _ajI;switch(_V4){case ExpAPIXml.kEleInt16Property:case ExpAPIXml.kEleInt32Property:case ExpAPIXml.kEleInt64Property:_ajI=CUIFilterExpr.kIntNumericProp;break;case ExpAPIXml.kEleDecimalProperty:case ExpAPIXml.kEleNumericProperty:case ExpAPIXml.kEleFloatProperty:case ExpAPIXml.kEleFloat16Property:case ExpAPIXml.kEleFloat32Property:case ExpAPIXml.kEleFloat64Property:_ajI=CUIFilterExpr.kFloatNumericProp;break;case ExpAPIXml.kEleCharacterProperty:case ExpAPIXml.kEleCharacter16Property:case ExpAPIXml.kEleCharacter32Property:case ExpAPIXml.kEleCharProperty:case ExpAPIXml.kEleVarCharProperty:case ExpAPIXml.kEleMunliteralProperty:_ajI=CUIFilterExpr.kAlphanumericProp;break;case ExpAPIXml.kEleDateProperty:case ExpAPIXml.kEleDate2Property:_ajI=CUIFilterExpr.kDateProp;break;case ExpAPIXml.kEleTimeProperty:case ExpAPIXml.kEleTime2Property:_ajI=CUIFilterExpr.kTimeProp;break;case ExpAPIXml.kEleDatetimeProperty:case ExpAPIXml.kEleDatetime2Property:_ajI=CUIFilterExpr.kDatetimeProp;break;case ExpAPIXml.kEleIntervalProperty:case ExpAPIXml.kEleInterval2Property:case ExpAPIXml.kEleIntervalYMProperty:_ajI=CUIFilterExpr.kIntervalProp;break;default:_ajI=CUIFilterExpr.kAlphanumericProp;break;}return _ajI;};CUIFilterExpr.prototype.SetPropFltOperatorOpts=function(_D5,_MN){var oProp=this._mR.GetPropertyById(_D5);if(oProp){var _awC=this.DetermineDataTypeControl(oProp.GetDataType());Debug.Assert(_awC!=null);switch(_awC){case CUIFilterExpr.kAlphanumericProp:this.SetAlphanumericOperatorOpts(this._vM,_MN);break;case CUIFilterExpr.kIntNumericProp:case CUIFilterExpr.kFloatNumericProp:case CUIFilterExpr.kDateProp:case CUIFilterExpr.kTimeProp:case CUIFilterExpr.kDatetimeProp:case CUIFilterExpr.kIntervalProp:this.SetNumericOperatorOpts(this._vM,_MN);break;}}else{this.SetAlphanumericOperatorOpts(this._vM);}};CUIFilterExpr.prototype.HandlePropertyOperatorChange=function(_NM){Debug.Assert(this._hx);var _ajD=this._vM.GetValue();if((this._xu&&(_ajD==CUIUserDefFilterDlg.kISNULL||_ajD==CUIUserDefFilterDlg.kISNOTNULL))||((!this._xu)&&_ajD!=CUIUserDefFilterDlg.kISNULL&&_ajD!=CUIUserDefFilterDlg.kISNOTNULL)){this.CreatePropertyValueInputEle(this._hx.GetValue(),_NM);}};CUIFilterExpr.prototype.CreatePropertyValueInputEle=function(_D5,_NM,_N8){var oProp=this._mR.GetPropertyById(_D5);if(oProp){if(this._vM.GetValue()==CUIUserDefFilterDlg.kISNULL||this._vM.GetValue()==CUIUserDefFilterDlg.kISNOTNULL){if(this._xu){if(this._mR.SubsVarsExist()&&this._aI){this._kv.Unload();this._aI.Unload();this._kv=null;this._aI=null;}this._xu=null;}Dom.RemoveAllChildren(_NM);_NM.appendChild(COTInputElementFactory.CreateLabel(this._pP.oRes.GetString('IDS_FLT_DLG_RULE_VALUE_NA')));COTStyle.SetWidth(_NM,80,'px');return;}this._xu=null;Dom.RemoveAllChildren(_NM);var _awC=this.DetermineDataTypeControl(oProp.GetDataType());switch(_awC){case CUIFilterExpr.kAlphanumericProp:case CUIFilterExpr.kDateProp:case CUIFilterExpr.kTimeProp:case CUIFilterExpr.kDatetimeProp:case CUIFilterExpr.kIntervalProp:this._xu=COTInputElementFactory.CreateTextBox(80,'px',_N8,false);_NM.appendChild(this._xu);break;case CUIFilterExpr.kIntNumericProp:this._xu=COTInputElementFactory.CreateIntegerTextBox(this,8,_N8,false,false);COTInputElementFactory.SetNumericTextBoxWidth(this._xu,80,'px');_NM.appendChild(this._xu);break;case CUIFilterExpr.kFloatNumericProp:this._xu=COTInputElementFactory.CreateFloatTextBox(this,8,_N8,false,false);COTInputElementFactory.SetNumericTextBoxWidth(this._xu,80,'px');_NM.appendChild(this._xu);break;}}else{this._xu=COTInputElementFactory.CreateTextBox(80,'px',_N8,false);_NM.appendChild(this._xu);}};CUIFilterExpr.prototype.CreateMeasureValueInputEle=function(_N8,_NM){if(this._vM.GetValue()==CUIUserDefFilterDlg.kISNULL||this._vM.GetValue()==CUIUserDefFilterDlg.kISNOTNULL){if(this._xu){if(this._mR.SubsVarsExist()&&this._aI){this._kv.Unload();this._aI.Unload();this._kv=null;this._aI=null;}this._xu=null;}Dom.RemoveAllChildren(_NM);_NM.appendChild(COTInputElementFactory.CreateLabel(this._pP.oRes.GetString('IDS_FLT_DLG_RULE_VALUE_NA')));COTStyle.SetWidth(_NM,80,'px');return;}if(!this._xu){Dom.RemoveAllChildren(_NM);if(this._mR.SubsVarsExist()){this._kv=new CUIListCtrl(this._pP.oDialogMgr.oUIMgr);this._kv.SetMaxHeight(80);this._kv.Init();this._kv.DisableHAutoScroll();this._aI=new CUIComboBox(this._pP.oDialogMgr.oUIMgr,this._kv);this._aI.Subscribe(this,ExpEvent.kCUIComboBox_OnSelection);this._aI.SetArrowImageName("substitution_variables.gif");this._aI.SetArrowImageDisabledName("substitution_variables_disabled.gif");this._aI.AllowTextEdit();this._aI.DisableIcon();this._aI.SetArrowTDClassName("ComboBoxArrowWhite");this._xu=this._aI.Init();this._aI.SetWidthByPX(80);this._aI.EnableHoverOverArrowEffect("ComboBoxArrowWhite_hover");var _axz=_N8;if(_N8){var _YJ=this._mR.GetSubsVar(_N8);if(_YJ){_axz=_YJ._xU;}}this._aI.SetValue(_N8,_axz);this.PopulateSubsVars(this._mR._gY,this._aI);}else{this._xu=COTInputElementFactory.CreateFloatTextBox(this,8,_N8,false,false);COTInputElementFactory.SetNumericTextBoxWidth(this._xu,80,'px');}_NM.appendChild(this._xu);}};CUIFilterExpr.SafeHandleRuleSelection=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}if(this.oUIRuleObj){this.oUIRuleObj.HandleRuleSelection(e.ctrlKey,e.shiftKey);}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIFilterExpr.prototype.HandleRuleSelection=function(_K4,_yN){var _aqz=false;if(!(_K4||_yN)){for(var i in this._pP._lK){if(this.GetId()!=i){this._pP._lK[i].bSelected=false;this._pP._lK[i].SetStyle();delete this._pP._lK[i];}else{_aqz=true;}}}if(!_aqz){if(_yN){if(this._pP._n3){var _IH=COTInputElementFactory.TRShiftSelection(this._pP._pR,this._pP._n3._uw,this._uw);for(var j=0;j<_IH.length;j++){var _T3=_IH[j].oUIRuleObj;_T3.bSelected=true;_T3._pP._lK[_T3.GetId()]=_T3;_T3.SetStyle();}}}else{this.bSelected=true;this._pP._lK[this.GetId()]=this;this.SetStyle();this._pP._n3=this;}}};CUIFilterExpr.prototype.SetStyle=function(){if(this.bSelected){this._uw.className='pagerCtrlTBLItem_selected';}else{this._uw.className='pagerCtrlTBLItem';}};CUIFilterExpr.prototype.OnTextBoxSelect=function(){this.HandleRuleSelection();};CUIFilterExpr.prototype.GetNumberValue=function(){if(this._aI){return this._aI.GetValue();}else{if(this._xu){return this._xu.value;}return null;}};CUIFilterExpr.prototype.GetNumberLabel=function(){if(this._aI){return this._aI.GetLabel();}else{if(this._xu){return this._xu.value;}return null;}};CUIFilterExpr.prototype.SetCurrentTrigger=function(_Mu){this._oCurrTrigger=_Mu;};CUIFilterExpr.prototype.Notify=function(_Dy){if(_Dy==ExpEvent.kCUIComboBox_OnSelection){this.HandleSubsVarChange();}else if(_Dy==ExpEvent.kCOTPropsLoadingMgr_Merge_Complete){this.UpdateAttributeLoadingMenu();if(this._kn){this._pP.SetAttributeOpts(this._hx,this._kn);}this._mR.UnSubscribe(this._pP._ev,ExpEvent.kCDLMetadata_Merge_Properties);this._pP._ev.UnSubscribe(this,ExpEvent.kCOTPropsLoadingMgr_Merge_Complete);}else if(_Dy==ExpEvent.kCUIComboBox_OnSelChange){var _NM=document.getElementById(this._kV);if(this._vk._jU==ExpAPIXml.kEleProperty){if(this._oCurrTrigger.GetId()==this._ip){var _WG=this._oCurrTrigger.GetValue();var _8Q=this._mR.GetPropertyById(_WG);var _1z=this._mR.GetPropertyById(this._oCurrTrigger.GetPrevValue());if(_8Q.GetDataType()!=_1z.GetDataType()){this.SetPropFltOperatorOpts(_WG);this.CreatePropertyValueInputEle(_WG,_NM);}}else{this.HandlePropertyOperatorChange(_NM);}}else if(this._vk._jU==ExpAPIXml.kEleMeasure){this.CreateMeasureValueInputEle('',_NM);}else{}}};CUIFilterExpr.prototype.HandleSubsVarChange=function(){if(this._aI._kH.value==this._pP.oRes.GetString('IDS_USER_DEF_CALCU_NUMBER_SEL')&&!isNaN(Decimal.GetNumericDecimal(this._aI.GetPrevText()))){var _LX=this._aI.oListCtrl.GetItemByValue(this._aI.GetPrevText());if(_LX){this._aI.SetValueFromListItem(_LX,false);}else{this._aI.SetValue(0,this._aI.GetPrevText());}this._aI._kH.select();}else if(this._aI._kH.value==this._pP.oRes.GetString('IDS_USER_DEF_CALCU_NUMBER_SEL')){this._aI.SetValue('','');this._aI._kH.focus();}};CUIUserDefFilterDlg.SafeOpenCombineFilterDlg=function(_Ke){try{FindApp(_Ke).uiManager.oDialogMgr._jg.DoSubmitFilterRule(true);}catch(e){_f.HandleException(e);}};CUIUserDefFilterDlg.prototype.OpenCombineFilterDlg=function(_Gd){var _OX=(Utilities.GetObjArrayLength(this._i2)==1);CUIDialogMgr.SafeHideCurrentDialog(this.sAppName);if(this._oC){this.oCombineFLTDlg=this._oC;}else if(!this.oCombineFLTDlg){this.oCombineFLTDlg=new CUICombineFilterDlg(this._iP);this.oCombineFLTDlg.Init(this.oDialogMgr);this.oCombineFLTDlg.SubscribeWSEvent();}if(this._tC){this.oCombineFLTDlg.SetHostObj(this._tC);if(this._th){this.oCombineFLTDlg.SetInitFilterExpr(this._yg);}else{_Gd=_Gd?_Gd.Clone(_OX):null;this._w1=_Gd;this.oCombineFLTDlg._oC=this;_Gd=_Gd?_Gd.Clone(_OX):null;this.oCombineFLTDlg.SetInitFilterExpr(_Gd);}this.oCombineFLTDlg.Create();this.oCombineFLTDlg.Display();}this.ClearDlg();};function CUICombineFilterDlg(_H8){this.base=CUIDialog;this.base();this._tC=null;this._kn=null;this._xo=new Object();this._o4=new Object();this._t5=new Array();this._uc=document.createElement('TD');this._uc.className="pagerCtrlTBLHeader";this._xD=document.createElement('TD');this._xD.className="pagerCtrlTBLHeaderLastColumn";this._iP=_H8?true:false;this._ap=0;};CUICombineFilterDlg.prototype=new CUIDialog;CUICombineFilterDlg.superclass=CUIDialog.prototype;CUICombineFilterDlg.kBrandNew='brandnew';CUICombineFilterDlg.prototype.IsInSaveMode=function(){return this._iP;};CUICombineFilterDlg.prototype.GetOpener=function(){return this._oC;};CUICombineFilterDlg.prototype.GetRootOpener=function(){if(this.IsInSaveMode()){return this.oDialogMgr.oUIMgr.oBlockPropsPane;}else{return this.GetOpener();}};CUICombineFilterDlg.prototype.Display=function(_M3){this._fs=false;var _Co=this.oDialogMgr.oUIMgr.appobj.oResources;var _Ke=this.sAppName;var _MY=new Object();var _Xf=Utilities.GenerateCallback(CUIManager.SafeDoHelpTopic,[_Ke,HelpConstants.kCombineFiltersLink]);_MY['IDS_HELP']=_Xf;if(!_M3){CUIUserDefFilterDlg.superclass.Display.call(this,'IDS_COMBINE_FLT_DLG_TITLE',_MY,this._lq,'IDS_COMBINE_FLT_DLG_INSTRUCT');}else{var _Li=this.oDialogMgr.oUIMgr.dataManager.GetCurrentDataMatrix();var _W7=_Li.GetAllBlocksArray();var _Nk=new Array();for(var i=0;i<_W7.length;i++){if(_W7[i].CanApplyUserDefFilter()){_Nk.push(_W7[i]);}}var _aJh=true;this.DisplayInvalidSelection('IDS_COMBINE_FLT_DLG_TITLE',_MY,_Nk,_Li,'FILTER',_aJh);this._jM=true;return;}this.ScrollBarDisplayChecking();};CUICombineFilterDlg.prototype.ScrollBarDisplayChecking=function(){if(this._tT){var _aqK=document.getElementById(this._tT).offsetHeight;var _ZG=this._pR.offsetHeight;var _aDt=document.getElementById(this._tT).offsetWidth-18;if(_aqK<_ZG){COTStyle.SetWidth(this._pR,_aDt);}else{COTStyle.SetWidth(this._pR,100,'%');}}};CUICombineFilterDlg.prototype.ClearDlg=function(_EA){this._tT=null;var _JA=true;if((!_EA)&&this.copyWithoutNewLine){if(this.copyWithoutNewLine!=CUICombineFilterDlg.kBrandNew){this.copyWithoutNewLine.ClearExpr();}this.copyWithoutNewLine=null;}if(Utilities.GetObjArrayLength(this._xo)>0){this.DoDelRule(_JA,true);}this._ap=0;this._n3=null;this._v8=null;};CUICombineFilterDlg.prototype.Unload=function(){this.ClearDlg();CUICombineFilterDlg.superclass.Unload.call(this);};CUICombineFilterDlg.prototype.SetInitFilterExpr=function(_Gd){this._kn=_Gd;};CUICombineFilterDlg.prototype.RetrieveFLTRules=function(_F0){this._xo=Utilities.ClearObjectArray(this._xo);var _KR=this._kn.GetExprNode();var _1T=_KR.GetOperator();if(_KR._cS){this.TransferToUIFLTRule(_KR,null,_F0);}else{for(var i=0;i<_KR._sy.length;i++){var _ZB=_KR._sy[i];var _Sg=(i==0)?null:_1T;this.TransferToUIFLTRule(_ZB,_Sg,_F0);}}};CUICombineFilterDlg.prototype.SetHostObj=function(_Oa){this._tC=_Oa;};CUICombineFilterDlg.prototype.SubscribeWSEvent=function(){this.oDialogMgr.oUIMgr._jf.Subscribe(this,ExpEvent.kCUIWorksheet_ChangedBlockSel);};CUICombineFilterDlg.prototype.CheckVldExpNode=function(_Fn){if(_Fn._sy){if(_Fn._sy.length>0){var _UN=_Fn._sy[0]._jU;var _RT=_Fn._sy[0]._ja;if(_RT!="measure"&&_RT!="context"){return true;}if(_UN=="default"||this._kn._lR.metadata.GetMeasure(_UN)||this._kn._lR._kX.GetCalculation(_UN))return true;}}return false;};CUICombineFilterDlg.prototype.IsValidExprNode=function(){var _KR=this._kn.GetExprNode();if(_KR._cS){tmpValue=this.CheckVldExpNode(_KR);if(tmpValue==false){Utilities.DeleteAllFromArray(_KR._sy);}return tmpValue;}else{for(var i=0;i<_KR._sy.length;i++){var _aHi=_KR._sy[i];tmpValue=this.CheckVldExpNode(_aHi);if(tmpValue==false){Utilities.DeleteFromArray(_KR._sy,_aHi);}}return true;}};CUICombineFilterDlg.prototype.Create=function(){if(Utilities.GetObjArrayLength(CUIUserDefFilterDlg.FLTOprKeyMap)==0){CUIUserDefFilterDlg.SetRuleOperators(this.oRes);};this.ClearDlg();var _atD=COTStyle.GetWidth(this.oDialogMgr._p2)*0.98*0.85*0.96;this._qM=_atD-28;var _Ke=this.sAppName;var _zr=document.createElement('TABLE');_zr.className='dialogTable';_zr.onclick=CUIUserDefFilterDlg.SafeHandleClick;var _F0=document.createElement('TBODY');this._eB=this._tC.GetLabel();var _NH=document.createElement('TR');var _NM=document.createElement('TD');_NM.colSpan=4;var _agx=document.createElement('DIV');_agx.className='userDefFLTDlgRuleDiv';_agx.id=Utilities.GenerateId();this._tT=_agx.id;this._pR=document.createElement('TABLE');this._pR.className='pagerCtrlTBL';var _1S=document.createElement('TBODY');this._pR.appendChild(_1S);_1S.appendChild(this.CreateRuleTBLHeader());if(this._kn&&this.IsValidExprNode()){this.RetrieveFLTRules(_1S);}if(_1S.childNodes.length==1){_1S.appendChild(this.DrawEmptyFilterLine());}_agx.appendChild(this._pR);_NM.appendChild(_agx);_NH.appendChild(_NM);_F0.appendChild(_NH);_NH=document.createElement('TR');_NM=this._K.cloneNode(false);_NM.colSpan=4;var _aFs=Utilities.GenerateCallback(CUICombineFilterDlg.SafeDoGroup,[_Ke]);this._cs=COTInputElementFactory.CreateLink(_aFs,this.oRes.GetString('IDS_COMBINE_FLT_DLG_GROUP'),true);_NM.appendChild(this._cs);_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString(' '));_NM.appendChild(_apS);var _9d=Utilities.GenerateCallback(CUICombineFilterDlg.SafeDoUnGroup,[_Ke]);this._wW=COTInputElementFactory.CreateLink(_9d,this.oRes.GetString('IDS_COMBINE_FLT_DLG_UNGROUP'),true);_NM.appendChild(this._wW);_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString(' '));_NM.appendChild(_apS);var _6X=Utilities.GenerateCallback(CUICombineFilterDlg.SafeDoDelRule,[_Ke]);this._aT=COTInputElementFactory.CreateLink(_6X,this.oRes.GetString('IDS_FLT_RULE_DEL'),true);_NM.appendChild(this._aT);_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString(' '));_NM.appendChild(_apS);var _ajJ=Utilities.GenerateCallback(CUICombineFilterDlg.SafeDoDelRule,[_Ke,true]);this._wQ=COTInputElementFactory.CreateLink(_ajJ,this.oRes.GetString('IDS_FLT_DLG_DEL_ALL_RULES'),true);_NM.appendChild(this._wQ);_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString(' '));_NM.appendChild(_apS);var _anl=Utilities.GenerateCallback(CUICombineFilterDlg.SafeDoAddNewLine,[_Ke]);this._u5=COTInputElementFactory.CreateLink(_anl,this.oRes.GetString('IDS_FLT_RULE_ADD'),true);_NM.appendChild(this._u5);_NH.appendChild(_NM);_F0.appendChild(_NH);if(!this._iP){this._Y=Utilities.GenerateCallback(this.DoSubmitFilterExpr,[],this);}else{this._yi=Utilities.GenerateCallback(this.DoSubmitFilterExpr,[true],this);}this._of=Utilities.GenerateCallback(this.DoCancel,[_Ke],this);this._gl=Utilities.GenerateCallback(this.DoCancel,[_Ke],this);_zr.appendChild(_F0);this._lq=_zr;Dom.SetObjRef(this._lq,this,'_oDlgObj');};CUICombineFilterDlg.prototype.CreateRuleTBLHeader=function(){var _NH=document.createElement('TR');var _NM=this._uc.cloneNode(false);COTStyle.SetWidth(_NM,5,'%');_NH.appendChild(_NM);_NM=this._uc.cloneNode(false);COTStyle.SetWidth(_NM,10,'%');_NH.appendChild(_NM);_NM=this._uc.cloneNode(false);COTStyle.SetWidth(_NM,85,'%');_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_COMBINE_FLT_DLG_HEADER_FILTER'));_NM.appendChild(_apS);_NH.appendChild(_NM);return _NH;};CUICombineFilterDlg.prototype.DrawEmptyFilterLine=function(){this._v8=document.createElement('TR');var _NM=document.createElement('TD');this._v8.appendChild(_NM);_NM=this._g5.cloneNode(false);_NM.colSpan=3;var _apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_FLT_DLG_NON_FLT'));_NM.appendChild(_apS);var _Ke=this.sAppName;var _anl=Utilities.GenerateCallback(CUICombineFilterDlg.SafeDoAddNewLine,[_Ke]);var _O3=COTInputElementFactory.CreateLink(_anl,this.oRes.GetString('IDS_FLT_RULE_ADD'),true);_NM.appendChild(_O3);this._v8.appendChild(_NM);return this._v8;};CUICombineFilterDlg.prototype.ReCheckExprProperty=function(){if(Utilities.GetObjArrayLength(this._xo)==0){this._kn=null;}else if(Utilities.GetObjArrayLength(this._xo)<=1){this._kn.GetExprNode()._s4=null;this._kn._nt=true;}if(this._kn){this._kn._lW=ExpAPIXml.kEleCombineFilterExpr;}};CUICombineFilterDlg.prototype.DoSubmitFilterExpr=function(_H8){this.oDialogMgr.oUIMgr._jf.SetLastBlockSelectionId(this._tC.GetId());this.ReCheckExprProperty();if(!_H8){this._tC.SetProperty(ExpAPIXml.kEleUserDefFilter,this._kn);if(this._oC){if(this._oC._w1){this._oC._w1.ClearExpr();this._oC._w1=null;}if(this._oC._yg){this._oC._yg.ClearExpr();this._oC._yg=null;}this._oC.ClearDlg();this._oC=null;}if(this._kn){this._kn.ClearExpr();}}else{this._tC._vG=this._kn;}CUIDialogMgr.SafeHideCurrentDialog(this.sAppName);};CUICombineFilterDlg.prototype.TransferToUIFLTRule=function(_G8,_Sg,_F0){var _0G=new CUIFltRulesGroup(this);var _avY=_0G.GetId();_0G.InitExprNode(_G8);this._xo[_avY]=_0G;if(_0G._ni._cS){_0G.AddRuleToGroup(_G8);var _aAP=this._xo[_avY].Create(_Sg);_F0.appendChild(_aAP);}else{var _aAP=_0G.Create(_Sg,false,true);_F0.appendChild(_aAP);_0G.SetupGroupStructure(_0G,_G8);if(this._ap<_0G._cL){this._ap=_0G._cL;}CUICombineFilterDlg.kReservedBraketWidth=this._ap*2*CUIFltRulesGroup.kReservedBraketWidth;_0G.MergeRules(_0G._mC,_0G);}return this._xo[_avY];};CUICombineFilterDlg.SafeDoDelRule=function(_Ke,_JA){try{FindApp(_Ke).uiManager.oDialogMgr._jg.DoDelRule(_JA);}catch(excep){_f.HandleException(excep);}};CUICombineFilterDlg.prototype.DoDelRule=function(_JA,_zj){var _ahs=_JA?this._xo:this._o4;var _9A=_zj?true:false;for(var i in _ahs){this.DelCurrentRule(_ahs[i],false,_9A);}if((Utilities.GetObjArrayLength(this._xo)==0)&&(!this._v8)){if(!_9A){this._kn.ClearExpr();this._kn=null;}if(!this._v8){var _F0=Dom.GetImmediateChildByName(this._pR,'TBODY');_F0.appendChild(this.DrawEmptyFilterLine());}}this.ScrollBarDisplayChecking();};CUICombineFilterDlg.prototype.DelCurrentRule=function(_Hz,_JX,_zj,_N7){delete this._o4[_Hz.GetId()];delete this._xo[_Hz.GetId()];if(!_zj){this._kn.GetExprNode().RemoveExprNodeOperands(_Hz._ni);}if(!_JX){if(!_N7){var _ara=_Hz._ni;if(_ara._cS){Utilities.DeleteFromArray(this._t5,_ara);}else{var _ajH=new Array();_ara.GetAllLeafExprs(_ara,_ajH);for(var i=0;i<_ajH.length;i++){Utilities.DeleteFromArray(this._t5,_ajH[i]);}}}_Hz._uw.oUIRuleObj=null;Dom.RemoveObject(_Hz._uw);Utilities.RemoveAllChildObjects(_Hz);}else{_Hz._uw.className="pagerCtrlTBLItem_hidden";}};CUICombineFilterDlg.prototype.ClearCachedSettings=function(){if(this._kn){this._kn.ClearExpr();this._kn=null;}Utilities.DeleteAllFromArray(this._t5);if(this._oC){this._oC.ClearCachedSettings();this._oC=null;}this._fs=true;};CUICombineFilterDlg.prototype.HasBeenChanged=function(){if(this._jM||this._fs){return false;}this.ReCheckExprProperty();var _aDJ=this._tC.GetUserDefFLT();if((this._kn==null)&&(_aDJ==null)){return false;}else if((this._kn!=null)&&(_aDJ!=null)){var _U5=!CDLBlockTransaction.IsUserDefFLTExprEqual(this._kn,_aDJ);return _U5;}else{return true;}};CUICombineFilterDlg.SafeDoClearUncommittedChanges=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager.oDialogMgr._jg.ClearUncommittedChanges();/*@if(!@bering_debug)@*/}catch(excep){_f.HandleException(excep);}/*@end@*/};CUICombineFilterDlg.prototype.ClearUncommittedChanges=function(){this.ClearCachedSettings();this.ClearDlg();this.oDialogMgr.HideCurrentDialog();};CUICombineFilterDlg.prototype.ConfirmLossOfChanges=function(){if(this.HasBeenChanged()){var _Ke=this.sAppName;var _aAS=Utilities.GenerateCallback(CUICombineFilterDlg.SafeDoClearUncommittedChanges,[_Ke]);var _anu=Utilities.GenerateCallback(CUIDialogMgr.SafeHideCurrentDialog,[_Ke]);var _aAo=Utilities.GenerateCallbackUnion([Utilities.SafeDoRemoveHoldingProcedure,_anu]);CUIDialogMgr._q5.SetCallBackFuntion(_aAS,_aAo);CUIDialogMgr._q5.Display('IDS_FLT_DLG_ONLY_COMMIT_CHANGES','',CUIConfirmDlg._hw);return Utilities.eStateHold;}else{return Utilities.eStateContinue;}};CUICombineFilterDlg.prototype.Notify=function(_Dy){if(_Dy==ExpEvent.kCUIManager_Unload){this.Unload();}else if(_Dy==ExpEvent.kCUIWorksheet_ChangedBlockSel){this.ClearCachedSettings();if(this._r3){if(this._iP){this.oDialogMgr.HideCurrentDialog(true);return;}var _FK=this.oDialogMgr.oUIMgr._jf.GetSelectedBlock();if(_FK&&_FK.CanApplyUserDefFilter()){var _axc=_FK.GetUserDefFLT();if(_axc&&_axc._lW&&_axc._lW==ExpAPIXml.kEleCombineFilterExpr){this.SetHostObj(_FK);this.SetInitFilterExpr(_FK.GetUserDefFLT()?_FK.GetUserDefFLT().Clone():null);this.Create();this.Display();}else{CUIDialogMgr.SafeHideCurrentDialog(this.sAppName);CUIWorkSheet.SafeOpenFilterDlg(this.sAppName);}}else{if(this._eB){this._eB=null;}this.ClearDlg();var _M3=true;this.Display(_M3);}}}};CUICombineFilterDlg.prototype.ClearRuleSelection=function(){for(var i in this._o4){this._o4[i].bSelected=false;this._o4[i].SetStyle();delete this._o4[i];}this._n3=null;};CUICombineFilterDlg.SafeHandleClick=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}var _SJ=Dom.GetEventTarget(e);if(!_SJ||_SJ.tagName=='A'){return;}while(_SJ.tagName!='TABLE'){_SJ=_SJ.parentNode;}var _5r=_SJ._oDlgObj;if(_5r){_5r.ClearRuleSelection();}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICombineFilterDlg.prototype.DoGroup=function(){if(Utilities.GetObjArrayLength(this._o4)<2){return;}var _2x=false;var _Sg=null;var _5f=new CUIFltRulesGroup(this);var _avY=_5f.GetId();_5f._ui=new Array();var _azE=false;for(var i in this._o4){if(!this._o4[i]._mu.oUIGrpObj){_azE=true;}}for(var i in this._o4){var _aet=this._o4[i];if(!_2x){_5f._cL=_aet._cL+1;_2x=true;if(_aet._mu.oUIGrpObj){_Sg=_aet._mu._jU;}var _ac1=_aet._uw;var _AZ=_Sg?false:true;this._xo[_avY]=_5f;var _Qr=true;_5f.InitExprNode(null,_Sg);var _aiq=Utilities.GetObjIndex(this._kn.GetExprNode()._sy,_aet._ni);this._kn.GetExprNode().AddOperands(_5f._ni,null,CDLMathMLOperands.Apply,_aiq);var _aAP=this._xo[_avY].Create(_Sg,_AZ,_Qr);_ac1.parentNode.insertBefore(_aAP,_ac1);}if((!_Sg)&&_aet._mu.oUIGrpObj){_Sg=_aet._mu._jU;_5f._ni._s4=_Sg;}if(_aet._cL>=_5f._cL){_5f._cL=_aet._cL+1;}_5f.AddRuleToGroup(_aet);_5f._ni.AddOperands(_aet._ni,null,CDLMathMLOperands.Apply);_5f._ui.push(_aet);this.DelCurrentRule(_aet,true);}_5f._mC.className+=' vCellSpacing';if(this._ap<_5f._cL){this._ap=_5f._cL;}CUICombineFilterDlg.kReservedBraketWidth=this._ap*2*CUIFltRulesGroup.kReservedBraketWidth;CUIFltRulesGroup.IndentationLevel=-1;_5f.MergeRules(_5f._mC,_5f);if(_azE){var _apA=COTInputElementFactory.GetFirstNonHeaderTRWithCertainClassName(this._pR,"pagerCtrlTBLItem_hidden",false);if(_apA.oUIRuleObj._mu.oUIGrpObj){_apA.oUIRuleObj._mu.oUIGrpObj.RemoveGlobalRelObj();}}};CUICombineFilterDlg.SafeDoGroup=function(_Ke){try{FindApp(_Ke).uiManager.oDialogMgr._jg.DoGroup();}catch(excep){_f.HandleException(excep);}};CUICombineFilterDlg.prototype.DoUnGroup=function(){var _9Q=null;var _6N=null;for(var i in this._o4){if(this._o4[i]._ui){_9Q=this._o4[i];_6N=i;}}if(!_9Q){return;}if(_9Q._ui.length>0){var _ahV=null;var _aCm=(this._ap==_9Q._cL);var _aiq=Utilities.GetObjIndex(this._kn.GetExprNode()._sy,_9Q._ni);if(this._kn._nt){this._kn.GetExprNode()._s4=CUIUserDefFilterDlg.kAnd;this._kn._nt=false;}for(var i=_9Q._ui.length-1;i>=0;i--){_ahV=_9Q._ui[i];_ahV.bSelected=true;this._kn.GetExprNode().AddOperands(_ahV._ni,null,CDLMathMLOperands.Apply,_aiq);this._xo[_ahV.GetId()]=_ahV;this._o4[_ahV.GetId()]=_ahV;_ahV.RecheckGlobalCombo();_ahV._uw.className="pagerCtrlTBLItem_show";_ahV.SetStyle();}var _aE7=_9Q._mu.oUIGrpObj?false:true;var _JX=false;var _zj=false;var _N7=true;this.DelCurrentRule(_9Q,_JX,_zj,_N7);if(_aE7){var _apA=COTInputElementFactory.GetFirstNonHeaderTRWithCertainClassName(this._pR,"pagerCtrlTBLItem_hidden",false);if(_apA.oUIRuleObj._mu.oUIGrpObj){_apA.oUIRuleObj._mu.oUIGrpObj.RemoveGlobalRelObj();}}if(_aCm){var _aJi=true;for(var i in this._xo){if(this._ap==this._xo[i]._cL){_aJi=false;break;}}if(_aJi){this._ap-=1;}}}};CUICombineFilterDlg.SafeDoUnGroup=function(_Ke){try{FindApp(_Ke).uiManager.oDialogMgr._jg.DoUnGroup();}catch(excep){_f.HandleException(excep);}};CUICombineFilterDlg.prototype.DoEdit=function(_ME,_T1){var _SA=new CDLUserDefFilterExpr(this._tC.oAxis._rk._he,CUIUserDefFilterDlg.kAnd);for(var i=0;i<this._t5.length;i++){_SA.GetExprNode().AddOperands(this._t5[i],null,CDLMathMLOperands.Apply);}if(_T1){_SA.GetExprNode().AddOperands(_T1,null,CDLMathMLOperands.Apply);}if(!this.oUserDefFLTDlg){this.oUserDefFLTDlg=new CUIUserDefFilterDlg(true);this.oUserDefFLTDlg.Init(this.oDialogMgr);this.oUserDefFLTDlg.InitFLTRuleOptions();this.oUserDefFLTDlg.SubscribeWSEvent();}else{this.oUserDefFLTDlg._iP=true;}this.oUserDefFLTDlg._oC=this;this.oUserDefFLTDlg._th=true;this.oUserDefFLTDlg._yg=this._kn;this.oUserDefFLTDlg.SetHostObj(this._tC);this.ClearDlg(true);this.oDialogMgr.HideCurrentModalessDialog(true);this.oUserDefFLTDlg.SetInitFilterExpr(_SA);this.oUserDefFLTDlg.Create();this.oUserDefFLTDlg.Display();this.oUserDefFLTDlg.SetPreSelection(_ME);};CUICombineFilterDlg.SafeDoEdit=function(_Ke,_ME){try{FindApp(_Ke).uiManager.oDialogMgr._jg.DoEdit(_ME);}catch(excep){_f.HandleException(excep);}};CUICombineFilterDlg.prototype.DoAddEmptyGroup=function(){var _IP=new CDLMathMLExprNode(null,true,true);if(this._kn){var _am6=(this._t5.length==1);this.copyWithoutNewLine=this._kn.Clone(_am6);this.copyWithoutNewLine.bNeedWrap=_am6;}else{this.copyWithoutNewLine=CUICombineFilterDlg.kBrandNew;}if(!this._kn){this._kn=new CDLUserDefFilterExpr(this._tC.oAxis._rk._he,null);}else if(!this._kn.GetExprNode()._s4){this._kn.GetExprNode()._s4=CUIUserDefFilterDlg.kAnd;}this._kn.GetExprNode().AddOperands(_IP,null,CDLMathMLOperands.Apply);this._kn._ni._cS=false;_IP.AddOperands('','',CDLMathMLOperands.CIOperand);_IP.AddOperands('','',CDLMathMLOperands.CNOperand);_IP.AddOperands(DefaultConstants.kDefScope,DefaultConstants.kDefScope,CDLMathMLOperands.TupleOperand);this.DoEdit(_IP._ve,_IP);if(this._kn._lW==ExpAPIXml.kEleCombineFilterExpr&&Utilities.GetObjArrayLength(this._kn._ni._sy)>1){this._kn._nt=false;}};CUICombineFilterDlg.SafeDoAddNewLine=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager.oDialogMgr._jg.DoAddEmptyGroup();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICombineFilterDlg.prototype.DoCancel=function(_Ke){CUIDialogMgr.SafeHideCurrentDialog(_Ke);if(this._oC){this._oC.SetHostObj(this._tC);this._oC.SetInitFilterExpr(this._oC._w1);this._oC.Create();this._oC.Display();this._oC=null;}};CUIFltRulesGroup.kGlobalRel=1;CUIFltRulesGroup.kInnerRel=2;function CUIFltRulesGroup(_VN,_FU){this._pP=_VN;this._ve=Utilities.GenerateId();this._uw=null;this._i2=new Array();this._ni=null;this._gm=new Array();this._fi='prop_dropdown_arrow';this._wt='ComboBoxArrow.gif';this.bSelected=false;this._cL=_FU?_FU:0;};CUIFltRulesGroup.prototype.GetId=function(){return this._ve;};CUIFltRulesGroup.prototype.AddRuleToGroup=function(_Bo){this._i2.push(_Bo);};CUIFltRulesGroup.prototype.InitExprNode=function(_IP,_Sg){if(_IP){this._ni=_IP;}else{if(!_Sg){var _Sg=null;}this._ni=new CDLMathMLExprNode(_Sg,false,true);}};CUIFltRulesGroup.lastDiv=null;CUIFltRulesGroup.kInnerDivHeight=18;CUIFltRulesGroup.kReservedBraketWidth=6;CUIFltRulesGroup.kBaseRightMargin=20;CUIFltRulesGroup.kRightIndentationWidth=15;CUIFltRulesGroup.prototype.MergeRules=function(_EP,_T3,_EH){if(_T3._cL>0){var _amJ=document.createElement('SPAN');_amJ.className='flt_rule_group_brakets_open';var _aE6=document.createTextNode('(');_amJ.appendChild(_aE6);_EP.appendChild(_amJ);}var _afJ=null;var _Ke=this._pP.sAppName;for(var i=0;i<_T3._i2.length;i++){_afJ=_T3._i2[i];if(_afJ._cS){var _ME=_afJ._ve;var _3c=Utilities.GenerateCallback(CUICombineFilterDlg.SafeDoEdit,[_Ke,_ME]);var _aIw=COTInputElementFactory.CreateLink(_3c,_afJ.GetLeafNodeLabel(this._pP._kn),false,'editable_content_link');_EH.appendChild(_aIw);}else if(_afJ instanceof CUIFltRulesGroup){var _1k=null;if((_afJ._cL==0)&&((i==0)||((i>0)&&(_T3._i2[i-1]._cL>0))||((i>0)&&(_T3._cL>1)))){_1k=document.createElement('SPAN');_1k.className='inner_rule_div';_EP.appendChild(_1k);COTStyle.SetWidth(_1k,this._pP._qM-CUICombineFilterDlg.kReservedBraketWidth-8,'px');COTStyle.SetHeight(_1k,CUIFltRulesGroup.kInnerDivHeight,'px');CUIFltRulesGroup.lastDiv=_1k;}_T3.MergeRules(_EP,_afJ,CUIFltRulesGroup.lastDiv);}if(i<(_T3._i2.length-1)){var _aD6=document.createElement('DIV');_aD6._dl=CUIFltRulesGroup.kInnerRel;_aD6.oUIGrpObj=_T3;var _SL=_T3._ni._s4?_T3._ni._s4:CUIUserDefFilterDlg.kAnd;var _zi=CUIUserDefFilterDlg.FLTRuleRelArr[_SL];var _1w='dlg_dropdown_container';if(_T3._cL!=1){var _am4;if(_afJ._cL==_T3._i2[i+1]._cL){if(CUIFltRulesGroup.IndentationLevel>-1){_am4=CUIFltRulesGroup.IndentationLevel;}else{_am4=this._pP._ap-1;}}else{var _avu=Math.max(_afJ._cL,_T3._i2[i+1]._cL);_am4=this._pP._ap-_avu;CUIFltRulesGroup.IndentationLevel=_am4;}_1w='dlg_dropdown_block_container';var _acT=this._pP._ap-_T3._cL;var _ajF=CUIFltRulesGroup.kBaseRightMargin+_acT*CUIFltRulesGroup.kRightIndentationWidth;_aD6.style.paddingRight=_ajF+'px';_EP.appendChild(_aD6);while(_am4>0){var _afT=document.createElement('IMG');_afT.src=Utilities.IMG_PATH+"blank.gif";_afT.style.width=CUIFltRulesGroup.kReservedBraketWidth+'px';_EP.appendChild(_afT);_am4--;}}else{CUIFltRulesGroup.lastDiv.appendChild(_aD6);}_T3._gm.push(COTInputElementFactory.CreateDropdownEle(_aD6,_1w,this,null,_SL,_zi,null,true));}}if(_T3._cL>0){var _awK=document.createElement('SPAN');_awK.className='flt_rule_group_brakets_close';var _ZQ=document.createTextNode(')');_awK.appendChild(_ZQ);_EP.appendChild(_awK);}};CUIFltRulesGroup.prototype.Create=function(_Sg,_AZ,_Qr){var _NH=document.createElement('TR');var _NM=document.createElement('TD');_NM.className+=' vAlign_top';COTStyle.SetWidth(_NM,3,'%');this._xB=COTInputElementFactory.CreateImage('filter_row_selector.gif',16,16);this._xB.className+=' dlg_img_in_pageCtrlTBL link_image';var _Co=this._pP.oDialogMgr.oUIMgr.appobj.oResources;var _Rz=_Co.GetString('IDS_FLT_SELECT_LINE');this._xB.title=_Rz;this._xB.alt=_Rz;_NM.appendChild(this._xB);_NH.appendChild(_NM);this._mu=document.createElement('TD');if(!_AZ){var _adw=Utilities.GetObjArrayLength(this._pP._xo);if(_adw>1){this.AddGlobalRelObj(_Sg);}}_NH.appendChild(this._mu);var _Ke=this._pP.sAppName;this._mC=this._pP._g5.cloneNode(false);if(!_Qr){var _KR=this._ni;var _ME=_KR._ve;var _3c=Utilities.GenerateCallback(CUICombineFilterDlg.SafeDoEdit,[_Ke,_ME]);var _apS=COTInputElementFactory.CreateLink(_3c,_KR.GetLeafNodeLabel(this._pP._kn),true,'editable_content_link');this._mC.appendChild(_apS);this._pP._t5.push(_KR);}_NH.appendChild(this._mC);this._uw=_NH;this._uw.onclick=CUIFltRulesGroup.SafeHandleRuleSelection;Dom.SetObjRef(this._uw,this,'oUIRuleObj');return _NH;};CUIFltRulesGroup.prototype.SetupGroupStructure=function(_EV,_IP){var _asf=1;_EV._ui=new Array();for(var i=0;i<_IP._sy.length;i++){var _at1=_IP._sy[i];var _alh=new CUIFltRulesGroup(_EV._pP);_alh.InitExprNode(_at1);_EV.AddRuleToGroup(_alh);var op=this._pP._kn.GetExprNode()._s4;if(!op){op=CUIUserDefFilterDlg.kAnd;}if(_at1._cS){_alh.AddRuleToGroup(_at1);var _aAP=_alh.Create(op);this._pP._pR.firstChild.appendChild(_aAP);_aAP.className="pagerCtrlTBLItem_hidden";_EV._ui.push(_alh);}else{var _aua=_alh.Create(op,false,true);this._pP._pR.firstChild.appendChild(_aua);_aua.className="pagerCtrlTBLItem_hidden";_alh.SetupGroupStructure(_alh,_at1);if(this._ap<_alh._cL){this._ap=_alh._cL;}CUICombineFilterDlg.kReservedBraketWidth=this._pP._ap*2*CUIFltRulesGroup.kReservedBraketWidth;_alh.MergeRules(_alh._mC,_alh);_EV._ui.push(_alh);_asf++;}}_EV._cL=_asf;};CUIFltRulesGroup.prototype.ShowDropdown=function(e,x,y,_Pn){var _Kk=new CUIContextMenu(this._pP.sAppName,0,this);var _SJ=Dom.GetEventTarget(e);if(!_SJ){return;}if(_SJ.parentNode._dl==CUIFltRulesGroup.kGlobalRel){this._pP._iw=this._mu;}else{this._pP._iw=_SJ.parentNode;}for(var i in CUIUserDefFilterDlg.FLTRuleRelDetailArr){var _AG=new Array(this._pP.sAppName,i,_SJ.parentNode._dl);var _PM=new ContextItem('',CUIUserDefFilterDlg.FLTRuleRelDetailArr[i],CUIFltRulesGroup.SafeDoUpdateRelAtSameLevel,false,_AG,_Kk);_PM.SetSkipUncomitChangesChecking();}_Kk.SetChildrenComplete();_Kk.display(e,true,null,y);};CUIFltRulesGroup.SafeDoUpdateRelAtSameLevel=function(_Ke,_Ja,_O6){var _3M=FindApp(_Ke).uiManager.oDialogMgr._jg._iw;if(_3M){var _U5=(_3M._jU!=_Ja);if(_U5){var _asG=_3M.oUIGrpObj;_3M._jU=_Ja;_asG.SyncAllRelSelectionAtSameLevel(_O6,_Ja);}}};CUIFltRulesGroup.prototype.SyncAllRelSelectionAtSameLevel=function(_O6,_Tn){var _am3=CUIUserDefFilterDlg.FLTRuleRelArr[_Tn];switch(_O6){case CUIFltRulesGroup.kGlobalRel:this._pP._kn.GetExprNode().SetOperator(_Tn);for(var i in this._pP._xo){if(this._pP._xo[i]._mu._jU){this._pP._xo[i]._mu._jU=_Tn;if(this._pP._xo[i]._mu.firstChild){Dom.ReplaceText(this._pP._xo[i]._mu.firstChild,_am3);}}}break;case CUIFltRulesGroup.kInnerRel:this._ni._s4=_Tn;for(var i=0;i<this._gm.length;i++){this._gm[i]._jU=_Tn;Dom.ReplaceText(this._gm[i].firstChild,_am3);}break;}};CUIFltRulesGroup.SafeHandleRuleSelection=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}var _SJ=Dom.GetEventTarget(e);if(!_SJ||_SJ.tagName=='A'){return;}if(this.oUIRuleObj){this.oUIRuleObj.HandleRuleSelection(e.ctrlKey,e.shiftKey,this);}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIFltRulesGroup.prototype.HandleRuleSelection=function(_K4,_yN,_SJ){var _aqz=false;if(!(_K4||_yN)){for(var i in this._pP._o4){if(this.GetId()!=i){this._pP._o4[i].bSelected=false;this._pP._o4[i].SetStyle();delete this._pP._o4[i];}else{_aqz=true;}}}if(!_aqz){if(_yN){if(this._pP._n3){var _IH=COTInputElementFactory.TRShiftSelection(this._pP._pR,this._pP._n3._uw,this._uw);for(var j=0;j<_IH.length;j++){var _abD=_IH[j].oUIRuleObj;if(_abD){if(_abD._uw.className!="pagerCtrlTBLItem_hidden"){_abD.bSelected=true;_abD._pP._o4[_abD.GetId()]=_abD;_abD.SetStyle();}}else{Utilities.DeleteFromArray(_IH,_abD);}}}}else{this.bSelected=true;this._pP._o4[this.GetId()]=this;this.SetStyle();this._pP._n3=this;}}};CUIFltRulesGroup.prototype.SetStyle=function(){if(this.bSelected){this._uw.className='pagerCtrlTBLItem_selected';}else{this._uw.className='pagerCtrlTBLItem';}};CUIFltRulesGroup.prototype.RemoveGlobalRelObj=function(){if(this._mu.oUIGrpObj){Dom.RemoveAllChildren(this._mu);this._mu.oUIGrpObj=null;}};CUIFltRulesGroup.prototype.AddGlobalRelObj=function(_Sg){this._mu.oUIGrpObj=this;var _SL=_Sg?_Sg:CUIUserDefFilterDlg.kAnd;var _zi=CUIUserDefFilterDlg.FLTRuleRelArr[_SL];COTInputElementFactory.CreateDropdownEle(this._mu,'dlg_img_in_pageCtrlTBL',this,null,_SL,_zi);this._mu._dl=CUIFltRulesGroup.kGlobalRel;};CUIFltRulesGroup.prototype.RecheckGlobalCombo=function(){var _adw=Utilities.GetObjArrayLength(this._pP._xo);if(_adw<=1){if(this._mu.oUIGrpObj){this.RemoveGlobalRelObj();}}else if(_adw>=1){if(!this._mu.oUIGrpObj){this.AddGlobalRelObj(this._pP._kn._ni._s4);}}};CUIReportOptionsDlg.kCurrentTab=0;CUIReportOptionsDlg.kDlg=1;function CUIReportOptionsDlg(_Mb){this.base=CUIDialog;this.base();this.bSaveOnly=_Mb?_Mb:false;};CUIReportOptionsDlg.prototype=new CUIDialog;CUIReportOptionsDlg.superclass=CUIDialog.prototype;CUIReportOptionsDlg.prototype.PushOntoDialogStack=function(){this.SetReportOptions();};CUIReportOptionsDlg.prototype.GetContextArray=function(){var _Ow=new Array();_Ow[CUIDialogMgr.kStackedDlgReOpenFunction]=CUIReportOptionsDlg.SafeRestoreFromContext;_Ow[CUIReportOptionsDlg.kDlg]=this;_Ow[CUIReportOptionsDlg.kCurrentTab]=this.oTabCtrl.GetCurrentTabIndex();return _Ow;};CUIReportOptionsDlg.SafeRestoreFromContext=function(_Bh,_Dm){/*@if(!@bering_debug)@*/try{/*@end@*/var _aGD=_Bh[CUIReportOptionsDlg.kDlg];_aGD.Display(_Bh[CUIReportOptionsDlg.kCurrentTab]);return _aGD;/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIReportOptionsDlg.prototype.Display=function(_Re){var _Co=this.oDialogMgr.oUIMgr.appobj.oResources;var _Ke=this.sAppName;var _MY=new Object();var _Xf=Utilities.GenerateCallback(CUIManager.SafeDoHelpTopic,[_Ke,HelpConstants.kReportOptionsLink]);_MY['IDS_HELP']=_Xf;if(!this.oHostAnalysis._mn){this.oHostAnalysis.SendGetPaperSizeReq();}this.Draw(_Re);CUIReportOptionsDlg.superclass.Display.call(this,'IDS_REPORT_OPTIONS_DLG_TITLE',_MY,this._vO,'IDS_REPORT_OPTIONS_DLG_INSTR_TEXT');this.oTabCtrl.Show();};CUIReportOptionsDlg.prototype.Init=function(_yt,_Sb){this._bw=_Sb;CUIReportOptionsDlg.superclass.Init.call(this,_yt,_Sb);this.oTitleTab=new CUITitleTab(this);this.oDisplayTab=new CUIDisplayTab(this);this.oPaperTab=new CUIPaperTab(this);this._aX=new Array(this.oTitleTab,this.oDisplayTab,this.oPaperTab);if(!_yt.oUIMgr.appobj._cl){this.oReportTemplateTab=new CUIReportTemplateTab(this);this._aX.push(this.oReportTemplateTab);}this.oPurposeTab=new CUIPurposeTab(this);this._aX.push(this.oPurposeTab);this.oDispNamesTab=new CUIDispNamesTab(this);this._aX.push(this.oDispNamesTab);_yt.oUIMgr.dataManager._kX.Subscribe(this,ExpEvent.kCDLAnalysis_Replace);};CUIReportOptionsDlg.prototype.Notify=function(_Dy){switch(_Dy){case ExpEvent.kCDLAnalysis_Replace:if((this.oHostAnalysis&&this.oHostAnalysis._mn)&&(this.oPaperTab&&!this.oPaperTab._cx)){this.oPaperTab.RedrawPaperSizeList(this.oHostAnalysis);if(this.oDialogMgr.oUIMgr.oBlockPropsPane._w7){this.oDialogMgr.oUIMgr.oBlockPropsPane._w7=false;}}break;}};CUIReportOptionsDlg.prototype.Unload=function(){for(i in this._aX){this._aX[i].Unload();}Dom.RemoveObject(this._vO);CUIReportOptionsDlg.superclass.Unload.call(this);Utilities.RemoveAllChildObjects(this);};CUIReportOptionsDlg.prototype.SetHostObj=function(_JE,_CK){this.oHostAnalysis=_JE;if(_CK){this.oNewAnalysis=_CK;}else{this.oNewAnalysis=_JE.Clone();}};CUIReportOptionsDlg.prototype.Draw=function(tabIndex){var _zr=document.createElement('TABLE');this._vO=_zr;COTStyle.SetHeight(_zr,235);_zr.className='dialogTable';var _Ke=this.sAppName;var _RK=_zr.appendChild(document.createElement('TBODY'));this._xS=_RK;var _acP=_RK.appendChild(document.createElement('TR'));COTStyle.SetHeight(_acP,26);var _acw=_acP.appendChild(document.createElement('TD'));var _Tx=true;this.oTabCtrl=new CUITabControll(this,_acw,this.oDialogMgr.oUIMgr,_Tx,'tab_div_reportOption');var _KP=this.oRes.GetString('IDS_REPORT_OPTIONS_DLG_TITLE_TAB');var _0M=this.oRes.GetString('IDS_REPORT_OPTIONS_DLG_DISPLAY_TAB');var _alR=this.oRes.GetString('IDS_REPORT_OPTIONS_DLG_PAPER_TAB');var _A9=this.oRes.GetString('IDS_REPORT_OPTIONS_DLG_REPORT_TEMPLATE_TAB');var _5D=this.oRes.GetString('IDS_REPORT_OPTIONS_DLG_OUTPUT_PURPOSE_TAB');var _anM=this.oRes.GetString('IDS_REPORT_OPTIONS_DLG_DISPLAY_NAMES_TAB');if(!this.oDialogMgr.oUIMgr.appobj._cl){var _abQ=new Array(_KP,_0M,_alR,_A9,_5D,_anM);}else{var _abQ=new Array(_KP,_0M,_alR,_5D,_anM);}tabIndex=isNaN(tabIndex)?0:tabIndex;this.oTabCtrl.SetUpTabs(_abQ,this._aX,false,null,tabIndex);var _97=this._xS.appendChild(document.createElement('TR'));var _Yi=_97.appendChild(document.createElement('TD'));_Yi.className='rs_content_top_alignment';COTStyle.SetWidth(_Yi,100,'%');for(i in this._aX){this._aX[i].Draw(_Yi,this.oNewAnalysis);}for(i in this._aX){if(i==tabIndex){this._aX[i].Show();}else{this._aX[i].Hide();}}this._Y=Utilities.GenerateCallback(this.OnReportOptionsOK,[],this);this._of=Utilities.GenerateCallback(this.OnCancelReportOptions,[],this);this._om=2;};CUIReportOptionsDlg.prototype.OnReportOptionsOK=function(){this.SetReportOptions();if(!this.bSaveOnly){this.CommitChanges();}CUIDialogMgr.SafeHideCurrentDialog(this.sAppName);};CUIReportOptionsDlg.prototype.CommitChanges=function(){var _Jj=this.oHostAnalysis.Modify(this.oNewAnalysis,true);var _AE=new Array();_AE.push(_Jj);if(this.oDialogMgr.oUIMgr._jf._my.isViewsChartNameChanged()){_AE.push(this.oDialogMgr.oUIMgr._jf._my.ModifyViewsChartName(true));}if(this.oDialogMgr.oUIMgr._jf._my.isViewsXtabNameChanged()){_AE.push(this.oDialogMgr.oUIMgr._jf._my.ModifyViewsXtabName(true));}var _aBj=this.oDialogMgr.oUIMgr.dataManager.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this.oDialogMgr.oUIMgr.dataManager.GetCurrentWorkSheet(),true);};CUIReportOptionsDlg.prototype.SetReportOptions=function(){this.oNewAnalysis.SetTitle(this.oTitleTab.GetTitle());this.oNewAnalysis.SetSubtitle(this.oTitleTab.GetSubtitle());this.oNewAnalysis.SetPaperOrientation(this.oPaperTab.GetPaperOrientation());this.oNewAnalysis.SetPaperSize(this.oPaperTab.GetPaperSize());this.oNewAnalysis.SetFitPage(this.oPaperTab.GetFitPage());this.oNewAnalysis.SetDisplayFilters(this.oDisplayTab.GetDisplayFilters());this.oNewAnalysis.SetFilterDisplayPos(this.oDisplayTab.GetDisplayFilterPos());this.oNewAnalysis.SetDisplayDataUpdatedOn(this.oDisplayTab.GetDisplayDataUpdatedOn());this.oNewAnalysis.SetDisplayWarningPage(this.oDisplayTab.GetDisplayWarningPage());this.oNewAnalysis.SetDisplayAll(this.oDisplayTab.GetDisplayAll());this.oNewAnalysis.SetDisplayOutermostGroups(this.oDisplayTab.GetDisplayOutermostGroups());this.oNewAnalysis.SetDisplaySections(this.oDisplayTab.GetDisplaySections());if(this.oDisplayTab.GetDisplaySections()){this.oNewAnalysis.SetDisplaySectionItem(this.oDisplayTab.GetDisplaySectionItem());}if(!this.oDialogMgr.oUIMgr.appobj._cl){this.oNewAnalysis.SetUseReportTemplate(this.oReportTemplateTab.GetReportTemplateSelectionPos());}this.oNewAnalysis.SetOutputPurpose(this.oPurposeTab.GetOutputPurpose());this.oNewAnalysis.SetDisplayBreadcrumb(this.oPurposeTab.GetDisplayBreadcrumb());var _PX=this.oDialogMgr.oUIMgr._jf;if(_PX._ca==CUIWorkSheet.eLayoutXtabOnly||_PX._ca==CUIWorkSheet.eLayoutXtabAndChart){this.oDialogMgr.oUIMgr._jf._my.SetViewsXtabName(this.oDispNamesTab.GetXtabName());}if(_PX._ca==CUIWorkSheet.eLayoutChartOnly||_PX._ca==CUIWorkSheet.eLayoutXtabAndChart){this.oDialogMgr.oUIMgr._jf._my.SetViewsChartName(this.oDispNamesTab.GetChartName());}};CUIReportOptionsDlg.prototype.OnCancelReportOptions=function(){this.oNewAnalysis=this.oHostAnalysis;this.oDialogMgr.oUIMgr._jf._my.SetViewsXtabName(this.oDialogMgr.oUIMgr._jf._my.GetViewsXtabName());this.oDialogMgr.oUIMgr._jf._my.SetViewsChartName(this.oDialogMgr.oUIMgr._jf._my.GetViewsChartName());CUIDialogMgr.SafeHideCurrentDialog(this.sAppName);};CUIReportOptionsDlg.prototype.GetNewAnalysisObj=function(){return this.oNewAnalysis;};CUIReportOptionsDlg.prototype.GetHostAnalysisObj=function(){return this.oHostAnalysis;};function CUITitleTab(oDialog){this.oDialog=oDialog;};CUITitleTab.prototype.Unload=function(){Dom.RemoveObject(this._p2);Utilities.RemoveAllChildObjects(this);};CUITitleTab.prototype.Show=function(){this._p2.style.display="block";};CUITitleTab.prototype.Hide=function(){this._p2.style.display="none";};CUITitleTab.prototype.Draw=function(_EP,_JE){this._p2=_EP.appendChild(document.createElement('DIV'));var _32=this._p2.appendChild(document.createElement('DIV'));COTStyle.SetHeight(_32,15,'px');_32.style.paddingTop="5px";var _1a=this.oDialog.oRes.GetString('IDS_REPORT_OPTIONS_DLG_TITLE_CAPTION');_32.appendChild(COTInputElementFactory.CreateLabel(_1a));_32.className="dialogText_bold";var _KP=_JE.GetTitle()?_JE.GetTitle():"";var _55=COTInputElementFactory.CreateTextBox(90,'%',_KP);this._bY="Title"+Utilities.GenerateId();_55.id=this._bY;this._p2.appendChild(_55);var _aaS=this._p2.appendChild(document.createElement('DIV'));var _aji=this.oDialog.oRes.GetString('IDS_REPORT_OPTIONS_DLG_SUBTITLE_CAPTION');_aaS.appendChild(COTInputElementFactory.CreateLabel(_aji));_aaS.className="dialogText_bold";_aaS.style.marginTop="20px";var _RQ=_JE.GetSubtitle()?_JE.GetSubtitle():"";var _ayh=COTInputElementFactory.CreateTextBox(90,'%',_RQ);this._pM="Subtitle"+Utilities.GenerateId();_ayh.id=this._pM;this._p2.appendChild(_ayh);};CUITitleTab.prototype.GetTitle=function(){var _adW=document.getElementById(this._bY);return _adW.value;};CUITitleTab.prototype.GetSubtitle=function(){var _aEg=document.getElementById(this._pM);return _aEg.value;};function CUIDisplayTab(oDialog){this.oDialog=oDialog;};CUIDisplayTab.prototype.Unload=function(){Dom.RemoveObject(this._p2);Utilities.RemoveAllChildObjects(this);};CUIDisplayTab.prototype.Show=function(){this._p2.style.display="block";};CUIDisplayTab.prototype.Hide=function(){this._p2.style.display="none";};CUIDisplayTab.prototype.Draw=function(_EP,_JE){this._p2=_EP.appendChild(document.createElement('DIV'));COTStyle.SetWidth(this._p2,100,'%');var _zr=this._p2.appendChild(document.createElement('TABLE'));COTStyle.SetWidth(_zr,100,'%');var _RK=_zr.appendChild(document.createElement('TBODY'));var _NH=_RK.appendChild(document.createElement('TR'));var _NM=_NH.appendChild(document.createElement('TD'));_NM.className='vAlign_top';COTStyle.SetWidth(_NM,50,'%');var _ajh=_NM.appendChild(document.createElement('TABLE'));var _8h=_ajh.appendChild(document.createElement('TBODY'));var _aA8=_8h.appendChild(document.createElement('TR'));var _aG5=_aA8.appendChild(this.oDialog._l4.cloneNode(false));var _auP=this.oDialog.oRes.GetString('IDS_REPORT_OPTIONS_DLG_SHOW_IN_REPORT');_aG5.appendChild(COTInputElementFactory.CreateLabel(_auP));_aG5.colSpan=3;if(_JE._he.metadata.GetDataUpdatedOn()){_aA8=_8h.appendChild(document.createElement('TR'));var _aEN=_aA8.appendChild(document.createElement('TD'));var _acC=COTInputElementFactory.CreateCheckBox("show_cube_properties",ExpAPIXml.kEleDisplayDataUpdatedOn,_JE.DisplayDataUpdatedOn(),null);_aEN.appendChild(_acC);COTStyle.SetWidth(_aEN,15,"%");var _aH4=_aA8.appendChild(this.oDialog._g5.cloneNode(false));_aH4.appendChild(COTInputElementFactory.CreateLabel(this.oDialog.oRes.GetString('IDS_REPORT_OPTIONS_DLG_SHOW_DATA_UPDATED_ON')));COTStyle.SetWidth(_aH4,85,"%");_aH4.colSpan=2;}_aA8=_8h.appendChild(document.createElement('TR'));var _1s=_aA8.appendChild(document.createElement('TD'));var _XH=COTInputElementFactory.CreateCheckBox("show_filter_in_report",ExpAPIXml.kEleDisplayFilter,_JE.DisplayFilters(),CUIDisplayTab.SafeOnFilterCheck);_1s.appendChild(_XH);COTStyle.SetWidth(_1s,15,"%");var _XA=_aA8.appendChild(this.oDialog._g5.cloneNode(false));_XA.appendChild(COTInputElementFactory.CreateLabel(this.oDialog.oRes.GetString('IDS_REPORT_OPTIONS_DLG_SHOW_FILTERS')));COTStyle.SetWidth(_XA,85,"%");_XA.colSpan=2;_aA8=_8h.appendChild(document.createElement('TR'));var _9L=_aA8.appendChild(document.createElement('TD'));COTStyle.SetWidth(_9L,15,"%");_9L=_aA8.appendChild(document.createElement('TD'));var _aco=COTInputElementFactory.CreateRadioButton("filter_location",ExpAPIXml.kFiltersAtTop,!_JE.DisplayFiltersAtEnd(),null);_9L.appendChild(_aco);this._n6=Utilities.GenerateId();_aco.id=this._n6;COTStyle.SetWidth(_9L,15,"%");_aG5=_aA8.appendChild(this.oDialog._g5.cloneNode(false));_aG5.appendChild(COTInputElementFactory.CreateLabel(this.oDialog.oRes.GetString('IDS_REPORT_OPTIONS_DLG_SHOW_FILTERS_BEG')));COTStyle.SetWidth(_aG5,70,"%");_aA8=_8h.appendChild(document.createElement('TR'));var _ah6=_aA8.appendChild(document.createElement('TD'));COTStyle.SetWidth(_ah6,15,"%");_ah6=_aA8.appendChild(document.createElement('TD'));var _an3=COTInputElementFactory.CreateRadioButton("filter_location",ExpAPIXml.kFiltersAtBottom,_JE.DisplayFiltersAtEnd(),null);_ah6.appendChild(_an3);this._pG=Utilities.GenerateId();_an3.id=this._pG;COTStyle.SetWidth(_ah6,15,"%");_aG5=_aA8.appendChild(this.oDialog._g5.cloneNode(false));_aG5.appendChild(COTInputElementFactory.CreateLabel(this.oDialog.oRes.GetString('IDS_REPORT_OPTIONS_DLG_SHOW_FILTERS_END')));COTStyle.SetWidth(_aG5,70,"%");_XH.sBegId=this._n6;_XH.sEndId=this._pG;_aA8=_8h.appendChild(document.createElement('TR'));var _awh=_aA8.appendChild(document.createElement('TD'));COTStyle.SetHeight(_awh,10,'px');_aA8=_8h.appendChild(document.createElement('TR'));_aG5=_aA8.appendChild(this.oDialog._l4.cloneNode(false));var _aaA=this.oDialog.oRes.GetString('IDS_REPORT_OPTIONS_DLG_EXPAND_MORE');_aG5.appendChild(COTInputElementFactory.CreateLabel(_aaA));_aG5.colSpan=3;_aA8=_8h.appendChild(document.createElement('TR'));var _Z7=_aA8.appendChild(document.createElement('TD'));var _ayX=COTInputElementFactory.CreateRadioButton("show_report",ExpAPIXml.kEleDisplayAllItems,_JE.DisplayAll(),null);_Z7.appendChild(_ayX);COTStyle.SetWidth(_ah6,15,"%");_aG5=_aA8.appendChild(this.oDialog._g5.cloneNode(false));_aG5.appendChild(COTInputElementFactory.CreateLabel(this.oDialog.oRes.GetString('IDS_REPORT_OPTIONS_DLG_SHOW_ALL')));COTStyle.SetWidth(_aG5,85,"%");_aG5.colSpan=2;_aA8=_8h.appendChild(document.createElement('TR'));var _Zg=_aA8.appendChild(document.createElement('TD'));var _atz=COTInputElementFactory.CreateRadioButton("show_report",'visibleitem',!_JE.DisplayAll(),null);_Zg.appendChild(_atz);COTStyle.SetWidth(_ah6,15,"%");_aG5=_aA8.appendChild(this.oDialog._g5.cloneNode(false));_aG5.appendChild(COTInputElementFactory.CreateLabel(this.oDialog.oRes.GetString('IDS_REPORT_OPTIONS_DLG_SHOW_VISIBLE')));COTStyle.SetWidth(_aG5,85,"%");_aG5.colSpan=2;_NM=_NH.appendChild(document.createElement('TD'));COTStyle.SetWidth(_NM,50,'%');_NM.className='vAlign_top';var _auH=_NM.appendChild(document.createElement('TABLE'));var _3S=_auH.appendChild(document.createElement('TBODY'));var _aeC=_3S.appendChild(document.createElement('TR'));var _awG=_aeC.appendChild(this.oDialog._l4.cloneNode(false));var _2z=this.oDialog.oRes.GetString('IDS_REPORT_OPTIONS_DLG_PAGE_BREAKS');_awG.appendChild(COTInputElementFactory.CreateLabel(_2z));_awG.colSpan=2;_aeC=_3S.appendChild(document.createElement('TR'));var _an4=_aeC.appendChild(document.createElement('TD'));var _aoY=this.oDialog.oHostAnalysis._he.GetCurrentWSFilterSet();var _auK=(!this.oDialog.oHostAnalysis._he.HasContextItemUsedAsParam()&&(_aoY.GetDimFilters().length>0));var _apJ=COTInputElementFactory.CreateCheckBox("page_breaks",ExpAPIXml.kEleDisplaySections,_JE.DisplaySections(),null,!_auK);_an4.appendChild(_apJ);COTStyle.SetWidth(_an4,15,"%");_awG=_aeC.appendChild(this.oDialog._g5.cloneNode(false));_awG.appendChild(COTInputElementFactory.CreateLabel(this.oDialog.oRes.GetString('IDS_REPORT_OPTIONS_DLG_SECTIONS')));COTStyle.SetWidth(_awG,85,"%");_aeC=_3S.appendChild(document.createElement('TR'));_awG=_aeC.appendChild(document.createElement('TD'));_awG.appendChild(document.createTextNode(' '));var _aeL=_aeC.appendChild(document.createElement('TD'));this.oListCtrl=new CUIListCtrl(this.oDialog.oDialogMgr.oUIMgr);this.oListCtrl.iMaxHeight=150;this.oListCtrl.Init();this.oComboBox=new CUIComboBox(this.oDialog.oDialogMgr.oUIMgr,this.oListCtrl);this.oComboBox.DisableIcon();var _afs=_aeL.appendChild(this.oComboBox.Init());this.oComboBox.SetWidth(200,'px');this.PopulateContextItems(_JE);_aeC=_3S.appendChild(document.createElement('TR'));var _Ya=_aeC.appendChild(document.createElement('TD'));var _aBB=COTInputElementFactory.CreateCheckBox("page_breaks",ExpAPIXml.kEleDisplayOutermostGroups,_JE.DisplayOutermostGroups(),null);_Ya.appendChild(_aBB);COTStyle.SetWidth(_Ya,15,"%");_awG=_aeC.appendChild(this.oDialog._g5.cloneNode(false));_awG.appendChild(COTInputElementFactory.CreateLabel(this.oDialog.oRes.GetString('IDS_REPORT_OPTIONS_DLG_GROUPS_ON_ROWS')));COTStyle.SetWidth(_awG,85,"%");_aeC=_3S.appendChild(document.createElement('TR'));_awh=_aeC.appendChild(document.createElement('TD'));COTStyle.SetHeight(_awh,10,'px');_aeC=_3S.appendChild(document.createElement('TR'));_awG=_aeC.appendChild(this.oDialog._l4.cloneNode(false));_awG.appendChild(COTInputElementFactory.CreateLabel(this.oDialog.oRes.GetString('IDS_REPORT_OPTIONS_DLG_WARNING_PAGE')));_awG.colSpan=2;_aeC=_3S.appendChild(document.createElement('TR'));var _4r=_aeC.appendChild(document.createElement('TD'));var _amy=COTInputElementFactory.CreateCheckBox("display_warning_page",ExpAPIXml.kEleDisplayWarningPage,_JE.DisplayWarningPage(),null);_4r.appendChild(_amy);COTStyle.SetWidth(_4r,15,"%");_awG=_aeC.appendChild(this.oDialog._g5.cloneNode(false));_awG.appendChild(COTInputElementFactory.CreateLabel(this.oDialog.oRes.GetString('IDS_REPORT_OPTIONS_DLG_SHOW_WARNING_PAGE')));COTStyle.SetWidth(_awG,85,"%");};CUIDisplayTab.prototype.GetDisplayFilters=function(){return COTInputElementFactory.IsChecked("show_filter_in_report",ExpAPIXml.kEleDisplayFilter);};CUIDisplayTab.prototype.GetDisplayFilterPos=function(){return COTInputElementFactory.GetRadioSelectionValue("filter_location");};CUIDisplayTab.prototype.GetDisplayDataUpdatedOn=function(){var _aiT=document.getElementsByName("show_cube_properties");if(_aiT.length>0){return COTInputElementFactory.IsChecked("show_cube_properties",ExpAPIXml.kEleDisplayDataUpdatedOn);}return false;};CUIDisplayTab.prototype.GetDisplayWarningPage=function(){var _aiT=document.getElementsByName("display_warning_page");if(_aiT.length>0){return COTInputElementFactory.IsChecked("display_warning_page",ExpAPIXml.kEleDisplayWarningPage);}return false;};CUIDisplayTab.prototype.GetDisplayAll=function(){var _FT=COTInputElementFactory.GetRadioSelectionValue("show_report");return(_FT==ExpAPIXml.kEleDisplayAllItems);};CUIDisplayTab.prototype.GetDisplayOutermostGroups=function(){return COTInputElementFactory.IsChecked("page_breaks",ExpAPIXml.kEleDisplayOutermostGroups);};CUIDisplayTab.prototype.GetDisplaySections=function(){return COTInputElementFactory.IsChecked("page_breaks",ExpAPIXml.kEleDisplaySections);};CUIDisplayTab.prototype.GetDisplaySectionItem=function(){return this.oComboBox.GetValue();};CUIDisplayTab.prototype.PopulateContextItems=function(_JE){var _aoY=_JE._he.GetCurrentWSFilterSet();var _ajG=false;var _ayk=null;if(!_JE._he.HasContextItemUsedAsParam()){var _aDG=_aoY.GetDimFilters();for(var i=0;i<_aDG.length;i++){var _EB=_aDG[i];var _BM=_EB.GetLabel();var oContextItem=this.oListCtrl.AddItem('',_BM,0,_EB.elcid,"",false);var _YI=_JE.GetDisplaySectionItem();if((!_ajG)&&_YI&&_YI==_EB.elcid){this.oComboBox.SetValueFromListItem(oContextItem,false);_ajG=true;}if(i==0){_ayk=oContextItem;}}if(!_ajG&&_ayk){this.oComboBox.SetValueFromListItem(_ayk,false);}}if(!_ayk){this.oComboBox.Disable();}};CUIDisplayTab.SafeOnFilterCheck=function(){/*@if(!@bering_debug)@*/try{/*@end@*/var _9L=document.getElementById(this.sBegId);if(_9L){if(this.checked){COTInputElementFactory.EnableInput(_9L);}else{COTInputElementFactory.DisableInput(_9L);}}var _ah6=document.getElementById(this.sEndId);if(_ah6){if(this.checked){COTInputElementFactory.EnableInput(_ah6);}else{COTInputElementFactory.DisableInput(_ah6);}}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};function CUIPaperTab(oDialog){this.oDialog=oDialog;};CUIPaperTab.prototype.Unload=function(){Dom.RemoveObject(this._p2);Utilities.RemoveAllChildObjects(this);};CUIPaperTab.prototype.Show=function(){this._p2.style.display="block";};CUIPaperTab.prototype.Hide=function(){this._p2.style.display="none";};CUIPaperTab.prototype.Draw=function(_EP,_JE){this._p2=_EP.appendChild(document.createElement('DIV'));COTStyle.SetWidth(this._p2,100,'%');var _zr=this._p2.appendChild(document.createElement('TABLE'));COTStyle.SetWidth(_zr,100,'%');var _RK=_zr.appendChild(document.createElement('TBODY'));var _asA=_RK.appendChild(document.createElement('TR'));var _amU=_asA.appendChild(this.oDialog._l4.cloneNode(false));var _5a=this.oDialog.oRes.GetString('IDS_REPORT_OPTIONS_DLG_ORIENTATION');_amU.appendChild(COTInputElementFactory.CreateLabel(_5a));_amU.colSpan=2;var _14=_asA.appendChild(this.oDialog._l4.cloneNode(false));var _aAi=this.oDialog.oRes.GetString('IDS_REPORT_OPTIONS_DLG_PAPER_SIZE');_14.appendChild(COTInputElementFactory.CreateLabel(_aAi));_14.colSpan=2;COTStyle.SetWidth(_14,50,'%');var _1g=_RK.appendChild(document.createElement('TR'));var _Y8=_1g.appendChild(document.createElement('TD'));var _azO=COTInputElementFactory.CreateRadioButton("orientation",ExpAPIXml.kPortrait,_JE.IsPortraitOrientation(),null);_Y8.appendChild(_azO);var _ac4=_1g.appendChild(this.oDialog._g5.cloneNode(false));_ac4.appendChild(COTInputElementFactory.CreateLabel(this.oDialog.oRes.GetString('IDS_REPORT_OPTIONS_DLG_PORTRAIT')));COTStyle.SetWidth(_ac4,45,"%");var _av0=_1g.appendChild(document.createElement('TD'));this.oListCtrl=new CUIListCtrl(this.oDialog.oDialogMgr.oUIMgr);this.oListCtrl.iMaxHeight=150;this.oListCtrl.Init();this.oComboBox=new CUIComboBox(this.oDialog.oDialogMgr.oUIMgr,this.oListCtrl);this.oComboBox.DisableIcon();var _afs=_av0.appendChild(this.oComboBox.Init());this.oComboBox.SetWidth(200,'px');this.PopulatePaperSizeList(_JE);_av0.colSpan=2;COTStyle.SetWidth(_av0,30,"%");var _1g=_RK.appendChild(document.createElement('TR'));var _4c=_1g.appendChild(document.createElement('TD'));var _aeT=COTInputElementFactory.CreateRadioButton("orientation",ExpAPIXml.kLandscape,!_JE.IsPortraitOrientation(),null);_4c.appendChild(_aeT);var _2i=_1g.appendChild(this.oDialog._g5.cloneNode(false));_2i.colSpan=3;_2i.appendChild(COTInputElementFactory.CreateLabel(this.oDialog.oRes.GetString('IDS_REPORT_OPTIONS_DLG_LANDSCAPE')));var _aqr=_RK.appendChild(document.createElement('TR'));var _anH=_aqr.appendChild(document.createElement('TD'));_anH.colSpan=2;var _ayN=_aqr.appendChild(this.oDialog._l4.cloneNode(false));var _aIl=this.oDialog.oRes.GetString('IDS_REPORT_OPTIONS_DLG_PAGE_SCALE');_ayN.appendChild(COTInputElementFactory.CreateLabel(_aIl));_ayN.colSpan=2;var _aqr=_RK.appendChild(document.createElement('TR'));var _anH=_aqr.appendChild(document.createElement('TD'));_anH.colSpan=2;var _Ya=_aqr.appendChild(document.createElement('TD'));var _aBB=COTInputElementFactory.CreateCheckBox("page_breaks",ExpAPIXml.kEleHorizontalPagination,_JE.FitPage(),null);_Ya.appendChild(_aBB);COTStyle.SetWidth(_Ya,5,"%");var _aGT=_aqr.appendChild(this.oDialog._g5.cloneNode(false));_aGT.appendChild(COTInputElementFactory.CreateLabel(this.oDialog.oRes.GetString('IDS_REPORT_OPTIONS_DLG_FIT_A_PAGE')));COTStyle.SetWidth(_aGT,45,"%");};CUIPaperTab.prototype.PopulatePaperSizeList=function(_JE){var _BM=this.oDialog.oRes.GetString('IDS_REPORT_OPTIONS_DLG_DEFAULT_PAPER');var _FT=ExpAPIXml.kDefaultPaper;var _aAA=this.oListCtrl.AddItem('',_BM,0,_FT,"",false);var _aFt=_JE.GetPaperSizeList();for(var s in _aFt){this._cx=true;var _BM=_aFt[s];var _aw1=this.oListCtrl.AddItem('',_BM,0,s,"",false);if(s==_JE.GetPaperSize()){_aAA=_aw1;}}this.oComboBox.SetValueFromListItem(_aAA,false);};CUIPaperTab.prototype.RedrawPaperSizeList=function(_JE){this.oListCtrl.ClearAllItems();this.PopulatePaperSizeList(_JE);this.oListCtrl.Show();};CUIPaperTab.prototype.GetPaperOrientation=function(){return COTInputElementFactory.GetRadioSelectionValue("orientation");};CUIPaperTab.prototype.GetPaperSize=function(){return this.oComboBox.GetValue();};CUIPaperTab.prototype.GetFitPage=function(){return COTInputElementFactory.IsChecked("page_breaks",ExpAPIXml.kEleHorizontalPagination);};function CUIReportTemplateTab(oDialog){this.oDialog=oDialog;this._fl=null;this._hE=null;this._eu="";};CUIReportTemplateTab.prototype.Show=function(){this._p2.style.display="block";};CUIReportTemplateTab.prototype.Hide=function(){this._p2.style.display="none";};CUIReportTemplateTab.prototype.Draw=function(_EP,_JE){this._hE=_JE;this._p2=_EP.appendChild(document.createElement('DIV'));var _zr=this._p2.appendChild(document.createElement('TABLE'));COTStyle.SetWidth(_zr,100,'%');var _RK=_zr.appendChild(document.createElement('TBODY'));var _asA=_RK.appendChild(document.createElement('TR'));var _atS=_asA.appendChild(this.oDialog._l4.cloneNode(false));var _aJB=this.oDialog.oRes.GetString('IDS_REPORT_OPTIONS_DLG_REPORT_TEMPLATE');_atS.appendChild(COTInputElementFactory.CreateLabel(_aJB));_atS.colSpan=2;var _aBr=_RK.appendChild(document.createElement('TR'));var _XV=_aBr.appendChild(document.createElement('TD'));var _5C=COTInputElementFactory.CreateRadioButton("reportTemplate",ExpAPIXml.kDefaultTemplate,!_JE.GetUseReportTemplate(),null);_XV.appendChild(_5C);var _adD=_aBr.appendChild(this.oDialog._g5.cloneNode(false));_adD.appendChild(COTInputElementFactory.CreateLabel(this.oDialog.oRes.GetString('IDS_REPORT_OPTIONS_DLG_DEFAULT_REPORT_TEMPLATE')));var _aya=_RK.appendChild(document.createElement('TR'));var _XM=_aya.appendChild(document.createElement('TD'));var _aaD=COTInputElementFactory.CreateRadioButton("reportTemplate",ExpAPIXml.kReportTemplate,_JE.GetUseReportTemplate(),null);_XM.appendChild(_aaD);var _XD=_aya.appendChild(this.oDialog._g5.cloneNode(false));_XD.appendChild(COTInputElementFactory.CreateLabel(this.oDialog.oRes.GetString('IDS_REPORT_OPTIONS_DLG_APPLY_REPORT_TEMPLATE')));COTStyle.SetWidth(_XD,95,"%");var _aEo=_RK.appendChild(document.createElement('TR'));var _aj4=_aEo.appendChild(document.createElement('TD'));this._nB=_aEo.appendChild(this.oDialog._g5.cloneNode(false));var _amE=this.GetDisplayName();if(!_amE||_amE==""){this._nB.appendChild(COTInputElementFactory.CreateLabel(this.oDialog.oRes.GetString('IDS_REPORT_OPTIONS_DLG_REPORT_TEMPLATE_NONE')));}else{this._nB.appendChild(COTInputElementFactory.CreateLabel(_amE));}this._nB.appendChild(document.createTextNode(" "));var _7q=Utilities.GenerateCallback(CUIReportTemplateTab.SafeDoOpenReportTemplate,[this.oDialog.sAppName]);var _afX=COTInputElementFactory.CreateLink(_7q,this.oDialog.oRes.GetString('IDS_REPORT_OPTIONS_DLG_SELECT_REPORT_TEMPLATE'),true);this._nB.appendChild(_afX);Dom.SetObjRef(_afX,this,'oReportTemplateTab');};CUIReportTemplateTab.SafeDoOpenReportTemplate=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager.oDialogMgr._jg.oReportTemplateTab.DoOpenReportTemplate();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIReportTemplateTab.prototype.DoOpenReportTemplate=function(){if(!this.oReportTemplateDlg){this.oReportTemplateDlg=new CUIReportTemplateDlg(this.oDialog);var _apG=this.oReportTemplateDlg.Init(this.oDialog.oDialogMgr);if(_apG){this.oReportTemplateDlg.Display(false);}}else{this.oReportTemplateDlg.Display(true);}};CUIReportTemplateTab.prototype.GetReportTemplateSelectionPos=function(){return COTInputElementFactory.GetRadioSelectionValue("reportTemplate");};CUIReportTemplateTab.prototype.Unload=function(){Dom.RemoveObject(this._p2);Utilities.RemoveAllChildObjects(this);};CUIReportTemplateTab.kName="[@name='";CUIReportTemplateTab.prototype.GetDisplayName=function(){var _y8=this._hE.GetReportTemplate();var _5A=[];var _atA=_y8.split('/');for(var _asu=0;_asu<_atA.length;++_asu){var _E1=_atA[_asu];var _aF0=_E1.split(CUIReportTemplateTab.kName);if(_aF0.length===2){var name=_aF0[1].split("'")[0];_5A.push(name);}}return _5A.join(" > ");};function CUIPurposeTab(oDialog){this.oDialog=oDialog;};CUIPurposeTab.prototype.Show=function(){this._p2.style.display="block";};CUIPurposeTab.prototype.Hide=function(){this._p2.style.display="none";};CUIPurposeTab.prototype.Draw=function(_EP,_JE){this._hE=_JE;this._p2=_EP.appendChild(document.createElement('DIV'));var _zr=this._p2.appendChild(document.createElement('TABLE'));COTStyle.SetWidth(_zr,100,'%');var _RK=_zr.appendChild(document.createElement('TBODY'));var _asA=_RK.appendChild(document.createElement('TR'));var _atS=_asA.appendChild(this.oDialog._l4.cloneNode(false));var _aJB=this.oDialog.oRes.GetString('IDS_REPORT_OPTIONS_DLG_REPORT_OUTPUT_PURPOSE');_atS.appendChild(COTInputElementFactory.CreateLabel(_aJB));_atS.colSpan=2;var _ayV=_RK.appendChild(document.createElement('TR'));var _ajl=_ayV.appendChild(document.createElement('TD'));COTStyle.SetWidth(_ajl,5,'%');var _39=Utilities.EventCallback(CUIPurposeTab.SafeChangePrintPurpose,[this.oDialog.sAppName],this,true,true);var _65=COTInputElementFactory.CreateRadioButton("outputpurpose",ExpAPIXml.kPrintPurpose,_JE.IsForPrint(),false,_39);_ajl.appendChild(_65);var _6e=_ayV.appendChild(this.oDialog._g5.cloneNode(false));_6e.appendChild(COTInputElementFactory.CreateLabel(this.oDialog.oRes.GetString('IDS_REPORT_OPTIONS_DLG_FOR_PRINT')));var _awA=_RK.appendChild(document.createElement('TR'));var _aeG=_awA.appendChild(document.createElement('TD'));var _39=Utilities.EventCallback(CUIPurposeTab.SafeChangePrintPurpose,[this.oDialog.sAppName],this,true,true);var _au2=COTInputElementFactory.CreateRadioButton("outputpurpose",ExpAPIXml.kDrillPurpose,!_JE.IsForPrint(),false,_39);_aeG.appendChild(_au2);var _atj=_awA.appendChild(this.oDialog._g5.cloneNode(false));_atj.appendChild(COTInputElementFactory.CreateLabel(this.oDialog.oRes.GetString('IDS_REPORT_OPTIONS_DLG_FOR_DRILL')));if(this.oDialog.oDialogMgr.oUIMgr._jf.IsDisplayBreadcrumbEnabled()){var _52=_RK.appendChild(document.createElement('TR'));var _ae9=_52.appendChild(this.oDialog._l4.cloneNode(false));var _amf=this.oDialog.oRes.GetString('IDS_REPORT_OPTIONS_DLG_BREADCRUMB');_ae9.appendChild(COTInputElementFactory.CreateLabel(_amf));_ae9.colSpan=2;var _1Z=_RK.appendChild(document.createElement('TR'));var _15=_1Z.appendChild(document.createElement('TD'));this.oBreadcrumbCheckbox=COTInputElementFactory.CreateCheckBox("breadcrumb",ExpAPIXml.kTrue,_JE.GetDisplayBreadcrumb(),null,!_JE.IsForPrint());_15.appendChild(this.oBreadcrumbCheckbox);var _8C=_1Z.appendChild(this.oDialog._g5.cloneNode(false));_8C.appendChild(COTInputElementFactory.CreateLabel(this.oDialog.oRes.GetString('IDS_REPORT_OPTIONS_DLG_BREADCRUMB_DESC')));}};CUIPurposeTab.prototype.GetOutputPurpose=function(){return COTInputElementFactory.GetRadioSelectionValue("outputpurpose");};CUIPurposeTab.prototype.GetDisplayBreadcrumb=function(){var _aak=false;if(this.GetOutputPurpose()==ExpAPIXml.kPrintPurpose&&this.oBreadcrumbCheckbox){_aak=this.oBreadcrumbCheckbox.checked;}return _aak;};CUIPurposeTab.SafeChangePrintPurpose=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/var _aEk=FindApp(_Ke).uiManager.oDialogMgr._jg;if(_aEk&&_aEk.oPurposeTab){_aEk.oPurposeTab.ChangePrintPurpose();}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIPurposeTab.prototype.ChangePrintPurpose=function(){/*@if(!@bering_debug)@*/try{/*@end@*/if(this.oBreadcrumbCheckbox){if(this.GetOutputPurpose()==ExpAPIXml.kPrintPurpose){COTInputElementFactory.EnableInput(this.oBreadcrumbCheckbox);}else{this.oBreadcrumbCheckbox.checked=false;COTInputElementFactory.DisableInput(this.oBreadcrumbCheckbox);}}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIPurposeTab.prototype.Unload=function(){Dom.RemoveObject(this._p2);Utilities.RemoveAllChildObjects(this);};function CUIDispNamesTab(oDialog){this.oDialog=oDialog;this.xtabNameKey="xtabName";this.chartNameKey="chartName";};CUIDispNamesTab.prototype.Show=function(){this._p2.style.display="block";};CUIDispNamesTab.prototype.Hide=function(){this._p2.style.display="none";};CUIDispNamesTab.prototype.Draw=function(_EP,_JE){this._hE=_JE;this._p2=_EP.appendChild(document.createElement('DIV'));var _zr=this._p2.appendChild(document.createElement('TABLE'));COTStyle.SetWidth(_zr,100,'%');var _RK=_zr.appendChild(document.createElement('TBODY'));var _asA=_RK.appendChild(document.createElement('TR'));var _PX=this.oDialog.oDialogMgr.oUIMgr._jf;var _U9=_PX._my._ak;if(_PX._ca==CUIWorkSheet.eLayoutXtabOnly||_PX._ca==CUIWorkSheet.eLayoutXtabAndChart){var _ado=this._p2.appendChild(document.createElement('DIV'));COTStyle.SetHeight(_ado,15,'px');_ado.style.paddingTop="5px";var _1a=this.oDialog.oRes.GetString('IDS_REPORT_OPTIONS_DLG_CROSSTAB_NAME_LABEL');_ado.appendChild(COTInputElementFactory.CreateLabel(_1a));_ado.className="dialogText";var _ap5=_PX._my.GetViewsXtabName(true);var _55=COTInputElementFactory.CreateTextBox(90,'%',_ap5);_55.id=this.xtabNameKey;this._p2.appendChild(_55);}if(_PX._ca==CUIWorkSheet.eLayoutChartOnly||_PX._ca==CUIWorkSheet.eLayoutXtabAndChart){var _Xw=this._p2.appendChild(document.createElement('DIV'));COTStyle.SetHeight(_Xw,15,'px');var _aji=this.oDialog.oRes.GetString('IDS_REPORT_OPTIONS_DLG_CHART_NAME_LABEL');_Xw.appendChild(COTInputElementFactory.CreateLabel(_aji));_Xw.className="dialogText";if(_PX._ca==CUIWorkSheet.eLayoutXtabAndChart){_Xw.style.marginTop="20px";}else{_Xw.style.marginTop="5px";}var _aCQ=_PX._my.GetViewsChartName(true);var _ayh=COTInputElementFactory.CreateTextBox(90,'%',_aCQ);_ayh.id=this.chartNameKey;this._p2.appendChild(_ayh);}};CUIDispNamesTab.prototype.GetXtabName=function(){var _aBl=null;var el=document.getElementById(this.xtabNameKey);if(el){var _Vj=Utilities.trim(el.value);_aBl=(_Vj=="")?this.oDialog.oRes.GetString('IDS_REPORT_OPTIONS_DLG_CROSSTAB_NAME_DefValue'):_Vj;}return _aBl;};CUIDispNamesTab.prototype.GetChartName=function(){var _aBl=null;var el=document.getElementById(this.chartNameKey);if(el){var _Vj=Utilities.trim(el.value);_aBl=(_Vj=="")?this.oDialog.oRes.GetString('IDS_REPORT_OPTIONS_DLG_CHART_NAME_DefValue'):_Vj;}return _aBl;};CUIDispNamesTab.prototype.Unload=function(){var _Hk=this.oDialog.oDialogMgr.oUIMgr;if(_Hk){_Hk._jf._my.SetViewsXtabName(_Hk._jf._my.GetViewsXtabName());_Hk._jf._my.SetViewsChartName(_Hk._jf._my.GetViewsChartName());}Dom.RemoveObject(this._p2);Utilities.RemoveAllChildObjects(this);};function CUIAutoSubtotalsDlg(_Mb){this.base=CUIDialog;this.base();this._iP=_Mb?_Mb:false;};CUIAutoSubtotalsDlg.prototype=new CUIDialog;CUIAutoSubtotalsDlg.superclass=CUIDialog.prototype;CUIAutoSubtotalsDlg.prototype.Init=function(_Hy,oOwner){CUIAutoSubtotalsDlg.superclass.Init.call(this,_Hy);this.oOwner=oOwner;this.oOwner.Subscribe(this,ExpEvent.kCUIWorksheet_ChangedBlockSel);this._om=2;if(this._iP){this._yi=Utilities.GenerateCallback(this.DoSubmitAutoSubtotals,[],this);this._of=Utilities.GenerateCallback(this.DoCancel,[this.sAppName],this);}else{this._Y=Utilities.GenerateCallback(this.DoSubmitAutoSubtotals,[],this);}};CUIAutoSubtotalsDlg.prototype.Draw=function(){var _Ij=document.createElement('DIV');_Ij.className="dialogInnerDiv";this._kw=_Ij;var _zr=document.createElement('TABLE');_Ij.appendChild(_zr);this._vO=_zr;_zr.className='dialogTable';var _Ke=this.sAppName;var _RK=_zr.appendChild(document.createElement('TBODY'));this._xS=_RK;var _5u=document.createElement('TR');var _NM=_5u.appendChild(this._l4.cloneNode(false));_NM.appendChild(document.createTextNode(this.oRes.GetString('IDS_AUTO_SUBTOTALS_DLG_SHOW_CAPTION')));_RK.appendChild(_5u);_NM.colSpan=2;if(this.oHostBlock.CanApplyShowSubtotalsOnly()){var _aqr=_RK.appendChild(document.createElement('TR'));var _BM=this.oRes.GetString('IDS_AUTO_SUBTOTALS_DLG_VISIBLE_ITEMS');var _aJQ=this.oHostBlock.IsVisibleEnabled();var _agE=new CUICheckBox(_aqr,_BM,ExpAPIXml.kEleAxisOpExprShowVisible,_aJQ,null,false);this._rm=_agE.elCheckBox.id;}var _aqr=_RK.appendChild(document.createElement('TR'));var _amr=_aqr.appendChild(document.createElement('TD'));_amr.className="CheckBoxText";COTStyle.SetWidth(_amr,20);var _api=COTInputElementFactory.CreateImage('check.gif',16,16);_amr.appendChild(_api);_amr=_aqr.appendChild(document.createElement('TD'));_amr.className="CheckBoxText";_amr.appendChild(COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_AUTO_SUBTOTALS_DLG_CALCULATED_ITEMS')));if(this.oHostBlock.CanApplySubtotalVisibleItems()){var _aqr=_RK.appendChild(document.createElement('TR'));var _BM=this.oRes.GetString('IDS_AUTO_SUBTOTALS_DLG_SUBTOTAL_VISIBLE_ITEMS');var _aJQ=this.oHostBlock.IsSubTotalEnabled();var _agE=new CUICheckBox(_aqr,_BM,ExpAPIXml.kEleAxisOpExprSubTotal,_aJQ,null,false);COTStyle.SetWidth(_agE.elTextTD,45,'%');this._oD=_agE.elCheckBox.id;}if(this.oHostBlock.CanApplyRemainder()){var _aqr=_RK.appendChild(document.createElement('TR'));var _BM=this.oRes.GetString('IDS_AUTO_SUBTOTALS_DLG_OTHER');var _aJQ=this.oHostBlock.IsRemainderEnabled();var _agE=new CUICheckBox(_aqr,_BM,ExpAPIXml.kEleAxisOpExprRemainder,_aJQ,null,false);this._B=_agE.elCheckBox.id;}if(this.oHostBlock.CanApplyFilterSubtotals()){var _aqr=_RK.appendChild(document.createElement('TR'));var _BM=this.oRes.ReplaceParam('IDS_AUTO_SUBTOTALS_DLG_INCLUDED',1,this.oRes.GetString('IDS_PASSED_FILTER_SUBTOTAL_LABEL'));_BM=this.oRes.ReplaceParam(_BM,2,this.oRes.GetString('IDS_CROSSTAB_SUBTOTAL_INCLUDED_TOOLTIP'));var _aJQ=this.oHostBlock.IsPassedFilterAggregateEnabled();var _agE=new CUICheckBox(_aqr,_BM,ExpAPIXml.kEleAxisOpExprPassedFilterAggr,_aJQ,null,false);this._rc=_agE.elCheckBox.id;var _aqr=_RK.appendChild(document.createElement('TR'));var _BM=this.oRes.ReplaceParam('IDS_AUTO_SUBTOTALS_DLG_EXCLUDED',1,this.oRes.GetString('IDS_FILTER_SUBTOTAL_LABEL'));_BM=this.oRes.ReplaceParam(_BM,2,this.oRes.GetString('IDS_CROSSTAB_SUBTOTAL_EXCLUDED_TOOLTIP'));var _aJQ=this.oHostBlock.IsFilterAggregateEnabled();var _agE=new CUICheckBox(_aqr,_BM,ExpAPIXml.kEleAxisOpExprFilterAggr,_aJQ,null,false);this._pU=_agE.elCheckBox.id;}if(this.oHostBlock.CanApplySummary()){var _aqr=_RK.appendChild(document.createElement('TR'));var _BM=this.oRes.GetString('IDS_AUTO_SUBTOTALS_DLG_TOTAL');var _aJQ=this.oHostBlock.ShowSummary();var _agE=new CUICheckBox(_aqr,_BM,ExpAPIXml.kEleAxisOpExprSummary,_aJQ,null,false);this._f2=_agE.elCheckBox.id;}COTStyle.SetWidth(_agE.elTextTD,95,'%');};CUIAutoSubtotalsDlg.prototype.SetHostObj=function(_FK){this.oHostBlock=_FK;this._eB=this.oHostBlock.GetLabel();};CUIAutoSubtotalsDlg.prototype.Notify=function(_Dy){if(_Dy==ExpEvent.kCUIWorksheet_ChangedBlockSel){if(this._iP&&this._r3){this.DoCancel(this.sAppName);return;}else if(this._r3&&this.oOwner.GetSelectedBlock()&&this.oOwner.GetSelectedBlock().CanApplyAutoSubtotals()){this.SetHostObj(this.oOwner.GetSelectedBlock());this.Display();}else if(this._r3){var _M3=true;this.Display(_M3);}}};CUIAutoSubtotalsDlg.prototype.Display=function(_M3){var _Co=this.oDialogMgr.oUIMgr.appobj.oResources;var _Ke=this.sAppName;var _MY=new Object();var _Xf=Utilities.GenerateCallback(CUIManager.SafeDoHelpTopic,[_Ke,HelpConstants.kAutoSubtotalsLink]);_MY['IDS_HELP']=_Xf;if(_M3){var _Li=this.oDialogMgr.oUIMgr.dataManager.GetCurrentDataMatrix();var _W7=_Li.GetAllBlocksArray();var _Nk=new Array();for(var i=0;i<_W7.length;i++){if(_W7[i].CanApplyAutoSubtotals()){_Nk.push(_W7[i]);}}var _aJh=false;this._eB=null;var _Ua='IDS_SELECTION_DLG_PICK_OTHER_SET_SUBTOTALS_SECOND_MSG';this.DisplayInvalidSelection('IDS_AUTO_SUBTOTALS_DLG_TITLE',_MY,_Nk,_Li,'SUBTOTALS',_aJh,_Ua);}else{this.Draw();CUIAutoSubtotalsDlg.superclass.Display.call(this,'IDS_AUTO_SUBTOTALS_DLG_TITLE',_MY,this._kw,'');}};CUIAutoSubtotalsDlg.prototype.DoCancel=function(_Ke){if(this.oHostBlock._hu){Utilities.ClearObjectArray(this.oHostBlock._hu);this.oHostBlock._hu=null;}CUIDialogMgr.SafeHideCurrentDialog(_Ke);};CUIAutoSubtotalsDlg.prototype.DoSubmitAutoSubtotals=function(){var _Le=true;var _VI=new Array();var _Mb=this._iP;var _6m=document.getElementById(this._rm);if(_6m){if(this._iP){this.oHostBlock._hu[CUIAutoSummaryProperty.kShowVisible]=_6m.checked;}else{_VI.push(this.oHostBlock.SetProperty(ExpAPIXml.kEleAxisOpExprShowVisible,_6m.checked,_Le));}}var _agX=document.getElementById(this._oD);if(_agX){if(this._iP){this.oHostBlock._hu[CUIAutoSummaryProperty.kVisibleSubtotal]=_agX.checked;}else{_VI.push(this.oHostBlock.SetProperty(ExpAPIXml.kEleAxisOpExprSubTotal,_agX.checked,_Le));}}var _adR=document.getElementById(this._B);if(_adR){if(this._iP){this.oHostBlock._hu[CUIAutoSummaryProperty.kOther]=_adR.checked;}else{_VI.push(this.oHostBlock.SetProperty(ExpAPIXml.kEleAxisOpExprRemainder,_adR.checked,_Le));}}if(!this.oHostBlock.IsChildrenMeasureBlock()){var _2t=document.getElementById(this._rc);if(this._iP){this.oHostBlock._hu[CUIAutoSummaryProperty.kIncluded]=_2t.checked;}else{_VI.push(this.oHostBlock.SetProperty(ExpAPIXml.kEleAxisOpExprPassedFilterAggr,_2t.checked,_Le));}var _aEC=document.getElementById(this._pU);if(this._iP){this.oHostBlock._hu[CUIAutoSummaryProperty.kExcluded]=_aEC.checked;}else{_VI.push(this.oHostBlock.SetProperty(ExpAPIXml.kEleAxisOpExprFilterAggr,_aEC.checked,_Le));}}var _Xl=document.getElementById(this._f2);if(this._iP){this.oHostBlock._hu[CUIAutoSummaryProperty.kTotal]=_Xl.checked;}else{_VI.push(this.oHostBlock.SetProperty(ExpAPIXml.kEleAxisOpExprSummary,_Xl.checked,_Le));}if(!this._iP){this.oHostBlock.oAxis._rk.SendDMActionArray(_VI);this.oDialogMgr.oUIMgr._jf.SetLastBlockSelectionId(this.oHostBlock.GetId());}CUIDialogMgr.SafeHideCurrentDialog(this.sAppName);};function CUIGlobalAutoSubtotalsDlg(){this.base=CUIDialog;this.base();};CUIGlobalAutoSubtotalsDlg.prototype=new CUIDialog;CUIGlobalAutoSubtotalsDlg.superclass=CUIDialog.prototype;CUIGlobalAutoSubtotalsDlg.prototype.Init=function(_Hy){CUIAutoSubtotalsDlg.superclass.Init.call(this,_Hy);this._om=2;this._Y=Utilities.GenerateCallback(this.DoSubmitAutoSubtotals,[],this);this._eB=this.oRes.GetString('IDS_AUTO_SUBTOTALS_DLG_ALL_SETS');};CUIGlobalAutoSubtotalsDlg.prototype.SetHostObj=function(){this._hE=this.oDialogMgr.oUIMgr.dataManager._kX.Clone();};CUIGlobalAutoSubtotalsDlg.prototype.Draw=function(){var _Ij=document.createElement('DIV');_Ij.className="dialogInnerDiv";this._kw=_Ij;var _zr=document.createElement('TABLE');_Ij.appendChild(_zr);this._vO=_zr;_zr.className='dialogTable';var _Ke=this.sAppName;var _RK=_zr.appendChild(document.createElement('TBODY'));this._xS=_RK;var _5u=document.createElement('TR');var _NM=_5u.appendChild(this._l4.cloneNode(false));_NM.colSpan=2;COTStyle.SetWidth(_NM,100,'%');_NM.appendChild(document.createTextNode(this.oRes.GetString("IDS_AUTO_SUBTOTALS_DLG_SHOW_CAPTION")));_RK.appendChild(_5u);var _aqr=_RK.appendChild(document.createElement('TR'));var _amr=_aqr.appendChild(document.createElement('TD'));_amr.className="CheckBoxText";var _api=COTInputElementFactory.CreateImage('check.gif',16,16);_amr.appendChild(_api);_amr=_aqr.appendChild(document.createElement('TD'));_amr.className="CheckBoxText";_amr.appendChild(COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_AUTO_SUBTOTALS_DLG_VISIBLE_ITEMS')));var _aqr=_RK.appendChild(document.createElement('TR'));var _amr=_aqr.appendChild(document.createElement('TD'));_amr.className="CheckBoxText";COTStyle.SetWidth(_amr,20);var _api=COTInputElementFactory.CreateImage('check.gif',16,16);_amr.appendChild(_api);_amr=_aqr.appendChild(document.createElement('TD'));_amr.className="CheckBoxText";_amr.appendChild(COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_AUTO_SUBTOTALS_DLG_CALCULATED_ITEMS')));var _aqr=_RK.appendChild(document.createElement('TR'));var _BM=this.oRes.GetString('IDS_AUTO_SUBTOTALS_DLG_SUBTOTAL_VISIBLE_ITEMS');var _aJQ=this._hE.IsSubTotalEnabled();var _agE=new CUICheckBox(_aqr,_BM,ExpAPIXml.kAttrSubTotal,_aJQ,null,false);this._oD=_agE.elCheckBox.id;var _aqr=_RK.appendChild(document.createElement('TR'));var _BM=this.oRes.GetString('IDS_AUTO_SUBTOTALS_DLG_OTHER_GLOBAL');var _aJQ=this._hE.IsRemainderEnabled();var _agE=new CUICheckBox(_aqr,_BM,ExpAPIXml.kEleAxisOpExprRemainder,_aJQ,null,false);this._B=_agE.elCheckBox.id;var _ahc=document.createElement('SPAN');this._vD=Utilities.GenerateId();_ahc.id=this._vD;_ahc.className=Dom.GetStyleByBrowser("BlockPropertiesText");var _Hd=(this._hE.GetRemainderMode()==ExpAPIXml.kNullRemainderMode)?'IDS_AUTO_SUBTOTALS_DLG_OTHER_VALUE_SETTING_NOT_SHOW':'IDS_AUTO_SUBTOTALS_DLG_OTHER_VALUE_SETTING_SHOW';_ahc.appendChild(document.createTextNode(this.oRes.GetString(_Hd)));var _azP=document.createElement('IMG');_azP.className='prop_dropdown_arrow';_ahc.appendChild(_azP);_azP.src=Utilities.IMG_PATH+'ComboBoxArrow.gif';Dom.SetObjRef(_azP,this,'oDlg');_azP.onclick=CUIGlobalAutoSubtotalsDlg.SafeHandleDropDownClick;COTStyle.SetSize(_azP,CUIAbsBlockProperty.kArrowWidth,CUIAbsBlockProperty.kArrowHeight);this.oArrowImg=_azP;var re=this.oRes.GetParameterForReplace(1);COTInputElementFactory.InsertTextBoxIntoLabelSpan(_agE.elTextTD,_ahc,_BM,re);var _aqr=_RK.appendChild(document.createElement('TR'));var _BM=this.oRes.ReplaceParam('IDS_AUTO_SUBTOTALS_DLG_INCLUDED',1,this.oRes.GetString('IDS_PASSED_FILTER_SUBTOTAL_LABEL'));_BM=this.oRes.ReplaceParam(_BM,2,this.oRes.GetString('IDS_CROSSTAB_SUBTOTAL_INCLUDED_TOOLTIP'));var _aJQ=this._hE.IsPassedFilterAggregateEnabled();var _agE=new CUICheckBox(_aqr,_BM,ExpAPIXml.kEleAxisOpExprPassedFilterAggr,_aJQ,null,false);this._rc=_agE.elCheckBox.id;var _aqr=_RK.appendChild(document.createElement('TR'));var _BM=this.oRes.ReplaceParam('IDS_AUTO_SUBTOTALS_DLG_EXCLUDED',1,this.oRes.GetString('IDS_FILTER_SUBTOTAL_LABEL'));_BM=this.oRes.ReplaceParam(_BM,2,this.oRes.GetString('IDS_CROSSTAB_SUBTOTAL_EXCLUDED_TOOLTIP'));var _aJQ=this._hE.IsFilterAggregateEnabled();var _agE=new CUICheckBox(_aqr,_BM,ExpAPIXml.kEleAxisOpExprFilterAggr,_aJQ,null,false);this._pU=_agE.elCheckBox.id;var _aqr=_RK.appendChild(document.createElement('TR'));var _BM=this.oRes.GetString('IDS_AUTO_SUBTOTALS_DLG_TOTAL');var _aJQ=this._hE.ShowSummary();var _agE=new CUICheckBox(_aqr,_BM,ExpAPIXml.kEleAxisOpExprSummary,_aJQ,null,false);this._f2=_agE.elCheckBox.id;COTStyle.SetWidth(_agE.elTextTD,95,'%');};CUIGlobalAutoSubtotalsDlg.prototype.Display=function(){var _Co=this.oDialogMgr.oUIMgr.appobj.oResources;var _Ke=this.sAppName;var _MY=new Object();var _Xf=Utilities.GenerateCallback(CUIManager.SafeDoHelpTopic,[_Ke,HelpConstants.kAutoSubtotalsLink]);_MY['IDS_HELP']=_Xf;this.Draw();CUIAutoSubtotalsDlg.superclass.Display.call(this,'IDS_AUTO_SUBTOTALS_DLG_TITLE',_MY,this._kw,'IDS_AUTO_SUBTOTALS_DLG_GLOBAL_INSTR_TEXT');};CUIGlobalAutoSubtotalsDlg.prototype.DoSubmitAutoSubtotals=function(){var _aAa=document.getElementById(this._oD);this._hE.SetSubTotal(_aAa.checked);var _adR=document.getElementById(this._B);this._hE.SetRemainder(_adR.checked);var _2t=document.getElementById(this._rc);this._hE.SetPassedFilterAggregateEnabled(_2t.checked);var _aEC=document.getElementById(this._pU);this._hE.SetFilterAggregateEnabled(_aEC.checked);var _Xl=document.getElementById(this._f2);this._hE.SetSummary(_Xl.checked);this.oDialogMgr.oUIMgr.dataManager._kX.ModifyGlobalSubtotals(this._hE);CUIDialogMgr.SafeHideCurrentDialog(this.sAppName);};CUIGlobalAutoSubtotalsDlg.SafeHandleDropDownClick=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}var _Qb=Dom.GetRelativeOffset(this.oDlg.oArrowImg,document.body);var x=_Qb.iLeft+COTStyle.GetDisplayOffsetWidth(this.oDlg.oArrowImg);var y=_Qb.iTop+COTStyle.GetDisplayOffsetHeight(this.oDlg.oArrowImg);this.oDlg.ShowDropDown(e,x,y);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIGlobalAutoSubtotalsDlg.prototype.ShowDropDown=function(e,x,y){var _Ke=this.sAppName;var _Kk=new CUIContextMenu(_Ke,0,this);_Kk.SetUnloadOnHide(true);var _Jj=CUIGlobalAutoSubtotalsDlg.SafeDoSetRemainderMode;var _AG=new Array(_Ke,ExpAPIXml.kNullRemainderMode);var _BM=this.oRes.GetString('IDS_AUTO_SUBTOTALS_DLG_OTHER_VALUE_SETTING_NOT_SHOW');var _PM=new ContextItem("",_BM,_Jj,false,_AG,_Kk);_PM.SetRadioState(this._hE.GetRemainderMode()==ExpAPIXml.kNullRemainderMode);_AG=new Array(_Ke,ExpAPIXml.kSubtractRemainderMode);_BM=this.oRes.GetString('IDS_AUTO_SUBTOTALS_DLG_OTHER_VALUE_SETTING_SHOW');var _PM=new ContextItem("",_BM,_Jj,false,_AG,_Kk);_PM.SetRadioState(!(this._hE.GetRemainderMode()==ExpAPIXml.kNullRemainderMode));_Kk.SetChildrenComplete();_Kk.display(e,true,x,y);};CUIGlobalAutoSubtotalsDlg.SafeDoSetRemainderMode=function(_Ke,_Sv){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager.oDialogMgr._jg.UpdateRemainderMode(_Sv);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIGlobalAutoSubtotalsDlg.prototype.UpdateRemainderMode=function(_Sv){this._hE.SetRemainderMode(_Sv);var _Hd=(_Sv==ExpAPIXml.kNullRemainderMode)?'IDS_AUTO_SUBTOTALS_DLG_OTHER_VALUE_SETTING_NOT_SHOW':'IDS_AUTO_SUBTOTALS_DLG_OTHER_VALUE_SETTING_SHOW';var _ahc=document.getElementById(this._vD);Dom.ReplaceTextNode(_ahc,this.oRes.GetString(_Hd));};function CUIDataFormatDlg(){this.base=CUIDialog;this.base();this.oHostAnalysis=null;};CUIDataFormatDlg.prototype=new CUIDialog;CUIDataFormatDlg.superclass=CUIDialog.prototype;CUIDataFormatDlg.prototype.Init=function(_yt){CUIDataFormatDlg.superclass.Init.call(this,_yt);};CUIDataFormatDlg.prototype.Display=function(){var _Co=this.oDialogMgr.oUIMgr.appobj.oResources;var _Ke=this.sAppName;var _MY=new Object();var _Xf=Utilities.GenerateCallback(CUIManager.SafeDoHelpTopic,[_Ke,HelpConstants.kDataFormatLink]);_MY['IDS_HELP']=_Xf;CUIDataFormatDlg.superclass.Display.call(this,'IDS_DATA_FORMAT_DLG_TITLE',_MY,this._lq,'IDS_DATA_FORMAT_DLG_INSTRUCT');};CUIDataFormatDlg.prototype.ClearDlg=function(){this.prevTarget=null;this._uf=null;this._sO=null;this._xa=null;this._s2=null;this._wD=null;this._kd=null;this._fU=null;};CUIDataFormatDlg.prototype.SetHostObj=function(_JE){this.oHostAnalysis=_JE;};CUIDataFormatDlg.prototype.Create=function(){this.ClearDlg();var _Ke=this.sAppName;var _zr=document.createElement('TABLE');_zr.className='dialogTable';var _F0=document.createElement('TBODY');var _NH=document.createElement('TR');var _NM=this._l4.cloneNode(false);COTStyle.SetWidth(_NM,65,'%');var _apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_DATA_FORMAT_GENERAL_PROPERTIES'));_NM.appendChild(_apS);_NH.appendChild(_NM);_NM=this._l4.cloneNode(false);COTStyle.SetWidth(_NM,35,'%');_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_DATA_FORMAT_INFORMATION'));_NM.appendChild(_apS);_NH.appendChild(_NM);_F0.appendChild(_NH);_NH=document.createElement('TR');_NM=document.createElement('TD');_NM.className='formatEditArea';COTStyle.SetWidth(_NM,65,'%');var _ahN=document.createElement('TABLE');COTStyle.SetWidth(_ahN,90,'%');var _HC=document.createElement('TBODY');_ahN.appendChild(_HC);_NM.appendChild(_ahN);_NH.appendChild(_NM);_F0.appendChild(_NH);_ahN.className="pagerCtrlTBL";var _aqH=document.createElement('TR');_HC.appendChild(_aqH);var _aqM=document.createElement('TD');_aqM.className='pagerCtrlTBLTD';_aqM.id=ExpAPIXml.kEleWhenMissing;Dom.SetObjRef(_aqM,this,'oDialog');_aqM.onmousedown=CUIDataFormatDlg.SafeHandleMouseDown;var _asp=this.CreateLabelEle(_aqM,this.oRes.GetString('IDS_DATA_FORMAT_MISSING_VALUE_CHARACTERS'));_aqM.appendChild(_asp);_aqH.appendChild(_aqM);_aqM=document.createElement('TD');_aqM.className='pagerCtrlTBLTD';COTStyle.SetHeight(_aqM,20);var _asz=this.CreateTextBoxEle(_aqM,this.oHostAnalysis.GetWhenMissing());this._uf="WhenMissing"+Utilities.GenerateId();_asz.id=this._uf;_aqM.appendChild(_asz);_aqH.appendChild(_aqM);var _aqH=document.createElement('TR');_HC.appendChild(_aqH);var _aqM=document.createElement('TD');_aqM.className='pagerCtrlTBLTD';_aqM.id=ExpAPIXml.kEleWhenZero;Dom.SetObjRef(_aqM,this,'oDialog');_aqM.onmousedown=CUIDataFormatDlg.SafeHandleMouseDown;var _asp=this.CreateLabelEle(_aqM,this.oRes.GetString('IDS_DATA_FORMAT_ZERO_VALUE_CHARACTERS'));_aqM.appendChild(_asp);_aqH.appendChild(_aqM);_aqM=document.createElement('TD');_aqM.className='pagerCtrlTBLTD';COTStyle.SetHeight(_aqM,20);var _aIc=this.CreateTextBoxEle(_aqM,this.oHostAnalysis.GetWhenZero());this._sO="WhenZero"+Utilities.GenerateId();_aIc.id=this._sO;_aqM.appendChild(_aIc);_aqH.appendChild(_aqM);_aqH=document.createElement('TR');_HC.appendChild(_aqH);_aqM=document.createElement('TD');_aqM.className='pagerCtrlTBLTD';_aqM.id=ExpAPIXml.kEleWhenDivideZero;Dom.SetObjRef(_aqM,this,'oDialog');_aqM.onmousedown=CUIDataFormatDlg.SafeHandleMouseDown;var _asp=this.CreateLabelEle(_aqM,this.oRes.GetString('IDS_DATA_FORMAT_DIVIDE_BY_ZERO_CHARACTERS'));_aqM.appendChild(_asp);_aqH.appendChild(_aqM);_aqM=document.createElement('TD');_aqM.className='pagerCtrlTBLTD';COTStyle.SetHeight(_aqM,20);var _4Y=this.CreateTextBoxEle(_aqM,this.oHostAnalysis.GetWhenDivideZero());this._xa="WhenDivideZero"+Utilities.GenerateId();_4Y.id=this._xa;_aqM.appendChild(_4Y);_aqH.appendChild(_aqM);_aqH=document.createElement('TR');_HC.appendChild(_aqH);_aqM=this._g5.cloneNode(false);_aqM=document.createElement('TD');_aqM.className='pagerCtrlTBLTD';_aqM.id=ExpAPIXml.kEleWhenNumericOverflow;_aqM.onmousedown=CUIDataFormatDlg.SafeHandleMouseDown;Dom.SetObjRef(_aqM,this,'oDialog');var _asp=this.CreateLabelEle(_aqM,this.oRes.GetString('IDS_DATA_FORMAT_NUMERIC_OVERFLOW_CHARACTERS'));_aqM.appendChild(_asp);_aqH.appendChild(_aqM);_aqM=document.createElement('TD');_aqM.className='pagerCtrlTBLTD';COTStyle.SetHeight(_aqM,20);var _aFH=this.CreateTextBoxEle(_aqM,this.oHostAnalysis.GetWhenNumericOverflow());this._s2="WhenNumericOverflow"+Utilities.GenerateId();_aFH.id=this._s2;_aqM.appendChild(_aFH);_aqH.appendChild(_aqM);_aqH=document.createElement('TR');_HC.appendChild(_aqH);_aqM=document.createElement('TD');_aqM.className='pagerCtrlTBLTD';_aqM.id=ExpAPIXml.kEleWhenNotApplicable;Dom.SetObjRef(_aqM,this,'oDialog');_aqM.onmousedown=CUIDataFormatDlg.SafeHandleMouseDown;var _asp=this.CreateLabelEle(_aqM,this.oRes.GetString('IDS_DATA_FORMAT_NOT_APPLICABLE_CHARACTERS'));_aqM.appendChild(_asp);_aqH.appendChild(_aqM);_aqM=document.createElement('TD');_aqM.className='pagerCtrlTBLTD';COTStyle.SetHeight(_aqM,20);var _ai4=this.CreateTextBoxEle(_aqM,this.oHostAnalysis.GetWhenNotApplicable());this._wD="WhenNotApplicable"+Utilities.GenerateId();_ai4.id=this._wD;_aqM.appendChild(_ai4);_aqH.appendChild(_aqM);_aqH=document.createElement('TR');_HC.appendChild(_aqH);var _aqM=document.createElement('TD');_aqM.className='pagerCtrlTBLTD';_aqM.id=ExpAPIXml.kEleWhenSecurityError;Dom.SetObjRef(_aqM,this,'oDialog');_aqM.onmousedown=CUIDataFormatDlg.SafeHandleMouseDown;var _asp=this.CreateLabelEle(_aqM,this.oRes.GetString('IDS_DATA_FORMAT_SECURITY_ERROR_CHARACTERS'));_aqM.appendChild(_asp);_aqH.appendChild(_aqM);_aqM=document.createElement('TD');_aqM.className='pagerCtrlTBLTD';COTStyle.SetHeight(_aqM,20);var _24=this.CreateTextBoxEle(_aqM,this.oHostAnalysis.GetWhenSecurityError());this._kd="WhenSecurityError"+Utilities.GenerateId();_24.id=this._kd;_aqM.appendChild(_24);_aqH.appendChild(_aqM);_aqH=document.createElement('TR');_HC.appendChild(_aqH);_aqM=document.createElement('TD');_aqM.className='pagerCtrlTBLTD';_aqM.id=ExpAPIXml.kEleWhenAnyError;Dom.SetObjRef(_aqM,this,'oDialog');_aqM.onmousedown=CUIDataFormatDlg.SafeHandleMouseDown;var _asp=this.CreateLabelEle(_aqM,this.oRes.GetString('IDS_DATA_FORMAT_ALL_ERROR_TYPE_CHARACTERS'));_aqM.appendChild(_asp);_aqH.appendChild(_aqM);_aqM=document.createElement('TD');_aqM.className='pagerCtrlTBLTD';COTStyle.SetHeight(_aqM,20);var _acN=this.CreateTextBoxEle(_aqM,this.oHostAnalysis.GetWhenAnyError());this._fU="WhenAnyError"+Utilities.GenerateId();_acN.id=this._fU;_aqM.appendChild(_acN);_aqH.appendChild(_aqM);_aqH=document.createElement('TR');_HC.appendChild(_aqH);_aqM=document.createElement('TD');_aqM.className='pagerCtrlTBLTD';var _asp=this.CreateLabelEle(_aqM,'');_aqM.appendChild(_asp);_aqH.appendChild(_aqM);_aqM=document.createElement('TD');_aqM.className='pagerCtrlTBLTD';COTStyle.SetHeight(_aqM,20);COTStyle.SetWidth(_aqM,60,'%');var _Yk=COTInputElementFactory.CreateTextBox(204,'px','',true,null,null,null,this);_aqM.appendChild(_Yk);_Yk.style.border="0px";_aqH.appendChild(_aqM);_NM=document.createElement('TD');COTStyle.SetWidth(_NM,35,'%');var _U4=2;this._xh=COTInputElementFactory.CreateTextArea(14,40,'',false);this._xh.readOnly=true;this._xh.style.backgroundColor="#FEFEE1";_NM.appendChild(this._xh);_NH.appendChild(_NM);_F0.appendChild(_NH);_NH=document.createElement('TR');_NM=this._gM.cloneNode(false);_NM.style.textAlign="right";_NM.style.paddingRight="6%";var _4v=Utilities.GenerateCallback(this.ResetDefaultSettings,[],this);_apS=COTInputElementFactory.CreateLink(_4v,this.oRes.GetString('IDS_DATA_FORMAT_RESET'),true);_apS.id=Utilities.GenerateId();this._iD=_apS.id;_NM.appendChild(_apS);_NH.appendChild(_NM);_F0.appendChild(_NH);this._Y=Utilities.GenerateCallback(this.OnFormatOK,[],this);this._om=4;_zr.appendChild(_F0);this._lq=_zr;};CUIDataFormatDlg.SafeHandleMouseDown=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/this.oDialog.HandleMouseDown(e);/*@if(!@bering_debug)@*/}catch(excep){_f.HandleException(excep);}/*@end@*/};CUIDataFormatDlg.prototype.HandleMouseDown=function(e){if(!e){e=window.event;}if(this.prevTarget){this.prevTarget.className='pagerCtrlTBLTD';}var _N9=Dom.GetEventTarget(e);_N9.className="pagerCtrlTBLTD_selected";switch(_N9.id){case ExpAPIXml.kEleWhenMissing:this._xh.value=this.oRes.GetString('IDS_DATA_FORMAT_MISSING_VALUE_INFORMATION');break;case ExpAPIXml.kEleWhenZero:this._xh.value=this.oRes.GetString('IDS_DATA_FORMAT_ZERO_VALUE_INFORMATION');break;case ExpAPIXml.kEleWhenSecurityError:this._xh.value=this.oRes.GetString('IDS_DATA_FORMAT_SECURITY_ERROR_INFORMATION');break;case ExpAPIXml.kEleWhenNotApplicable:this._xh.value=this.oRes.GetString('IDS_DATA_FORMAT_NOT_APPLICABLE_INFORMATION');break;case ExpAPIXml.kEleWhenAnyError:this._xh.value=this.oRes.GetString('IDS_DATA_FORMAT_ALL_ERROR_TYPE_INFORMATION');break;case ExpAPIXml.kEleWhenDivideZero:this._xh.value=this.oRes.GetString('IDS_DATA_FORMAT_DIVIDE_BY_ZERO_INFORMATION');break;case ExpAPIXml.kEleWhenNumericOverflow:this._xh.value=this.oRes.GetString('IDS_DATA_FORMAT_NUMERIC_OVERFLOW_INFORMATION');break;}this.prevTarget=_N9;};CUIDataFormatDlg.prototype.ResetDefaultSettings=function(){var _asz=document.getElementById(this._uf);_asz.value='';var _aIc=document.getElementById(this._sO);_aIc.value='';var _4Y=document.getElementById(this._xa);_4Y.value='';var _aFH=document.getElementById(this._s2);_aFH.value='';var _ai4=document.getElementById(this._wD);_ai4.value='';var _24=document.getElementById(this._kd);_24.value='';var _acN=document.getElementById(this._fU);_acN.value='';};CUIDataFormatDlg.prototype.CreateLabelEle=function(_Um,_BM){COTStyle.SetHeight(_Um,20);COTStyle.SetWidth(_Um,40,'%');var _apS=COTInputElementFactory.CreateLabel(_BM);return _apS;};CUIDataFormatDlg.prototype.CreateTextBoxEle=function(_R3,_Mr){COTStyle.SetWidth(_R3,60,'%');var _F3=_Mr?_Mr:"";var _aD7=COTInputElementFactory.CreateTextBox(90,'%',_F3);_aD7.style.border="0px";_aD7.style.fontSize='100%';return _aD7;};CUIDataFormatDlg.prototype.GetWhenMissing=function(){var _asz=document.getElementById(this._uf);return _asz.value;};CUIDataFormatDlg.prototype.GetWhenZero=function(){var _aIc=document.getElementById(this._sO);return _aIc.value;};CUIDataFormatDlg.prototype.GetWhenDivideZero=function(){var _4Y=document.getElementById(this._xa);return _4Y.value;};CUIDataFormatDlg.prototype.GetWhenNumericOverflow=function(){var _aFH=document.getElementById(this._s2);return _aFH.value;};CUIDataFormatDlg.prototype.GetWhenNotApplicable=function(){var _ai4=document.getElementById(this._wD);return _ai4.value;};CUIDataFormatDlg.prototype.GetWhenSecurityError=function(){var _24=document.getElementById(this._kd);return _24.value;};CUIDataFormatDlg.prototype.GetWhenAnyError=function(){var _acN=document.getElementById(this._fU);return _acN.value;};CUIDataFormatDlg.prototype.OnFormatOK=function(){var _CK=this.oHostAnalysis.Clone();_CK.SetWhenMissing(this.GetWhenMissing());_CK.SetWhenZero(this.GetWhenZero());_CK.SetWhenDivideZero(this.GetWhenDivideZero());_CK.SetWhenNumericOverflow(this.GetWhenNumericOverflow());_CK.SetWhenNotApplicable(this.GetWhenNotApplicable());_CK.SetWhenSecurityError(this.GetWhenSecurityError());_CK.SetWhenAnyError(this.GetWhenAnyError());this.oHostAnalysis.Modify(_CK);CUIDialogMgr.SafeHideCurrentDialog(this.sAppName);};CUIDataFormatDlg.prototype.UnLoad=function(){Dom.RemoveAllChildren(this._vO);CUIDataFormatDlg.superclass.Unload.call(this);};function CUISetBasedCalcDlg(){this.base=CUIDialog;this.base();};CUISetBasedCalcDlg.prototype=new CUIDialog;CUISetBasedCalcDlg.superclass=CUIDialog.prototype;CUISetBasedCalcDlg.prototype.Init=function(_Hy,oOwner){CUISetBasedCalcDlg.superclass.Init.call(this,_Hy);this.oOwner=oOwner;this.oOwner.Subscribe(this,ExpEvent.kCUIWorksheet_ChangedBlockSel);this.Draw();};CUISetBasedCalcDlg.prototype.Draw=function(){var _zr=document.createElement('TABLE');this._vO=_zr;_zr.className='dialogTable';this._vO.style.paddingBottom="20px";var _Ke=this.sAppName;var _RK=_zr.appendChild(document.createElement('TBODY'));this._xS=_RK;var _5u=document.createElement('TR');var _NM=_5u.appendChild(this._l4.cloneNode(false));_NM.appendChild(document.createTextNode(this.oRes.GetString('IDS_SET_BASED_CALCS_DLG_ADD_CAPTION')));_RK.appendChild(_5u);_NM.style.paddingTop="10px";var _atd=document.createElement('TR');this._aa=new CUIListCtrl(this.oDialogMgr.oUIMgr);this._aa.iMaxHeight=150;this._aa.Init();this._aa.DisableHAutoScroll();_BM=this.oRes.GetString('IDS_SET_BASED_CALCS_DLG_SUM');var _aFI=this._aa.AddItem('',_BM,0,ExpAPIXml.kSumFunc,"",true);var _BM=this.oRes.GetString('IDS_SET_BASED_CALCS_DLG_AVG');this._aa.AddItem('',_BM,0,ExpAPIXml.kAvgFunc,"",false);_BM=this.oRes.GetString('IDS_SET_BASED_CALCS_DLG_MAX');this._aa.AddItem('',_BM,0,ExpAPIXml.kMaxFunc,"",false);_BM=this.oRes.GetString('IDS_SET_BASED_CALCS_DLG_MIN');this._aa.AddItem('',_BM,0,ExpAPIXml.kMinFunc,"",false);_BM=this.oRes.GetString('IDS_SET_BASED_CALCS_DLG_MED');this._aa.AddItem('',_BM,0,ExpAPIXml.kMedianFunc,"",false);_BM=this.oRes.GetString('IDS_SET_BASED_CALCS_DLG_VAR');this._aa.AddItem('',_BM,0,ExpAPIXml.kVarFunc,"",false);_BM=this.oRes.GetString('IDS_SET_BASED_CALCS_DLG_STDDEV');this._aa.AddItem('',_BM,0,ExpAPIXml.kStddevFunc,"",false);_BM=this.oRes.GetString('IDS_SET_BASED_CALCS_DLG_COUNT');this._aa.AddItem('',_BM,0,ExpAPIXml.kCountFunc,"",false);_NM=_atd.appendChild(document.createElement('TD'));_RK.appendChild(_atd);this._aj=new CUIComboBox(this.oDialogMgr.oUIMgr,this._aa);this._aj.DisableIcon();var _afs=_NM.appendChild(this._aj.Init());COTStyle.SetHeight(_atd,COTStyle.GetDisplayOffsetHeight(_afs));this._aj.SetWidth(50,'%');this._aj.SetValueFromListItem(_aFI,false);var _aCy=_RK.appendChild(document.createElement('TR'));COTStyle.SetHeight(_aCy,10);this._om=2;this._Y=Utilities.GenerateCallback(this.DoSubmitSetBasedCalc,[],this);};CUISetBasedCalcDlg.prototype.DoSubmitSetBasedCalc=function(){var _aDQ=this._aj.GetValue();var _aEr=CUIWorkSheet.CreateSetBasedCalcExpr(_aDQ,this.oHostBlock,this.oRes);_aEr._rB.CreateMathMLCalcExpr(_aEr._p8,_aEr._ni,_aEr._p8);this.oDialogMgr.oUIMgr._jf.SetLastBlockSelectionId(this.oHostBlock.GetId());};CUISetBasedCalcDlg.prototype.SetHostObj=function(_FK){this.oHostBlock=_FK;this._eB=this.oHostBlock.GetLabel();var _aFI=this._aa.GetItemByIndex(0);this._aj.SetValueFromListItem(_aFI,false);};CUISetBasedCalcDlg.prototype.Notify=function(_Dy){if(_Dy==ExpEvent.kCUIWorksheet_ChangedBlockSel){if(this._r3&&this.oOwner.GetSelectedBlock()&&this.oOwner.GetSelectedBlock().CanApplySetBasedCalc()){this.SetHostObj(this.oOwner.GetSelectedBlock());this.Display();}else if(this._r3){var _M3=true;this.Display(_M3);}}};CUISetBasedCalcDlg.prototype.Display=function(_M3){var _Co=this.oDialogMgr.oUIMgr.appobj.oResources;var _Ke=this.sAppName;var _MY=new Object();var _Xf=Utilities.GenerateCallback(CUIManager.SafeDoHelpTopic,[_Ke,HelpConstants.kSetBasedCalcLink]);_MY['IDS_HELP']=_Xf;if(_M3){var _Li=this.oDialogMgr.oUIMgr.dataManager.GetCurrentDataMatrix();var _W7=_Li.GetAllBlocksArray();var _Nk=new Array();for(var i=0;i<_W7.length;i++){if(_W7[i].CanApplySetBasedCalc()){_Nk.push(_W7[i]);}}var _aJh=false;this.DisplayInvalidSelection('IDS_SET_BASED_CALCS_DLG_TITLE',_MY,_Nk,_Li,'SUMMARIZE',_aJh);}else{CUITopBottomDlg.superclass.Display.call(this,'IDS_SET_BASED_CALCS_DLG_TITLE',_MY,this._vO,'IDS_SET_BASED_CALCS_DLG_INSTR_TEXT');this._aj.ResetEventHandlers();}};CUIDialogMgr.eNormalState=1;CUIDialogMgr.eModalState=2;CUIDialogMgr.iInteractMDlgPcntOfTWidth=0.60;CUIDialogMgr.iMsgBoxPcntOfTWidth=0.45;CUIDialogMgr.iConfirmDlgPcntOfTWidth=0.45;CUIDialogMgr.iDefaultDlgPcntOfTWidth=0.35;CUIDialogMgr.kStackedDlgReOpenFunction="reOpenFunction";function CUIDialogMgr(_Hk){this.oUIMgr=_Hk;this._jg=null;this._dj=new Array();this._wK=0;this._nq=0;this._uC=0;this._xx=0;this._vq=0;this._qu=CUIDialogMgr.eNormalState;this._e6=new Array();this._e6[ExpEvent.kCUIDialogMgr_ShowDialog]=new Array();this._e6[ExpEvent.kCUIDialogMgr_HideDialog]=new Array();this._e6[ExpEvent.kCUIDialogMgr_HideModalDialog]=new Array();};CUIDialogMgr.prototype.Init=function(){this.oUIMgr.Subscribe(this,ExpEvent.kCUIManager_Unload);CUIDialogMgr._jD=new CUIMessageBox();CUIDialogMgr._jD.Init(this);this.CreateConfirmDialogs();CUIDialogMgr._sQ=new CUIPromptDlg();CUIDialogMgr._sQ.Init(this);CUIDialogMgr._tR=new CUIDefaultAnalysisDlg();CUIDialogMgr._tR.Init(this);};CUIDialogMgr.SetResource=function(_Io){CUIDialogMgr._jD.SetResource(_Io);CUIDialogMgr._q5.SetResource(_Io);CUIDialogMgr._U.SetResource(_Io);CUIDialogMgr._cw.SetResource(_Io);CUIDialogMgr._sQ.SetResource(_Io);CUIDialogMgr._tR.SetResource(_Io);};CUIDialogMgr.DisplayMessageBox=function(_I4,_BK,_LB,_G3){if(CUIDialogMgr._jD&&CUIDialogMgr._jD.IsVisible()){return;}if(CUIDialogMgr._jD){CUIDialogMgr._jD.SetSeverityType(_I4);CUIDialogMgr._jD.Display(_BK,_LB,_G3);}};CUIDialogMgr.DisplayDefaultANSDialog=function(){CUIDialogMgr._tR.Display();};CUIDialogMgr.prototype.CreateConfirmDialogs=function(){CUIDialogMgr._q5=new CUIConfirmDlg(CUIConfirmDlg._hr);CUIDialogMgr._q5.Init(this);CUIDialogMgr._U=new CUIConfirmDlg(CUIConfirmDlg._kl);CUIDialogMgr._U.Init(this);CUIDialogMgr._cw=new CUIConfirmDlg(CUIConfirmDlg._uR);CUIDialogMgr._cw.Init(this);};CUIDialogMgr.prototype.IsModalessDialogDisplayed=function(){return this._jg!=null;};CUIDialogMgr.prototype.IsModalDialogDisplayed=function(){return(this._qu==CUIDialogMgr.eModalState);};CUIDialogMgr.prototype.CreateTemplate=function(_EP,_CV){this._p2=document.createElement('DIV');this._p2.className=Dom.GetStyleByBrowser("dialogDiv");this._uC=395;this._lT=_CV;this._p2.style.top=this._uC+"px";COTStyle.SetHeight(this._p2,310);_EP.appendChild(this._p2);};CUIDialogMgr.prototype.ActivateModalDlgTemplate=function(){this._ib=document.createElement('DIV');Dom.EnableTextSelection(this._ib);document.body.appendChild(this._ib);this._ib.className="modalDialogDiv";COTStyle.SetHeight(this._ib,Dom.GetWindowHeight());COTStyle.SetWidth(this._ib,Dom.GetWindowWidth());this._qu=CUIDialogMgr.eModalState;};CUIDialogMgr.prototype.DeActivateModalDlgTemplate=function(_EP){this._H.OnHide();if(this._ib){Dom.RemoveObject(this._ib);}this._qu=CUIDialogMgr.eNormalState;};CUIDialogMgr.prototype.Unload=function(){Dom.RemoveAllChildren(this._p2);Utilities.RemoveAllChildObjects(this);};CUIDialogMgr.prototype.SetLeft=function(_P6){this._wK=_P6;this._p2.style.left=_P6+'px';};CUIDialogMgr.prototype.SetWidth=function(_F4){COTStyle.SetWidth(this._p2,_F4);};CUIDialogMgr.prototype.GetTop=function(){if(this._jg){return this._uC;}else{return this._vq;}};CUIDialogMgr.prototype.Show=function(_Ot){switch(this._qu){case CUIDialogMgr.eModalState:this._H=_Ot;this._ib.appendChild(_Ot.GetDiv());this.SetModalDlgPosition(_Ot.GetDiv());this._ib.style.visibility='visible';CUIManager.HijackKeyDown(CUIDialog.SafeHandleKeyDown);break;case CUIDialogMgr.eNormalState:if(_Ot==this._jg){Dom.RemoveAllChildren(this._p2);}else if(this._jg){if(this._jg.PushOntoDialogStack&&_Ot.CanStackPreviousDlg()){this._jg.PushOntoDialogStack();this._dj.push(this._jg.GetContextArray());}else{Utilities.DeleteAllFromArray(this._dj);}this._jg.OnHide();if(this._jg.GetDiv()){this._p2.removeChild(this._jg.GetDiv());}}this._jg=_Ot;CUIManager.HijackKeyDown(CUIDialog.SafeHandleKeyDown);this._p2.appendChild(_Ot.GetDiv());this._p2.style.visibility='visible';this.HandleResize();break;}this.Notify(ExpEvent.kCUIDialogMgr_ShowDialog);};CUIDialogMgr.prototype.HandleResize=function(_Dg){if(_Dg){this._vq=_Dg;}if(this._jg){var _Ij=this._jg.GetDlgContentDiv();var _Dg=this._vq;var _4z=_Ij.scrollHeight;if(_o.is_firefox&&this._jg._n8=="CUISuppressionDlg"){kMaxHeight=260;_4z=(_4z>kMaxHeight)?kMaxHeight:_4z;}var _22=document.getElementById(this._jg._dw);var _acn=document.getElementById(this._jg._ke);var _anf=COTStyle.GetDisplayOffsetHeight(_22);var _aa4=COTStyle.GetDisplayOffsetHeight(_acn);var _aHQ=COTStyle.GetDisplayOffsetWidth(_acn);var _awW=this._vq-_anf-_aa4;var _T6=Math.min(_4z,_Ij._u3)+_anf+_aa4;this._uC=Math.max(_Dg-_T6,this._lT);this._p2.style.top=this._uC+"px";COTStyle.SetWidth(this._p2,_aHQ);if(this._jg instanceof CUIUserDefFilterDlg){var _aJf=COTStyle.GetDisplayOffsetWidth(_22);COTStyle.SetWidth(_Ij,_aJf);}if(_4z>_awW){COTStyle.SetHeight(this._p2,_Dg);COTStyle.SetHeight(_Ij,_awW);}else{COTStyle.SetHeight(this._p2,_T6);if(!_Ij._fu){_Ij._fu=true;_Ij._u3=_4z;}COTStyle.SetHeight(_Ij,Math.min(_4z,_Ij._u3));}}if(this._qu==CUIDialogMgr.eModalState){var _Ij=this._H.GetDiv();this.SetModalDlgPosition(_Ij);}};CUIDialogMgr.prototype.SetModalDlgWidth=function(_Ka){this._j6=_Ka;};CUIDialogMgr.prototype.SetModalDlgPosition=function(_Ij){var _atP=Dom.GetWindowWidth();var _azw=Dom.GetWindowHeight();COTStyle.SetHeight(this._ib,_azw);COTStyle.SetWidth(this._ib,_atP);var _9J=(_Ij.offsetWidth<700)&&(_atP*this._j6<_Ij.offsetWidth);var _F4=Math.min((_9J?_Ij.offsetWidth:_atP*this._j6),700);var _T6=COTStyle.GetDisplayOffsetHeight(_Ij);var _ayG=null;var _22=document.getElementById(this._H._dw);var _acn=document.getElementById(this._H._ke);var _ax8=false;for(var i=0;i<_Ij.childNodes.length;i++){var _Y9=_Ij.childNodes[i];if(_Y9.className=="modalDialogContentDiv_NS"||_Y9.className=="modalDialogContentDiv"){_ayG=_Y9;if(_Y9.scrollHeight>_Y9.clientHeight){_ax8=true;break;}}}if((_T6>_azw||_ax8||_T6==0)&&_ayG){var _ahb=_azw/2-COTStyle.GetDisplayOffsetHeight(_acn)-COTStyle.GetDisplayOffsetHeight(_22);var _alt=_atP/2;var _aIx=_azw/4;var _3Q=_atP/4;var _aEb=_aIx*3;var _ajj=_3Q*3;_Ij.style.position='absolute';_Ij.style.top=_aIx+'px';_Ij.style.left=_3Q+'px';_Ij.style.bottom=_aEb+'px';_Ij.style.right=_ajj+'px';_ayG.style.overflow="auto";COTStyle.SetHeight(_ayG,_ahb);COTStyle.SetWidth(_Ij,_alt);}else{_Ij.style.position='absolute';_Ij.style.left=Math.max((_atP-_F4)/2,0)+'px';_Ij.style.top=(_azw-_T6)/2+'px';COTStyle.SetWidth(_Ij,_F4);}};CUIDialogMgr.prototype.SetMultiModalDlg=function(_Cy){this._fo=_Cy;this._wT=this._ib;};CUIDialogMgr.prototype.HideCurrentDialog=function(_GF,_Ut){switch(this._qu){case CUIDialogMgr.eModalState:this.DeActivateModalDlgTemplate();this.oUIMgr._wc=false;CUIManager.ReleaseKeyDown();this.Notify(ExpEvent.kCUIDialogMgr_HideModalDialog);if(this._fo){this._qu=CUIDialogMgr.eModalState;this._H=this._fo;this._ib=this._wT;this._fo=null;}break;case CUIDialogMgr.eNormalState:this.HideCurrentModalessDialog(_GF,_Ut);break;}};CUIDialogMgr.prototype.HideCurrentModalessDialog=function(_GF,_Ut){if(this._jg){this._jg.OnHide();if(this._jg.GetDiv()){this._p2.removeChild(this._jg.GetDiv());}if(this._jg.ClearDlg){this._jg.ClearDlg();}this._jg=null;}CUIManager.ReleaseKeyDown();this._p2.style.visibility='hidden';if(!_GF){this.Notify(ExpEvent.kCUIDialogMgr_HideDialog);}if(_Ut){Utilities.DeleteAllFromArray(this._dj);}if(this._dj.length>0){var _ajq=this._dj.pop();this._jg=_ajq[CUIDialogMgr.kStackedDlgReOpenFunction](_ajq,this);}};CUIDialogMgr.SafeHideCurrentDialog=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager.oDialogMgr.HideCurrentDialog();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIDialogMgr.SafeHandleExit=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager.oDialogMgr.HideCurrentDialog();window.close();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIDialogMgr.prototype.Notify=function(_Dy){if(_Dy==ExpEvent.kCUIManager_Unload){this.Unload();}else if(this._e6[_Dy]){for(var i=0;i<this._e6[_Dy].length;i++){this._e6[_Dy][i].Notify(_Dy);}}};CUIDialogMgr.prototype.Subscribe=function(obj,_Dy){if(this._e6[_Dy]){this._e6[_Dy].push(obj);}};CUIDialogMgr.prototype.UnSubscribe=function(obj,_Dy){if(this._e6&&this._e6[_Dy]){Utilities.DeleteFromArray(this._e6[_Dy],obj);}};CUIDialogMgr.prototype.ConfirmLossOfChanges=function(){if(this._jg&&this._jg.ConfirmLossOfChanges){return this._jg.ConfirmLossOfChanges();}return Utilities.eStateContinue;};CUIConfirmDlg._dZ=1;CUIConfirmDlg._kl=2;CUIConfirmDlg._uR=3;CUIConfirmDlg._hr=4;CUIConfirmDlg._qc=20;CUIConfirmDlg._pB=21;CUIConfirmDlg._hw=22;CUIConfirmDlg._xI=23;CUIConfirmDlg._bZ=30;CUIConfirmDlg._i5=31;CUIConfirmDlg._iE=32;function CUIConfirmDlg(_Rt){this.base=CUIDialog;this.base();this._n8=_Rt;this._wv=new Object();this._wv[CUIConfirmDlg._pB]='msg_information.gif';this._wv[CUIConfirmDlg._hw]='msg_warning.gif';};CUIConfirmDlg.prototype=new CUIDialog;CUIConfirmDlg.superclass=CUIDialog.prototype;CUIConfirmDlg.prototype.Init=function(_Hy){CUIConfirmDlg.superclass.Init.call(this,_Hy,false,true);this.SetModalState();var _anu=Utilities.GenerateCallback(CUIDialogMgr.SafeHideCurrentDialog,[this.sAppName]);this._gl=Utilities.GenerateCallbackUnion([Utilities.SafeDoRemoveHoldingProcedure,_anu]);};CUIConfirmDlg.prototype.DrawMainButtons=function(){var _asW=new Array();var _8P=new Array();var _ahX=new Array();switch(this._n8){case CUIConfirmDlg._kl:_asW.push(this.oRes.GetString('IDS_BUTTON_OK'));_asW.push(this.oRes.GetString('IDS_BUTTON_CANCEL'));Debug.Assert(this._xL!=null);_ahX.push(this._xL);Debug.Assert(this._of!=null);_ahX.push(this._of);break;case CUIConfirmDlg._uR:_asW.push(this.oRes.GetString('IDS_BUTTON_YES'));_asW.push(this.oRes.GetString('IDS_BUTTON_NO'));_asW.push(this.oRes.GetString('IDS_BUTTON_CANCEL'));Debug.Assert(this._xL!=null);_ahX.push(this._xL);Debug.Assert(this._w0!=null);_ahX.push(this._w0);Debug.Assert(this._of!=null);_ahX.push(this._of);break;case CUIConfirmDlg._hr:_asW.push(this.oRes.GetString('IDS_BUTTON_YES'));_asW.push(this.oRes.GetString('IDS_BUTTON_NO'));Debug.Assert(this._xL!=null);_ahX.push(this._xL);Debug.Assert(this._w0!=null);_ahX.push(this._w0);break;}var _F0=document.createElement('TBODY');var _aE1=document.createElement('table');_aE1.className='dialogbuttons';_aE1.appendChild(_F0);this._p2.appendChild(_aE1);this._ke=Utilities.GenerateId();_aE1.id=this._ke;_EJ=document.createElement('TR');var _Cs=document.createElement('TD');_Cs.colSpan=2;for(var i=0;i<_asW.length;i++){var _Ic=_asW[i];var _apS=COTInputElementFactory.CreateButton(_Ic+'btn',_Ic,_ahX[i],false,true,this._om);_Cs.appendChild(_apS);_EJ.appendChild(_Cs);}_F0.appendChild(_EJ);return _EJ;};CUIConfirmDlg.prototype.SetCallBackFuntion=function(_UX,_Jz,_CD){this._xL=_UX;this._w0=_Jz;var _Ke=this.sAppName;if(!_CD){var _anu=Utilities.GenerateCallback(CUIDialogMgr.SafeHideCurrentDialog,[_Ke]);_CD=Utilities.GenerateCallbackUnion([Utilities.SafeDoRemoveHoldingProcedure,_anu]);}this._of=_CD;};CUIConfirmDlg.prototype.Display=function(_Ku,_KP,_Is){this.oDialogMgr.ActivateModalDlgTemplate();this.oDialogMgr.SetModalDlgWidth(CUIDialogMgr.iMsgBoxPcntOfTWidth);this._sY=this._wv[_Is];CUIConfirmDlg.superclass.Display.call(this,ExpMiscStr.kProductName,null,null,null,_Ku);};CUIConfirmDlg.prototype.Draw=function(){};CUIConfirmDlg.prototype.Unload=function(){CUIConfirmDlg.superclass.Unload.call(this);};CUIConfirmDlg.prototype.HandleKeyDown=function(e){if(e.keyCode==Dom.KeyCodes.Enter&&this._xL){this._xL();}else if(e.keyCode==Dom.KeyCodes.F5){CUIManager.HandleCommonKeys(e);}};CUIMessageBox.kInformation=1;CUIMessageBox.kWarning=2;CUIMessageBox.kCritical=3;function CUIMessageBox(){this.base=CUIDialog;this.base();this._bv=CUIMessageBox.kInformation;this._wv=new Object();this._wv[CUIMessageBox.kInformation]='msg_information.gif';this._wv[CUIMessageBox.kWarning]='msg_warning.gif';this._wv[CUIMessageBox.kCritical]='msg_error.gif';this._ho=false;this._h5=null;};CUIMessageBox.prototype=new CUIDialog;CUIMessageBox.superclass=CUIDialog.prototype;CUIMessageBox.prototype.Init=function(_yt){CUIMessageBox.superclass.Init.call(this,_yt,false,true);this.SetModalState();};CUIMessageBox.prototype.SetSeverityType=function(_Hx){this._bv=_Hx;this._sY=this._wv[_Hx];};CUIMessageBox.prototype.Display=function(_BK,_LB,_G3,_KH){this._ho=false;this._h5=null;this.oDialogMgr.ActivateModalDlgTemplate();this.oDialogMgr.SetModalDlgWidth(CUIDialogMgr.iMsgBoxPcntOfTWidth);if(_LB){this._ho=true;this._h5=_LB;}this._hB=false;if(_G3){this._gl=_G3;}var _KP=_KH?_KH:ExpMiscStr.kProductName;CUIMessageBox.superclass.Display.call(this,_KP,null,null,null,_BK,_G3);};CUIMessageBox.SafeDoShowDetail=function(){try{var _aq4=document.getElementById(CUIMessageBox._iJ);_aq4.style.display='block';var _azP=document.getElementById(CUIMessageBox._gi);_azP.src=Utilities.IMG_PATH+'prompt_option_collapse.gif';_azP.onclick=CUIMessageBox.SafeDoHideDetail;}catch(e){_f.HandleException(e);}};CUIMessageBox.SafeDoHideDetail=function(){try{var _aq4=document.getElementById(CUIMessageBox._iJ);_aq4.style.display='none';var _azP=document.getElementById(CUIMessageBox._gi);_azP.src=Utilities.IMG_PATH+'prompt_option_expand.gif';_azP.onclick=CUIMessageBox.SafeDoShowDetail;}catch(e){_f.HandleException(e);}};CUIMessageBox.prototype.ShowMessageInDetail=function(_RK){var _NH=document.createElement('TR');var _NM=document.createElement('TD');_NH.appendChild(_NM);_NM=this._gM.cloneNode(false);var _ad6=CUIMessageBox.SafeDoShowDetail;var _apS=COTInputElementFactory.CreateLink(_ad6,this.oRes.GetString('IDS_ERROR_MSG_DETAILS'),true);_NM.appendChild(_apS);_apS=COTInputElementFactory.CreateImage("prompt_option_expand.gif",10,10,CUIMessageBox.SafeDoShowDetail,false,true);_apS.id=Utilities.GenerateId();CUIMessageBox._gi=_apS.id;_NM.appendChild(_apS);_NH.appendChild(_NM);_RK.appendChild(_NH);_NH=document.createElement('TR');_NM=document.createElement('TD');_NH.appendChild(_NM);_NM=this._gM.cloneNode(false);_NH.appendChild(_NM);var _aeX=document.createElement('DIV');_aeX.id=Utilities.GenerateId();CUIMessageBox._iJ=_aeX.id;_NM.appendChild(_aeX);_aeX.className="detailErrMssgDiv";_aeX.appendChild(document.createTextNode(this._h5));_aeX.style.display='none';_RK.appendChild(_NH);};function CUIDeleteErrorMsgBox(){this.base=CUIMessageBox;this.base();};CUIDeleteErrorMsgBox.prototype=new CUIMessageBox;CUIDeleteErrorMsgBox.superclass=CUIMessageBox.prototype;CUIDeleteErrorMsgBox.prototype.Display=function(_BK){this.oDialogMgr.ActivateModalDlgTemplate();this.oDialogMgr.SetModalDlgWidth(CUIDialogMgr.iMsgBoxPcntOfTWidth);this._hB=false;var _aJB=this.oRes.GetString('IDS_DELETE_ERROR_DLG_CAPTION');CUIMessageBox.superclass.Display.call(this,_aJB,null,null,null,_BK);};function CUIPromptDlg(){this.base=CUIDialog;this.base();};CUIPromptDlg.prototype=new CUIDialog;CUIPromptDlg.superclass=CUIDialog.prototype;CUIPromptDlg.prototype.Init=function(_yt){CUIPromptDlg.superclass.Init.call(this,_yt,false,true);this.SetModalState();};CUIPromptDlg.prototype.Display=function(_BK,_Ty,_KH){this.oDialogMgr.ActivateModalDlgTemplate();this.oDialogMgr.SetModalDlgWidth(CUIDialogMgr.iMsgBoxPcntOfTWidth);var _zr=document.createElement('TABLE');_zr.className='dialogTable';var _F0=document.createElement('TBODY');var _NH=document.createElement('TR');var _NM=this._l4.cloneNode(false);var _apS=COTInputElementFactory.CreateLabel(this.oRes.GetString(_BK));_NM.appendChild(_apS);_NH.appendChild(_NM);_F0.appendChild(_NH);_NH=document.createElement('TR');_NM=this._gM.cloneNode(false);_apS=COTInputElementFactory.CreateTextBox(200,'px',_Ty?_Ty:'',false,false,1,100);_apS.style.fontSize='100%';this._x=Utilities.GenerateId();_apS.id=this._x;_NM.appendChild(_apS);_NH.appendChild(_NM);_F0.appendChild(_NH);_zr.appendChild(_F0);var _Ke=this.sAppName;this._om=1;this._lq=_zr;var _KP=ExpMiscStr.kProductName;if(_KH){_KP=_KH;}CUIPromptDlg.superclass.Display.call(this,_KP,null,this._lq);_apS.focus();_apS.select();};CUIPromptDlg.prototype.SetCallBackFuntion=function(_Pe){this._Y=_Pe;var _Ke=this.sAppName;var _CD=Utilities.GenerateCallback(CUIDialogMgr.SafeHideCurrentDialog,[_Ke]);this._of=_CD;};CUIPromptDlg.prototype.GetPromptValue=function(){var _FT='';_FT=document.getElementById(this._x).value;return _FT;};CUIPromptDlg.prototype.SetPromptValue=function(_FT){document.getElementById(this._x).value=_FT;};function COTInputElementFactory(){};COTInputElementFactory.BoldFontSuffix="_bold";COTInputElementFactory.CreateLabel=function(_Ic){var _aGi=document.createTextNode(_Ic);return _aGi;};COTInputElementFactory.iMaxTextBoxLength=256;COTInputElementFactory.CreateTextBox=function(_F4,_zp,_Kb,_Ss,_Ds,_U4,_LA,oOwner){var _AH=document.createElement('INPUT');_AH.type="text";_AH.className="dialogTextBox";COTStyle.SetWidth(_AH,_F4,_zp);_AH._mi=ExpAPIXml.kAttrStringData;_AH.value=_Kb?_Kb:"";if(oOwner){Dom.SetObjRef(_AH,oOwner,'oOwner');}_AH.onclick=Utilities.EventCallback(Dom.SetFocus,[],null,true,false);_AH.onmousedown=Utilities.EventCallback(Dom.SetFocus,[],null,true,false);_AH.onfocus=COTInputElementFactory.SafeOnFocusTextBox;var _asV=_U4!=null?_U4:1;_AH.tabIndex=_asV;if(_LA){_AH.maxLength=_LA;}_AH.id=Utilities.GenerateId();if(_Ss){COTInputElementFactory.DisableInput(_AH);}if(!_Ds){Dom.EnableTextSelection(_AH);}return _AH;};COTInputElementFactory.ResetTextBoxHandlers=function(_AH,_Ds){_AH.onclick=Utilities.EventCallback(Dom.SetFocus,[],null,true,false);_AH.onfocus=COTInputElementFactory.SafeOnFocusTextBox;if(!_Ds){Dom.EnableTextSelection(_AH);}};COTInputElementFactory.InsertTextBoxIntoLabelSpan=function(_An,_Ll,_Fw,_HQ){Dom.RemoveAllChildren(_An);var _aAe=_Fw.split(_HQ);_An.appendChild(document.createTextNode(_aAe[0]));_An.appendChild(_Ll);_An.appendChild(document.createTextNode(_aAe[1]));};COTInputElementFactory.CreateFloatTextBox=function(oOwner,_Cg,_Kb,_Ss,_Ds,_QC,_IB,_GZ,_Lw){var _RB=COTInputElementFactory.CreateIntegerTextBox(oOwner,_Cg,_Kb,_Ss,_Ds,_QC,_IB,_GZ,_Lw);_RB._mi=ExpAPIXml.kAttrFloatData;return _RB;};COTInputElementFactory.SetNumericTextBoxWidth=function(_Ll,_F4,_zp){COTStyle.SetWidth(_Ll,_F4,_zp);};COTInputElementFactory.CreateIntegerTextBox=function(oOwner,_Cg,_Kb,_Ss,_Ds,_QC,_IB,_zy,_Lw,_Sk,_LA){var _AH=document.createElement('INPUT');_AH.type="text";_AH._mi=ExpAPIXml.kAttrIntData;if(_zy){_AH.className="integerTextBox_centered";}else{_AH.className="integerTextBox";}_AH.sBaseClassName=_AH.className;_AH.size=_Cg;if(_LA){_AH.maxLength=_LA;}_AH.value=_Kb?_Kb:"";_AH.onclick=Utilities.EventCallback(Dom.SetFocus,[],null,true,false);Dom.SetObjRef(_AH,oOwner,'oOwner');_AH.iMaxValue=_IB;_AH.iMinValue=_QC;_AH.id=Utilities.GenerateId();_AH.sLastValue=_AH.value;if(!_Lw){_AH.onblur=COTInputElementFactory.SafeOnBlurTextBox;}_AH._rO=_Sk?false:true;_AH.onfocus=COTInputElementFactory.SafeOnFocusTextBox;if(_Ss){COTInputElementFactory.DisableInput(_AH);}if(!_Ds){Dom.EnableTextSelection(_AH);}return _AH;};COTInputElementFactory.SetNewTextBoxValue=function(_Ll,_R0){_Ll.value=_R0;_Ll.sLastValue=_R0;};COTInputElementFactory.SafeOnFocusTextBox=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/this.select();if(_o.is_firefox){CUIManager.SafeForceComboBoxHide();}CUIManager.HijackMouseDown(COTInputElementFactory.SafeOnBlurTextBox,e);this.onkeydown=COTInputElementFactory.SafeOnTextBoxKeyDown;this.onkeyup=COTInputElementFactory.SafeOnTextBoxKeyUp;window.idCurrentTextBox=this.id;if(this.oOwner&&this.oOwner.OnTextBoxSelect){this.oOwner.OnTextBoxSelect(this);}if(this.oOwner&&this.oOwner.OnFocusTextBox){this.oOwner.OnFocusTextBox(this);}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};COTInputElementFactory.ValidateCurrentNumBox=function(){var _Ll=document.getElementById(window.idCurrentTextBox);if(_Ll._mi==ExpAPIXml.kAttrFloatData){var _ah5=Decimal.validateDecimal(_Ll.value);if(_ah5!=''){if(_Ll.value!=_ah5){_Ll.value=_ah5;}}else{_Ll.value="";}}if(_Ll._mi==ExpAPIXml.kAttrIntData){var _ah5=Decimal.validateInteger(_Ll.value);if(_ah5!=''){if(_Ll.value!=_ah5){_Ll.value=_ah5;}}else{_Ll.value="";}}};COTInputElementFactory.SafeOnTextBoxKeyUp=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}if(e.keyCode==Dom.KeyCodes.Enter||e.keyCode==Dom.KeyCodes.Escape||e.keyCode==Dom.KeyCodes.ArrowLeft||e.keyCode==Dom.KeyCodes.ArrowUp||e.keyCode==Dom.KeyCodes.ArrowRight||e.keyCode==Dom.KeyCodes.ArrowDown){return;}COTInputElementFactory.ValidateCurrentNumBox();if(this.oOwner&&this.oOwner.OnTextBoxKeyUp){this.oOwner.OnTextBoxKeyUp(this);}Dom.CancelBubble(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};COTInputElementFactory.SafeOnTextBoxKeyDown=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}if(e.keyCode==Dom.KeyCodes.Delete){CUIManager.skipHandleKeyDown=true;Dom.CancelBubble(e);return;}else if(e.keyCode==Dom.KeyCodes.Enter){COTInputElementFactory.SafeOnBlurTextBox(e);}else if(e.keyCode==Dom.KeyCodes.Escape){COTInputElementFactory.SafeOnBlurTextBox(e);}else{CUIManager.HandleCommonKeys(e);}Dom.CancelBubble(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};COTInputElementFactory.SafeOnBlurTextBox=function(e,_QN){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}var _Ll=document.getElementById(window.idCurrentTextBox);if(_Ll){if(!_QN){if(Dom.GetEventTarget(e)==_Ll&&e.type=="mousedown"){return;}}_Ll.blur();CUIManager.ReleaseMouseDown();window.idCurrentTextBox=null;if(_Ll.oOwner&&_Ll.oOwner.OnUnSelect){_Ll.oOwner.OnUnSelect();}if(_Ll._mi==ExpAPIXml.kAttrFloatData){COTInputElementFactory.OnBlurFloatTextBox(_Ll);return;}if(_Ll._mi==ExpAPIXml.kAttrIntData){if(isNaN(parseInt(_Ll.value,10))){_Ll.value=_Ll.sLastValue;}else{var _aBz=false;var _agr=parseInt(_Ll.value,10);var _aBg=false;var _ao3=false;var _afR=null;if(_Ll.iMaxValue!=null&&_Ll.iMinValue!=null){if(_agr<=_Ll.iMaxValue&&_agr>=_Ll.iMinValue){_aBz=true;}else if(_agr>_Ll.iMaxValue){_aBg=true;_afR=_Ll.iMaxValue;_ao3=true;}else if(_agr<_Ll.iMinValue){_aBg=true;_afR=_Ll.iMinValue;}}else if(_Ll.iMaxValue!=null){if(_agr<=_Ll.iMaxValue){_aBz=true;}else{_aBg=true;_afR=_Ll.iMaxValue;_ao3=true;}}else if(_Ll.iMinValue!=null){if(_agr>=_Ll.iMinValue){_aBz=true;}else{_aBg=true;_afR=_Ll.iMinValue;}}else{_aBz=true;}if(_aBz){_Ll.value=_agr;_Ll.sLastValue=_Ll.value;}else if(_aBg&&_afR!=null){_Ll.value=_afR;}else{_Ll.value=_Ll.sLastValue;}}if(_ao3&&_Ll.oOwner&&_Ll.oOwner.OnTextBoxMaxExceeded){_Ll.oOwner.OnTextBoxMaxExceeded(_Ll.id,Dom.GetEventTarget(e));}if(_Ll.oOwner&&_Ll.oOwner.OnTextBoxValueChange){_Ll.oOwner.OnTextBoxValueChange(_Ll.id,_Ll.value);}}}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};COTInputElementFactory.OnBlurFloatTextBox=function(_Ll){var _4Z=(_Ll.value==Decimal.displayThousand||_Ll.value==Decimal.displayDecimal||_Ll.value==Decimal.displayNegative);if(_Ll.value!=_Ll.sLastValue){var _aAL=Decimal.validateDecimal(_Ll.value);var _aBz=false;var _ao3=false;if(!_4Z){var _agr=Decimal.GetNumericDecimal(_aAL);if(_Ll.iMaxValue!=null&&_Ll.iMinValue!=null){if(_agr<=_Ll.iMaxValue&&_agr>=_Ll.iMinValue){_aBz=true;}else if(_agr>_Ll.iMaxValue){_ao3=true;}}else if(_Ll.iMaxValue!=null){if(_agr<=_Ll.iMaxValue){_aBz=true;}else{_ao3=true;}}else if(_Ll.iMinValue!=null){if(_agr>=_Ll.iMinValue){_aBz=true;}}else{_aBz=true;}}if(_aBz){_Ll.value=_aAL;_Ll.sLastValue=_Ll.value;}else{_Ll.value=_Ll.sLastValue;}}if(_ao3&&_Ll.oOwner&&_Ll.oOwner.OnTextBoxMaxExceeded){_Ll.oOwner.OnTextBoxMaxExceeded(_Ll.id);}if(_Ll.oOwner&&_Ll.oOwner.OnTextBoxValueChange){_Ll.oOwner.OnTextBoxValueChange(_Ll.id,_Ll.value);}};COTInputElementFactory.CreateTextArea=function(_P1,_Gf,_Kb,_Ds,_GH,_U4){var _AY=document.createElement('textarea');_AY.className="dialogTextArea";_AY.rows=_P1;_AY.cols=_Gf;_AY.value=_Kb?_Kb:"";if(_GH){_AY.iMaxLength=_GH;}_AY.onkeydown=COTInputElementFactory.SafeHandleKeyDownOnTextArea;_AY.onclick=Utilities.EventCallback(Dom.SetFocus,[],null,true,false);if(_U4!=null){_AY.tabIndex=_U4;}if(!_Ds){Dom.EnableTextSelection(_AY);};return _AY;};COTInputElementFactory.SetTextAreaEnterEventHandler=function(_AY){_AY.onfocus=Utilities.GenerateCallback(COTInputElementFactory.SetTextAreaFocus,[true]);_AY.onblur=Utilities.GenerateCallback(COTInputElementFactory.SetTextAreaFocus,[false]);};COTInputElementFactory.SetTextAreaFocus=function(_Vu){document._tZ=_Vu;};COTInputElementFactory.ResetTextAreaHandlers=function(_AY,_Ds){_AY.onkeydown=COTInputElementFactory.SafeHandleKeyDownOnTextArea;_AY.onclick=Utilities.EventCallback(Dom.SetFocus,[],null,true,false);if(!_Ds){Dom.EnableTextSelection(_AY);}};COTInputElementFactory.SafeHandleKeyDownOnTextArea=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}if(this.value.length>this.iMaxLength){this.value=this.value.substr(0,this.iMaxLength);}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};function CUICheckBox(_NH,_BM,_UN,_GW,_JY,_Ss){this.elCheckBoxTD=_NH.appendChild(document.createElement('TD'));COTStyle.SetWidth(this.elCheckBoxTD,10);this.elCheckBox=COTInputElementFactory.CreateCheckBox(_UN,_UN,_GW,_JY,_Ss);this.elCheckBoxTD.appendChild(this.elCheckBox);this.elTextTD=_NH.appendChild(document.createElement('TD'));this.elTextTD.appendChild(COTInputElementFactory.CreateLabel(_BM));this.elTextTD.className="CheckBoxText";};COTInputElementFactory.CreateCheckBox=function(name,_UN,_GW,_VS,_Ss){var _ag8=null;if(_o.is_ie5_5up){var _4x=_GW?'checked':'';var _aGP='<input type="checkbox" name="'+name+'" value="'+_UN+'" '+_4x+'>';_ag8=document.createElement(_aGP);_ag8.id='id_'+name+Utilities.GenerateId();_ag8.className="dialogCheckBox";}else{_ag8=document.createElement('INPUT');_ag8.type="checkbox";_ag8.className="dialogCheckBox";_ag8.setAttribute('value',_UN);_ag8.id='id_'+name+Utilities.GenerateId();_ag8.checked=_GW?_GW:false;_ag8.name=name;}if(_VS){_ag8.onclick=_VS;}if(_Ss){COTInputElementFactory.DisableInput(_ag8);}return _ag8;};COTInputElementFactory.CheckAll=function(_PB){var _aA0=_PB.getElementsByTagName("input");for(var i=0;i<_aA0.length;i++){if(_aA0[i].type=="checkbox"){_aA0[i].checked=true;}}};COTInputElementFactory.UnCheckAll=function(_PB){var _aA0=_PB.getElementsByTagName("input");for(var i=0;i<_aA0.length;i++){if(_aA0[i].type=="checkbox"){_aA0[i].checked=false;}}};COTInputElementFactory.ToggleCheckAllBox=function(_JU,_PB){var _Do=_PB.getElementById(_JU);if(_Do.checked){COTInputElementFactory.CheckAll(_PB);}else{COTInputElementFactory.UnCheckAll(_PB);}};COTInputElementFactory.IsChecked=function(_Vj,_FT){var _aiT=document.getElementsByName(_Vj);Debug.Assert(_aiT.length>0);for(var i=0;i<_aiT.length;i++){if(_aiT[i].value==_FT){return _aiT[i].checked;}}return null;};COTInputElementFactory.CreateSingleSelectionBox=function(name,_HR){var _aH7=document.createElement("SELECT");_aH7.className='dialogSelectBox';_aH7.setAttribute('name',name);_aH7.setAttribute('id','id_'+name+Utilities.GenerateId());if(_HR){_aH7.onchange=_HR;}return _aH7;};COTInputElementFactory.CreateMultipleSelectionBox=function(name,_GU,_Pt){var _aH7=document.createElement("SELECT");_aH7.multiple=true;_aH7.size=_GU;_aH7.className='dialogSelectBox';_aH7.style.width='90%';_aH7.setAttribute('name',name);_aH7.setAttribute('id','id_'+name+Utilities.GenerateId());if(_Pt){_aH7.onclick=_Pt;}return _aH7;};COTInputElementFactory.SelectAll=function(_PE){for(var i=0;i<_PE.options.length;i++){_PE.options[i].selected=true;}};COTInputElementFactory.UnCheckAll=function(_PE){for(var i=0;i<_PE.options.length;i++){_PE.options[i].selected=false;}};COTInputElementFactory.CreateOption=function(_TL,_UN,_RM,_Gt){var _aay=document.createElement('OPTION');_aay.value=_UN;_aay.text=_TL;_aay.selected=_RM?_RM:false;if(_Gt){_aay.onclick=_Gt;}return _aay;};COTInputElementFactory.AddOption=function(_PE,_Hm){_PE.options[_PE.options.length]=_Hm;};COTInputElementFactory.RemoveNthOption=function(_PE,_NU){_PE.options.remove(_NU);};COTInputElementFactory.RemoveAllOptions=function(_PE){while(_PE.options.length>0){_PE.options[_PE.options.length-1]=null;}};COTInputElementFactory.CreateButton=function(name,_UN,_VS,_AM,_zD,_U4){var _VO=document.createElement('TABLE');_VO.style.display='inline';if(_o.is_firefox){_VO.style.display='inline-table';}_VO.cellPadding=0;_VO.cellSpacing=0;var _ary=_VO.appendChild(document.createElement('TBODY'));var _ayJ=_ary.appendChild(document.createElement('TR'));var _aeH=_ayJ.appendChild(document.createElement('TD'));_aeH.name=name;_aeH.value=_UN;var _HA=document.createElement('A');_HA.href="#";_HA.className=Dom.GetStyleByBrowser("buttonText");_HA.appendChild(document.createTextNode(_UN));_aeH.appendChild(_HA);if(_U4!=null){_HA.tabIndex=_U4;}_VO.className=Dom.GetStyleByBrowser('dialogButton');_VO.sBaseClassName=Dom.GetStyleByBrowser('dialogButton');if(_VS){_VO.onclick=_VS;_HA.onclick=Utilities.EventCallback(Dom.PreventDefault,null,null,false,true);}_VO.onmouseover=Utilities.EventCallback(Dom.SetCSSClassName,[Dom.GetStyleByBrowser('dialogButton_hover')],null,true,false);_VO.onmouseout=Utilities.EventCallback(Dom.SetCSSClassName,[Dom.GetStyleByBrowser('dialogButton')],null,true,false);if(_AM){_VO.style.marginTop='10px';}if(_zD){_VO.style.marginLeft='10px';}return _VO;};COTInputElementFactory.SetButtonAnchorTextColor=function(_VO,_Vm){var _aEf=_VO.getElementsByTagName('a');if(_aEf.length>0){_aEf[0].style.color=_Vm;}};COTInputElementFactory.kImgButtonMinWidth=70;COTInputElementFactory.kImgButtonHPadding=22;COTInputElementFactory.CreateImgButton=function(_Ic,_Tf,_VS,_Ss,_ND,_PU,_NO,_y0){var _7n=document.createElement('SPAN');_7n.className='dialogImgButton';_7n.sBaseClassName=_7n.className;COTStyle.SetWidth(_7n,100,'%');if(_Ic){_apS=COTInputElementFactory.CreateLabel(_Ic);_7n.appendChild(_apS);}var _F4=_NO?_NO:15;var _T6=_y0?_y0:16;_apS=COTInputElementFactory.CreateImage(_Tf,_F4,_T6);if(_PU){_apS.style.display="block";_7n.style.fontSize="100%";}_7n.appendChild(_apS);_7n._nn=_VS;_7n.onclick=_VS;_7n.onmouseover=Utilities.EventCallback(COTInputElementFactory.SetImgButtonStyle,['dialogImgButton_hover'],null,true,false);_7n.onmouseout=Utilities.EventCallback(COTInputElementFactory.SetImgButtonStyle,['dialogImgButton'],null,true,false);if(_ND){_7n.style.marginTop='10px';}if(_Ss){COTInputElementFactory.DisableInput(_7n);}return _7n;};COTInputElementFactory.SetImgButtonStyle=function(el,style){if(!el.bSelected){el.className=style;}};COTInputElementFactory.SelectImgButton=function(_RB){_RB.className='dialogImgButton_selected';_RB.bSelected=true;};COTInputElementFactory.ResetToBaseButtonStyle=function(_RB){_RB.className=Dom.GetStyleByBrowser('dialogButton');};COTInputElementFactory.ResetToBaseImgButtonStyle=function(_RB){_RB.className='dialogImgButton';_RB.bSelected=false;};COTInputElementFactory.ResetImgButtonAction=function(_R8){_R8.onclick=_R8._nn;_R8.onmouseover=Utilities.GenerateCallback(COTInputElementFactory.SetImgButtonStyle,['dialogImgButton_hover'],null,true,false);_R8.onmouseout=Utilities.GenerateCallback(COTInputElementFactory.SetImgButtonStyle,['dialogImgButton'],null,true,false);};COTInputElementFactory.DisableInput=function(_RB){if(_RB.disabled){return;}_RB.className+=" disabledTextBox";_RB.disabled=true;if(!(_o.is_ie5_5up)){_RB.bBackedUp=true;_RB.oldOnClick=_RB.onclick;_RB.oldOnMouseover=_RB.onmouseover;_RB.oldOnMouseOut=_RB.onmouseout;_RB.oldOnMouseDown=_RB.onmousedown;_RB.oldOnKeyDown=_RB.onkeydown;_RB.oldOnFocus=_RB.onfocus;_RB.oldOnDblClick=_RB.ondblclick;_RB.onclick=Dom.SafePreventDefault;_RB.onmouseover=Dom.SafePreventDefault;_RB.onmouseout=Dom.SafePreventDefault;_RB.onmousedown=Dom.SafePreventDefault;_RB.onkeydown=Dom.SafePreventDefault;_RB.onfocus=Dom.SafePreventDefault;_RB.ondblclick=Dom.SafePreventDefault;_RB.onmouseup=Dom.SafePreventDefault;_RB.onkeypress=Dom.SafePreventDefault;_RB.onkeyup=Dom.SafePreventDefault;_RB.onselect=Dom.SafePreventDefault;}};COTInputElementFactory.EnableInput=function(_RB){_RB.disabled=false;if(_RB.sBaseClassName!=null){_RB.className=_RB.sBaseClassName;}else{var _aj5=_RB.className.indexOf(" ");if(_aj5!=-1){_RB.className=_RB.className.substr(0,_aj5);}}if(!(_o.is_ie5_5up)){if(_RB.bBackedUp==true){_RB.onclick=_RB.oldOnClick;_RB.onmouseover=_RB.oldOnMouseover;_RB.onmouseout=_RB.oldOnMouseOut;_RB.onmousedown=_RB.oldOnMouseDown;_RB.onkeydown=_RB.oldOnKeyDown;_RB.onfocus=_RB.oldOnFocus;_RB.ondblclick=_RB.oldOnDblClick;_RB.onmouseup=null;_RB.onkeypress=null;_RB.onkeyup=null;_RB.onselect=null;}}};COTInputElementFactory.CreateRadioButton=function(name,_UN,_Ng,_Ss,_Da){var _apX;if(_o.is_ie5_5up){if(_Ng){_apX=document.createElement('<INPUT TYPE="radio" NAME="'+name+'" value="'+_UN+'" checked></INPUT>');}else{_apX=document.createElement('<INPUT TYPE="radio" NAME="'+name+'" value="'+_UN+'"></INPUT>');}_apX.className='dialogRadioBtn';}else{_apX=document.createElement('INPUT');_apX.type='radio';_apX.className='dialogRadioBtn';_apX.name=name;_apX.value=_UN;if(_Ng){_apX.checked=true;}else{_apX.checked=false;}}if(_Da){_apX.onclick=_Da;}if(_Ss!=null){if(_Ss){COTInputElementFactory.DisableInput(_apX);}}return _apX;};COTInputElementFactory.GetRadioSelectionValue=function(_DK){var _agG=document.getElementsByName(_DK);for(var i=0;i<_agG.length;i++){if(_agG[i].checked){return _agG[i].value;}}return null;};COTInputElementFactory.SelectRadioItem=function(_DK,_FT){var _ayw=null;var _agG=document.getElementsByName(_DK);for(var i=0;i<_agG.length;i++){if(_agG[i].value==_FT){_agG[i].checked=true;_ayw=_agG[i];}else{_agG[i].checked=false;}}return _ayw;};COTInputElementFactory.DisableRadioItem=function(_DK,_FT){var _agG=document.getElementsByName(_DK);for(var i=0;i<_agG.length;i++){if(_agG[i].value==_FT){COTInputElementFactory.DisableInput(_agG[i]);}}};COTInputElementFactory.CreateLink=function(_MD,_TL,_H0,_Eb){var _HA=document.createElement('A');if(_Eb){_HA.className=_Eb;}else{if(_H0){_HA.className='dialogFunctionLink';}else{_HA.className='dialogAnchor';}}_HA.href="#";var _SQ=[_MD,Utilities.EventCallback(Dom.PreventDefault,null,null,false,true)];var _atY=Utilities.GenerateCallbackUnion(_SQ);_HA.onclick=_atY;Dom.SetObjRef(_HA,_MD,'fCallBack');_HA.appendChild(document.createTextNode(_TL));return _HA;};COTInputElementFactory.DisableLink=function(_HA,_VJ){if(_o.is_ie5_5up){_HA.disabled=true;if(_VJ){_HA.title=_VJ;}_HA.onclick=null;}else{if(_HA.className.indexOf('cancelLink')!=-1)_HA.className="disabled_cancelLink";}};COTInputElementFactory.EnableLink=function(_HA,_VJ){if(_o.is_ie5_5up){_HA.disabled=false;if(_VJ){_HA.title=_VJ;}_HA.onclick=_HA.fCallBack;}else{if(_HA.className.indexOf('disabled_cancelLink')!=-1)_HA.className="cancelLink";}};COTInputElementFactory.CreateImage=function(_Bb,_F4,_T6,_MD,_AM,_zD){var _agf=document.createElement("IMG");_agf.className="dialogImage";if(_F4){COTStyle.SetWidth(_agf,_F4,'px');}if(_T6){COTStyle.SetHeight(_agf,_T6,'px');}if(_AM){_agf.style.marginTop='5px';_agf.style.marginBottom='5px';}if(_zD){_agf.style.marginLeft='10px';_agf.style.marginRight='10px';}if(_MD){_agf.onclick=_MD;}_agf.src=Utilities.IMG_PATH+_Bb;return _agf;};COTInputElementFactory.CreateToolTip=function(_KP){var _7n=document.createElement('SPAN');_7n.title=_KP;return _7n;};COTInputElementFactory.AppendImgOnTop=function(_MU,el,_Vz,_Tf,_QI,_T6,_F4,_Al,_yY,_E0,_Gi,_FJ,_y9,_Sy){var _afe=document.createElement("DIV");var _azP=document.createElement("IMG");_azP.src=Utilities.IMG_PATH+_Tf;_azP.alt=_QI;_azP.title=_QI;_afe.style.position='absolute';_afe.style.top=el.offsetTop+_E0+'px';_azP.style.position="absolute";_azP.style.left="0px";_azP.style.top="0px";if(_Vz==CUIAxisMember.kTRCorner){var _P6=el.offsetLeft+el.offsetWidth-_F4-_Gi;_afe.style.left=_P6+'px';if(_Sy>0){_afe.style.left=_P6-_Sy+'px';}if(_y9>0){_azP.style.top=_y9+'px';}}else if(_Vz==CUIAxisMember.kTLCorner){_afe.style.left=el.offsetLeft+2*_Gi+'px';}COTStyle.SetHeight(_azP,_T6);COTStyle.SetWidth(_azP,_F4);COTStyle.SetHeight(_afe,_T6);COTStyle.SetWidth(_afe,_F4);if(_Al){_azP.onmouseover=_Al;}if(_yY){_azP.onmouseout=_yY;}_MU.appendChild(_afe);_afe.appendChild(_azP);if(!_FJ){_azP._vd=el;el.dummyAnnoImg=_azP;}return _azP;};COTInputElementFactory.AppendDivOnTop=function(_EP,el,_Vz,_E3,_T6,_F4,_Al,_yY,_E0,_Gi,_Mq){var _Ij=document.createElement("DIV");_Ij.className=_E3;_Ij.style.position='absolute';_Ij.style.top=el.offsetTop+_E0+'px';if(_Vz==CUIAxisMember.kTRCorner){_Ij.style.left=el.offsetLeft+el.offsetWidth-_F4-_Gi+'px';}else if(_Vz==CUIAxisMember.kTLCorner){if(_Mq){_Ij.style.left=el.offsetLeft+_Gi+'px';}else{_Ij.style.left=el.offsetLeft+2*_Gi+'px';}}COTStyle.SetHeight(_Ij,_T6);COTStyle.SetWidth(_Ij,_F4);if(_Al){_Ij.onmouseover=_Al;}if(_yY){_Ij.onmouseout=_yY;}_EP.appendChild(_Ij);return _Ij;};COTInputElementFactory.CreateDropdownEle=function(_EP,className,_Ks,_Id,_SL,_zi,_Pt,_AM){_EP._jU=_SL;_EP.className=className;if(_Id){_EP.appendChild(COTInputElementFactory.CreateImage(_Id,16,16));}if(_zi){var _aBG=document.createElement('SPAN');_aBG.style.marginLeft='4px';_EP.appendChild(_aBG);_aBG.appendChild(COTInputElementFactory.CreateLabel(_zi));}var _azP=document.createElement('IMG');_azP.className='dlg_dropdown_arrow';_azP.src=Utilities.IMG_PATH+'ComboBoxArrow.gif';if(_AM){_azP.style.marginTop='3px';_azP.style.marginBottom='3px';}_EP.appendChild(_azP);Dom.SetObjRef(_azP,_Ks,'_oOwnerUIObj');_azP.parentId=_EP._ve;_azP.onclick=COTInputElementFactory.SafeDoShowDropDown;_Ks.oArrowImg=_azP;return _EP;};COTInputElementFactory.SafeDoShowDropDown=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}if(this._oOwnerUIObj.ShowDropdown){var _Qb=Dom.GetRelativeOffset(this,document.body);var x=_Qb.iLeft;var y=_Qb.iTop+COTStyle.GetDisplayOffsetHeight(this);this._oOwnerUIObj.ShowDropdown(e,x,y,this.parentId);}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};COTInputElementFactory.NeedScrollBar=function(_EP,_Gw){return _EP.offsetHeight<_Gw.offsetHeight;};COTInputElementFactory.GetFirstDisplayedNonHeaderTR=function(_zr){var _aq5=1;while(_zr.firstChild.childNodes[_aq5].style.display=='none'){_aq5++;}return _zr.firstChild.childNodes[_aq5];};COTInputElementFactory.GetFirstNonHeaderTRWithCertainClassName=function(_zr,_Gj,_Qd){var _aq5=1;if(!_Qd)_Qd=true;while((_zr.firstChild.childNodes[_aq5].className==_Gj)==_Qd){_aq5++;}return _zr.firstChild.childNodes[_aq5];};COTInputElementFactory.TRShiftSelection=function(_zr,_TY,_Lc){var _2C=0;var _afI=0;var _alp=_zr.firstChild.childNodes;for(var x=1;x<_alp.length;x++){if(_TY==_alp[x]){_2C=x;}if(_Lc==_alp[x]){_afI=x;}if((_2C>0)&&(_afI>0)){break;}}var _5Q=new Array();for(var i=Math.min(_2C,_afI);i<=Math.max(_2C,_afI);i++){_5Q.push(_alp[i]);}return _5Q;};COTInputElementFactory.SetAsRequiredFieldIndicator=function(_EP,_Rz){var _azP=document.createElement("IMG");_azP.src=Utilities.IMG_PATH+'icon_required.gif';_azP.alt=_Rz;_azP.title=_Rz;_azP.className="dialogRequiredFieldIndicator";_EP.appendChild(_azP);};COTInputElementFactory.RemoveRequiredFieldIndicator=function(_EP){_EP.removeChild(_EP.lastChild);};function CUIPropertyPane(_Ga,_EP,_Hk){this.oUIMgr=_Hk;this.oMenu=_Ga;this.oRes=_Hk.appobj.oResources;this._r1=_EP;this._eV=new Array();this.oSelection=null;this.bDisplayInfo=false;this.oUIMgr.Subscribe(this,ExpEvent.kCUIManager_OnSelChange);this.oUIMgr.Subscribe(this,ExpEvent.kCUIManager_Unload);this._bB=document.createElement('TD');this._bB.className="InfoTableCell";this._fc=document.createElement('TD');this._fc.className="InfoDragCell";this._bU=document.createElement('DIV');this._bU.className="InfoTableLabelText";this._v7=document.createElement('DIV');this._v7.className="InfoTableValueText";this._uC=null;CUIPropertyPane.propPane=this;};CUIPropertyPane.prototype.SetValidSelections=function(_Ax){this._eV=_Ax;};CUIPropertyPane.prototype.IsCollapsed=function(){return!this.bDisplayInfo;};CUIPropertyPane.prototype.DrawHeading=function(){if(!this._p2){this._p2=document.createElement('DIV');this._p2.className="left_pane_footer";var _51=this.oRes.GetString('IDS_INFORMATION_PANE_HEADER');this.oToggleBar=new CUIToggleBar(_51);this.oToggleBar.Init(this._p2,this,CUIPropertyPane.SafeToggleDisplay);this._p2.style.left=COTStyle.GetPaddingLeft(this._r1)+"px";this._r1.appendChild(this._p2);this._p2.oInfoPane=this;this._p2.onclick=CUIPropertyPane.SafeHandleClick;}else{var _ayv="";if(this.oSelection&&this.oSelection.GetSelectionLabel()){_ayv='IDS_INFORMATION_PANE_HEADER_SEL';_ayv=this.oRes.ReplaceParam(_ayv,1,this.oSelection.GetSelectionLabel());}else{_ayv=this.oRes.GetString('IDS_INFORMATION_PANE_HEADER');}this.oToggleBar.Update(_ayv,this.bDisplayInfo);}};CUIPropertyPane.prototype.ShowInfo=function(_Qm){if(!this.sContainerId&&this.bDisplayInfo){var _az6=this._p2.appendChild(document.createElement('DIV'));this.sContainerId="infoContainer"+Utilities.GenerateId();_az6.id=this.sContainerId;_az6.className="InfoContainer";var _ZM=COTStyle.GetWidthFromOffset(this._p2)-COTStyle.GetHorizontalExtrasWidth(_az6);COTStyle.SetWidth(_az6,_ZM);var _aGU=document.createElement('DIV');_aGU.className="Description";_az6.appendChild(_aGU);this.sDescDivId="infoDescDiv"+Utilities.GenerateId();_aGU.id=this.sDescDivId;var _aE1=document.createElement('table');_aE1.className=Dom.GetStyleByBrowser("InfoTable");_az6.appendChild(_aE1);_aE1.cellSpacing=0;COTStyle.SetWidth(_aE1,100,'%');var _F0=document.createElement('tbody');this.sTBodyId="infoTBody"+Utilities.GenerateId();_F0.id=this.sTBodyId;_aE1.appendChild(_F0);}var _aGU=document.getElementById(this.sDescDivId);if(_aGU){_aGU.style.display="none";}if(this.bDisplayInfo&&this.oSelection&&this.oSelection.GetDescription&&this.oSelection.GetDescription()!=""){var _az6=document.getElementById(this.sContainerId);if(_az6){_az6.style.visibility="visible";}var _aGU=document.getElementById(this.sDescDivId);_aGU.style.display="block";Dom.ReplaceText(_aGU,this.oSelection.GetDescription());}if(this.bDisplayInfo&&this.oSelection&&this.oSelection.GetPropertyList){var _az6=document.getElementById(this.sContainerId);if(_az6){_az6.style.visibility="visible";}var _RK=document.getElementById(this.sTBodyId);Dom.RemoveAllChildren(_RK);var _JP=this.oSelection.GetPropertyList(_Qm);for(var i=0;_RK&&i<_JP.length;i++){var _NH=document.createElement('TR');var _5l=_NH.appendChild(this._bB.cloneNode(false));COTStyle.SetWidth(_5l,40,'%');var _an9=_5l.appendChild(this._bU.cloneNode(false));var _BM=this.oRes.GetString(_JP[i].sLabel);_an9.appendChild(document.createTextNode(_BM));_5l.title=this.oRes.GetString(_JP[i].sLabelTooltip);if(_JP[i]instanceof COTDraggablePair){var _ab8=_NH.appendChild(this._fc.cloneNode(false));var _aiw=_ab8.appendChild(document.createElement('IMG'));_aiw.className="InfoDragIcon";_aiw.src=Utilities.IMG_PATH+_JP[i].sIcon;COTStyle.SetSize(_aiw,16,16);_ab8.bHover=false;_ab8.bSelected=false;_ab8.onmousedown=CUIPropertyPane.SafeMouseDownOnDragItem;_ab8.onmouseover=CUIPropertyPane.SafeMouseOverOnDragItem;_ab8.onmouseout=CUIPropertyPane.SafeMouseOutOnDragItem;if(_JP[i].bSupportsContextMenu){_ab8.oncontextmenu=CUIPropertyPane.SafeHandleContextMenu;}Dom.SetObjRef(_ab8,this,'oInfoPane');_ab8.sId=_JP[i].sId;_ab8.id=_JP[i].sId;}else{var _ab8=_NH.appendChild(this._bB.cloneNode(false));}if(_JP[i]instanceof COTLoadingPair){var _aiw=_ab8.appendChild(document.createElement('IMG'));_aiw.className="InfoLoadingIcon";_aiw.src=Utilities.IMG_PATH+_JP[i].sIcon;COTStyle.SetSize(_aiw,16,16);_ab8.appendChild(_aiw);_NH.id=Utilities.GenerateId();this._sc=_NH.id;}_an9=_ab8.appendChild(this._v7.cloneNode(false));_BM=this.oRes.GetString(_JP[i].sValue);_an9.appendChild(document.createTextNode(_BM));if(_JP[i].DrawDropDownArrow){_JP[i].DrawDropDownArrow(_an9);}_ab8.title=this.oRes.GetString(_JP[i].sValueTooltip);_RK.appendChild(_NH);}}else{var _RK=document.getElementById(this.sTBodyId);Dom.RemoveAllChildren(_RK);var _az6=document.getElementById(this.sContainerId);if(_az6&&!this.bDisplayInfo){COTStyle.SetHeight(_az6,0,'%');_az6.style.visibility="hidden";COTStyle.SetHeight(this._p2,this.GetHeaderHeight());}}};CUIPropertyPane.prototype.SetTop=function(_TM){this._p2.style.top=_TM+"px";this._uC=_TM;};CUIPropertyPane.prototype.SetHeight=function(_T6){COTStyle.SetHeight(this._p2,_T6);var _az6=document.getElementById(this.sContainerId);if(_az6){COTStyle.SetHeight(_az6,_T6-this.GetHeaderHeight()-COTStyle.GetVerticalExtrasHeight(_az6));}};CUIPropertyPane.prototype.SetWidth=function(_F4){var _aFK=_F4-COTStyle.GetHorizontalExtrasWidth(this._p2);COTStyle.SetWidth(this._p2,_aFK);var _az6=document.getElementById(this.sContainerId);if(_az6){var _ZM=_aFK-COTStyle.GetHorizontalExtrasWidth(_az6);COTStyle.SetWidth(_az6,_ZM);}};CUIPropertyPane.prototype.GetHeaderHeight=function(){return COTStyle.GetDisplayOffsetHeight(this.oToggleBar._cT);};CUIPropertyPane.prototype.Hide=function(){this._p2.style.display="none";};CUIPropertyPane.prototype.Show=function(){this._p2.style.display="block";};CUIPropertyPane.SafeToggleDisplay=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/this.oOwner.bDisplayInfo=!this.oOwner.bDisplayInfo;this.oOwner.DrawHeading();this.oOwner.ShowInfo();this.oOwner.oMenu.OnInfoPaneResize();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIPropertyPane.prototype.Notify=function(_Dy){if(_Dy==ExpEvent.kCUIManager_OnSelChange){var _axS=false;if(this.oUIMgr.GetSelPane()!=this){for(var i=0;this.oUIMgr.GetSelPane()&&i<this._eV.length;i++){if(this.oUIMgr.GetSelPane()==this._eV[i]){_axS=true;this.oSelection=this.oUIMgr.GetSelPane().GetLastSelection();break;}}if(_axS){this.DrawHeading();this.ShowInfo();}this.UnselectAll();}}else if(_Dy==ExpEvent.kCUIManager_Unload){this.Unload();}else if(_Dy==ExpEvent.kCDLMetadata_Merge_Properties){this.RemoveLoadingPair();if(this.oUIMgr.GetMetadataTree()instanceof CUIMissingMetadataTree){this.oUIMgr.OnSelChange(this.oUIMgr.GetMetadataTree());}}};CUIPropertyPane.prototype.RemoveLoadingPair=function(){var _NH=document.getElementById(this._sc);if(_NH){Dom.RemoveObject(_NH);}this._sc=null;};CUIPropertyPane.prototype.Unload=function(){this.oToggleBar.Unload();this._p2.oInfoPane=null;Dom.RemoveObject(this._p2);Utilities.RemoveAllChildObjects(this);};CUIPropertyPane.SafeHandleClick=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}this.oInfoPane.HandleClick(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIPropertyPane.prototype.UnselectAll=function(){if(this._r4){var _NM=document.getElementById(this._r4.sId);if(_NM){var _Ij=Dom.GetElementsByTagName(_NM,"DIV")[0];_Ij.bSelected=false;CUIPropertyPane.SetStyleForItem(_Ij);}}};CUIPropertyPane.prototype.HandleClick=function(e){var _IJ=Dom.GetEventTarget(e);if(this._r4){var _NM=document.getElementById(this._r4.sId);if(_NM&&!Dom.IsDescendant(_NM,_IJ)){var _Ij=Dom.GetElementsByTagName(_NM,"DIV")[0];if(_Ij!=null){_Ij.bSelected=false;CUIPropertyPane.SetStyleForItem(_Ij);}}}};CUIPropertyPane.prototype.MouseDownOnDragItem=function(e,_Lx,_NM){this.oUIMgr.OnSelChange(this);var _IJ=Dom.GetEventTarget(e);this.UnselectAll();var _aD7=Dom.GetElementsByTagName(_NM,"DIV")[0];_aD7.bSelected=true;CUIPropertyPane.SetStyleForItem(_aD7);var _JP=this.oSelection.GetPropertyList();for(var i=0;i<_JP.length;i++){if(_JP[i].sId==_Lx){this._r4=_JP[i];}}if(this.oSelection.OnDragStart&&this.oSelection.OnDragEnd){CUIDragDropSource.HandleMouseDown(e,_IJ,this.oSelection,_Lx);}};CUIPropertyPane.SafeMouseDownOnDragItem=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}this.oInfoPane.MouseDownOnDragItem(e,this.sId,this);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIPropertyPane.SafeMouseOverOnDragItem=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}var _aD7=Dom.GetElementsByTagName(this,"DIV")[0];_aD7.bHover=true;CUIPropertyPane.SetStyleForItem(_aD7);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIPropertyPane.SafeMouseOutOnDragItem=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}var _aD7=Dom.GetElementsByTagName(this,"DIV")[0];_aD7.bHover=false;CUIPropertyPane.SetStyleForItem(_aD7);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIPropertyPane.prototype.HandleContextMenuOnItem=function(e,_Lx,_NM){var _IJ=Dom.GetEventTarget(e);var _aD7=Dom.GetElementsByTagName(_NM,"DIV")[0];_aD7.bSelected=true;CUIPropertyPane.SetStyleForItem(_aD7);var _JP=this.oSelection.GetPropertyList();for(var i=0;i<_JP.length;i++){if(_JP[i].sId==_Lx){this._r4=_JP[i];}}if(this.oSelection.OnPropertyContextMenu){this.oSelection.OnPropertyContextMenu(e,_Lx);}};CUIPropertyPane.SafeHandleContextMenu=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}this.oInfoPane.HandleContextMenuOnItem(e,this.sId,this);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIPropertyPane.SafeHandleDataSourceSelection=function(_Qm){{/*@if(!@bering_debug)@*/try{/*@end@*/CUIPropertyPane.propPane.ShowInfo(_Qm);/*@if(!@bering_debug)@*/}catch(_Qm){_f.HandleException(e);}/*@end@*/}};CUIPropertyPane.SetStyleForItem=function(_Oe){if(_Oe.bHover){_Oe.className+=" InfoDragText_Hover";}if(_Oe.bSelected){_Oe.className="InfoTableValueText InfoDragText_Selected";}if(!_Oe.bSelected&&!_Oe.bHover){_Oe.className="InfoTableValueText";}};CUIPropertyPane.prototype.GetLastSelection=function(){return this._r4;};function CUILeftPaneMenu(_EE,_EP){this._m4=_EE;this._m4.Subscribe(this,ExpEvent.kCUIManager_Unload);this._r3=true;this.cotResource=this._m4.appobj.oResources;this._l9=new CUIPane();var _7g=parseInt(COTStyle.GetWidthFromOffset(_EP)*0.25);this._l9.Create(_EP,null,100,"pane",'%');COTStyle.SetWidth(this._l9.GetDom(),_7g);this._l9.SetPosition(0,0,'px');this._st=this._l9.m_oDom;this._rd=document.createElement('DIV');this._rd.className="insert_objects";this._st.appendChild(this._rd);var _aHS=COTStyle.GetWidthFromOffset(this._st);_aHS=_aHS-COTStyle.GetHorizontalBordersWidth(this._rd)-COTStyle.GetHorizontalPaddingWidth(this._rd)-COTStyle.GetPaddingLeft(this._st);COTStyle.SetWidth(this._rd,_aHS);this._rd.style.left=COTStyle.GetPaddingLeft(this._st)+"px";this._rd.style.top=COTStyle.GetPaddingTop(this._st)+"px";this.oTopBar=document.createElement('DIV');this.oTopBar.className='ins_obj_title_bar';this.oTopBar.appendChild(document.createTextNode(this.cotResource.GetString('IDS_INSERTABLE_OBJ')));this._rd.appendChild(this.oTopBar);this._gI=document.createElement('IMG');this._gI.className='hide_show';this._gI.src=Utilities.IMG_PATH+'hide_pane.gif';this._gI.alt=this.cotResource.GetString('IDS_HIDE_TREE_ALT');this._gI.title=this._gI.alt;this._gI.style.left=(COTStyle.GetDisplayOffsetWidth(this._st)-COTStyle.GetBorderLeft(this._st))+"px";this._gI.style.top="-"+COTStyle.GetBorderTop(this._st)+"px";this._gI.onmouseover=Utilities.EventCallback(Dom.AppendCSSClassName,["hide_show_hover"],null,true,false);this._gI.onmouseout=Utilities.EventCallback(Dom.SetCSSClassName,["hide_show"],null,true,false);this._gI.onmousedown=Utilities.EventCallback(Dom.AppendCSSClassName,["hide_show_pressed"],null,true,false);this._gI.onclick=CUILeftPaneMenu.SafeHandleMenuToggle;COTStyle.SetWidth(this._gI,CUILeftPaneMenu.kiCollapseImgWidth);Dom.SetObjRef(this._gI,this,'oLeftPaneMenu');this._st.appendChild(this._gI);this._uC=0;this._jA=false;this._tq=null;this._ht=null;};CUILeftPaneMenu.kiInsertObjectsRightBorder=1;CUILeftPaneMenu.kiCollapseImgWidth=6;CUILeftPaneMenu.kiDefaultInfoPaneHeightPercent=0.15;CUILeftPaneMenu.prototype.GetDIV=function(){return this._st;};CUILeftPaneMenu.prototype.GetTreeParentDIV=function(){return this._rd;};CUILeftPaneMenu.prototype.GetTopPadding=function(){return COTStyle.GetPaddingTop(this._st);};CUILeftPaneMenu.prototype.IsVisible=function(){return this._r3;};CUILeftPaneMenu.prototype.GetRight=function(){var _Kl=COTStyle.GetPosition(this._st,'left')+COTStyle.GetDisplayOffsetWidth(this._st);var _aeY=COTStyle.GetHorizontalExtrasWidth(this._gI);_Kl+=CUILeftPaneMenu.kiCollapseImgWidth+_aeY;return _Kl;};CUILeftPaneMenu.prototype.GetRightBorderPos=function(){var _Kl=COTStyle.GetPosition(this._st,'left')+COTStyle.GetDisplayOffsetWidth(this._st);_Kl-=COTStyle.GetBorderRight(this._st);return _Kl;};CUILeftPaneMenu.prototype.ChangeWidthBy=function(_Ny){var _aif=COTStyle.GetWidthFromOffset(this._st);this._ht=_aif+_Ny;COTStyle.SetWidth(this._st,this._ht);};CUILeftPaneMenu.SafeHandleMenuToggle=function(e){try{this.oLeftPaneMenu.HandleMenuToggle(e);}catch(e){_f.HandleException(e);}};CUILeftPaneMenu.SafeDoMenuToggle=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager.oLeftPaneMenu.HandleMenuToggle();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUILeftPaneMenu.prototype.HandleMenuToggle=function(e){this._r3=!this._r3;if(!this._r3){this._gI.src=Utilities.IMG_PATH+'show_pane.gif';this._gI.alt=this.cotResource.GetString('IDS_SHOW_TREE_ALT');this._gI.title=this._gI.alt;COTStyle.SetWidth(this._st,2);COTStyle.SetHeight(this._st,this._p4-COTStyle.GetPaddingBottom(this._st)-COTStyle.GetBorderBottom(this._st));this.oTabs.Hide();this.oInfoPane.Hide();this.oTopBar.style.display='none';this._rd.style.display="none";}else{if(this._ht){COTStyle.SetWidth(this._st,this._ht);}else{COTStyle.SetWidth(this._st,25,'%');}this.oTopBar.style.display='block';this._rd.style.display="block";this._gI.src=Utilities.IMG_PATH+'hide_pane.gif';this._gI.alt=this.cotResource.GetString('IDS_HIDE_TREE_ALT');this._gI.title=this._gI.alt;this.oTabs.Show();this.oInfoPane.Show();}this._gI.className="hide_show";this._m4.HandleResize();};CUILeftPaneMenu.prototype.HandleResize=function(_MS,_Nt,_yI,_K8,_Dc){if(_MS!=null){this._p4=_MS;this._kJ=_MS-COTStyle.GetPaddingBottom(this._st)-COTStyle.GetBorderBottom(this._st);COTStyle.SetHeight(this._st,this._kJ);}var _aqo=COTStyle.GetWidthFromOffset(this._st);var _anV=COTStyle.GetDisplayOffsetWidth(this._st);this._gI.style.left=_anV-COTStyle.GetBorderLeft(this._st)+'px';COTStyle.SetWidth(this.oTopBar,_aqo-COTStyle.GetHorizontalExtrasWidth(this.oTopBar));var _aHS=_aqo-COTStyle.GetHorizontalExtrasWidth(this._rd);COTStyle.SetWidth(this._rd,_aHS);if(_Nt!=null){var _alI=this._dz+_Nt;var _agd=_alI+this.oTabs.GetHeight()+2*CUIManager.kiSpaceBtwComponents;var _aI5=this._kJ-_agd>this.oInfoPane.GetHeaderHeight()?true:false;if(_alI>(this.GetTopBarHeight()+this.oTabs.GetHeight())&&_aI5){this._dz+=_Nt;this._tq=this._dz;}}if(_K8){this._dz=this._tq;}var _auS=0;if(this.oInfoPane.IsCollapsed()&&!this._jA){_auS=this.oInfoPane.GetHeaderHeight();}else if(!this._jA){_auS=Math.ceil(CUILeftPaneMenu.kiDefaultInfoPaneHeightPercent*this._kJ);}else{_auS=this._kJ-this.oTabs.GetHeight()-this._dz-2*CUIManager.kiSpaceBtwComponents;}if(!this._jA||!this._dz||this.oInfoPane.IsCollapsed()){this._dz=this._kJ-this.oTabs.GetHeight()-_auS-2*CUIManager.kiSpaceBtwComponents;}COTStyle.SetHeight(this._rd,this._dz);this.ResizeTabControl();this.oInfoPane.SetTop(this._dz+this.oTabs.GetHeight()+2*CUIManager.kiSpaceBtwComponents+COTStyle.GetPaddingTop(this._st));this.oInfoPane.SetHeight(_auS);this.oInfoPane.SetWidth(_aqo);this.oHorizontalSplitter.SetTop(this._dz+this.oTabs.GetHeight()+COTStyle.GetPaddingTop(this._st)+CUIManager.kiSpaceBtwComponents);this.oHorizontalSplitter.SetLeft(COTStyle.GetPaddingLeft(this._st));this.oHorizontalSplitter.SetWidth(_aqo);var _aGy=this._dz-this.GetTopBarHeight();var _aip=_aqo-COTStyle.GetHorizontalExtrasWidth(this._rd);this._m4._qi.SetHeight(_aGy);this._m4._qi.SetTop(this.GetTopBarHeight());this._m4._qi.SetWidth(_aip);this._m4._np.SetHeight(_aGy);this._m4._np.SetTop(this.GetTopBarHeight());this._m4._np.SetWidth(_aip);};CUILeftPaneMenu.prototype.SetTop=function(_TM){this._st.style.top=_TM+'px';this._uC=_TM;};CUILeftPaneMenu.prototype.SetHeight=function(_T6){COTStyle.SetHeight(this._st,_T6);};CUILeftPaneMenu.prototype.GetHeight=function(){return this._p4;};CUILeftPaneMenu.prototype.GetTreeHeight=function(){return COTStyle.GetHeightFromOffset(this._rd)-this.GetTopBarHeight();};CUILeftPaneMenu.prototype.GetTopBarHeight=function(){var _T6=COTStyle.GetDisplayOffsetHeight(this.oTopBar);return _T6;};CUILeftPaneMenu.prototype.GetTabLabelArr=function(){var _ake=new Array(this.cotResource.GetString("IDS_DATA"),this.cotResource.GetString("IDS_CALCU_ITEM"));return _ake;};CUILeftPaneMenu.prototype.SetTabControll=function(){this.oTabs=new CUITabControll(this,this._st,this._m4);this.oHorizontalSplitter=new CUIHorizPaneSplitter();this.oHorizontalSplitter.OnCreate(this._l9,this,0,'px',"resize_area.gif");};CUILeftPaneMenu.prototype.CreatePropertiesPane=function(){this.oInfoPane=new CUIPropertyPane(this,this._st,this._m4);this.oInfoPane.DrawHeading();};CUILeftPaneMenu.prototype.UpdateValidSelPanes=function(_Ax,_zG){this.oInfoPane.SetValidSelections(_Ax);var _Vn=this.GetTabLabelArr();this.oTabs.SetUpTabs(_Vn,_Ax,true,new Array('tab_source.gif','analysis_items_tab_icon.gif'),0);this.ShowDefaultTab(_Ax[_zG]);};CUILeftPaneMenu.prototype.ShowDefaultTab=function(_CE){if(_CE.GetAssoTabId){this.oTabs.SwitchTab(_CE.GetAssoTabId());}};CUILeftPaneMenu.prototype.OnInfoPaneResize=function(){var _K8=false;var _asQ=false;if(this._tq&&!this.oInfoPane.IsCollapsed()){_K8=true;this._jA=true;}if(this.oInfoPane.IsCollapsed()){this._jA=false;}this.HandleResize(null,null,null,_K8);};CUILeftPaneMenu.prototype.ResizeTabControl=function(){var _Uz=this._dz+COTStyle.GetPaddingTop(this._st);this.oTabs.SetTop(_Uz);this.oTabs.SetLeft(COTStyle.GetPaddingLeft(this._st));var _8r=COTStyle.GetWidthFromOffset(this._st)-COTStyle.GetHorizontalExtrasWidth(this.oTabs._st);this.oTabs.SetWidth(_8r);};CUILeftPaneMenu.prototype.HandleUnload=function(){this.oHorizontalSplitter.Unload();this._l9.Unload();Dom.RemoveObject(this._gI);Utilities.RemoveAllChildObjects(this);};CUILeftPaneMenu.prototype.Notify=function(_Dy){if(_Dy==ExpEvent.kCUIManager_Unload){this.HandleUnload();}else if(_Dy==ExpEvent.kCUIPaneSplitter_Move){this._jA=true;this.HandleResize(null,this.oHorizontalSplitter.iLastMove);}};function CUITabControll(_SR,_MU,_Hk,_Tx,_Ex){this._uK=_SR;this._j1=_Hk;this.bTabAboveContent=false;if(_Tx){this.bTabAboveContent=_Tx;}this._st=document.createElement('DIV');if(!_Ex){_Ex='tab_div';}this._st.className=Dom.GetStyleByBrowser(_Ex);_MU.appendChild(this._st);this._iC=document.createElement('table');if(this._j1.appobj.browserInfo.is_netscape){this._iC.className="tab_table_NS";}else{this._iC.className="tab_table";}this._kz=document.createElement('tbody');this._cA=document.createElement('tr');this._ys=document.createElement('td');this._hC=document.createElement('span');this._x7=new Object();this._bA=new Object();this._j1.Subscribe(this,ExpEvent.kCUIManager_Unload);};CUITabControll.prototype.Hide=function(){this._st.style.display='none';};CUITabControll.prototype.Show=function(){this._st.style.display='block';};CUITabControll.prototype.SetUpTabs=function(_Vn,_He,_P8,_Oc,tabIndex){Utilities.ClearObjectArray(this._x7);Utilities.ClearObjectArray(this._bA);Dom.RemoveAllChildren(this._st);var _Mx=this._j1.appobj.appname;var td,_avI;var _aE1=this._iC.cloneNode(false);var _F0=this._kz.cloneNode(false);var tr=this._cA.cloneNode(false);for(var i=0;i<_Vn.length+1;i++){td=this._ys.cloneNode(false);_avI=this._hC.cloneNode(false);td.appendChild(_avI);td.bLast=false;if(i>=_Vn.length-1){td.bLast=true;}this._oU=isNaN(tabIndex)?0:tabIndex;td.bFirst=false;if(i==this._oU){td.bFirst=true;td.bSelected=true;this.SetTabStyle(_avI);}else{td.bSelected=false;var _Lu=false;if(i==_Vn.length){_Lu=true;}this.SetTabStyle(_avI,_Lu);}_avI.id=Utilities.GenerateId();if(i<_Vn.length){if(_P8){var _afT=COTInputElementFactory.CreateImage(_Oc[i],16,16);_avI.title=_Vn[i];_avI.appendChild(_afT);}else{_avI.appendChild(document.createTextNode(_Vn[i]));}_avI.onclick=Utilities.GenerateCallback(this.SwitchTab,[_avI.id],this);this._x7[_avI.id]=_avI;this._bA[_avI.id]=_He[i];if(_He[i].SetAssoTabId){_He[i].SetAssoTabId(_avI.id);}}else{COTStyle.SetWidth(td,100,'%');}tr.appendChild(td);}_F0.appendChild(tr);_aE1.appendChild(_F0);this._st.appendChild(_aE1);if(!_o.is_ie5_5up){this.SetPosition("relative");}};CUITabControll.prototype.SetTabStyle=function(_H3,_Lu){if(this.bTabAboveContent){if(_H3.parentNode.bSelected){_H3.className='tab_text_selected';_H3.parentNode.className='top_tab_td_selected';}else{_H3.className='tab_text_none_selected';if(_Lu){_H3.parentNode.className='top_tab_dummy_td_none_selected';}else{_H3.parentNode.className='top_tab_td_none_selected';}}}else{if(_H3.parentNode.bSelected){_H3.className='tab_text_selected';_H3.parentNode.className='tab_td_selected';}else{_H3.className='tab_text_none_selected';if(_Lu){_H3.parentNode.className='tab_dummy_td_none_selected';}else{_H3.parentNode.className='tab_td_none_selected';}}}if(!_H3.parentNode.bLast&&!_H3.parentNode.bSelected){_H3.parentNode.className+=" tab_right_border";}if(_H3.parentNode.bFirst&&_H3.parentNode.bSelected){_H3.parentNode.className+=" tab_left_border";}};CUITabControll.prototype.SwitchTab=function(_Bv){var _Re=0;for(var i in this._x7){if(i==_Bv){this._x7[i].parentNode.bSelected=true;this._oU=_Re;this.SetTabStyle(this._x7[i]);if(this._bA[i].Show){this._bA[i].Show();}}else{this._x7[i].parentNode.bSelected=false;this.SetTabStyle(this._x7[i]);if(this._bA[i].Hide){this._bA[i].Hide();}}_Re++;}};CUITabControll.prototype.GetCurrentTabIndex=function(){return this._oU;};CUITabControll.prototype.Notify=function(_Dy){if(_Dy==ExpEvent.kCUIManager_Unload){this.Unload();}};CUITabControll.prototype.Unload=function(){for(var i in this._x7){this._x7[i].onclick=null;}Dom.RemoveObject(this._st);Utilities.RemoveAllChildObjects(this);};CUITabControll.prototype.SetTop=function(_TM){this._st.style.top=_TM+'px';};CUITabControll.prototype.SetLeft=function(_P6){this._st.style.left=_P6+"px";};CUITabControll.prototype.SetWidth=function(_F4){COTStyle.SetWidth(this._st,_F4);};CUITabControll.prototype.SetPosition=function(_UR){this._st.style.position=_UR;};CUITabControll.prototype.GetHeight=function(){return COTStyle.GetDisplayOffsetHeight(this._st);};function CUIComboBox(_Hk,oListCtrl){this.oUIMgr=_Hk;this.oListCtrl=oListCtrl;this._xG=false;this._e6=new Array();this._e6[ExpEvent.kCUIComboBox_OnSelChange]=new Array();this._e6[ExpEvent.kCUIComboBox_OnSelection]=new Array();this._e6[ExpEvent.kCUIComboBox_OnBlurTextBox]=new Array();this._ub=18;this._ky=18;this._tv=18;this._d6=true;this._jU=null;this._uY=false;this._ph="ComboBoxArrow.gif";this._l0="ComboBoxArrow_disabled.gif";this._cB="ComboBoxArrow";this._qo="ComboBoxArrow";this._sC="";this._jP=false;this._ve=Utilities.GenerateId();this._wx=false;this._iX=null;};CUIComboBox.kDummyItem='dummyitem';CUIComboBox.kEmptyItem='none';CUIComboBox.prototype.GetId=function(){return this._ve;};CUIComboBox.prototype.DisableIcon=function(){this._d6=false;};CUIComboBox.prototype.SetIconSize=function(_Cg){this._ub=_Cg;};CUIComboBox.prototype.AllowTextEdit=function(){this._uY=true;};CUIComboBox.prototype.SetArrowSize=function(_F4,_T6){this._ky=_T6;this._tv=_F4;};CUIComboBox.prototype.SetArrowImageName=function(_Pj){this._ph=_Pj;};CUIComboBox.prototype.SetArrowImageDisabledName=function(_Pj){this._l0=_Pj;};CUIComboBox.prototype.SetArrowTDClassName=function(_E3){this._cB=_E3;};CUIComboBox.prototype.Disable=function(){this._jP=true;this._bd.style.backgroundImage="url("+Utilities.IMG_PATH+this._l0+")";};CUIComboBox.prototype.Enable=function(){this._jP=false;this._bd.style.backgroundImage="url("+Utilities.IMG_PATH+this._ph+")";};CUIComboBox.prototype.Init=function(){this.oUIMgr.Subscribe(this,ExpEvent.kCUIManager_Unload);this._vO=document.createElement('TABLE');COTStyle.SetWidth(this._vO,100,'%');var _RK=this._vO.appendChild(document.createElement('TBODY'));var _NH=_RK.appendChild(document.createElement('TR'));this._vO.cellPadding=0;this._vO.cellSpacing=0;this._vO.className="ComboBox";this._vz=_NH.appendChild(document.createElement('TD'));this._vz.className="ComboBoxIconEmpty";if(this._d6){this._vz.className="ComboBoxIcon";var _aiw=this._vz.appendChild(document.createElement('IMG'));_aiw.className="ListCtrlIcon";COTStyle.SetSize(_aiw,this._ub,this._ub);COTStyle.SetSize(this._vz,this._ub,this._ub);}if(this._uY){this._kH=COTInputElementFactory.CreateTextBox(204,'px','',false,false,null,null,this);this._kH.style.fontSize='100%';this._kH.onblur=CUIComboBox.SafeOnBlurTextBox;Dom.SetObjRef(this._kH,this,'oComboBox');this._iv=_NH.appendChild(document.createElement('TD'));this._iv.appendChild(this._kH);this._iv.className="ComboBoxText";}else{this._rU=_NH.appendChild(document.createElement('TD'));this._rU.className="ComboBoxText";}this._bd=_NH.appendChild(document.createElement('TD'));this._bd.className=this._cB;if(_o.is_ie5_5up){var _Mz=this._bd.appendChild(document.createElement('IMG'));_Mz.src=Utilities.IMG_PATH+"tv_white.gif";COTStyle.SetSize(_Mz,this._tv,this._ky);}this._bd.style.backgroundImage="url("+Utilities.IMG_PATH+this._ph+")";COTStyle.SetSize(this._bd,this._tv,this._ky);Dom.SetObjRef(this._bd,this,'oComboBox');this._bd.onmousedown=CUIComboBox.SafeToggleDropDown;this._ag=document.body.appendChild(this.oListCtrl._p2);this.oListCtrl.bAutoHeight=true;this.oUIMgr.Subscribe(this,ExpEvent.kCUIManager_OnWindowResize);this._ag.className="ListView_dropdown";this._ag.style.position="absolute";this._ag.style.zIndex=1000;this._ag.style.left=-2000+"px";this._ag.style.visibility="hidden";return this._vO;};CUIComboBox.prototype.ResetEventHandlers=function(){Dom.SetObjRef(this._bd,this,'oComboBox');this._bd.onmousedown=CUIComboBox.SafeToggleDropDown;};CUIComboBox.prototype.SetWidthByPX=function(_F4){COTStyle.SetWidth(this._vO,_F4);};CUIComboBox.prototype.SetWidth=function(_F4,_Rn){COTStyle.SetWidth(this._vO,_F4,_Rn);};CUIComboBox.prototype.EnableHoverOverArrowEffect=function(_E3){this._qo=_E3;this._bd.onmouseover=CUIComboBox.SafeHandleMouseOverArrow;this._bd.onmouseout=CUIComboBox.SafeHandleMouseOutArrow;};CUIComboBox.prototype.Unload=function(){this.oUIMgr.UnSubscribe(this,ExpEvent.kCUIManager_Unload);this.oUIMgr.UnSubscribe(this,ExpEvent.kCUIManager_OnWindowResize);document.body.oComboBox=null;if(this._bd){this._bd.oComboBox=null;}this.f_fireOnShowDropDown=null;this.oUIMgr.RemoveDropDestination(this);Utilities.RemoveAllChildObjects(this);if(Utilities.bUnlimitedCalcEnabled){this.dragOverValidationFCallBackName=null;this.aValidationParams=null;this.bNotifySelChangeOnDrop=null;}};CUIComboBox.prototype.Show=function(){};CUIComboBox.prototype.KeepPrevValue=function(){this._wx=true;};CUIComboBox.prototype.GetPrevValue=function(){if(this._wx){return this._iX;}return null;};CUIComboBox.prototype.SetValueFromListItem=function(_LX,_NN,_Kh){var _Vk=false;if(this._gx!=null&&this._gx!=_LX){_Vk=true;if(this._wx){this._iX=this.GetValue();}}else if(this.GetValue()==CUIComboBox.kDummyItem){_Vk=true;if(this._N){COTInputElementFactory.RemoveRequiredFieldIndicator(this._vO.parentNode);this._N=false;}}this._gx=_LX;this.SetValue(_LX.sValue,_LX.sResString,_LX.sIcon);this.oListCtrl.SelectItem(_LX,null,_Kh);this._vO.title=_LX.GetToolTip();if(_Vk&&_NN){this.Notify(ExpEvent.kCUIComboBox_OnSelChange);}if(_NN){this.Notify(ExpEvent.kCUIComboBox_OnSelection);}};CUIComboBox.prototype.ClearValue=function(){if(this._uY){this._sC=this.oText._jU;this.oText._jU='';this._jU='';}else{this._gx=null;this._sC=this._rU.innerHTML;this._rU.innerHTML='';this._jU='';}};CUIComboBox.prototype.SetValue=function(_FT,_Fc,_T5,_Jq){if(this._uY){this._sC=this._kH.value;this._kH.value=_Fc;}else{this._sC=this._rU.innerHTML;Dom.ReplaceText(this._rU,_Fc);}this._jU=_FT;if(_T5){if(!this._d6){Dom.RemoveAllChildren(this._vz);this._vz.className="ComboBoxIcon";var _aiw=this._vz.appendChild(document.createElement('IMG'));_aiw.className="ListCtrlIcon";}this._vz.firstChild.src=Utilities.IMG_PATH+_T5;}else{Dom.RemoveAllChildren(this._vz);this._vz.className="ComboBoxIconEmpty";COTStyle.SetWidth(this._vz,0,'px');}if(_Jq&&(_FT==CUIComboBox.kDummyItem)&&(!this._N)){this._vO.style.display='inline';if(_o.is_firefox){this._vO.style.display='inline-table';}var _QI=this.oUIMgr.appobj.oResources.GetString('IDS_DLG_REQUIRED_FIELD');COTInputElementFactory.SetAsRequiredFieldIndicator(this._vO.parentNode,_QI);this._N=true;}};CUIComboBox.prototype.GetLabel=function(){if(this._uY){return this._kH.value;}else{return this._rU.innerHTML;}};CUIComboBox.prototype.GetValue=function(){return this._jU;};CUIComboBox.prototype.GetPrevText=function(){return this._sC;};CUIComboBox.SafeOnBlurTextBox=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}this.oComboBox.OnBlurTextBox(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIComboBox.prototype.OnBlurTextBox=function(e){this.Notify(ExpEvent.kCUIComboBox_OnBlurTextBox);};CUIComboBox.prototype.OnTextBoxKeyUp=function(e){if(this._uY){if(this._sC!=this._kH.value){this.SetValue(this._kH.value,this._kH.value);}}};CUIComboBox.SafeHandleMouseOverArrow=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}this.oComboBox.HandleMouseOverArrow(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIComboBox.prototype.HandleMouseOverArrow=function(e){this._bd.className=this._qo;};CUIComboBox.SafeHandleMouseOutArrow=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}this.oComboBox.HandleMouseOutArrow(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIComboBox.prototype.HandleMouseOutArrow=function(e){this._bd.className=this._cB;};CUIComboBox.SafeToggleDropDown=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}this.oComboBox.ToggleDropDown(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIComboBox.prototype.ToggleDropDown=function(e){if(this._xG){this.hideDropDown(e);}else{this.ShowDropDown(e);}};CUIComboBox.prototype.SetCallbackOnShowDropDown=function(_BC){this.f_fireOnShowDropDown=_BC;};CUIComboBox.prototype.RemoveCallbackOnShowDropDown=function(){this.f_fireOnShowDropDown=null;};CUIComboBox.prototype.ShowDropDown=function(e){if(this._jP){return;}if(this.f_fireOnShowDropDown){this.f_fireOnShowDropDown();this.oLastEvent=Dom.CloneMouseEvent(e);}this.oListCtrl.SetMaxWidth(COTStyle.GetWidthFromOffset(this._vO));this._bd.className=this._cB+"_down";var _5z=Dom.GetRelativeOffset(this._vO,document.body);_5z.iTop+=COTStyle.GetDisplayOffsetHeight(this._vO);this._ag.style.left=-2000+"px";this._ag.style.visibility="visible";this._xG=true;CUIManager.HijackMouseDown(CUIComboBox.SafeHideDropDown,e);CUIManager.HijackKeyDown(CUIComboBox.SafeHandleKeyDown);Dom.SetObjRef(document.body,this,'oComboBox');this.oListCtrl.Show();var _aEX=COTStyle.GetDisplayOffsetHeight(this._ag);if((_5z.iTop+_aEX)>Dom.GetWindowHeight()){_5z.iTop=Math.max(_5z.iTop-_aEX-COTStyle.GetDisplayOffsetHeight(this._vO),0);}this._ag.scrollTop=0;var _abB=1;this._ag.style.left=(_5z.iLeft+_abB)+"px";this._ag.style.top=(_5z.iTop+_abB)+"px";this._ag.style.visibility="visible";if(this._gx){this.oListCtrl.SelectItem(this._gx);}this.oListCtrl.Subscribe(this,ExpEvent.kCUIListCtrl_OnItemClick);if(e){Dom.CancelBubble(e);}};CUIComboBox.prototype.hideDropDown=function(){if(this._jP){return;}this._bd.className=this._cB;this._ag.style.visibility="hidden";CUIManager.ReleaseMouseDown();CUIManager.ReleaseKeyDown();this._xG=false;document.body.oComboBox=null;};CUIComboBox.SafeHideDropDown=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}if(this.oComboBox){if(Dom.GetEventTarget(e)!=this.oComboBox._ag&&!Dom.IsDescendant(this.oComboBox._ag,Dom.GetEventTarget(e))){this.oComboBox.hideDropDown();}}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIComboBox.SafeHandleKeyDown=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}if(e.keyCode==Dom.KeyCodes.Escape&&this.oComboBox){this.oComboBox.hideDropDown();}else if(e.keyCode==Dom.KeyCodes.Enter&&this.oComboBox){this.oComboBox.SetValueFromListItem(this.oComboBox.oListCtrl.GetSelection(),true);this.oComboBox.hideDropDown();}else{CUIManager.HandleCommonKeys(e);}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIComboBox.prototype.Notify=function(_Dy){if(_Dy==ExpEvent.kCUIListCtrl_OnItemClick){this.hideDropDown();this.SetValueFromListItem(this.oListCtrl.oClkItem,true);}else if(_Dy==ExpEvent.kCUIManager_Unload){this.Unload();return;}else if(_Dy==ExpEvent.kCUIManager_OnWindowResize){if(this._xG){this.hideDropDown();}}if(this._e6[_Dy]){for(var i=0;i<this._e6[_Dy].length;i++){if(this._e6[_Dy][i].SetCurrentTrigger){this._e6[_Dy][i].SetCurrentTrigger(this);}this._e6[_Dy][i].Notify(_Dy);}}};CUIComboBox.prototype.Subscribe=function(obj,_Dy){if(this._e6[_Dy]){this._e6[_Dy].push(obj);}};CUIComboBox.prototype.PopulateMeaureOptionsWithFilter=function(_Tc,_Li,_DJ,_zd,_Hf,_Ia){this.oListCtrl.ClearAllItems();this.ClearValue();var _apH='';var _LX;var _Vk=_Ia?false:true;var _anv=_Tc.HasMultipleMeasureDim();if(_DJ&&_Li.GetCurrentMeasure()){var _Rz=_Tc.GetMeasure(_Li.GetCurrentMeasureId()).GetBreadCrumbText(true);var _amw=_anv?_Rz:_Li.GetCurrentMeasureLabel();_BM=this.oUIMgr.appobj.oResources.ReplaceParam('IDS_DLG_RULE_DEFAULT_MEASURE',1,_amw);var _LX=this.oListCtrl.AddItem('',_BM,0,ExpAPIXml.kEleDefault,_BM);if(_Ia)this.SetValueFromListItem(_LX,_Vk);}if(_zd){var _BM=this.oUIMgr.appobj.oResources.GetString('IDS_CALC_EXPR_SEL_OTH_MEASURE_INSTRUCTION');var _LX=this.oListCtrl.AddItem('',_BM,0,CUIComboBox.kDummyItem,_BM);this.SetValueFromListItem(_LX,_Vk);}var _axM=false;var _aho=_Li.GetAllMeasuresAndMeasureCalcs(_Hf);if(!_Li.GetCurrentMeasure()){var _Oi=0;var _Rz,_BM;for(var _aqb in _aho){_BM=_aho[_aqb];if(_Tc.GetMeasure(_aqb)){_Rz=_Tc.GetMeasure(_aqb).GetBreadCrumbText(true);_BM=_anv?_Rz:_BM;}else{_Rz=_BM;}_LX=this.oListCtrl.AddItem('',_BM,0,_aqb,_Rz);_Oi++;}if(_Oi>0){_axM=true;if(_Oi<Utilities.GetObjArrayLength(_Tc._yb)){this.oListCtrl.AddSeparator(35);}}}var _ac9=_Tc.GetNumDisplayableMeasuresInComboBox();var _aIQ=0;for(var i in _Tc._yb){if(_aIQ>=_ac9){break;}var _abs=true;if(_axM){var _PM=this.oListCtrl.GetItemByValue(i);if(_PM!=null){_abs=false;}}if(_abs&&_Tc._yb[i]._mi!=ExpAPIXml.kEleTimeProperty&&_Tc._yb[i]._mi!=ExpAPIXml.kEleDateProperty){var _Rz=_Tc._yb[i].GetBreadCrumbText(true);var _apH=_anv?_Rz:_Tc._yb[i].GetLabel();_LX=this.oListCtrl.AddItem('',_apH,0,i,_Rz);_aIQ++;}}if(_Li.GetCurrentMeasure()){var _3U=false;for(var _aqb in _aho){if(!_Tc._yb[_aqb]){if(!_3U){this.oListCtrl.AddSeparator(35);_3U=true;}var _BM=_aho[_aqb];_LX=this.oListCtrl.AddItem('',_BM,0,_aqb,_BM);}}}if(Utilities.GetObjArrayLength(_Tc._yb)>_ac9){var _BM=this.oUIMgr.appobj.oResources.GetString('IDS_DRAG_AND_DROP_MEASURE');var _Rz="";var _adZ=new Array();var _ak3=null;for(var mDimId in _Tc._xV){_adZ.push(_Tc._xV[mDimId].GetLabel());}if(_adZ.length>1){_ak3=this.oUIMgr.appobj.oResources.ReplaceParamList('IDS_WORKSHEET_BASIC_MULTI_MEASURE_INSTRUCTION',_adZ);}else{if(_adZ[0]){_ak3=_adZ[0];}}if(_ak3){_Rz=this.oUIMgr.appobj.oResources.ReplaceParam('IDS_WORKSHEET_BASIC_MEASURE_INSTRUCTION',1,_ak3);}var _ayk=this.oListCtrl.GetItemByIndex(0);var _LX=this.oListCtrl.AddItem("insert_arrow_combo_box.gif",_BM,0,_ayk.GetValue(),_Rz);}};CUIComboBox.prototype.PopulateMeasureOptions=function(_Tc,_Li,_DJ,_zd,_Hf,_Ia){this.oListCtrl.ClearAllItems();this.ClearValue();var _apH='';var _LX;var _Vk=_Ia?false:true;var _anv=_Tc.HasMultipleMeasureDim();if(_DJ&&_Li.GetCurrentMeasure()){var _Rz=_Tc.GetMeasure(_Li.GetCurrentMeasureId()).GetBreadCrumbText(true);var _amw=_anv?_Rz:_Li.GetCurrentMeasureLabel();_BM=this.oUIMgr.appobj.oResources.ReplaceParam('IDS_DLG_RULE_DEFAULT_MEASURE',1,_amw);var _LX=this.oListCtrl.AddItem('',_BM,0,ExpAPIXml.kEleDefault,_BM);if(_Ia)this.SetValueFromListItem(_LX,_Vk);}if(_zd){var _BM=this.oUIMgr.appobj.oResources.GetString('IDS_CALC_EXPR_SEL_OTH_MEASURE_INSTRUCTION');var _LX=this.oListCtrl.AddItem('',_BM,0,CUIComboBox.kDummyItem,_BM);this.SetValueFromListItem(_LX,_Vk);}var _axM=false;var _aho=_Li.GetAllMeasuresAndMeasureCalcs(_Hf);if(!_Li.GetCurrentMeasure()){var _Oi=0;var _Rz,_BM;for(var _aqb in _aho){_BM=_aho[_aqb];if(_Tc.GetMeasure(_aqb)){_Rz=_Tc.GetMeasure(_aqb).GetBreadCrumbText(true);_BM=_anv?_Rz:_BM;}else{_Rz=_BM;}_LX=this.oListCtrl.AddItem('',_BM,0,_aqb,_Rz);_Oi++;}if(_Oi>0){_axM=true;if(_Oi<Utilities.GetObjArrayLength(_Tc._yb)){this.oListCtrl.AddSeparator(35);}}}var _ac9=_Tc.GetNumDisplayableMeasuresInComboBox();var _aIQ=0;for(var i in _Tc._yb){if(_aIQ>=_ac9){break;}var _abs=true;if(_axM){var _PM=this.oListCtrl.GetItemByValue(i);if(_PM!=null){_abs=false;}}if(_abs){var _Rz=_Tc._yb[i].GetBreadCrumbText(true);var _apH=_anv?_Rz:_Tc._yb[i].GetLabel();_LX=this.oListCtrl.AddItem('',_apH,0,i,_Rz);_aIQ++;}}if(_Li.GetCurrentMeasure()){var _3U=false;for(var _aqb in _aho){if(!_Tc._yb[_aqb]){if(!_3U){this.oListCtrl.AddSeparator(35);_3U=true;}var _BM=_aho[_aqb];_LX=this.oListCtrl.AddItem('',_BM,0,_aqb,_BM);}}}if(Utilities.GetObjArrayLength(_Tc._yb)>_ac9){var _BM=this.oUIMgr.appobj.oResources.GetString('IDS_DRAG_AND_DROP_MEASURE');var _Rz="";var _adZ=new Array();var _ak3=null;for(var mDimId in _Tc._xV){_adZ.push(_Tc._xV[mDimId].GetLabel());}if(_adZ.length>1){_ak3=this.oUIMgr.appobj.oResources.ReplaceParamList('IDS_WORKSHEET_BASIC_MULTI_MEASURE_INSTRUCTION',_adZ);}else{if(_adZ[0]){_ak3=_adZ[0];}}if(_ak3){_Rz=this.oUIMgr.appobj.oResources.ReplaceParam('IDS_WORKSHEET_BASIC_MEASURE_INSTRUCTION',1,_ak3);}var _ayk=this.oListCtrl.GetItemByIndex(0);var _LX=this.oListCtrl.AddItem("insert_arrow_combo_box.gif",_BM,0,_ayk.GetValue(),_Rz);}};CUIComboBox.prototype.SetupComboBoxForDragDrop=function(_Hk,_Ml,_J8,_Ch){this._vO.onmouseover=CUIComboBox.SafeHandleMouseOver;this._vO.onmouseout=CUIComboBox.SafeHandleMouseOut;Dom.SetObjRef(this._vO,this,'obj');Dom.SetObjRef(this._vO,_Hk.dataManager.metadata,'oMetaDL');_Hk.AddDropDestination(this);if(Utilities.bUnlimitedCalcEnabled){if(_Ml){this.dragOverValidationFCallBackName=_Ml;this.aValidationParams=_J8;this.bNotifySelChangeOnDrop=_Ch;}else{this.dragOverValidationFCallBackName=null;this.aValidationParams=null;this.bNotifySelChangeOnDrop=null;}}};CUIComboBox.prototype.GetDIVObj=function(){return this._vO;};CUIComboBox.SafeHandleMouseOver=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/this.obj.HandleMouseOver(e);/*@if(!@bering_debug)@*/}catch(excep){_f.HandleException(excep);}/*@end@*/};CUIComboBox.prototype.HandleMouseOver=function(e){if(!e){var e=window.event;}var _N9=Dom.GetEventTarget(e);if(CUIDragDrop.IsDragging()){this.HandleDragOver(e);return;}};CUIComboBox.prototype.SafeHandleDragOver=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}this.obj.HandleDragOver(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIComboBox.prototype.HandleDragOver=function(e){if(!e){var e=window.event;}Dom.CancelEvent(e);var _N9=Dom.GetEventTarget(e);while(_N9.tagName!='TABLE'){_N9=_N9.parentNode;}CUIDragDrop.setEffect(CUIDragDrop.eEffectCopy);CUIDragDrop.SetCursorImgPosition(e.clientX,e.clientY);window.status="copy effect cursor";var _adn=this.IsValidDropTarget(_N9,this._oM);if(_adn){CUIDragDrop.SetCursorImgPosition(e.clientX,e.clientY);_N9.bValidTgt=true;window.status="valid DZ";}else{this.handleInvalidDZ(e);CUIDragDrop.SetCursorImgPosition(e.clientX,e.clientY);_N9.bValidTgt=false;}};CUIComboBox.prototype.IsValidDropTarget=function(_yW,_Lv){if(this.dragOverValidationFCallBackName){var _AG=[_Lv].concat(this.aValidationParams);return this.dragOverValidationFCallBackName.apply(this,_AG);}var _azF=_Lv.GetDataType(_yW.oMetaDL);if(_azF==ExpAPIXml.eMeasure){return true;}else{return false;}};CUIComboBox.prototype.handleInvalidDZ=function(e){CUIDragDrop.setEffect(CUIDragDrop.eEffectNone);window.status="invalid DZ";CUIDragDrop.SetCursorImgPosition(e.clientX,e.clientY);};CUIComboBox.SafeHandleMouseOut=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/this.obj.HandleMouseOut(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIComboBox.prototype.HandleMouseOut=function(e){if(!e){var e=window.event;}Dom.CancelEvent(e);var _N9=Dom.GetEventTarget(e);return;};CUIComboBox.prototype.SetDropData=function(_FZ){this._oM=_FZ;};CUIComboBox.prototype.SafeHandleDragDrop=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}this.obj.HandleDragDrop(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIComboBox.prototype.HandleDragDrop=function(e){if(!this._oM){return;}if(!e){var e=window.event;}var _N9=Dom.GetEventTarget(e);while(_N9.tagName!='TABLE'){_N9=_N9.parentNode;}if(_N9.bValidTgt){var _Bd=this._oM.sId;if(Utilities.bUnlimitedCalcEnabled){this.AddExternalDataToComboBox(_N9.oMetaDL,_Bd);}else{this.AddMeasureToComboBox(_N9.oMetaDL,_Bd);}}this._oM=null;};CUIComboBox.prototype.AddMeasureToComboBox=function(_D7,_Lx){var item=this.oListCtrl.GetItemByValue(_Lx);if(item==null){var _aGq=_D7.datamanager._kX.GetCalculation(_Lx);var _aES=null;if(_aGq&&_aGq.CanUseAsMeasure()){_aES=_aGq;}else{_aES=_D7.GetMeasure(_Lx);}if(_aES){var _BM=_aES.GetLabel();item=this.oListCtrl.AddItemToFront('',_BM,0,_Lx,_BM);}}this.SetValueFromListItem(item);return item;};CUIComboBox.prototype.AddExternalDataToComboBox=function(_D7,_Lx){var item=this.oListCtrl.GetItemByValue(_Lx);if(item==null){var _XB=_D7.GetMemberOrMeasure(_Lx);var _BM=_XB.GetLabel();item=this.oListCtrl.AddItemToFront('dragged_in_member.gif',_BM,0,_Lx,_BM);this.oListCtrl.Notify(ExpEvent.kCUIListCtrl_OnExternalDataDrop);}this.SetValueFromListItem(item);if(this.bNotifySelChangeOnDrop){this.Notify(ExpEvent.kCUIComboBox_OnSelChange);}return item;};CUIListCtrl.NoNumRestriction=-10000;CUIListCtrl.kMinHeight=30;function CUIListCtrl(_Hk){this.oUIMgr=_Hk;this.oRes=this.oUIMgr.appobj.oResources;this.iMaxHeight=500;this.iMaxWidth=500;this.iMinWidth=50;this.bAutoHeight=false;this.bAutoWidth=true;this.sHeightUnit="px";this.sWidthUnit="px";this._wV=new Array();this._wj=new Array();this._aG=new Array();this._ix=new Array();this.bMultiSelect=false;this.bWordWrap=false;this._kZ=CUIListCtrl.NoNumRestriction;this._aW=CUIListCtrl.NoNumRestriction;this._e6=new Array();this._e6[ExpEvent.kCUIListCtrl_OnItemClick]=new Array();this._e6[ExpEvent.kCUIListCtrl_OnItemDblClick]=new Array();this._e6[ExpEvent.kCUIListCtrl_OnKeyDown]=new Array();this._e6[ExpEvent.kCUIListCtrl_OnSelChange]=new Array();this._e6[ExpEvent.kCUIListCtrl_OnExternalDataDrop]=new Array();this._yk=document.createElement('TD');this._yk.className="srchDlgResultTBLHeader";this._o0=document.createElement('TR');for(var i=0;i<1;i++){var _arF=document.createElement('TD');this._o0.appendChild(_arF);_arF.appendChild(document.createElement('A'));}this._o0.className="ListCtrlItem";this._nE=document.createElement('TR');this._nE.appendChild(document.createElement('TD'));this._nE.className="ListCtrlSeparator";};CUIListCtrl.iIndentLength=5;CUIListCtrl.prototype.AddHeader=function(_JB,_H5){this._wV.push(new CUIListCtrlHeader(_JB,_H5));return this._wV[this._wV.length-1];};CUIListCtrl.prototype.EnableMultiSelect=function(){this.bMultiSelect=true;};CUIListCtrl.prototype.SetSelItemNumRange=function(_FF,_Qi){this._kZ=_FF;this._aW=_Qi;};CUIListCtrl.prototype.GetMinSelItemNum=function(){return this._kZ;};CUIListCtrl.prototype.GetMaxSelItemNum=function(){return this._aW;};CUIListCtrl.prototype.EnableWordWrap=function(){this.bWordWrap=true;};CUIListCtrl.prototype.AddItemToFront=function(_Gm,_JB,_Q9,_FT,_QI,_RM){this._wj.unshift(new CUIListCtrlItem(_Gm,_JB,_Q9,_FT,_QI,_RM,0));return this._wj[0];};CUIListCtrl.prototype.AddItem=function(_Gm,_JB,_Q9,_FT,_QI,_RM){var _aaJ=new CUIListCtrlItem(_Gm,_JB,_Q9,_FT,_QI,_RM,this._wj.length);this._wj.push(_aaJ);if(_RM){this.SelectItem(_aaJ);}return _aaJ;};CUIListCtrl.prototype.AddSeparator=function(_CY){if(!_CY){var _CY=10;}var _abk=this.oRes.GetString('IDS_LIST_CTRL_SEPARATOR');this._wj.push(new CUIListCtrlSep(_CY,_abk));return this._wj[this._wj.length-1];};CUIListCtrl.prototype.ClearAllItems=function(_DD){for(var i=0;i<this._wj.length;i++){if(this._ix[this._wj[i]._jw]){clearTimeout(this._ix[this._wj[i]._jw]);Utilities.DeleteFromArray(this._ix,this._ix[this._wj[i]._jw]);}this._wj[i].Unload();}Utilities.DeleteAllFromArray(this._wj);Utilities.DeleteAllFromArray(this._aG);Utilities.DeleteAllFromArray(this._ix);this.oClkItem=null;if(_DD){this.Show();}};CUIListCtrl.prototype.RemoveItems=function(_DD,_IH){for(var i=0;i<_IH.length;i++){if(this._ix[_IH[i]._jw]){clearTimeout(this._ix[_IH[i]._jw]);Utilities.DeleteFromArray(this._ix,this._ix[_IH[i]._jw]);}if(_IH[i]==this.oClkItem){this.oClkItem=null;}_IH[i].Unload();Utilities.DeleteFromArray(this._wj,_IH[i]);Utilities.DeleteFromArray(this._aG,_IH[i]);}if(_DD){this.Show();}};CUIListCtrl.prototype.Unload=function(){for(var i=0;i<this._wj.length;i++){this._wj[i].Unload();}this.oUIMgr.RemoveDropDestination(this);Utilities.DeleteAllFromArray(this._wj);Utilities.DeleteAllFromArray(this._aG);Utilities.DeleteAllFromArray(this._ix);Utilities.DeleteAllFromArray(this._wV);Utilities.DeleteAllFromArray(this._e6);if(Utilities.IsInArray(this.oUIMgr._e6[ExpEvent.kCUIManager_Unload],this)){Utilities.DeleteFromArray(this.oUIMgr._e6[ExpEvent.kCUIManager_Unload],this);}Utilities.RemoveAllChildObjects(this);if(Utilities.bUnlimitedCalcEnabled){this.dragOverValidationFCallBackName=null;this.dropValidationParams=null;}};CUIListCtrl.prototype.Init=function(){this.oUIMgr.Subscribe(this,ExpEvent.kCUIManager_Unload);this._p2=document.createElement('DIV');this._p2.className="ListCtrl";this._vO=document.createElement('TABLE');this._vO.className='listCtrlTBL';this._vK=this._vO.appendChild(document.createElement('THEAD'));this._xS=this._vO.appendChild(document.createElement('TBODY'));for(var i=0;i<this._wV.length;i++){var _1P=document.createElement('TR');var _ang=this._yk.cloneNode(false);COTStyle.SetWidth(_ang,this._wV[i].fPercent,'%');var _apS=COTInputElementFactory.CreateLabel(this.oRes.GetString(this._wV.sResString));_ang.appendChild(_apS);_1P.appendChild(_ang);this._vK.appendChild(_1P);}this._p2.appendChild(this._vO);return this._p2;};CUIListCtrl.prototype.SetMaxHeight=function(_T6,_Rn){this.iMaxHeight=_T6;if(_Rn){this.sHeightUnit=_Rn;}};CUIListCtrl.prototype.SetMaxWidth=function(_F4,_Rn){this.iMaxWidth=_F4;this.bAutoWidth=false;if(_Rn){this.sWidthUnit=_Rn;}};CUIListCtrl.prototype.DisableHAutoScroll=function(){this._p2.style.overflowX='hidden';};CUIListCtrl.prototype.Show=function(_JG){this._ik=_JG;this._hH=-100;if(!_o.is_ie5_5up){this._hH=null;}Dom.RemoveAllChildren(this._xS);var _aCL=new Array();var _aDD=this.GetSelection();for(var i=0;i<this._wj.length;i++){var _U4=(this._wj[i]==this.oClkItem)?this._ik:this._hH;_U4=(i==0&&!_aDD)?this._ik:this._hH;_aCL[i]=this.DrawItem(this._wj[i],_U4);}if(!this.bAutoHeight){if(this._jy){COTStyle.SetHeight(this._p2,this.iMaxHeight-2,this.sHeightUnit);}else{COTStyle.SetHeight(this._p2,this.iMaxHeight,this.sHeightUnit);this._jy=true;}}else{this._p2.style.height="auto";if(this._wj.length==0){COTStyle.SetHeight(this._p2,CUIListCtrl.kMinHeight,'px');}else{var _T6=COTStyle.GetHeightFromOffset(this._p2);if(_T6>this.iMaxHeight&&this.sHeightUnit=="px"){_T6=this.iMaxHeight;}COTStyle.SetHeight(this._p2,_T6);}}var _aD4=null;if(!this.bAutoWidth){COTStyle.SetWidth(this._p2,this.iMaxWidth,this.sWidthUnit);}else{this._p2.style.width="auto";var _F4=COTStyle.GetWidthFromOffset(this._p2);if(_F4>this.iMaxWidth&&this.sWidthUnit=="px"){_F4=this.iMaxWidth;}COTStyle.SetWidth(this._p2,Math.max(_F4,this.iMinWidth));}};CUIListCtrl.prototype.PreSelItems=function(){for(var i=0;i<this._wj.length;i++){if(this._wj[i]._qD){this.SelectItem(this._wj[i]);}}};CUIListCtrl.prototype.GetItemByHtmlId=function(_Lx){for(var i=0;i<this._wj.length;i++){if(this._wj[i]._br==_Lx){return this._wj[i];}}return null;};CUIListCtrl.prototype.DrawItem=function(_PM,_Dl){if(_PM instanceof CUIListCtrlSep){var _NH=this._nE.cloneNode(true);_PM._br="listItem"+Utilities.GenerateId();_NH.id=_PM._br;_abL=COTInputElementFactory.CreateLabel(this.oRes.GetString(_PM.sResString));_NH.firstChild.appendChild(_abL);this._xS.appendChild(_NH);_NH.firstChild.className='nonWrapListCtrlTBL';return _NH;}var _NH=this._o0.cloneNode(true);_NH.onmousedown=CUIListCtrl.SafeHandleMouseDown;_NH.ondblclick=CUIListCtrl.SafeHandleDblClick;_NH.onmouseover=CUIListCtrl.SafeHandleMouseOver;_NH.onmouseout=CUIListCtrl.SafeHandleMouseOut;if(_NH.addEventListener){_NH.addEventListener("dblclick",CUIListCtrl.SafeHandleDblClick,false);}Dom.SetObjRef(_NH,this,'oListCtrl');_PM._br="listItem"+Utilities.GenerateId();_NH.id=_PM._br;if(!this.bWordWrap){_NH.firstChild.className='nonWrapListCtrlTBL';}if(_PM.iIndentLevel>0){_NH.firstChild.style.paddingLeft=parseInt(_PM.iIndentLevel*CUIListCtrl.iIndentLength)+"px";}if(_PM.sIcon){var _afT=COTInputElementFactory.CreateImage(_PM.sIcon,16,16);_NH.firstChild.firstChild.appendChild(_afT);_afT.className="ListCtrlIcon";}if(_Dl!=null){Dom.SetTabStop(_NH.firstChild.firstChild,_Dl);}_abL=COTInputElementFactory.CreateLabel(this.oRes.GetString(_PM.sResString));_NH.firstChild.firstChild.appendChild(_abL);_NH.firstChild.firstChild.onkeydown=CUIListCtrl.SafeHandleKeyDown;_NH.firstChild.firstChild.onfocus=CUIListCtrl.SafeHandleFocus;if(_PM.sToolTip!=null){_NH.title=_PM.sToolTip;}this._xS.appendChild(_NH);_PM.SetStyle(_NH);return _NH;};CUIListCtrl.prototype.GetItemByValue=function(_UN,_Fj){if(_Fj==null){var _Fj=this._wj.length;}for(var i=0;i<this._wj.length&&i<_Fj;i++){if(this._wj[i].GetValue()==_UN){return this._wj[i];}if(_UN instanceof Array&&this._wj[i].GetValue()instanceof Array&&Utilities.AreArrayContentsEqual(this._wj[i].GetValue(),_UN)){return this._wj[i];}}return null;};CUIListCtrl.prototype.GetItemByIndex=function(_PQ){if(_PQ<this._wj.length&&_PQ>-1){return this._wj[_PQ];}return null;};CUIListCtrl.prototype.SelectItem=function(_PM,_Oe,_Kh){if(_PM instanceof CUIListCtrlSep){return;}var _amF=(this._aW==CUIListCtrl.NoNumRestriction);if(!_amF){_amF=(this._aG.length<this._aW);}if(!_amF){return;}if(!this.bMultiSelect){this.ClearSelections();}this.oClkItem=_PM;_PM._qD=true;if(!Utilities.IsInArray(this._aG,_PM)){this._aG.push(_PM);}_PM._jw=this._aG.length-1;if(!_Oe){var _Oe=document.getElementById(_PM._br);}if(_Oe){_PM.SetStyle(_Oe);}if(!_Kh){var _6z=Utilities.GenerateCallback(CUIListCtrl.SetFocus,[_PM._br]);this._ix[_PM._jw]=setTimeout(_6z,1);}};CUIListCtrl.prototype.ShowEditBox=function(_PM){var _NH=document.getElementById(_PM._br);var _RB=COTInputElementFactory.CreateTextBox(90,"%",_PM._p8,false);var _3g=Dom.GetElementsByTagName(_NH,"A");_NH.firstChild.replaceChild(_RB,_3g[0]);_RB.focus();};CUIListCtrl.SetFocus=function(_Lx){var _NH=document.getElementById(_Lx);if(!_NH||!_NH.oListCtrl){return;}for(var i=0;i<_NH.oListCtrl._wj.length;i++){var _aBh=document.getElementById(_NH.oListCtrl._wj[i]._br);if(_aBh.firstChild.firstChild&&_aBh.firstChild.firstChild.nodeType==Dom.NodeType.ElementNode){_aBh.firstChild.firstChild.tabIndex=_NH.oListCtrl._hH;if(!_o.is_ie5_5up){_aBh.firstChild.firstChild.tabIndex=null;}}}_NH.firstChild.firstChild.tabIndex=_NH.oListCtrl._ik;if(_NH&&COTStyle.IsVisible(_NH)){_NH.firstChild.firstChild.focus();}var _PM=_NH.oListCtrl.GetItemByHtmlId(_NH.id);_NH.oListCtrl._ix[_PM._jw]=null;};CUIListCtrl.prototype.ClearSelections=function(_NU){if(_NU>-1){if(this._ix[_NU]){clearTimeout(this._ix[_NU]);Utilities.DeleteNthFromArray(this._ix,_NU);}this._aG[_NU]._qD=false;this._aG[_NU].SetStyle();Utilities.DeleteNthFromArray(this._aG,_NU);for(var i=0;i<this._aG.length;i++){this._ix[i]=this._ix[this._aG[i]._jw];this._aG[i]._jw=i;}}else{for(var i=0;i<this._aG.length;i++){if(this._ix[i]){clearTimeout(this._ix[_NU]);this._ix[_NU]=null;}this._aG[i]._qD=false;this._aG[i].SetStyle();this._aG[i]=null;}this._aG.length=0;Utilities.DeleteAllFromArray(this._ix);}};CUIListCtrl.SafeHandleMouseDown=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/this.oListCtrl.HandleMouseDown(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIListCtrl.prototype.HandleMouseDown=function(e){if(!e){var e=window.event;}var _N9=Dom.GetEventTarget(e);while(_N9.tagName!='TR'&&_N9!=this._p2){_N9=_N9.parentNode;}if(_N9.tagName!="TR"){return;}this._yn=false;var _PM=null;var _RM=false;for(var i=0;i<this._aG.length;i++){if(_N9.id==this._aG[i]._br){_PM=this._aG[i];_RM=_PM._qD;break;}}if(!_PM){for(var i=0;i<this._wj.length;i++){if(_N9.id==this._wj[i]._br){_PM=this._wj[i];break;}}}var _73=null;if(this._aG.length>0){_73=this._aG[this._aG.length-1];}if(this.bMultiSelect&&(e.ctrlKey||e.shiftKey)){var _aBX=false;if(_73){_aBX=true;if(this._d2){_aBX=this._d2(_PM,_73);}}if(e.ctrlKey){if(_RM){this.ClearSelections(_PM._jw);this.Notify(ExpEvent.kCUIListCtrl_OnSelChange);return;}if(!_aBX){this.ClearSelections();}this.SelectItem(_PM,_N9);}else if(e.shiftKey){if(_aBX){var _aF7=Utilities.GetObjIndex(this._wj,_PM);var _ad7=Utilities.GetObjIndex(this._wj,_73);for(var i=Math.min(_aF7,_ad7);i<=Math.max(_aF7,_ad7);i++){this.SelectItem(this._wj[i]);}}else{this.ClearSelections();this.SelectItem(_PM,_N9);}}}else{this.ClearSelections();this.SelectItem(_PM,_N9);if(_RM&&_PM._pb){this.ShowEditBox(_PM);}if(_PM._x9){CUIDragDropSource.HandleMouseDown(e,_N9,this);}this.bClrOldSel=true;}this.Notify(ExpEvent.kCUIListCtrl_OnSelChange);this.Notify(ExpEvent.kCUIListCtrl_OnItemClick);};CUIListCtrl.prototype.GetSelection=function(){if(this.oClkItem){return this.oClkItem;}else{return null;}};CUIListCtrl.SafeHandleMouseOver=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(this.oListCtrl){this.oListCtrl.SetItemStyle(e,true);}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIListCtrl.SafeHandleMouseOut=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(this.oListCtrl){this.oListCtrl.SetItemStyle(e,false);}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIListCtrl.prototype.SetItemStyle=function(e,_D0){if(!e){var e=window.event;}var _N9=Dom.GetEventTarget(e);while(_N9.tagName!='TR'&&_N9!=this._p2){_N9=_N9.parentNode;}if(_N9.tagName!="TR"){return;}for(var i=0;i<this._wj.length;i++){if(this._wj[i]._br==_N9.id){this._wj[i].bHover=_D0;this._wj[i].SetStyle(_N9);break;}}};CUIListCtrl.prototype.SetItemSecondarySelectionStyle=function(){for(var i=0;i<this._aG.length;i++){this._aG[i].bBlur=true;this._aG[i]._qD=false;this._aG[i].SetStyle();}};CUIListCtrl.prototype.ClearSecondarySelection=function(){for(var i=0;i<this._wj.length;i++){this._wj[i].bBlur=false;this._wj[i].SetStyle();}};CUIListCtrl.prototype.SetItemPrimarySelectionStyle=function(){for(var i=0;i<this._aG.length;i++){this._aG[i]._qD=true;this._aG[i].bBlur=false;this._aG[i].SetStyle();}};CUIListCtrl.prototype.Subscribe=function(obj,_Dy){if(this._e6[_Dy]){this._e6[_Dy].push(obj);}};CUIListCtrl.prototype.Notify=function(_Dy){if(_Dy==ExpEvent.kCUIManager_Unload){this.Unload();return;}var _alZ=this._e6[_Dy];for(var i=0;_alZ&&i<_alZ.length;i++){_alZ[i].Notify(_Dy);}};CUIListCtrl.prototype.HandleDblClick=function(e){this.Notify(ExpEvent.kCUIListCtrl_OnItemDblClick);};CUIListCtrl.SafeHandleDblClick=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}if(this.oListCtrl){this.oListCtrl.HandleDblClick(e);}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIListCtrl.prototype.HandleKeyDown=function(e){this.iLastKeyCode=e.keyCode;this.Notify(ExpEvent.kCUIListCtrl_OnKeyDown);if(e.keyCode==Dom.KeyCodes.ArrowUp){if(this.GetSelection().iParentIdx>0){this.ClearSelections();this.SelectItem(this._wj[this.GetSelection().iParentIdx-1]);this.Notify(ExpEvent.kCUIListCtrl_OnSelChange);}}else if(e.keyCode==Dom.KeyCodes.ArrowDown){if(this.GetSelection().iParentIdx<this._wj.length-1){this.ClearSelections();this.SelectItem(this._wj[this.GetSelection().iParentIdx+1]);this.Notify(ExpEvent.kCUIListCtrl_OnSelChange);}}};CUIListCtrl.SafeHandleKeyDown=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}var _yW=Dom.GetEventTarget(e);while(_yW.tagName!='TR'&&_yW){_yW=_yW.parentNode;}if(_yW.tagName!="TR"){return;}if(_yW.oListCtrl){_yW.oListCtrl.HandleKeyDown(e);}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIListCtrl.SafeHandleFocus=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}var _yW=Dom.GetEventTarget(e);while(_yW.tagName!='TR'&&_yW){_yW=_yW.parentNode;}if(_yW.tagName!="TR"){return;}var _PM=_yW.oListCtrl.GetItemByHtmlId(_yW.id);if(_PM&&!_PM._qD){_yW.oListCtrl.SelectItem(_PM,_yW,true);_yW.oListCtrl.Notify(ExpEvent.kCUIListCtrl_OnSelChange);}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIListCtrl.prototype.SafeHandleDragOver=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}this.obj.HandleDragOver(e);Dom.CancelEvent(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIListCtrl.prototype.HandleDragOver=function(e){if(!e){var e=window.event;}Dom.CancelEvent(e);var _N9=Dom.GetEventTarget(e);while(_N9.tagName!='TABLE'){_N9=_N9.parentNode;}CUIDragDrop.setEffect(CUIDragDrop.eEffectCopy);CUIDragDrop.SetCursorImgPosition(e.clientX,e.clientY);var _adn=this.IsValidDropTarget(this._oM);if(_adn){CUIDragDrop.SetCursorImgPosition(e.clientX,e.clientY);_N9.bValidTgt=true;}else{this.handleInvalidDZ(e);CUIDragDrop.SetCursorImgPosition(e.clientX,e.clientY);_N9.bValidTgt=false;}};CUIListCtrl.prototype.handleInvalidDZ=function(e){CUIDragDrop.setEffect(CUIDragDrop.eEffectNone);CUIDragDrop.SetCursorImgPosition(e.clientX,e.clientY);};CUIListCtrl.prototype.GetDIVObj=function(){return this._vO;};CUIListCtrl.prototype.IsValidDropTarget=function(_Lv){if(this.dragOverValidationFCallBackName){var _AT=this.oUIMgr.dataManager;var _AG=[_Lv].concat(this.dropValidationParams);return this.dragOverValidationFCallBackName.apply(this,_AG);}return false;};CUIListCtrl.prototype.SetDropData=function(_FZ){this._oM=_FZ;};CUIListCtrl.prototype.SetupListCtrlForDragDrop=function(_Hk,_Ml,_J8){Dom.SetObjRef(this._vO,this,'obj');Dom.SetObjRef(this._vO,_Hk.dataManager.metadata,'oMetaDL');_Hk.AddDropDestination(this);this.dragOverValidationFCallBackName=_Ml;this.dropValidationParams=_J8;};CUIListCtrl.prototype.SafeHandleDragDrop=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}this.obj.HandleDragDrop(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIListCtrl.prototype.HandleDragDrop=function(e){if(!this._oM){return;}if(!e){var e=window.event;}var _N9=Dom.GetEventTarget(e);while(_N9.tagName!='TABLE'){_N9=_N9.parentNode;}if(_N9.bValidTgt){var _Eu=new Array();_Eu.push(this._oM.sId);if(this._oM.aOtherMemIds&&this._oM.aOtherMemIds.length>0){_Eu=_Eu.concat(this._oM.aOtherMemIds);}this.AddDropDataToList(_N9.oMetaDL,_Eu);}this._oM=null;};CUIListCtrl.prototype.AddDropDataToList=function(_D7,_Eu){var _aer=0;for(var i=0;i<_Eu.length;i++){var _Lx=_Eu[i];var item=this.GetItemByValue(_Lx);if(item==null){var _Jm=_D7.GetMemberOrMeasure(_Lx);var _BM=_Jm.GetLabel();item=this.AddItemToFront('dragged_in_member.gif',_BM,0,_Lx,_BM);_aer++;}}this._fF=_aer;this.Show();this.Notify(ExpEvent.kCUIListCtrl_OnExternalDataDrop);};CUIListCtrl.prototype.GetNewExternalDataCount=function(){return this._fF?this._fF:0;};function CUIListCtrlHeader(_JB,_H5){this.sResString=_JB;this.fPercent=_H5;};function CUIListCtrlItem(_Gm,_JB,_Q9,_FT,_QI,_RM,_Dl){if((_Gm!=null)&&(_Gm!='')){this.sIcon=_Gm;}this.sResString=_JB;this.iIndentLevel=0;this.iParentIdx=_Dl;this._qD=_RM?true:false;this._jw=null;this._br=null;this._x9=false;this._pb=false;if(!_FT){this.sValue=this.sResString;}else{this.sValue=_FT;}if(_Q9>0){this.iIndentLevel=_Q9;}if(_QI==null||_QI==""){var _QI=_JB;}this.sToolTip=_QI;this.sDefaultStyle="ListCtrlItem";};CUIListCtrlItem.prototype.SetDefaultStyle=function(_Jo){this.sDefaultStyle=_Jo;};CUIListCtrlItem.prototype.Unload=function(){if(this._br!=null){var _NH=document.getElementById(this._br);if(_NH){_NH.oListCtrl=null;}}};CUIListCtrlItem.prototype.IsSelected=function(){return this._qD;};CUIListCtrlItem.prototype.SetStyle=function(_Oe){if(!_Oe){var _Oe=document.getElementById(this._br);}if(!_Oe){return;}_Oe.className=this.sDefaultStyle;if(this._qD){_Oe.className+=" ListCtrlItem_Selected";}else if(this.bHover){_Oe.className+=" ListCtrlItem_Hover";}else if(this.bBlur){_Oe.className+=" ListCtrlItem_blur";}if(this._fO){_Oe.className+=" tempOperand";}var _O3=_Oe.firstChild.firstChild;if(_O3&&this._ar){_O3.className="invalidListCtrlItemLink";}else{_O3.className="ListCtrlItemLink";}};CUIListCtrlItem.prototype.GetLabel=function(){return this.sResString;};CUIListCtrlItem.prototype.GetValue=function(){return this.sValue;};CUIListCtrlItem.prototype.GetToolTip=function(){return this.sToolTip;};function CUIListCtrlSep(_CY,_JB){var _BM="";for(var i=0;i<_CY;i++){_BM+=_JB;}this.sResString=_BM;};CUIListCtrlSep.prototype.Unload=function(){};CUIListCtrlSep.prototype.GetValue=function(){return null;};function CUIToggleBar(_BM){this.sLabel=_BM;this.sTooltip=_BM;var _g=navigator.userAgent.toLowerCase().indexOf('firefox')!=-1?'_NS':'';this.sHeaderClass="ToggleBar"+_g;this.sTitleClass="ToggleBarTitle";this.sImgClass="ToggleBarArrow";};CUIToggleBar.prototype.Init=function(_EP,oOwner,_Qy){var _aFa=_EP.appendChild(document.createElement('TABLE'));COTStyle.SetWidth(_aFa,100,'%');this._cT=_aFa;_aFa.className=this.sHeaderClass;var _3h=_aFa.appendChild(document.createElement('TBODY'));var _NH=_3h.appendChild(document.createElement('TR'));var _ayx=_NH.appendChild(document.createElement('TD'));_ayx.className=this.sTitleClass;_ayx.appendChild(document.createTextNode(this.sLabel));_ayx.title=this.sLabel;this.sHeaderId="infoHeader"+Utilities.GenerateId();_ayx.id=this.sHeaderId;var _7x=_NH.appendChild(document.createElement('TD'));_7x.className=this.sImgClass;_7x.onmouseover=CUIToggleBar.SafeOnMouseOver;_7x.onmouseout=CUIToggleBar.SafeOnMouseOut;_7x.onmousedown=CUIToggleBar.SafeOnMouseDown;_7x.onclick=CUIToggleBar.SafeOnClick;COTStyle.SetWidth(_7x,12);_7x.oOwner=oOwner;_7x.fClick=_Qy;var _aca=_7x.appendChild(document.createElement('IMG'));_aca.src=Utilities.IMG_PATH+"show_area.gif";this.sToggleImgId="toggleImg"+Utilities.GenerateId();_aca.id=this.sToggleImgId;};CUIToggleBar.SafeOnMouseOver=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(this.oOwner&&this.oOwner.IsToggleDisabled&&this.oOwner.IsToggleDisabled()){return;}this.className+=" hide_show_hover";/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIToggleBar.SafeOnMouseOut=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/this.className="ToggleBarArrow";/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIToggleBar.SafeOnMouseDown=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(this.oOwner&&this.oOwner.IsToggleDisabled&&this.oOwner.IsToggleDisabled()){return;}this.className+=" hide_show_pressed";/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIToggleBar.SafeOnClick=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(this.oOwner&&this.oOwner.IsToggleDisabled&&this.oOwner.IsToggleDisabled()){return;}this.className="ToggleBarArrow";this.fClick.call(this,e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIToggleBar.prototype.Update=function(_WA,_TD){var _aFa=document.getElementById(this.sHeaderId);Debug.Assert(_aFa);if(_aFa){Dom.ReplaceText(_aFa,_WA);_aFa.title=_WA;}var _aFv=document.getElementById(this.sToggleImgId);_aFv.src=_TD?Utilities.IMG_PATH+"hide_area.gif":Utilities.IMG_PATH+"show_area.gif";};CUIToggleBar.prototype.DisableToggle=function(){var _aFv=document.getElementById(this.sToggleImgId);_aFv.parentNode.style.display='none';var _aav=document.getElementById(this.sHeaderId);COTStyle.SetHeight(_aav,15);};CUIToggleBar.prototype.EnableToggle=function(){var _aFv=document.getElementById(this.sToggleImgId);_aFv.parentNode.style.display='inline';};CUIToggleBar.prototype.InsertImgBeforeHeader=function(_Tf,_QI,_OV){if(!this._uX){var _aFa=document.getElementById(this.sHeaderId);Debug.Assert(_aFa);var _0i=_aFa.parentNode;var _Y4=document.createElement('TD');COTStyle.SetWidth(_Y4,16);_Y4.title=_QI;_Y4.appendChild(COTInputElementFactory.CreateImage(_Tf,16,16));_0i.insertBefore(_Y4,_aFa);this._uX='startImg'+Utilities.GenerateId();_Y4.id=this._uX;}};CUIToggleBar.prototype.RemoveImgBeforeHeader=function(){if(this._uX){var _atg=document.getElementById(this._uX);Dom.RemoveObject(_atg);this._uX=null;}};CUIToggleBar.prototype.Unload=function(){var _apI=document.getElementById(this.sToggleImgId);if(_apI){_apI.oOwner=null;_apI.fClick=null;}};function CUIDialogTitleBar(_BM,_Mx){this.sLabel=_BM;this.sTooltip=_BM;var _g=navigator.userAgent.toLowerCase().indexOf('firefox')!=-1?'_NS':'';this.sHeaderClass="DlgTitleBar"+_g;this.sTitleClass="DlgTitle"+_g;this.sImgClass="DlgCloseIcon";this.sAppName=_Mx;};CUIDialogTitleBar.prototype=new CUIToggleBar;CUIDialogTitleBar.superclass=CUIToggleBar.prototype;CUIDialogTitleBar.prototype.Init=function(_J0,_Kz,_IQ,_FY){var _aFa=document.createElement('TABLE');COTStyle.SetWidth(_aFa,100,'%');this._cT=_aFa;_aFa.className=this.sHeaderClass;var _3h=_aFa.appendChild(document.createElement('TBODY'));var _NH=_3h.appendChild(document.createElement('TR'));var _ayx=_NH.appendChild(document.createElement('TD'));_ayx.className=this.sTitleClass;_ayx.appendChild(document.createTextNode(this.sLabel));_ayx.title=this.sLabel;this.sHeaderId="infoHeader"+Utilities.GenerateId();_ayx.id=this.sHeaderId;if(_Kz){var _aGQ=_NH.appendChild(document.createElement('TD'));_aGQ.align='right';var _aia=COTInputElementFactory.CreateLink(_IQ,_Kz,false,'helplink');_aGQ.appendChild(_aia);}var _7x=_NH.appendChild(document.createElement('TD'));_7x.className=this.sImgClass;var _Ke=this.sAppName;var _GB=Utilities.GenerateCallback(CUIDialogMgr.SafeHideCurrentDialog,[_Ke]);_7x.onclick=_FY?_FY:_GB;COTStyle.SetWidth(_7x,16);var _afa=_7x.appendChild(document.createElement('IMG'));_afa.src=Utilities.IMG_PATH+"close.gif";_afa.alt=_J0;_afa.title=_J0;this.sToggleImgId="toggleImg"+Utilities.GenerateId();_afa.id=this.sToggleImgId;return this._cT;};CUIDialogTitleBar.prototype.Update=function(_WA){var _aFa=document.getElementById(this.sHeaderId);Debug.Assert(_aFa);if(_aFa){Dom.ReplaceText(_aFa,_WA);_aFa.title=_WA;}};function CUIDefaultAnalysisDlg(){this.base=CUIDialog;this.base();this._xs=null;this._eP=null;this._T=null;};CUIDefaultAnalysisDlg.prototype=new CUIDialog;CUIDefaultAnalysisDlg.superclass=CUIDialog.prototype;CUIDefaultAnalysisDlg.prototype.Init=function(_yt){CUIPromptDlg.superclass.Init.call(this,_yt,false,true);this._gl=Utilities.GenerateCallback(CUIDialogMgr.SafeHandleExit,[this.sAppName]);this.SetModalState();};CUIDefaultAnalysisDlg.prototype.Display=function(_BK,_Ty,_KH){window.oUIManager._v5=true;var _Ke=this.sAppName;this.oDialogMgr.ActivateModalDlgTemplate();this.oDialogMgr.SetModalDlgWidth(CUIDialogMgr.iDefaultDlgPcntOfTWidth);var _zr=document.createElement('TABLE');_zr.className='DefaultANSTable';var _F0=document.createElement('TBODY');var _NH=document.createElement('TR');var _NM=this._gM.cloneNode(false);var _Ro=new Array(_Ke,DefaultAnalysis.kBlank);var _Si=this.oRes.GetString('IDS_BLANK_ANALYSIS');var _Xf=Utilities.GenerateCallback(CUIDefaultAnalysisDlg.SetDefaultAnalysis,_Ro);var _ae4=document.createElement('div');_ae4.className='DefaultANSCellDiv';_ae4.onclick=_Xf;var _4w=COTInputElementFactory.CreateImage('icon_analysis_blank.gif',32,32);var _amh=COTInputElementFactory.CreateLabel(_Si);this._eP=document.createElement('SPAN');this._eP.className='DefaultANSTableTextDiv';this._eP.appendChild(_amh);_ae4.appendChild(_4w);_ae4.appendChild(document.createElement('BR'));_ae4.appendChild(this._eP);_NM.appendChild(_ae4);_NH.appendChild(_NM);_NM=this._gM.cloneNode(false);_Ro=new Array(_Ke,DefaultAnalysis.kServerDefault);_Si=this.oRes.GetString('IDS_DEFAULT_ANALYSIS');_Xf=Utilities.GenerateCallback(CUIDefaultAnalysisDlg.SetDefaultAnalysis,_Ro);var _9V=document.createElement('div');_9V.className='DefaultANSCellDiv';_9V.onclick=_Xf;_4w=COTInputElementFactory.CreateImage('icon_analysis_default.gif',32,32);_amh=COTInputElementFactory.CreateLabel(_Si);this._T=document.createElement('SPAN');this._T.className='DefaultANSTableTextDiv';this._T.appendChild(_amh);_9V.appendChild(_4w);_9V.appendChild(document.createElement('BR'));_9V.appendChild(this._T);_NM.appendChild(_9V);_NH.appendChild(_NM);_F0.appendChild(_NH);_NH=document.createElement('TR');_NM=document.createElement("TD");_NM.className='showOption';this._qv=COTInputElementFactory.CreateCheckBox('showWelcome',ExpAPIXml.kTrue,true);_NM.colSpan=2;COTStyle.SetWidth(_NM,100,'%');_NM.appendChild(this._qv);_amh=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_NOT_REMEMBER_WELCOME_DLG'));_NM.appendChild(_amh);_NH.appendChild(_NM);_F0.appendChild(_NH);_zr.appendChild(_F0);this._om=1;this._lq=_zr;var _KP=this.oRes.GetString('IDS_WELCOME_ANALYSIS');if(_KH){_KP=_KH;}var _MY=new Object();var _Xf=Utilities.GenerateCallback(CUIManager.SafeDoHelpTopic,[_Ke,HelpConstants.kDefaultAnalysisLink]);_MY['IDS_HELP']=_Xf;_Ro=new Array(_Ke);var _Hc=Utilities.GenerateCallback(CUIDefaultAnalysisDlg.SafeDoOK,_Ro);this._Y=_Hc;this._of=this._gl;this.FocusOnDefault(DefaultAnalysis.kBlank);var _ajX=new Array(DefaultAnalysis.kBlank);var _BC=Utilities.GenerateCallback(this.SetMouseOverStyle,_ajX,this);_ae4.onmouseover=_BC;_BC=Utilities.GenerateCallback(this.SetMouseOutStyle,_ajX,this);_ae4.onmouseout=_BC;_ajX=new Array(DefaultAnalysis.kServerDefault);_BC=Utilities.GenerateCallback(this.SetMouseOverStyle,_ajX,this);_9V.onmouseover=_BC;_BC=Utilities.GenerateCallback(this.SetMouseOutStyle,_ajX,this);_9V.onmouseout=_BC;CUIDefaultAnalysisDlg.superclass.Display.call(this,_KP,_MY,this._lq);_zr.parentNode.className='modalDialogInfoDiv';};CUIDefaultAnalysisDlg.prototype.FocusOnDefault=function(_Si){if(_Si==DefaultAnalysis.kBlank){this._eP.className='DefaultANSTableText_selected';this._T.className='DefaultANSTableTextDiv';}else{this._T.className='DefaultANSTableText_selected';this._eP.className='DefaultANSTableTextDiv';}this._xs=_Si;};CUIDefaultAnalysisDlg.SafeDoOK=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).UpdateDefaultAnalysis(CUIDialogMgr._tR._xs,true,CUIDialogMgr._tR._qv.checked);FindApp(_Ke).uiManager.dataManager.IssueInitialRequest();window.oUIManager._v5=false;CUIDialogMgr.SafeHideCurrentDialog(_Ke);/*@if(!@bering_debug)@*/}catch(excep){_f.HandleException(excep);}/*@end@*/};CUIDefaultAnalysisDlg.SetDefaultAnalysis=function(_Ke,_Si){/*@if(!@bering_debug)@*/try{/*@end@*/CUIDialogMgr._tR.FocusOnDefault(_Si);/*@if(!@bering_debug)@*/}catch(excep){_f.HandleException(excep);}/*@end@*/};CUIDefaultAnalysisDlg.prototype.SetMouseOutStyle=function(_OD){if(this._xs!=_OD){var _38=(_OD==DefaultAnalysis.kBlank)?this._eP:this._T;_38.className="DefaultANSTableTextDiv";}};CUIDefaultAnalysisDlg.prototype.SetMouseOverStyle=function(_OD){if(this._xs!=_OD){var _38=(_OD==DefaultAnalysis.kBlank)?this._eP:this._T;_38.className="DefaultANSTableText_hover";}};function CUIDiffMiningResultDlg(_KV){this.base=CUIDialog;this.base();this._s8=_KV;this._bV=new Array();this._vU=new Array();this._jr=new Array();};CUIDiffMiningResultDlg.prototype=new CUIDialog;CUIDiffMiningResultDlg.superclass=CUIDialog.prototype;CUIDiffMiningResultDlg.prototype.Init=function(_yt,_Sb){CUIDiffMiningResultDlg.superclass.Init.call(this,_yt,_Sb);this.oDialogMgr.oUIMgr._jf.Subscribe(this,ExpEvent.kCUIWorksheet_ChangedBlockSel);this._of=Utilities.GenerateCallback(this.DoCancel,[],this);};CUIDiffMiningResultDlg.prototype.ClearDlg=function(){if(this._vO){Dom.RemoveAllChildren(this._vO);}this._bV=new Array();this._vU=new Array();this._jr=new Array();};CUIDiffMiningResultDlg.OpenNewAnalysisFromDiffMining=function(_SD){window.oUIManager.appobj.OpenHLSFromDiffMining(_SD);};CUIDiffMiningResultDlg.ShowDiffMiningResultsReqTemplate='<ShowDiffMiningResults>'+'<cube>@CUBE_NAME@</cube>'+'<rowTerms>@ROW_TERMS@</rowTerms>'+'<colMuns>@COL_MUNS@</colMuns>'+'<contextMuns>@CONTEXT_MUNS@</contextMuns>'+'</ShowDiffMiningResults>';CUIDiffMiningResultDlg.rowTermsTemplate='<rowTerm>@ROW_TERM@</rowTerm>';CUIDiffMiningResultDlg.itemTemplate='<item>@ITEM@</item>';CUIDiffMiningResultDlg.genBlockRef=function(id){return '<blockRef value="'+id+'"/>';};CUIDiffMiningResultDlg.XjoinBlocks=function(_Jc){_asL='';if(_Jc.length==1){_asL=CUIDiffMiningResultDlg.genBlockRef(_Jc[0]);}else{_asL='<crossJoin>';_asL+=CUIDiffMiningResultDlg.genBlockRef(_Jc[0]);_asL+=CUIDiffMiningResultDlg.genBlockRef(_Jc[1]);_asL+='</crossJoin>';for(var i=2;i<_Jc.length;++i){_asL='<crossJoin>'+_asL;_asL+=CUIDiffMiningResultDlg.genBlockRef(_Jc[i]);_asL+='</crossJoin>';}}return _asL;};CUIDiffMiningResultDlg.UnionExprs=function(_WD){unionExpr='';if(_WD.length==1){unionExpr=_1A[0];}else{unionExpr='<union>';unionExpr+=_WD[0];unionExpr+=_WD[1];unionExpr+='</union>';for(var i=2;i<_WD.length;++i){unionExpr='<union>'+unionExpr;unionExpr+=_WD[i];unionExpr+='</union>';}}return unionExpr;};CUIDiffMiningResultDlg.ShowMeSelectedInNewAnalysis=function(_Ke,_Kx){var _aEt=FindApp(_Ke).uiManager.oDialogMgr._jg._s8;var _adX=new Array();for(var i=0;i<_Kx.length;++i){var _agE=document.getElementById(_Kx[i]);if(_agE.checked){var _3i=_aEt.diffResult[i];_adX.push(_3i);}}var _aqR=Array();for(var i=0;i<_adX.length;++i){_SH=_adX[i];var _4G=new Array();for(var j=0;j<_SH._xP.length;++j){_3w=_SH._xP[j];_Ti=_SH._vR[_3w];_4G.push(_Ti);}var _asL=CUIDiffMiningResultDlg.XjoinBlocks(_4G);_aqR.push(_asL);}var _amZ=CUIDiffMiningResultDlg.UnionExprs(_aqR);var _aza=_aEt.templateHls;_aza=_aza.replace('@ROW_AXIS_EXPR@',_amZ);CUIDiffMiningResultDlg.OpenNewAnalysisFromDiffMining(_aza);};CUIDiffMiningResultDlg.prototype.Draw=function(){this.ClearDlg();var _zr=document.createElement('TABLE');this._vO=_zr;COTStyle.SetHeight(_zr,110);_zr.className='dialogTable';var _Ke=this.sAppName;var _RK=_zr.appendChild(document.createElement('TBODY'));this._xS=_RK;var _QA=this.oDialogMgr.oUIMgr.dataManager.metadata;var _NH=document.createElement('TR');var _NM=this._l4.cloneNode(false);var _TL=document.createTextNode(' ');_NM.appendChild(_TL);_NH.appendChild(_NM);var _aty=this._s8.resultInfo[0]._e0;for(var i=0;i<_aty.length;++i){var _NM=this._l4.cloneNode(false);var _acZ=document.createTextNode(_QA.GetDimById(_aty[i]).GetLabel());_NM.appendChild(_acZ);_NH.appendChild(_NM);}var _aiA=new Array();var _Dz=this._s8.resultInfo[0]._qt;var _DA=this._s8.resultInfo[0]._aC;var _NM=this._l4.cloneNode(false);var _Ic='';for(var i=0;i<_Dz.length;++i){if(Utilities.IsInArray(_DA,_Dz[i])){_aiA.push(_Dz[i]);this._jr.push(_Dz[i]);}else{if(_Ic!=''){_Ic+=", ";}_Ic+=_QA.GetDataById(_Dz[i]).GetLabel();this._vU.push(_Dz[i]);}}var _WO="Context: ";for(var i=0;i<_aiA.length;++i){if(i!=0){_WO+=", ";}_WO+=_QA.GetDataById(_aiA[i]).GetLabel();}var _5V=document.createElement('TR');var _7M=this._l4.cloneNode(false);_7M.colSpan=3;var _3b=document.createTextNode(_WO);_7M.appendChild(_3b);_5V.appendChild(_7M);_RK.appendChild(_5V);var _acZ=document.createTextNode(_Ic);_NM.appendChild(_acZ);_NH.appendChild(_NM);_NM=this._l4.cloneNode(false);_Ic='';for(var i=0;i<_DA.length;++i){if(!Utilities.IsInArray(_Dz,_DA[i])){if(_Ic!=''){_Ic+=", ";}_Ic+=_QA.GetDataById(_DA[i]).GetLabel();this._vU.push(_DA[i]);}}_acZ=document.createTextNode(_Ic);_NM.appendChild(_acZ);_NH.appendChild(_NM);_RK.appendChild(_NH);var _5o=this._s8.diffResult;for(var i=0;i<_5o.length;i++){var _NH=document.createElement('TR');var _aow=this._g5.cloneNode(false);var _agE=new CUICheckBox(_aow,'',ExpAPIXml.kEleAxisOpExprShowVisible,false,null,false);this._bV.push(_agE.elCheckBox.id);_NH.appendChild(_aow);for(var _aGS=0;_aGS<_5o[i]._xP.length;_aGS++){var _3w=_5o[i]._xP[_aGS];var _TL=_QA.GetMemberOrMeasure(_3w).GetLabel();var _acZ=document.createTextNode(_TL);var _NM=this._g5.cloneNode(false);_NM.appendChild(_acZ);_NH.appendChild(_NM);}var _NM=this._g5.cloneNode(false);var _X8=document.createTextNode(_5o[i]._bu);_NM.appendChild(_X8);_NH.appendChild(_NM);_NM=this._g5.cloneNode(false);_X8=document.createTextNode(_5o[i]._bt);_NM.appendChild(_X8);_NH.appendChild(_NM);var _Xf=Utilities.GenerateCallback(CUIDiffMiningResultDlg.OpenNewAnalysisFromDiffMining,[_5o[i]._iH]);var _ZL=document.createElement('TD');_NH.appendChild(_ZL);_ZL.className='dlginnerlink';_ZL.appendChild(COTInputElementFactory.CreateLink(_Xf,'Show Me',true));_RK.appendChild(_NH);}var _NH=document.createElement('TR');var _Xf=Utilities.GenerateCallback(CUIDiffMiningResultDlg.ShowMeSelectedInNewAnalysis,[this.sAppName,this._bV]);var _alf=document.createElement('TD');_NH.appendChild(_alf);_alf.className='dlginnerlink';_alf.style.textAlign='left';var _av6=COTInputElementFactory.CreateLink(_Xf,'Show Me Seleted',true);Dom.SetObjRef(_av6,this,'oDiffMiningResultDlg');_alf.appendChild(_av6);_RK.appendChild(_NH);};CUIDiffMiningResultDlg.prototype.Display=function(){this.Draw();var _MY=new Array();CUIDiffMiningResultDlg.superclass.Display.call(this,'Results for Difference Analysis',_MY,this._vO,'');};CUIDiffMiningResultDlg.prototype.Unload=function(){Dom.RemoveObject(this._vO);this._s8=null;this._bV=null;this._vU=null;this._jr=null;CUIDiffMiningResultDlg.superclass.Unload.call(this);};CUIDiffMiningResultDlg.prototype.Notify=function(_Dy){};CUIDiffMiningResultDlg.SafeDoCancel=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager.oDialogMgr._jg.DoCancel(_Ke);/*@if(!@bering_debug)@*/}catch(excep){_f.HandleException(excep);}/*@end@*/};CUIDiffMiningResultDlg.prototype.DoCancel=function(_Ke){this.Unload();CUIDialogMgr.SafeHideCurrentDialog(_Ke);};function CUIAnalyzeDifferencesDlg(_Dz,_Fz,_DA,_Fy){this.base=CUIDialog;this.base();self._qt=_Dz;self._gZ=_Fz;self._aC=_DA;self._g2=_Fy;this.aDimsToAnalyze=new Array();this.aLevelComboBoxes=new Array();this.aMemsToAnalyze=new Array();this.aMemLevelComboBoxes=new Array();this.aAnalysisScopeItems=new Array();};CUIAnalyzeDifferencesDlg.prototype=new CUIDialog;CUIAnalyzeDifferencesDlg.superclass=CUIDialog.prototype;CUIAnalyzeDifferencesDlg.prototype.Init=function(_yt,_Sb){CUIAnalyzeDifferencesDlg.superclass.Init.call(this,_yt,_Sb);this.oDialogMgr.oUIMgr._jf.Subscribe(this,ExpEvent.kCUIWorksheet_ChangedBlockSel);this.oDialogMgr.oUIMgr.AddDropDestination(this);this._of=Utilities.GenerateCallback(this.DoCancel,[],this);};CUIAnalyzeDifferencesDlg.prototype.ClearDlg=function(){if(this._vO){Dom.RemoveAllChildren(this._vO);}this.aDimsToAnalyze=new Array();this.aLevelComboBoxes=new Array();this.aMemsToAnalyze=new Array();this.aMemLevelComboBoxes=new Array();this.aAnalysisScopeItems=new Array();};CUIAnalyzeDifferencesDlg.prototype.DrawHeadings=function(){Dom.RemoveAllChildren(this._xS);var _RK=this._vO.appendChild(document.createElement('TBODY'));this._xS=_RK;var _NH=document.createElement('TR');var _NM=this._l4.cloneNode(false);var _Y3=document.createTextNode('Analyze From Member');_NM.appendChild(_Y3);_NH.appendChild(_NM);_NM=this._l4.cloneNode(false);var _aIs=document.createTextNode('Analyze Down to Level');_NM.appendChild(_aIs);_NH.appendChild(_NM);this._xS.appendChild(_NH);};CUIAnalyzeDifferencesDlg.prototype.DrawDimDZ=function(){var _NH=document.createElement('TR');var _NM=this._l4.cloneNode(false);_NH.onmouseover=CUIAnalyzeDifferencesDlg.SafeHandleMouseOver;_NH.onmouseout=CUIAnalyzeDifferencesDlg.SafeHandleMouseOut;Dom.SetObjRef(_NH,this,'oAnalyzeDiffDlg');this.elDZTR=_NH;var _7E=_NM.appendChild(document.createElement('IMG'));_7E.src=Utilities.IMG_PATH+"drag_drop.gif";var _aA1=document.createTextNode(' Drop a Dimension to Analyze Here.');_NM.appendChild(_aA1);_NH.appendChild(_NM);this._xS.appendChild(_NH);};CUIAnalyzeDifferencesDlg.prototype.Draw=function(){this.ClearDlg();var _zr=document.createElement('TABLE');this._vO=_zr;COTStyle.SetHeight(_zr,170);_zr.className='dialogTable';var _Ke=this.sAppName;this.DrawHeadings();this.DrawDimDZ();this._Y=Utilities.GenerateCallback(this.DoConstructAnalyzeDiffsReq,[],this);};CUIAnalyzeDifferencesDlg.prototype.Display=function(){this.Draw();var _MY=new Array();CUIAnalyzeDifferencesDlg.superclass.Display.call(this,'Analyze Differences',_MY,this._vO,'Analyze Differences Instructions');};CUIAnalyzeDifferencesDlg.prototype.Unload=function(){Dom.RemoveObject(this._vO);this.oDialogMgr.oUIMgr.RemoveDropDestination(this);this.aDimsToAnalyze=null;this.aLevelComboBoxes=null;this.aMemsToAnalyze=null;this.aMemLevelComboBoxes=null;this.aAnalysisScopeItems=null;CUIAnalyzeDifferencesDlg.superclass.Unload.call(this);};CUIAnalyzeDifferencesDlg.prototype.Notify=function(_Dy){};CUIAnalyzeDifferencesDlg.SafeHandleMouseOver=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/this.oAnalyzeDiffDlg.HandleMouseOver(e);/*@if(!@bering_debug)@*/}catch(excep){_f.HandleException(excep);}/*@end@*/};CUIAnalyzeDifferencesDlg.prototype.HandleMouseOver=function(e){if(!e){var e=window.event;}var _N9=Dom.GetEventTarget(e);if(CUIDragDrop.IsDragging()){this.HandleDragOver(e);return;}};CUIAnalyzeDifferencesDlg.SafeHandleMouseOut=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/this.oAnalyzeDiffDlg.HandleMouseOut(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIAnalyzeDifferencesDlg.prototype.HandleMouseOut=function(e){if(!e){var e=window.event;}var _N9=Dom.GetEventTarget(e);if(this.isLeavingActiveDropZone(e)){this.HideReplaceDZ(_N9);return;}};CUIAnalyzeDifferencesDlg.prototype.isLeavingActiveDropZone=function(e){var _yW=Dom.GetEventTarget(e);if(CUIDragDrop.IsDragging()){var _aqw=Dom.GetToElement(e);if(_aqw!=_yW){return true;}}return false;};CUIAnalyzeDifferencesDlg.prototype.SafeHandleDragOver=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}this.oAnalyzeDiffDlg.HandleDragOver(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIAnalyzeDifferencesDlg.prototype.HandleDragOver=function(e){if(!e){var e=window.event;}Dom.CancelEvent(e);var _N9=Dom.GetEventTarget(e);if(_N9.tagName=='IMG'){_N9=_N9.parentNode;}CUIDragDrop.setEffect(CUIDragDrop.eEffectCopy);CUIDragDrop.SetCursorImgPosition(e.clientX,e.clientY);window.status="copy effect cursor";var _adn=this.IsValidDropTarget(_N9,this._oM);if(_adn){this.HighLightReplaceDZ(_N9);CUIDragDrop.SetCursorImgPosition(e.clientX,e.clientY);_N9.bValidTgt=true;window.status="valid DZ";}else{this.handleInvalidDZ(e);CUIDragDrop.SetCursorImgPosition(e.clientX,e.clientY);_N9.bValidTgt=false;}};CUIAnalyzeDifferencesDlg.prototype.IsValidDropTarget=function(_yW,_Lv){if(!_Lv){return false;}var _QA=this.oDialogMgr.oUIMgr.dataManager.metadata;var _Ni=_QA.GetDataById(_Lv.sId).GetDim();if(_Ni){return true;}else{return false;}};CUIAnalyzeDifferencesDlg.prototype.HighLightReplaceDZ=function(_yW){_yW.style.backgroundColor="#C0C0C0";};CUIAnalyzeDifferencesDlg.prototype.HideReplaceDZ=function(_yW){_yW.style.backgroundColor="#FFFFFF";};CUIAnalyzeDifferencesDlg.prototype.GetDIVObj=function(){return this.elDZTR;};CUIAnalyzeDifferencesDlg.prototype.handleInvalidDZ=function(e){window.status="Invalid DZ";CUIDragDrop.setEffect(CUIDragDrop.eEffectNone);CUIDragDrop.SetCursorImgPosition(e.clientX,e.clientY);};CUIAnalyzeDifferencesDlg.prototype.SafeHandleDragDrop=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}this.oAnalyzeDiffDlg.HandleDragDrop(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIAnalyzeDifferencesDlg.prototype.HandleDragDrop=function(e){if(!this._oM){return;}if(!e){var e=window.event;}Dom.CancelEvent(e);var _N9=Dom.GetEventTarget(e);if(_N9.tagName=='IMG'){_N9=_N9.parentNode;}if(_N9.bValidTgt){var _Ak=this._oM.sId;this.AddMemToAnalyze(_Ak);this.HideReplaceDZ(_N9);}CUIDragDrop.setEffect(CUIDragDrop.eEffectNone);CUIDragDrop.SetCursorImgPosition(e.clientX,e.clientY);this._oM=null;};CUIAnalyzeDifferencesDlg.prototype.AddMemToAnalyze=function(_Ak){var _QA=this.oDialogMgr.oUIMgr.dataManager.metadata;var oMem=_QA.GetMember(_Ak);this.aMemsToAnalyze.push(oMem);var oComboBox=this.CreateMemLevelComboBox(oMem);this.aMemLevelComboBoxes.push(oComboBox);this.DrawHeadings();for(var i=0;i<this.aMemsToAnalyze.length;++i){var _NH=document.createElement('TR');_NM=this._gM.cloneNode(false);var _Y3=document.createTextNode(this.aMemsToAnalyze[i].GetLabel());_NM.appendChild(_Y3);_NH.appendChild(_NM);_NM=this._gM.cloneNode(false);var oComboBox=this.aMemLevelComboBoxes[i];_NM.appendChild(oComboBox._vO);_NH.appendChild(_NM);this._xS.appendChild(_NH);}this.DrawDimDZ();};CUIAnalyzeDifferencesDlg.prototype.CreateMemLevelComboBox=function(oMem){var _ajQ=new CUIListCtrl(this.oDialogMgr.oUIMgr);_ajQ.iMaxHeight=150;_ajQ.Init();_ajQ.DisableHAutoScroll();var _avv=new CUIComboBox(this.oDialogMgr.oUIMgr,_ajQ);var _afs=_avv.Init();_avv.DisableIcon();var _QA=this.oDialogMgr.oUIMgr.dataManager.metadata;var _7N=oMem.GetLevel();if(_7N){var _aml=oMem.GetHierarchy()._gD;var _aj1=false;var _ac8=false;for(_E1 in _aml){if(_E1==_7N.GetId()){_ac8=true;_aj1=true;}if(_ac8){var _LX=_avv.oListCtrl.AddItem('',_aml[_E1].GetLabel(),0,_aml[_E1].GetId(),_aml[_E1].GetLabel());}if(_aj1){_avv.SetValueFromListItem(_LX);}_aj1=false;}return _avv;}else{return null;}};CUIAnalyzeDifferencesDlg.prototype.SetDropData=function(_FZ){this._oM=_FZ;};CUIAnalyzeDifferencesDlg.prototype.AddDimToAnalyze=function(_Ak){var _QA=this.oDialogMgr.oUIMgr.dataManager.metadata;var _Ni=_QA.GetDataById(_Ak).GetDim();this.aDimsToAnalyze.push(_Ni);var oComboBox=this.CreateDimLevelComboBox(_Ni);this.aLevelComboBoxes.push(oComboBox);this.DrawHeadings();for(var i=0;i<this.aDimsToAnalyze.length;++i){var _NH=document.createElement('TR');_NM=this._gM.cloneNode(false);var _WJ=document.createTextNode(this.aDimsToAnalyze[i].GetLabel());_NM.appendChild(_WJ);_NH.appendChild(_NM);_NM=this._gM.cloneNode(false);var oComboBox=this.aLevelComboBoxes[i];_NM.appendChild(oComboBox._vO);_NH.appendChild(_NM);this._xS.appendChild(_NH);}this.DrawDimDZ();};CUIAnalyzeDifferencesDlg.prototype.CreateDimLevelComboBox=function(_Ni){var _ajQ=new CUIListCtrl(this.oDialogMgr.oUIMgr);_ajQ.iMaxHeight=150;_ajQ.Init();_ajQ.DisableHAutoScroll();var _avv=new CUIComboBox(this.oDialogMgr.oUIMgr,_ajQ);var _afs=_avv.Init();_avv.DisableIcon();var _QA=this.oDialogMgr.oUIMgr.dataManager.metadata;var _aml;if(_Ni.GetDefaultHierarchy()){_aml=_Ni.GetDefaultHierarchy()._gD;}else if(_Ni._bj){_aml=_Ni._bj._gD;}else{var _Ts=Utilities.GetNthFromObjArray(_Ni._j5,1);_aml=_Ts._gD;}var _aj1=true;for(_E1 in _aml){var _LX=_avv.oListCtrl.AddItem('',_aml[_E1].GetLabel(),0,_aml[_E1].GetId(),_aml[_E1].GetLabel());if(_aj1){_avv.SetValueFromListItem(_LX);}_aj1=false;}return _avv;};CUIAnalyzeDifferencesDlg.prototype.DoConstructAnalyzeDiffsReq=function(){for(var i=0;i<this.aMemsToAnalyze.length;++i){var _afN=new Object();_afN.mem=this.aMemsToAnalyze[i].GetId();_afN.level=this.aMemLevelComboBoxes[i].GetValue();this.aAnalysisScopeItems.push(_afN);}this.oDialogMgr.oUIMgr.dataManager.GetCurrentWorkSheet().DiffMining(self._qt,self._gZ,self._aC,self._g2,this.aAnalysisScopeItems);var _Ke=this.sAppName;CUIDialogMgr.SafeHideCurrentDialog(_Ke);this.Unload();};CUIAnalyzeDifferencesDlg.prototype.DoCancel=function(_Ke){this.Unload();CUIDialogMgr.SafeHideCurrentDialog(_Ke);};function CUIQuadrantSegmentingDlg(){this.base=CUIDialog;this.base();this._pD=0;this._oN=0;this._nA=0;this._mj=0;this._ox=new Array();};CUIQuadrantSegmentingDlg.prototype=new CUIDialog;CUIQuadrantSegmentingDlg.superclass=CUIDialog.prototype;CUIQuadrantSegmentingDlg.prototype.Init=function(_yt,_Sb){CUIAnalyzeDifferencesDlg.superclass.Init.call(this,_yt,_Sb);this.oDialogMgr.oUIMgr._jf.Subscribe(this,ExpEvent.kCUIWorksheet_ChangedBlockSel);this.oDialogMgr.oUIMgr.AddDropDestination(this);this._of=Utilities.GenerateCallback(this.DoCancel,[],this);};CUIQuadrantSegmentingDlg.prototype.SetHostBlock=function(_FK){this.oBlock=_FK;};CUIQuadrantSegmentingDlg.prototype.ClearDlg=function(){if(this._vO){Dom.RemoveAllChildren(this._vO);}};CUIQuadrantSegmentingDlg.prototype.DrawMeasureDZ=function(){var _NH=document.createElement('TR');this.elDZTR=_NH;for(var i=0;i<2;i++){var _NM=this._l4.cloneNode(false);if(i<1){this.elM1DZ=_NM;}else{this.elM2DZ=_NM;}COTStyle.SetHeight(_NM,80,'px');_NH.onmouseover=Utilities.EventCallback(this.HandleMouseOver,[],this,false,true);_NH.onmouseout=Utilities.EventCallback(this.HandleMouseOut,[],this,false,true);Dom.SetObjRef(_NH,this,'oSegWizardDlg');var _7E=_NM.appendChild(document.createElement('IMG'));_7E.src=Utilities.IMG_PATH+"drag_drop.gif";var _aA1=document.createTextNode(' Drop your measure here.');_NM.appendChild(_aA1);_NH.appendChild(_NM);}this._xS.appendChild(_NH);};CUIQuadrantSegmentingDlg.prototype.Draw=function(){this.ClearDlg();var _zr=document.createElement('TABLE');this._vO=_zr;_zr.className='dialogTable';var _Ke=this.sAppName;var _RK=this._vO.appendChild(document.createElement('TBODY'));this._xS=_RK;var _NH=document.createElement('TR');this._xS.appendChild(_NH);var _NM=this._l4.cloneNode(false);_NM.appendChild(document.createTextNode('First Measure for segmenting:'));COTStyle.SetHeight(_NM,40,'px');_NH.appendChild(_NM);_NM=this._l4.cloneNode(false);_NM.appendChild(document.createTextNode('Second Measure for segmenting:'));_NH.appendChild(_NM);this.DrawMeasureDZ();this._Y=Utilities.GenerateCallback(this.DoCreateSegmentingBaseSet,[],this);};CUIQuadrantSegmentingDlg.prototype.Display=function(){this.Draw();var _MY=new Array();CUIQuadrantSegmentingDlg.superclass.Display.call(this,'Quadrant Segmenting Wizard',_MY,this._vO,'Specify your segmenting parameter');};CUIQuadrantSegmentingDlg.prototype.Unload=function(){Dom.RemoveObject(this._vO);this.oDialogMgr.oUIMgr.RemoveDropDestination(this);CUIQuadrantSegmentingDlg.superclass.Unload.call(this);};CUIQuadrantSegmentingDlg.prototype.Notify=function(_Dy){};CUIQuadrantSegmentingDlg.prototype.HandleMouseOver=function(e){if(!e){var e=window.event;}var _N9=Dom.GetEventTarget(e);if(CUIDragDrop.IsDragging()){this.HandleDragOver(e);return;}};CUIQuadrantSegmentingDlg.prototype.HandleMouseOut=function(e){if(!e){var e=window.event;}var _N9=Dom.GetEventTarget(e);if(this.isLeavingActiveDropZone(e)){this.HideReplaceDZ(_N9);return;}};CUIQuadrantSegmentingDlg.prototype.isLeavingActiveDropZone=function(e){var _yW=Dom.GetEventTarget(e);if(CUIDragDrop.IsDragging()){var _aqw=Dom.GetToElement(e);if(_aqw!=_yW){return true;}}return false;};CUIQuadrantSegmentingDlg.prototype.HandleDragOver=function(e){if(!e){var e=window.event;}Dom.CancelEvent(e);var _N9=Dom.GetEventTarget(e);if(_N9.tagName=='IMG'){_N9=_N9.parentNode;}CUIDragDrop.setEffect(CUIDragDrop.eEffectCopy);CUIDragDrop.SetCursorImgPosition(e.clientX,e.clientY);window.status="copy effect cursor";var _adn=this.IsValidDropTarget(_N9,this._oM);if(_adn){this.HighLightReplaceDZ(_N9);CUIDragDrop.SetCursorImgPosition(e.clientX,e.clientY);_N9.bValidTgt=true;window.status="valid DZ";}else{this.handleInvalidDZ(e);CUIDragDrop.SetCursorImgPosition(e.clientX,e.clientY);_N9.bValidTgt=false;}};CUIQuadrantSegmentingDlg.prototype.IsValidDropTarget=function(_yW,_Lv){if(!_Lv){return false;}var _QA=this.oDialogMgr.oUIMgr.dataManager.metadata;var _NS=_QA.GetMeasure(_Lv.sId);if(_NS){return true;}else{return false;}};CUIQuadrantSegmentingDlg.prototype.HighLightReplaceDZ=function(_yW){_yW.style.backgroundColor="#C0C0C0";};CUIQuadrantSegmentingDlg.prototype.HideReplaceDZ=function(_yW){_yW.style.backgroundColor="#FFFFFF";};CUIQuadrantSegmentingDlg.prototype.GetDIVObj=function(){return this.elDZTR;};CUIQuadrantSegmentingDlg.prototype.handleInvalidDZ=function(e){window.status="Invalid DZ";CUIDragDrop.setEffect(CUIDragDrop.eEffectNone);CUIDragDrop.SetCursorImgPosition(e.clientX,e.clientY);};CUIQuadrantSegmentingDlg.prototype.SafeHandleDragDrop=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}this.oSegWizardDlg.HandleDragDrop(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIQuadrantSegmentingDlg.prototype.HandleDragDrop=function(e){if(!this._oM){return;}if(!e){var e=window.event;}var _N9=Dom.GetEventTarget(e);if(_N9.tagName=='IMG'){_N9=_N9.parentNode;}if(_N9.bValidTgt){var _Ak=this._oM.sId;this.AddQuadrantMeasure(_Ak,_N9);this.HideReplaceDZ(_N9);}this._oM=null;};CUIQuadrantSegmentingDlg.prototype.AddQuadrantMeasure=function(_Ak,_NM){var _QA=this.oDialogMgr.oUIMgr.dataManager.metadata;var _NS=_QA.GetMeasure(_Ak);if(this.elM1DZ==_NM){this._ox[0]=_Ak;}else if(this.elM2DZ==_NM){this._ox[1]=_Ak;}Dom.RemoveAllChildren(_NM);var _7E=_NM.appendChild(COTInputElementFactory.CreateImage('measure.gif',16,16));_7E.src=Utilities.IMG_PATH+"measure.gif";var _aA1=document.createTextNode(_NS.GetLabel());_NM.appendChild(_aA1);};CUIQuadrantSegmentingDlg.prototype.CreateMemLevelComboBox=function(oMem){var _ajQ=new CUIListCtrl(this.oDialogMgr.oUIMgr);_ajQ.iMaxHeight=150;_ajQ.Init();_ajQ.DisableHAutoScroll();var _avv=new CUIComboBox(this.oDialogMgr.oUIMgr,_ajQ);var _afs=_avv.Init();_avv.DisableIcon();var _QA=this.oDialogMgr.oUIMgr.dataManager.metadata;var _7N=oMem.GetLevel();if(_7N){var _aml=oMem.GetHierarchy()._gD;var _aj1=false;var _ac8=false;for(_E1 in _aml){if(_E1==_7N.GetId()){_ac8=true;_aj1=true;}if(_ac8){var _LX=_avv.oListCtrl.AddItem('',_aml[_E1].GetLabel(),0,_aml[_E1].GetId(),_aml[_E1].GetLabel());}if(_aj1){_avv.SetValueFromListItem(_LX);}_aj1=false;}return _avv;}else{return null;}};CUIQuadrantSegmentingDlg.prototype.SetDropData=function(_FZ){this._oM=_FZ;};CUIQuadrantSegmentingDlg.prototype.CreateDimLevelComboBox=function(_Ni){var _ajQ=new CUIListCtrl(this.oDialogMgr.oUIMgr);_ajQ.iMaxHeight=150;_ajQ.Init();_ajQ.DisableHAutoScroll();var _avv=new CUIComboBox(this.oDialogMgr.oUIMgr,_ajQ);var _afs=_avv.Init();_avv.DisableIcon();var _QA=this.oDialogMgr.oUIMgr.dataManager.metadata;var _aml;if(_Ni.GetDefaultHierarchy()){_aml=_Ni.GetDefaultHierarchy()._gD;}else if(_Ni._bj){_aml=_Ni._bj._gD;}else{var _Ts=Utilities.GetNthFromObjArray(_Ni._j5,1);_aml=_Ts._gD;}var _aj1=true;for(_E1 in _aml){var _LX=_avv.oListCtrl.AddItem('',_aml[_E1].GetLabel(),0,_aml[_E1].GetId(),_aml[_E1].GetLabel());if(_aj1){_avv.SetValueFromListItem(_LX);}_aj1=false;}return _avv;};CUIQuadrantSegmentingDlg.prototype.DoCreateSegmentingBaseSet=function(){this.oBlock.CreateQuadrantBaseBlock(this._ox);var _Ke=this.sAppName;CUIDialogMgr.SafeHideCurrentDialog(_Ke);};CUIQuadrantSegmentingDlg.prototype.DoCancel=function(_Ke){CUIDialogMgr.SafeHideCurrentDialog(_Ke);};function CUIQuadSegmentEditingDlg(){this.base=CUIDialog;this.base();this._rK=null;};CUIQuadSegmentEditingDlg.prototype=new CUIDialog;CUIQuadSegmentEditingDlg.superclass=CUIDialog.prototype;CUIQuadSegmentEditingDlg.kDefaultSegName="defaultSegLabel";CUIQuadSegmentEditingDlg.kCustomCalcName='customSegName';CUIQuadSegmentEditingDlg.prototype.Display=function(_BK){var _Co=this.oDialogMgr.oUIMgr.appobj.oResources;var _Ke=this.sAppName;var _MY=new Object();var _Xf=Utilities.GenerateCallback(CUIManager.SafeDoHelpTopic,[_Ke,HelpConstants.kUserDefCalcLink]);_MY['IDS_HELP']=_Xf;var _KP=CDLQuadrantSegment.oSegNumToPositionMap[this._rK.GetQuadrandNum()]+": "+this._rK.GetLabel();CUIQuadSegmentEditingDlg.superclass.Display.call(this,_KP,_MY,this._lq,'Modify current segment caption.');};CUIQuadSegmentEditingDlg.prototype.SetSelection=function(_FK,_Q8){this._rB=_FK;this._rK=_FK.GetQuadSegmentById(_Q8);};CUIQuadSegmentEditingDlg.prototype.ClearDlg=function(){if(this._lq){Dom.RemoveObject(this._lq);}};CUIQuadSegmentEditingDlg.prototype.Create=function(){this.ClearDlg();var _Ke=this.sAppName;var _acs=this._rK.GetDefaultLabel();var _Ay=this._rK.GetLabel();var _5R=(_Ay==='')?true:false;var _zr=document.createElement('TABLE');_zr.className='dialogTable';var _F0=document.createElement('TBODY');_NH=document.createElement('TR');_F0.appendChild(_NH);_NM=this._l4.cloneNode(false);_NM.colSpan=2;_NM.style.paddingTop='10px';_apS=COTInputElementFactory.CreateLabel(this.oRes.GetString('IDS_CALC_NAME'));_NM.appendChild(_apS);_NH.appendChild(_NM);_NH=document.createElement('TR');_F0.appendChild(_NH);_NM=this._g5.cloneNode(false);COTStyle.SetWidth(_NM,25,'px');COTStyle.SetHeight(_NM,20);this._lV=COTInputElementFactory.CreateRadioButton('segName',CUIQuadSegmentEditingDlg.kDefaultSegName,_5R);_NM.appendChild(this._lV);_NH.appendChild(_NM);_NM=this._g5.cloneNode(false);_apS=COTInputElementFactory.CreateLabel(this.oRes.ReplaceParam('IDS_USE_DEF_CALC_NAME_SHOW_EXPR',1,_acs));_NM.appendChild(_apS);_NH.appendChild(_NM);_NH=document.createElement('TR');_F0.appendChild(_NH);_NM=this._g5.cloneNode(false);COTStyle.SetWidth(_NM,25,'px');COTStyle.SetHeight(_NM,20);this._nM=COTInputElementFactory.CreateRadioButton('segName',CUIQuadSegmentEditingDlg.kCustomCalcName,!_5R);_NM.appendChild(this._nM);_NH.appendChild(_NM);_NM=this._g5.cloneNode(false);this._jc=COTInputElementFactory.CreateTextBox(204,'px',_Ay,false,null,null,null,this);this._hJ=this._jc.id;this._jc.style.fontSize='100%';_NM.appendChild(this._jc);_NH.appendChild(_NM);this._Y=Utilities.GenerateCallback(this.SubmitSegLabel,[],this);this._iG="IDS_BUTTON_OK";_zr.appendChild(_F0);this._lq=_zr;};CUIQuadSegmentEditingDlg.prototype.OnFocusTextBox=function(_A4){this._nM.checked=true;};CUIQuadSegmentEditingDlg.prototype.SubmitSegLabel=function(){var _3B=null;if(this._nM.checked){_3B=this._jc.value;if(_3B==''){CUIDialogMgr.DisplayMessageBox(CUIMessageBox.kWarning,'IDS_RENAME_CALCU_DLG_NO_NAME_WARNING');return;}}else{_3B='';}var _Jj=this._rB.oAxis._rk.GetDMAction();_Jj.type=ExpAPIXml.kActionModify;var _Lh=_c.CreateElement(ExpAPIXml.kEleObjectPtr,this._rK.GetSegId());_Lh+=_c.CreateElement(ExpAPIXml.kEleAxisOpSegCaption,_3B);var _aA3=_c.CreateElement(ExpAPIXml.kEleAxisOpExprSegment,_Lh,true);_Jj.AddParameter(new CDLParameter(ExpAPIXml.kEleAxisOpExprSegment,_aA3,CDLParameter.XMLType()));_Jj.AddTargetItem(this._rB.oAxis._ks,ExpAPIXml.kEleAxis);_Jj.AddTargetItem(this._rB.sExprId,ExpAPIXml.kEleAxisOpExpression);this._rB.oAxis._rk.SendDMAction(_Jj);CUIDialogMgr.SafeHideCurrentDialog(this.sAppName);};function CUIMetadataTree(_EE,_B2){this.uiManager=_EE;this._ob=_B2;this._ov=new Array();this._jW=new Array();this._hQ=new Object();};CUIMetadataTree.prototype.Init=function(_EP){this._we=this.uiManager.appobj.oResources;this._st=document.createElement('DIV');this._st.id="metadata"+Utilities.GenerateId();_EP.appendChild(this._st);this._st.className="mdmetadata";this.oTree=new CUITreeView(this.uiManager);var _zs=this.uiManager.appobj.appname;this.oDimContextMenu=new CUIContextMenu(_zs,0);this.oDimFolderContextMenu=new CUIContextMenu(_zs,0);this.oMeasureContextMenu=new CUIContextMenu(_zs,0);this.oMeasureFolderContextMenu=new CUIContextMenu(_zs,0);this.oPackageContextMenu=new CUIContextMenu(_zs,0);this.oOtherContextMenu=new CUIContextMenu(_zs,0);this.oNamedSetContextMenu=new CUINamedSetContextMenu(_zs,this._we);if(!this._ob){var _aAw=document.createTextNode(this._we.GetString('IDS_METADATA_NONE'));this._st.appendChild(_aAw);return;}this._e6=new Array();this._e6[ExpEvent.kCUIMetadataTree_SelChange]=new Array();this._xf=new Object();this._xf[ExpAPIXml.eRoot]=this._we.GetString('IDS_NAMESPACE_TYPE');this._xf[ExpAPIXml.eMember]=this._we.GetString('IDS_MEMBER_TYPE');this._xf[ExpAPIXml.eMeasureRoot]=this._we.GetString('IDS_MEASUREDIM_TYPE');this._xf[ExpAPIXml.eMeasure]=this._we.GetString('IDS_MEASURE_TYPE');this._xf["non-aggregate"]=this._we.GetString('IDS_MEASURE_TYPE');this._xf[ExpAPIXml.eDimRoot]=this._we.GetString('IDS_MEMBER_TYPE');this._xf[ExpAPIXml.eNamedSet]=this._we.GetString('IDS_NAMEDSET_TYPE');this._xf[ExpAPIXml.eNamedSetFolderObj]=this._we.GetString('IDS_NAMEDSET_TYPE');this._xf[ExpAPIXml.eDim]=this._we.GetString('IDS_DIMENSION_TYPE');this._xf[ExpAPIXml.eHierarchy]=this._we.GetString('IDS_HIERARCHY_TYPE');this._xf[ExpAPIXml.eFolder]=this._we.GetString('IDS_FOLDER_TYPE');this._xf[ExpAPIXml.eNamespace]=this._we.GetString('IDS_NAMESPACE_TYPE');};CUIMetadataTree.kSortRecordOrder=0;CUIMetadataTree.kSortAscending=1;CUIMetadataTree.kSortDescending=2;CUIMetadataTree.prototype.Subscribe=function(obj,_Dy){if(this._e6[_Dy]){this._e6[_Dy].push(obj);}};CUIMetadataTree.prototype.GetDIV=function(){return this._st;};CUIMetadataTree.prototype.SetAssoTabId=function(_If){this._rv=_If;};CUIMetadataTree.prototype.GetAssoTabId=function(){return this._rv;};CUIMetadataTree.prototype.GetNodeDataById=function(_Eq){var _BF=_Eq._lW;if(_BF==ExpAPIXml.eFolder||_BF==ExpAPIXml.eMeasureFolder||_BF==ExpAPIXml.eRoot||_BF==ExpAPIXml.eNamespace){return this._ob.GetFolderObject(_Eq._ks);}else if(_BF==ExpAPIXml.eOther){return this._ob.GetDataById(_Eq._qR._ks);}else{return this._ob.GetDataById(_Eq._ks);}};CUIMetadataTree.prototype.InitSubscriptions=function(){this.uiManager._jf.Subscribe(this,ExpEvent.kCUIWorksheet_Free);this.uiManager._jf.Subscribe(this,ExpEvent.kCUIWorksheet_Busy);this.uiManager.Subscribe(this,ExpEvent.kCUIManager_Unload);this.uiManager.Subscribe(this,ExpEvent.kCUIManager_OnSelChange);this._ob.Subscribe(this,ExpEvent.kCDLMetadata_Replace);this.uiManager.dataManager.Subscribe(this,ExpEvent.kCDLDataManager_UpdateTree);};CUIMetadataTree.prototype.Hide=function(){this._st.style.display='none';};CUIMetadataTree.prototype.Show=function(){this._st.style.display='block';this.uiManager.OnSelChange(this);};CUIMetadataTree.prototype.GetBottom=function(){var _T6=COTStyle.GetDisplayOffsetHeight(this._st);return _T6;};CUIMetadataTree.prototype.SetHeight=function(_T6){COTStyle.SetHeight(this._st,_T6-COTStyle.GetVerticalExtrasHeight(this._st));};CUIMetadataTree.prototype.SetTop=function(_TM){this._st.style.top=_TM+"px";};CUIMetadataTree.prototype.SetWidth=function(_F4){COTStyle.SetWidth(this._st,_F4-COTStyle.GetHorizontalExtrasWidth(this._st));};CUIMetadataTree.prototype.SetUpMetadataTree=function(){this._qy=document.createElement('div');this._qy.className="tree_div";this._st.appendChild(this._qy);this._hA=new COTTreeVO(this);this.oTree.SetTreeVO(this._hA);this.InitTreeVO();this.oTree.SetDiv(this._qy);this.oTree.DrawTree();this.InitContextMenu();};CUIMetadataTree.prototype.InitTreeVO=function(){var _atx=this._ob.GetPackageName();var _aBo=this._ob.GetPackageId();var _QT=new COTTreeNode(ExpAPIXml.eRoot,_aBo,_atx,_aBo,null,null,_atx);_QT._qq=true;_QT._s5=true;_QT._uS=true;_QT._j4=false;this._hA.SetTreeRoot(_QT);this.CreateInitialTreeVO();};CUIMetadataTree.prototype.AddUIItem=function(_zQ){_Re=this._ov.length;if(_zQ instanceof CDLFolderObjDimension){var _EZ=this._ob.GetDimById(_zQ._cH);this._ov[_Re]=new CUIDimension(_EZ,this,_Re);}else if(_zQ instanceof CDLFolderObjMeasureDim){var _RG=this._ob.GetMeasureDim(_zQ._cH);var _aDX=this._ob.GetFolderObject(_zQ._ks);this._ov[_Re]=new CUIMeasureDim(_RG,_aDX,this,_Re);}else if(_zQ instanceof CDLFolder){var _aaC=this._ob.GetFolderObject(_zQ._ks);this._ov[_Re]=new CUIFolder(_aaC,this,_Re);}else if(_zQ instanceof CDLMeasureFolder){var _aCI=this._ob.GetFolderObject(_zQ._ks);this._ov[_Re]=new CUIMeasureFolder(_aCI,this,_Re);}else if(_zQ instanceof CDLFolderObjMeasure){var _SE=this._ob.GetMeasure(_zQ._cH);this._ov[_Re]=new CUIMeasure(_SE,this,_Re);}else if(_zQ instanceof CDLDimension){this._ov[_Re]=new CUIDimension(_zQ,this,_Re);}else if(_zQ instanceof CDLMeasure){this._ov[_Re]=new CUIMeasure(_zQ,this,_Re);}else if(_zQ instanceof CDLFolderObjNamedSet){var _aaC=this._ob.GetFolderObject(_zQ.GetId());this._ov[_Re]=new CUINamedSet(_zQ,this._ob,_aaC,_Re);}else{Debug.Assert(false);}return _Re;};CUIMetadataTree.prototype.CreateUIItemArray=function(_OO){var _aHp=this._ov.length;for(var i in _OO){var obj=_OO[i];this.AddUIItem(obj);}return _aHp;};CUIMetadataTree.prototype.CreateInitialTreeVO=function(){var _OO=this._ob._xr;if(_OO){var _aHp=this.CreateUIItemArray(_OO);var _akl=this._ov.length-1;for(var i=_aHp;i<=_akl;i++){var _OH=this._ov[i];this.AddChildNodeVO(this._hA._vp,_OH);}}};CUIMetadataTree.prototype.AddChildNodeVO=function(_Eq,_OH){if(_OH instanceof CUIDimension){this.AddDimensionNodeVO(_Eq,_OH);}else if(_OH instanceof CUIMeasureDim){this.AddMeasureDimNodeVO(_Eq,_OH);}else if(_OH instanceof CUIFolder){if(_OH.IsNamespaceFolder()){this.AddNamespaceNodeVO(_Eq,_OH);}else{this.AddFolderNodeVO(_Eq,_OH);}}else if(_OH instanceof CUIMeasureFolder){this.AddMeasureFolderNodeVO(_Eq,_OH);}else if(_OH instanceof CUIMeasure){this.AddMeasureNodeVO(_Eq,_OH);}else if(_OH instanceof CUINamedSet){this.AddNamedSetNodeVO(_Eq,_OH);}};CUIMetadataTree.prototype.AddDimensionNodeVO=function(_Eq,_Tj){var _QT;var _EZ=_Tj._xA;var _Ts=_EZ.GetSingleHierarchy();if(_Ts&&(!_EZ.isHierarchyHidden(_Ts.GetId()))){_QT=this.HandleHierarchyNode(_Ts,_Tj,_Eq,true);}else{_QT=this.CreateDimNode(_Eq,_EZ,_Tj._ue);this._hA.AddTreeNode(_QT);}return _QT;};CUIMetadataTree.prototype.AddMeasureDimNodeVO=function(_Eq,_JR){var _QT=this.CreateMeasureRootNode(_Eq,_JR._xA,_JR._ue);_JR.AddMemberChildren(_QT,_JR._xA);this._hA.AddTreeNode(_QT);return _QT;};CUIMetadataTree.prototype.AddFolderNodeVO=function(_Eq,_Ca){var _QT=this.CreateFolderNode(_Eq,_Ca._fP,_Ca._ue);_Ca.AddMemberChildren(_QT,_Ca._fP);this._hA.AddTreeNode(_QT);return _QT;};CUIMetadataTree.prototype.AddNamespaceNodeVO=function(_Eq,_Ca){var _QT=this.CreateNamespaceNode(_Eq,_Ca._fP,_Ca._ue);_Ca.AddMemberChildren(_QT,_Ca._fP);this._hA.AddTreeNode(_QT);return _QT;};CUIMetadataTree.prototype.AddMeasureFolderNodeVO=function(_Eq,_VF){var _QT=this.CreateMeasureFolderNode(_Eq,_VF._fP,_VF._ue);_VF.AddMemberChildren(_QT,_VF._fP);this._hA.AddTreeNode(_QT);return _QT;};CUIMetadataTree.prototype.AddMeasureNodeVO=function(_Eq,_Qq){var _QT=this.CreateMeasureNode(_Eq,_Qq._xA,_Qq._ue);this._hA.AddTreeNode(_QT);return _QT;};CUIMetadataTree.prototype.AddNamedSetNodeVO=function(_Eq,_HN){var _QT=this.CreateNamedSetNode(_Eq,_HN._sG,_HN._oi);this._hA.AddTreeNode(_QT);return _QT;};CUIMetadataTree.prototype.UpdateTreeVO=function(_Eq){if(!_Eq){var _Eq=this._hA._vp;}var _BF=_Eq._lW;switch(_BF){case ExpAPIXml.eMeasureFolder:case ExpAPIXml.eMember:case ExpAPIXml.eDimRoot:case ExpAPIXml.eMeasure:case CUIMeasure.kNonAggreMeasure:case ExpAPIXml.eMeasureRoot:case ExpAPIXml.eOther:case ExpAPIXml.eHierarchy:var _OH=this._ov[_Eq._wp];var _Jm=this.GetNodeDataById(_Eq);var _Bc=_Eq._uS||_Eq._nv;var _UI=_Bc?_Eq._qE:0;_OH.AddChildren(_Eq,_Jm,_UI,_Bc);if((!_Eq._uS)&&(_Eq._nv)){this.oTree.CollapseNode(_Eq);}if(!(_Eq._mO==CUITreeView.invalidHtmlId)){this.oTree.UpdateNode(_Eq);}break;default:Debug.Assert(false);}};CUIMetadataTree.prototype.ShowCancel=function(id,_ST,_Je){var _Eq=this._hA.GetNode(id);if(_Eq&&_Eq._vB){var _AA=document.getElementById(_Eq._mO);if(_AA){this.oTree.ShowCancel(_AA,_Eq,_ST,_Je);}}};CUIMetadataTree.prototype.InitContextMenu=function(){var _aCV=null;var _IS=false;this.oDimContextMenu.items=new Array();this.oMeasureContextMenu.items=new Array();this.oMeasureFolderContextMenu.items=new Array();this.oPackageContextMenu.items=new Array();this.oDimFolderContextMenu.items=new Array();this.oOtherContextMenu.items=new Array();CUIMetadataTree.SetBaseMemberXTabActionMenu(this.uiManager.appobj.appname,this.oDimContextMenu,true);var _BM=this._we.GetString('IDS_SEARCH');_PM=new ContextItem('icon_search.gif',_BM,CUIMetadataTree.SafeDoSearchFromNode,false,_aCV,this.oMeasureFolderContextMenu);_PM.SetFunctionId('IDS_SEARCH');_PM.Clone(this.oPackageContextMenu);this.oPackageContextMenu.SetChildrenComplete();_PM.Clone(this.oDimFolderContextMenu);_BM=this._we.GetString('TRE_METADATA_SET_MAX_CHILD_NUM');var _5L=new ContextItem('',_BM,CUIMetadataTree.SafeSetNodeMaxDisplayNumber,false,_aCV,this.oMeasureFolderContextMenu);_5L.id='TRE_METADATA_SET_MAX_CHILD_NUM';_5L.SetFunctionId('TRE_METADATA_SET_MAX_CHILD_NUM');_5L.Clone(this.oDimFolderContextMenu);_5L.Clone(this.oOtherContextMenu);_BM=this._we.GetString('TRE_METADATA_SORT');var _T8=new ContextItem('',_BM,null,false,_aCV,this.oMeasureFolderContextMenu);_T8.id='TRE_METADATA_SORT';var _Mt=_T8.CreateSubMenu(this.uiManager.appobj.appname,this.oMeasureFolderContextMenu._dl+1);_Mt.SetChildrenComplete();_BM=this._we.GetString('TRE_METADATA_SORT_ASCEND');var _PM=new ContextItem('',_BM,CUIMetadataTree.SafeDoSort,false,_aCV,_Mt);_PM.id='TRE_METADATA_SORT_ASCEND';_BM=this._we.GetString('TRE_METADATA_SORT_DESCEND');var _PM=new ContextItem('',_BM,CUIMetadataTree.SafeDoSort,false,_aCV,_Mt);_PM.id='TRE_METADATA_SORT_DESCEND';_BM=this._we.GetString('TRE_METADATA_SORT_RECORD_ORDER');var _PM=new ContextItem('',_BM,CUIMetadataTree.SafeDoSort,false,_aCV,_Mt);_PM.id='TRE_METADATA_SORT_RECORD_ORDER';_T8.Clone(this.oDimContextMenu,2);_T8.Clone(this.oDimFolderContextMenu,2);_T8.Clone(this.oOtherContextMenu);this.oDimFolderContextMenu.SetChildrenComplete();this.oDimContextMenu.SetChildrenComplete();this.oOtherContextMenu.SetChildrenComplete();var _aIC=new ContextSeparator(this.oDimContextMenu);_BM=this._we.GetString('TRE_METADATA_GLOSSARY');var _9Y=new ContextItem('action_glossary.gif',_BM,CUIMetadataTree.SafeGotoGlossary,true,_aCV,this.oMeasureFolderContextMenu);_9Y.id='TRE_METADATA_GLOSSARY';_9Y.SetFunctionId('TRE_METADATA_GLOSSARY');_9Y.Clone(this.oDimFolderContextMenu);_BM=this._we.GetString('TRE_METADATA_VIEW_SOURCE_INFO');var _5L=new ContextItem('action_lineage.gif',_BM,CUIMetadataTree.SafeGotoLineage,false,_aCV,this.oMeasureFolderContextMenu);_5L.id='TRE_METADATA_VIEW_SOURCE_INFO';_5L.SetFunctionId('TRE_METADATA_VIEW_SOURCE_INFO');_5L.Clone(this.oDimFolderContextMenu);CUIMetadataTree.SetMeasureContextMenu(this.uiManager.appobj.appname,this.oMeasureContextMenu,true);_T8.Clone(this.oMeasureContextMenu,2);this.oMeasureContextMenu.SetChildrenComplete();this.oMeasureFolderContextMenu.SetChildrenComplete();};CUIMetadataTree.SetSelectionBasedCntxItem=function(_Ke,_E2){var _aCV=null;var _IS=true;var _CI=FindApp(_Ke).oResources;var _BM=_CI.GetString('TRE_METADATA_INS_AFTER_SELECTION');var _PM=new ContextItem('',_BM,null,_IS,_aCV,_E2);_PM.id='TRE_METADATA_INS_AFTER_SELECTION';_BM=_CI.GetString('TRE_METADATA_INS_BEFORE_SELECTION');_PM=new ContextItem('',_BM,null,_IS,_aCV,_E2);_PM.id='TRE_METADATA_INS_BEFORE_SELECTION';_BM=_CI.GetString('TRE_METADATA_INS_ABOVE_SELECTION');_PM=new ContextItem('',_BM,null,_IS,_aCV,_E2);_PM.id='TRE_METADATA_INS_ABOVE_SELECTION';_BM=_CI.GetString('TRE_METADATA_INS_BELOW_SELECTION');_PM=new ContextItem('',_BM,null,_IS,_aCV,_E2);_PM.id='TRE_METADATA_INS_BELOW_SELECTION';_BM=_CI.GetString('TRE_METADATA_INS_INTO_SEL');_PM=new ContextItem('',_BM,null,_IS,_aCV,_E2);_PM.id='TRE_METADATA_INS_INTO_SEL';};CUIMetadataTree.SetBaseXTabInsertionMenu=function(_Ke,_E2){var _aCV=null;var _IS=true;var _CI=FindApp(_Ke).oResources;var _BM=_CI.GetString('TRE_METADATA_INSERT');var _at3=new ContextItem('',_BM,null,false,_aCV,_E2);_at3.id='TRE_METADATA_INSERT';var _Mt=_at3.CreateSubMenu(_Ke,_E2._dl+1);_Mt.SetChildrenComplete();var _BM=_CI.GetString('TRE_METADATA_DEF_ADD_ROW');var _PM=new ContextItem('',_BM,CUICrosstab.SafeDoAddMember,_IS,_aCV,_Mt);_PM.id='TRE_METADATA_DEF_ADD_ROW';_BM=_CI.GetString('TRE_METADATA_DEF_ADD_COL');_PM=new ContextItem('',_BM,CUICrosstab.SafeDoAddMember,_IS,_aCV,_Mt);_PM.id='TRE_METADATA_DEF_ADD_COL';_BM=_CI.GetString('TRE_METADATA_INS_NESTED_INNER_ROW');_PM=new ContextItem('',_BM,CUICrosstab.SafeDoAxisXJoin,_IS,_aCV,_Mt);_PM.id='TRE_METADATA_INS_NESTED_INNER_ROW';_BM=_CI.GetString('TRE_METADATA_INS_NESTED_INNER_COL');_PM=new ContextItem('',_BM,CUICrosstab.SafeDoAxisXJoin,_IS,_aCV,_Mt);_PM.id='TRE_METADATA_INS_NESTED_INNER_COL';var _aIC=new ContextSeparator(_Mt);CUIMetadataTree.SetSelectionBasedCntxItem(_Ke,_Mt);_BM=_CI.GetString('TRE_METADATA_REPLACE');var _aEP=new ContextItem('',_BM,null,false,_aCV,_E2);_aEP.id='TRE_METADATA_REPLACE';_Mt=_aEP.CreateSubMenu(_Ke,_E2._dl+1);_Mt.SetChildrenComplete();_BM=_CI.GetString('TRE_METADATA_REP_ROW');_PM=new ContextItem('',_BM,CUICrosstab.SafeDoReplaceAxis,_IS,_aCV,_Mt);_PM.id='TRE_METADATA_REP_ROW';_BM=_CI.GetString('TRE_METADATA_REP_COL');_PM=new ContextItem('',_BM,CUICrosstab.SafeDoReplaceAxis,_IS,_aCV,_Mt);_PM.id='TRE_METADATA_REP_COL';_BM=_CI.GetString('TRE_METADATA_REP_SELECTION');_PM=new ContextItem('',_BM,CUICrosstab.SafeDoReplaceLevelWithMember,_IS,_aCV,_Mt);_PM.id='TRE_METADATA_REP_SELECTION';var _aIC=new ContextSeparator(_E2);_BM=_CI.GetString('TRE_METADATA_INSERT_LEVEL');var _ai2=new ContextItem('',_BM,null,false,_aCV,_E2);_ai2.id='TRE_METADATA_INSERT_LEVEL';_ai2.SetFunctionId("insertlevel");_Mt=_ai2.CreateSubMenu(_Ke,_E2._dl+1);_Mt.SetChildrenComplete();_BM=_CI.GetString('TRE_METADATA_INSERT_LEVEL_ROWS');_PM=new ContextItem('',_BM,CUICrosstab.SafeDoAddMember,_IS,_aCV,_Mt);_PM.id='TRE_METADATA_INSERT_LEVEL_ROWS';_BM=_CI.GetString('TRE_METADATA_INSERT_LEVEL_COLS');_PM=new ContextItem('',_BM,CUICrosstab.SafeDoAddMember,_IS,_aCV,_Mt);_PM.id='TRE_METADATA_INSERT_LEVEL_COLS';_BM=_CI.GetString('TRE_METADATA_INSERT_LEVEL_INNER_ROWS');_PM=new ContextItem('',_BM,CUICrosstab.SafeDoAxisXJoin,_IS,_aCV,_Mt);_PM.id='TRE_METADATA_INSERT_LEVEL_INNER_ROWS';_BM=_CI.GetString('TRE_METADATA_INSERT_LEVEL_INNER_COLS');_PM=new ContextItem('',_BM,CUICrosstab.SafeDoAxisXJoin,_IS,_aCV,_Mt);_PM.id='TRE_METADATA_INSERT_LEVEL_INNER_COLS';var _aIC=new ContextSeparator(_Mt);_BM=_CI.GetString('TRE_METADATA_INSERT_LEVEL_AFTER_SEL');_PM=new ContextItem('',_BM,null,_IS,_aCV,_Mt);_PM.id='TRE_METADATA_INSERT_LEVEL_AFTER_SEL';_BM=_CI.GetString('TRE_METADATA_INSERT_LEVEL_BEFORE_SEL');_PM=new ContextItem('',_BM,null,_IS,_aCV,_Mt);_PM.id='TRE_METADATA_INSERT_LEVEL_BEFORE_SEL';_BM=_CI.GetString('TRE_METADATA_INSERT_LEVEL_BELOW_SEL');_PM=new ContextItem('',_BM,null,_IS,_aCV,_Mt);_PM.id='TRE_METADATA_INSERT_LEVEL_BELOW_SEL';_BM=_CI.GetString('TRE_METADATA_INSERT_LEVEL_ABOVE_SEL');_PM=new ContextItem('',_BM,null,_IS,_aCV,_Mt);_PM.id='TRE_METADATA_INSERT_LEVEL_ABOVE_SEL';_BM=_CI.GetString('TRE_METADATA_REPLACE_LEVEL');var _08=new ContextItem('',_BM,null,false,_aCV,_E2);_08.id='TRE_METADATA_REPLACE_LEVEL';_08.SetFunctionId("replacelevel");_Mt=_08.CreateSubMenu(_Ke,_E2._dl+1);_Mt.SetChildrenComplete();_BM=_CI.GetString('TRE_METADATA_REPLACE_LEVEL_ROWS');_PM=new ContextItem('',_BM,CUICrosstab.SafeDoReplaceAxis,_IS,_aCV,_Mt);_PM.id='TRE_METADATA_REPLACE_LEVEL_ROWS';_BM=_CI.GetString('TRE_METADATA_REPLACE_LEVEL_COLS');_PM=new ContextItem('',_BM,CUICrosstab.SafeDoReplaceAxis,_IS,_aCV,_Mt);_PM.id='TRE_METADATA_REPLACE_LEVEL_COLS';_BM=_CI.GetString('TRE_METADATA_REPLACE_LEVEL_SEL');_PM=new ContextItem('',_BM,CUICrosstab.SafeDoReplaceLevelWithMember,_IS,_aCV,_Mt);_PM.id='TRE_METADATA_REPLACE_LEVEL_SEL';var _aIC=new ContextSeparator(_E2);};CUIMetadataTree.SetBaseMemberXTabActionMenu=function(_Ke,_E2,_y3){var _aCV=null;var _IS=true;var _CI=FindApp(_Ke).oResources;_BM=_CI.GetString('IDS_SEARCH');var _awQ=new ContextItem('icon_search.gif',_BM,CUIMetadataTree.SafeDoSearchFromNode,false,_aCV,_E2);_awQ.SetFunctionId('IDS_SEARCH');if(_y3){var _BM=_CI.GetString('TRE_METADATA_SET_MAX_CHILD_NUM');var _5L=new ContextItem('',_BM,CUIMetadataTree.SafeSetNodeMaxDisplayNumber,false,_aCV,_E2);_5L.id='TRE_METADATA_SET_MAX_CHILD_NUM';_5L.SetFunctionId('TRE_METADATA_SET_MAX_CHILD_NUM');}var _aIC=new ContextSeparator(_E2);CUIMetadataTree.SetBaseXTabInsertionMenu(_Ke,_E2);var _aEH=_CI.GetString('TRE_TREEVIEW_FILTER_BY_MEMBER');var _awI=new ContextItem('',_aEH,CUIFilterContextSet.SafeDoInsertDimFilter,false,_aCV,_E2);_awI.SetFunctionId('TRE_TREEVIEW_FILTER_BY_MEMBER');var _aIC=new ContextSeparator(_E2);_BM=_CI.GetString('TRE_METADATA_GLOSSARY');var _9Y=new ContextItem('action_glossary.gif',_BM,CUIMetadataTree.SafeGotoGlossary,true,_aCV,_E2);_9Y.id='TRE_METADATA_GLOSSARY';_9Y.SetFunctionId('TRE_METADATA_GLOSSARY');_BM=_CI.GetString('TRE_METADATA_VIEW_SOURCE_INFO');var _9Y=new ContextItem('action_lineage.gif',_BM,CUIMetadataTree.SafeGotoLineage,true,_aCV,_E2);_9Y.id='TRE_METADATA_VIEW_SOURCE_INFO';_9Y.SetFunctionId('TRE_METADATA_VIEW_SOURCE_INFO');};CUIMetadataTree.SetMeasureContextMenu=function(_Ke,_E2,_y3){var _aCV=null;var _IS=true;var _CI=FindApp(_Ke).oResources;var _BM=_CI.GetString('IDS_SEARCH');var _PM=new ContextItem('icon_search.gif',_BM,CUIMetadataTree.SafeDoSearchFromNode,false,_aCV,_E2);_PM.SetFunctionId('IDS_SEARCH');if(_y3){_BM=_CI.GetString('TRE_METADATA_SET_MAX_CHILD_NUM');_PM=new ContextItem('',_BM,CUIMetadataTree.SafeSetNodeMaxDisplayNumber,false,_aCV,_E2);_PM.id='TRE_METADATA_SET_MAX_CHILD_NUM';_PM.SetFunctionId('TRE_METADATA_SET_MAX_CHILD_NUM');}var _aIC=new ContextSeparator(_E2);_BM=_CI.GetString('OTH_MEASURE_MENU_USE_AS_DEFAULT');_PM=new ContextItem('',_BM,CUIWorkSheet.SafeDoInsertDropData,false,_aCV,_E2);_PM.SetFunctionId('OTH_MEASURE_MENU_USE_AS_DEFAULT');_BM=_CI.GetString('TRE_METADATA_INSERT');var _at3=new ContextItem('',_BM,null,_IS,_aCV,_E2);_at3.id='TRE_METADATA_INSERT';var _Mt=_at3.CreateSubMenu(_Ke,_E2._dl+1);_Mt.SetChildrenComplete();_BM=_CI.GetString('TRE_METADATA_DEF_ADD_ROW');var _PM=new ContextItem('',_BM,null,_IS,_aCV,_Mt);_PM.id='TRE_METADATA_DEF_ADD_ROW';_BM=_CI.GetString('TRE_METADATA_DEF_ADD_COL');_PM=new ContextItem('',_BM,null,_IS,_aCV,_Mt);_PM.id='TRE_METADATA_DEF_ADD_COL';var _aIC=new ContextSeparator(_Mt);CUIMetadataTree.SetSelectionBasedCntxItem(_Ke,_Mt);_BM=_CI.GetString('TRE_METADATA_REPLACE');var _aEP=new ContextItem('',_BM,null,false,_aCV,_E2);_aEP.id='TRE_METADATA_REPLACE';_Mt=_aEP.CreateSubMenu(_Ke,_E2._dl+1);_BM=_CI.GetString('TRE_METADATA_REP_ROW');_PM=new ContextItem('',_BM,CUICrosstab.SafeDoReplaceAxis,_IS,_aCV,_Mt);_PM.id='TRE_METADATA_REP_ROW';_BM=_CI.GetString('TRE_METADATA_REP_COL');_PM=new ContextItem('',_BM,CUICrosstab.SafeDoReplaceAxis,_IS,_aCV,_Mt);_PM.id='TRE_METADATA_REP_COL';_BM=_CI.GetString('TRE_METADATA_REP_SELECTION');_PM=new ContextItem('',_BM,null,_IS,_aCV,_Mt);_PM.id='TRE_METADATA_REP_SELECTION';_Mt.SetChildrenComplete();var _aIC=new ContextSeparator(_E2);_BM=_CI.GetString('TRE_METADATA_GLOSSARY');var _9Y=new ContextItem('action_glossary.gif',_BM,CUIMetadataTree.SafeGotoGlossary,true,_aCV,_E2);_9Y.id='TRE_METADATA_GLOSSARY';_9Y.SetFunctionId('TRE_METADATA_GLOSSARY');_BM=_CI.GetString('TRE_METADATA_VIEW_SOURCE_INFO');_PM=new ContextItem('action_lineage.gif',_BM,CUIMetadataTree.SafeGotoLineage,true,_aCV,_E2);_PM.id='TRE_METADATA_VIEW_SOURCE_INFO';_PM.SetFunctionId('TRE_METADATA_VIEW_SOURCE_INFO');};CUIMetadataTree.SafeGotoLineage=function(_Ke,_Hg){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);var _Jy=_Mg.commManager.GetParameterValues();_Mg.uiManager._qi.gotoLineage(_Hg,_Jy);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIMetadataTree.prototype.gotoLineage=function(_Hg,_Jy){var _WP=this.uiManager.dataManager;var _Z9=_WP.metadata._lt;var _Xe=_WP.appobj.GetGatewayURL();var _aGb=_WP.GetConfigProperty(CDLConfiguration.K_sLineageURL);var _avi=_aGb?_aGb:CDLConfiguration.K_sDefaultLineageURL;var _aiW=new MDSRV_CognosConfiguration();_aiW.addProperty("lineageURI",_avi);_aiW.addProperty("gatewayURI",_Xe);lineage=new MDSRV_LineageFragmentContext(_aiW);if(_Jy){var _aA9=this.createExecutionParametersTemplate(_Jy);lineage.setExecutionParameters(_aA9);}lineage.setPackagePath(_Z9);var _YB=false;for(var i=0;_Hg&&i<_Hg.length;i++){lineage.addItem(Utilities.RemoveMUNPrefix(_Hg[i]));_YB=true;}if(_YB){lineage.open();}};CUIMetadataTree.SafeGotoGlossary=function(_Ke,oMem){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.uiManager._qi.gotoGlossary(oMem);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIMetadataTree.prototype.gotoGlossary=function(_RF){var _WP=this.uiManager.dataManager;var _Xe=_WP.appobj.GetGatewayURL();var _aka=_WP.GetConfigProperty(CDLConfiguration.K_sGlossaryURL);var _awU=_aka?_aka:CDLConfiguration.K_sDefaultGlossaryURL;var _aiW=new MDSRV_CognosConfiguration();_aiW.addProperty("glossaryURI",_awU);_aiW.addProperty("gatewayURI",_Xe);_aFy=new MDSRV_BusinessGlossary(_aiW);if(_RF&&_RF.length>0){for(var i=0;i<_RF.length;i++){_aFy.addTerm(_RF[i]);}_aFy.open();}};CUIMetadataTree.prototype.Refresh=function(){Dom.RemoveAllChildren(this._st);this.SetUpMetadataTree();};CUIMetadataTree.prototype.HandleMetadataReplace=function(){Utilities.DeleteAllFromArray(this._ov);this.clearTreeCache();this._hA=new COTTreeVO(this);this.oTree.SetTreeVO(this._hA);this.InitTreeVO();this.oTree.DrawTree();};CUIMetadataTree.prototype.UnLoad=function(){Dom.RemoveObject(this._st);this.clearTreeCache();Utilities.RemoveAllChildObjects(this);};CUIMetadataTree.prototype.clearTreeCache=function(){var _aBJ=this._hA._nl;var _LF;for(var i in _aBJ){_LF=_aBJ[i];Utilities.ClearObjectArray(_LF._dK);_LF._dK=null;_LF.Clear();delete _aBJ[i];}this._hA._nl=null;Utilities.RemoveAllChildObjects(this._hA);};CUIMetadataTree.prototype.GetRightPos=function(){return COTStyle.GetDisplayWidth(this._st)+COTStyle.GetPosition(this._st,'left');};CUIMetadataTree.prototype.Notify=function(event){var _4l=null;if(event==ExpEvent.kCUIManager_Unload){this.UnLoad();}else if(event==ExpEvent.kCUIWorksheet_Free){this.updateWSContextMenuOptions(false);}else if(event==ExpEvent.kCUIWorksheet_Busy){this.updateWSContextMenuOptions(true);}else if(event==ExpEvent.kCDLMetadata_Replace){this.HandleMetadataReplace();}else if(event==ExpEvent.kCDLMember_Merge){if(this.oTree.GetLastSelection()&&this._lo&&this.oTree.GetLastSelection()._ks==this._lo._ks){this.uiManager.OnSelChange(this);}if(this._kb){var _at1=this._hA._nl[this._kb._ks];if(_at1!=null){this._jW.push(_at1);}}}else if(event==ExpEvent.kCUISearchDlg_StateChange){if(this.uiManager.oDialogMgr._jg&&this.uiManager.oDialogMgr._jg.IsSearching&&!this.uiManager.oDialogMgr._jg.IsSearching()){this.UpdateTreeVO4AllSearchedNode();}}else if(event==ExpEvent.kCUIManager_OnSelChange){if(this.uiManager.GetSelPane()!=this){this.oTree.HandleBlur();}else{_4l=ExpEvent.kCUIMetadataTree_SelChange;}}else if(event==ExpEvent.kCDLAnalysis_Replace){this.oTree.ClearSelections();this.uiManager.dataManager._kX.UnSubscribe(this,ExpEvent.kCDLAnalysis_Replace);}else if(event==ExpEvent.kCDLDataManager_UpdateTree){if(this.uiManager.dataManager.metadata){var _NC=this.uiManager.dataManager.metadata._sN;if(_NC&&_NC.length>0){this.RefreshOtherNode(_NC);}}}if(_4l!=null){var _alZ=this._e6[_4l];for(var i=0;_alZ&&i<_alZ.length;i++){_alZ[i].Notify(_4l);}}};CUIMetadataTree.prototype.UpdateTreeVO4AllSearchedNode=function(){for(var i=0;i<this._jW.length;i++){this.UpdateTreeVO(this._jW[i]);}Utilities.DeleteAllFromArray(this._jW);};CUIMetadataTree.prototype.SortChildNodes=function(_Ky,_Jm){this.oTree.RemoveAllChildrenNodes(_Ky);this._hA.RemoveChildrenNodes(_Ky);this.oTree.SetNodeStoppingState(_Ky._ks,false);var _OH=this._ov[_Ky._wp];_OH.AddChildren(_Ky,_Jm,0,true,true);};CUIMetadataTree.prototype.updateWSContextMenuOptions=function(_KC){for(var i=0;i<this.oDimContextMenu.items.length;i++){this.oDimContextMenu.items[i]._eY=_KC;}for(var i=0;i<this.oMeasureContextMenu.items.length;i++){this.oMeasureContextMenu.items[i]._eY=_KC;}for(var i=0;i<this.oMeasureFolderContextMenu.items.length;i++){this.oMeasureFolderContextMenu.items[i]._eY=_KC;}for(var i=0;i<this.oPackageContextMenu.items.length;i++){this.oPackageContextMenu.items[i]._eY=_KC;}for(var i=0;i<this.oDimFolderContextMenu.items.length;i++){this.oDimFolderContextMenu.items[i]._eY=_KC;}for(var i=0;i<this.oNamedSetContextMenu.oContextMenu.items.length;i++){this.oNamedSetContextMenu.oContextMenu.items[i]._eY=_KC;}this.displayMenu();};CUIMetadataTree.prototype.displayMenu=function(){if(this.oDimContextMenu.IsVisible()){this.ShowContextMenu();}if(this.oMeasureContextMenu.IsVisible()){this.ShowContextMenu();}if(this.oMeasureFolderContextMenu.IsVisible()){this.ShowContextMenu();}if(this.oPackageContextMenu.IsVisible()){this.ShowContextMenu();}if(this.oDimFolderContextMenu.IsVisible()){this.ShowContextMenu();}if(this.oNamedSetContextMenu.oContextMenu.IsVisible()){this.ShowContextMenu();}};CUIMetadataTree.GetMemberText=function(_UY){return _UY._p8;};CUIMetadataTree.CanHaveAdditionalNode=function(_Nx){return _Nx._lW!=ExpAPIXml.eRoot;};CUIMetadataTree.prototype.GetAdditionalNodeElement=function(_Nx,_HI){if(!CUIMetadataTree.CanHaveAdditionalNode(_Nx)){return;}var _Do=document.createElement("A");_Do.className="additional_node_text";var _F3="";var _Jm=this.GetNodeDataById(_Nx);var _adx=(_HI>=0&&_HI<_Nx._ln)?_HI:_Nx._ln;if(_Jm){var _1n=(_Jm._v1&&this.GetUIChildCount(_Nx,_Jm)<=_Nx._ln);if(_1n){return _Do;}else if(_Nx._uS&&!_Nx._vB&&_Nx._s5){if(_Nx._lW==ExpAPIXml.eOther){_F3='IDS_METADATA_NODE_POPULATION_EXPANDED';_F3=this._we.ReplaceParam(_F3,1,_adx);_F3=this._we.ReplaceParam(_F3,2,_Jm.GetOtherChildCount());}else if(!_Nx._uD){if(_Jm._v1){_F3='IDS_METADATA_NODE_POPULATION_EXPANDED';}else{_F3='IDS_METADATA_NODE_POPULATION_EXPANDED_INCOMPLETE';}_F3=this._we.ReplaceParam(_F3,1,_adx);_F3=this._we.ReplaceParam(_F3,2,this.GetUIPopulation(_Jm));}_Do.className="additional_node_link";_Do.appendChild(document.createTextNode(_F3));_Do.onclick=CUIMetadataTree.SafeShowXofNMenu;}else if(_Nx._nv&&_Nx._s5){if(_Nx._lW==ExpAPIXml.eOther){_F3='IDS_METADATA_NODE_POPULATION_EXPANDED';_F3=this._we.ReplaceParam(_F3,1,_adx);_F3=this._we.ReplaceParam(_F3,2,_Jm.GetOtherChildCount());}else if(!_Nx._uD){if(_Jm._v1){_F3='IDS_METADATA_NODE_POPULATION_COLLAPSED';}else{_F3='IDS_METADATA_NODE_POPULATION_COLLAPSED_INCOMPLETE';}_F3=this._we.ReplaceParam(_F3,1,this.GetUIPopulation(_Jm));}_Do.className="additional_node_text";_Do.appendChild(document.createTextNode(_F3));}}return _Do;};CUIMetadataTree.prototype.GetAdditionalCtrlNodeElement=function(_Nx,_HI,_A8,_Im){if(!CUIMetadataTree.CanHaveAdditionalNode(_Nx)){return;}var _Do=document.createElement("A");if(!_HI){return _Do;}var _Ke=this.uiManager.appobj.appname;var _F3=(_A8?this._we.GetString('IDS_METADATA_NODE_CONTINUE_EXPANDED'):this._we.GetString('IDS_METADATA_NODE_STOP_EXPANDED'));var _UA=new Array(_Ke,_Nx._ks,_HI,_Im);_Xf=Utilities.GenerateCallback(CUITreeView.SafeSetDrawingState,_UA);_Do=COTInputElementFactory.CreateLink(_Xf,_F3,false,"link");return _Do;};CUIMetadataTree.SafeShowXofNMenu=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}var _IJ=Dom.GetEventTarget(e);var _Mp=_IJ;while(!_Mp.oTreeView){_Mp=_Mp.parentNode;}var _RJ=_Mp.oTreeView._kj._vd;_RJ.ShowXofNMenu(e,_IJ,_Mp);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIMetadataTree.prototype.ShowXofNMenu=function(e,_IJ,_Mp){if(!this._vY){this._vY=new CUIContextMenu(this.uiManager.appobj.appname,0,this);if(_Mp.oTreeNode._lW!=ExpAPIXml.eOther){var _BM=this._we.GetString('IDS_SEARCH');var _PM=new ContextItem('icon_search.gif',_BM,CUIMetadataTree.SafeDoSearchFromNode,false,null,this._vY);_PM.SetFunctionId('IDS_SEARCH');var _aIC=new ContextSeparator(this._vY);}var _BM=this._we.GetString('TRE_METADATA_SET_MAX_CHILD_NUM');var _5L=new ContextItem('',_BM,CUIMetadataTree.SafeSetNodeMaxDisplayNumber,false,null,this._vY);_5L.id='TRE_METADATA_SET_MAX_CHILD_NUM';_5L.SetFunctionId('TRE_METADATA_SET_MAX_CHILD_NUM');var _BM=this._we.GetString('TRE_TREE_NODE_X_OF_N_MENU_SHOW_ALL');var _PM=new ContextItem('',_BM,CUIMetadataTree.SafeShowAll,false,null,this._vY);_PM.id=_BM;var _BM=this._we.GetString('TRE_TREE_NODE_X_OF_N_MENU_RESET');var _PM=new ContextItem('',_BM,CUIMetadataTree.SafeResetMaxDisplayNumber,false,null,this._vY);_PM.id=_BM;}var _Jm=this.GetNodeDataById(_Mp.oTreeNode);var _Ke=this.uiManager.appobj.appname;for(var i=0;i<this._vY.items.length;i++){var _PM=this._vY.items[i];if(!(_PM instanceof ContextItem)){continue;}if(_PM.GetFunctionId()=='IDS_SEARCH'){_PM._ny=this._we.ReplaceParam('IDS_SEARCH',1,_Jm.GetLabel());var _zA=new Array(_Ke,_Mp.oTreeNode);_PM.SetParameterArr(_zA);}else if(_PM instanceof ContextItem){var _zA=new Array(_Ke,_Mp.oTreeNode);if(_PM.id==this._we.GetString('TRE_TREE_NODE_X_OF_N_MENU_SHOW_ALL')){var _ap8=this._ob.GetMaxExpandSize();if((_Jm.IsComplete()&&(this.GetUIChildCount(_Mp.oTreeNode,_Jm)<_ap8))||(_Mp.oTreeNode._lW==ExpAPIXml.eOther)){_ap8=this.GetUIChildCount(_Mp.oTreeNode,_Jm);}if(this.GetUIChildCount(_Mp.oTreeNode,_Jm)>_ap8){_ap8=this.GetUIChildCount(_Mp.oTreeNode,_Jm);}var _BM=this._we.ReplaceParam('TRE_TREE_NODE_X_OF_N_MENU_SHOW_ALL',1,_ap8);_PM._ny=_BM;if(_Mp.oTreeNode._ln==_ap8){_PM._eY=true;}else{_PM._eY=false;}_zA.push(_ap8);}else if(_PM.id==this._we.GetString('TRE_TREE_NODE_X_OF_N_MENU_RESET')){var _BM=this._we.ReplaceParam('TRE_TREE_NODE_X_OF_N_MENU_RESET',1,_Mp.oTreeNode._v3);_PM._ny=_BM;if(_Mp.oTreeNode._ln==_Mp.oTreeNode._v3){_PM._eY=true;}else{_PM._eY=false;}}else if(_PM.GetFunctionId()=='TRE_METADATA_SET_MAX_CHILD_NUM'){if(_Mp.oTreeNode._qE>0&&_Mp.oTreeNode._qE<_Mp.oTreeNode._ln&&_Mp.oTreeNode._qE<Utilities.GetObjArrayLength(_Mp.oTreeNode._dK)){_PM._eY=true;}else{_PM._eY=false;}}_PM.SetParameterArr(_zA);}}this._vY.display(e);_IJ.className="additional_node_link_hover";this._lp=_IJ;};CUIMetadataTree.prototype.OnContextMenuHide=function(_Ga){if(_Ga==this._vY){this._lp.className="additional_node_link";}};CUIMetadataTree.prototype.RemoveStaleItems=function(_Eq){for(var i=_Eq._ln-1;i>=_Eq._v3;i--){var _adY=this._hA.GetNode(_Eq._g1[i]);if(_adY&&this.oTree.IsNodeDisplayed(_adY)){this.oTree.ToggleDisplay(_Eq,_adY,'none');}}_Eq._qE=_Eq._v3;this.oTree.ShowOtherNode(_Eq,'none');};CUIMetadataTree.prototype.CreateDimNode=function(_Eq,_EZ,_Iu){var _HB=new COTTreeNode(ExpAPIXml.eDim,_EZ._ks,_EZ._p8,_EZ._ks,_Eq,null,_EZ._p8);_HB._j4=false;_HB._qq=_EZ._v1;_HB._s5=(_EZ.GetChildCount()==0)?false:true;_HB._wp=_Iu;return _HB;};CUIMetadataTree.prototype.CreateRootMemberNode=function(_Eq,_UY,_Iu){var _Ic=_UY._rM?_UY._rM:_UY._p8;var _HB=new COTTreeNode(ExpAPIXml.eDimRoot,_UY._ks,_Ic,_UY._ks,_Eq,null,_Ic);_HB._s5=(_UY._v1&&(_UY.GetChildCount()==0))?false:true;_HB._qq=_UY._v1||_UY._ge;_HB._wp=_Iu;return _HB;};CUIMetadataTree.prototype.CreateMemberNode=function(_Eq,_UY,_Iu){var _HB=new COTTreeNode(ExpAPIXml.eMember,_UY._ks,_UY._p8,_UY._ks,_Eq,null,_UY._p8);_HB._s5=(_UY._v1&&(_UY.GetChildCount()==0))?false:true;_HB._qq=_UY._v1||_UY._ge;_HB._wp=_Iu;return _HB;};CUIMetadataTree.prototype.CreateHierNode=function(_Eq,_Ts,_Iu){var _HB=new COTTreeNode(ExpAPIXml.eHierarchy,_Ts._ks,_Ts._p8,_Ts._ks,_Eq,null,_Ts._p8);_HB._s5=(_Ts._v1&&(_Ts.GetChildCount()==0))?false:true;_HB._qq=_Ts._v1;_HB._j4=false;_HB._wp=_Iu;return _HB;};CUIMetadataTree.prototype.CreateMeasureRootNode=function(_Eq,_Ff,_Iu){var _HB=new COTTreeNode(ExpAPIXml.eMeasureRoot,_Ff._ks,_Ff._p8,_Ff._ks,_Eq,null,_Ff._p8);_HB._s5=(_Ff._v1&&(_Ff.GetChildCount()==0))?false:true;_HB._qq=_Ff._v1;_HB._j4=false;_HB._wp=_Iu;return _HB;};CUIMetadataTree.prototype.CreateFolderNode=function(_Eq,_Bi,_Iu){var _HB=new COTTreeNode(ExpAPIXml.eFolder,_Bi._ks,_Bi._p8,_Bi._ks,_Eq,null,_Bi._p8);_HB._s5=(_Bi._v1&&(_Bi.GetChildCount()==0))?false:true;_HB._qq=_Bi._v1;_HB._k4=_Bi._v1;_HB._j4=false;_HB._wp=_Iu;return _HB;};CUIMetadataTree.prototype.CreateNamespaceNode=function(_Eq,_Bi,_Iu){var _HB=new COTTreeNode(ExpAPIXml.eNamespace,_Bi._ks,_Bi._p8,_Bi._ks,_Eq,null,_Bi._p8);_HB._s5=(_Bi._v1&&(_Bi.GetChildCount()==0))?false:true;_HB._qq=_Bi._v1;_HB._j4=false;_HB._wp=_Iu;return _HB;};CUIMetadataTree.prototype.CreateMeasureFolderNode=function(_Eq,_Bi,_Iu){var _HB=new COTTreeNode(ExpAPIXml.eMeasureFolder,_Bi._ks,_Bi._p8,_Bi._ks,_Eq,null,_Bi._p8);_HB._s5=(_Bi._v1&&(_Bi.GetChildCount()==0))?false:true;_HB._qq=_Bi._v1;_HB._j4=false;_HB._wp=_Iu;return _HB;};CUIMetadataTree.prototype.CreateMeasureNode=function(_Eq,_SE,_Iu){var _apM=_SE.IsAggregateable()?ExpAPIXml.eMeasure:CUIMeasure.kNonAggreMeasure;var _HB=new COTTreeNode(_apM,_SE._ks,_SE._p8,_SE._ks,_Eq,null,_SE._p8);_HB._s5=(_SE._v1&&(_SE.GetChildCount()==0))?false:true;_HB._qq=_SE._v1||_SE._ge;_HB._j4=true;_HB._wp=_Iu;return _HB;};CUIMetadataTree.prototype.CreateNamedSetNode=function(_Eq,_Po,_Iu){var _9m=new COTTreeNode(ExpAPIXml.eNamedSetFolderObj,_Po.GetId(),_Po.GetLabel(),_Po.GetId(),_Eq,null,_Po.GetLabel());_9m._s5=false;_9m._qq=true;_9m._j4=true;_9m._wp=_Iu;_9m._sx=_Po.GetObjPtr();return _9m;};CUIMetadataTree.prototype.CreateSearchNode=function(_Eq,_zM){var _S3=ExpAPIXml.eSearch+"_"+Utilities.GenerateId();_Eq._yq=_S3;var _6F=this.GetNodeDataById(_Eq);var _Ic=this._we.ReplaceParam('IDS_SEARCH',1,_6F.GetLabel());var _Ke=this.uiManager.appobj.appname;var _OM=Utilities.GenerateCallback(CUIMetadataTree.SafeDoSearchFromNode,[_Ke,_Eq]);var _5M=new COTTreeNode(ExpAPIXml.eSearch,_S3,_Ic,_S3,_Eq,_OM,_Ic);_5M._j4=false;_5M._c0=false;this._hA.AddTreeNode(_5M);return _5M;};CUIMetadataTree.prototype.HandleHierarchyNode=function(_Ts,_KA,_Eq,_IA){var _ay6=null;var oMem=_Ts.GetSingleRootMember();if(oMem){_ay6=this.CreateRootMemberNode(_Eq,oMem,_KA._ue);_KA.AddMemberChildren(_ay6,oMem);this._hA.AddTreeNode(_ay6);if(this._ob.IsFunctionSupported(ExpAPIXml.kQosMultiHierOfSameDim)){oMem.SetLineageLabel(new Array(_Ts._rj.GetLabel(),_Ts.GetLabel(),oMem.GetLabel()));}else{var _auG=_IA?new Array(oMem.GetLabel()):new Array(_Ts._rj.GetLabel(),oMem.GetLabel());oMem.SetLineageLabel(_auG);}}else{_ay6=this.CreateHierNode(_Eq,_Ts,_KA._ue);_KA.AddMemberChildren(_ay6,_Ts);this._hA.AddTreeNode(_ay6);_Ts.SetLineageLabels();}return _ay6;};CUIMetadataTree.prototype.CreateOtherNode=function(_Eq){var _zM=this.GetNodeDataById(_Eq);var _atp=this.GetUIOtherChildCount(_zM);if(_atp==0){return null;}if(_Eq._ly){var _Xa=_Eq._dK[_Eq._ly];}else{var _atW=ExpAPIXml.eOther+"_"+Utilities.GenerateId();_Eq._ly=_atW;var _Ic=this._we.GetString('IDS_METADATA_OTHER_MEMBERS');var _Rz=this._we.GetString('IDS_METADATA_OTHER_MEMBERS_TOOLTIP');var _Ke=this.uiManager.appobj.appname;var _Xa=new COTTreeNode(ExpAPIXml.eOther,_atW,_Ic,_atW,_Eq,null,_Rz);_Xa._j4=false;_Xa._s5=true;_Xa._wp=_Eq._wp;this._hA.AddTreeNode(_Xa);this.oTree.DrawNode(_Xa);_Xa._lx.sibling=true;if(this.oTree.IsNodeDisplayed(_Xa._lx)){this.oTree.UpdateNode(_Xa._lx);}}return _Xa;};CUIMetadataTree.prototype.CreateOtherMemberNode=function(_Eq,_UY){var _HB=new COTTreeNode(ExpAPIXml.eMember,_UY._ks,_UY._p8,_UY._ks,_Eq,null,_UY._p8);_HB._uD=true;_HB._s5=(_UY.GetOtherChildCount()>0);_HB._wp=_Eq._wp;this._hA.AddTreeNode(_HB);return _HB;};CUIMetadataTree.prototype.RefreshOtherNode=function(_NC){var _avS=false;for(var i=0;i<_NC.length;i++){var _C7=_NC[i];if(_C7){var _Eq=this._hA.GetNode(_C7);if(_Eq){var _OH=this._ov[_Eq._wp];if(_Eq._ly){var _Xa=_Eq._dK[_Eq._ly];_OH.AddChildren(_Xa,this.GetNodeDataById(_Xa),Utilities.GetObjArrayLength(_Xa._dK),_Xa._uS);}else if(_Eq._uD){_OH.AddChildren(_Eq,this.GetNodeDataById(_Eq),Utilities.GetObjArrayLength(_Eq._dK),_Eq._uS);}else if(_Eq._yq){var _aDp=_Eq._dK[_Eq._yq];if(_aDp&&_aDp._lW==ExpAPIXml.eSearch){this.CreateOtherNode(_Eq);}}this._ob.DeleteFromOtherItemArray(i);}else{_avS=true;}}}if(_avS){}};CUIMetadataTree.prototype.UpdatePrevSibling=function(_Eq,_zM){if(this.IsOtherItem(_Eq)){var _amB=Utilities.GetObjArrayLength(_Eq._dK);if(_amB>0&&_amB<_zM.GetOtherChildCount()){var _aDH=Utilities.GetNthFromObjArray(_Eq._dK,_amB);Debug.Assert(_aDH);_aDH._oW=true;if(this.oTree.IsNodeDisplayed(_aDH)){this.oTree.UpdateNode(_aDH);this.oTree.FillChildrenLineImg(_aDH,1);}}}};CUIMetadataTree.prototype.IsOtherItem=function(_Eq){if(_Eq){return(_Eq._lW==ExpAPIXml.eOther||_Eq._uD);}else{return false;}};CUIMetadataTree.prototype.CreateMoreNode=function(_Eq,_Bz){var _9T=ExpAPIXml.eMore+"_"+Utilities.GenerateId();_Eq._yq=_9T;var _Ic=this._we.GetString('IDS_METADATA_MORE_MEMBERS');var _Ke=this.uiManager.appobj.appname;var _zM=this.GetNodeDataById(_Eq);if(this.IsOtherItem(_Eq)){this.UpdatePrevSibling(_Eq,_zM);}var _UA=new Array(_Ke,_Eq,_zM,_9T,_Bz);var _OM=Utilities.GenerateCallback(CUIMetadataTree.SafeDoShowMore,_UA);var _aHN=new COTTreeNode(ExpAPIXml.eMore,_9T,_Ic,_9T,_Eq,_OM,_Ic);_aHN._j4=false;_aHN._c0=false;this._hA.AddTreeNode(_aHN);return _aHN;};CUIMetadataTree.prototype.FetchChildren=function(_Eq){var _Ke=this.uiManager.appobj.appname;var _BF=_Eq._lW;_Eq.bCancelled=false;_Eq._de=false;switch(_BF){case ExpAPIXml.eRoot:return false;break;case ExpAPIXml.eDim:var _OH=this._ov[_Eq._wp];var _EZ=_OH._xA;var _Ts=_EZ.GetSingleHierarchy();if(_Ts){var oMem=_Ts.GetSingleRootMember();if(oMem){if(_OH.CanDisplay(_Eq)){_OH.AddRootMemberChildren(_Eq,oMem);this.oTree.DrawChildren(_Eq,true,false,true);return false;}else{Debug.Assert(false);return false;}}else{this.oTree.DrawChildren(_Eq,true,false,true);}}else{_OH.AddMemberChildren(_Eq,_EZ);this.oTree.DrawChildren(_Eq,true,false,true);}break;case ExpAPIXml.eHierarchy:var _OH=this._ov[_Eq._wp];_OH._vc=this.GetNodeDataById(_Eq);_OH._nk=_Eq;if(_OH._vc._v1){this.oTree.DrawChildren(_Eq,true,false,true);}else{_OH._qu=CUIDimension.eStateLoading;_Eq._pg=0;_OH._vc.PopulateRootMember();var _6z=Utilities.GenerateCallback(_OH.FetchChildren,[_Eq],_OH);setTimeout(_6z,1000);return true;}break;case ExpAPIXml.eMeasureRoot:this.oTree.DrawChildren(_Eq,true,false,true);break;case ExpAPIXml.eFolder:case ExpAPIXml.eNamespace:case ExpAPIXml.eMeasureFolder:case ExpAPIXml.eMember:case ExpAPIXml.eDimRoot:case ExpAPIXml.eMeasure:case ExpAPIXml.eOther:case CUIMeasure.kNonAggreMeasure:var _OH=this._ov[_Eq._wp];_OH._vc=this.GetNodeDataById(_Eq);_OH._nk=_Eq;if(this.IsOtherItem(_Eq)){_OH.AddChildren(_Eq,this.GetNodeDataById(_Eq));this.oTree.DrawChildren(_Eq,true,false,true);return false;}else{if(_BF==ExpAPIXml.eMeasure||_BF==CUIMeasure.kNonAggreMeasure){_OH._vc.Populate();_OH.AddMemberChildren(_Eq,_OH._vc);this.oTree.DrawChildren(_Eq,true);return false;}else if(_OH._vc._v1){_OH.AddMemberChildren(_Eq,_OH._vc);this.oTree.DrawChildren(_Eq,true,false,true);return false;}else{_OH._qu=CUIDimension.eStateLoading;_Eq._pg=0;_OH._vc.Populate();var _6z=Utilities.GenerateCallback(_OH.FetchChildren,[_Eq],_OH);setTimeout(_6z,1000);return true;}}break;default:Debug.Assert(false,'unexpected objtype '+_BF+' in FetchChildren');return false;break;}return false;};CUIMetadataTree.prototype.GetLastSelection=function(){if(this.oTree.GetLastSelection()){return this;}return null;};CUIMetadataTree.prototype.GetLastTreeSelection=function(){return this.oTree.GetLastSelection();};CUIMetadataTree.prototype.GetSelectionLabel=function(){if(this.oTree.GetLastSelection()){return this.oTree.GetLastSelection()._p8;}return "";};CUIMetadataTree.prototype.GetAggregateLabel=function(_OQ){var _anp='';switch(_OQ){case ExpAPIXml.kEleSumAggre:_anp=this._we.GetString('IDS_MEASURE_AGGREGATION_SUM');break;case ExpAPIXml.kEleCountAggre:_anp=this._we.GetString('IDS_MEASURE_AGGREGATION_COUNT');break;case ExpAPIXml.kEleCountDistinctAggre:_anp=this._we.GetString('IDS_MEASURE_AGGREGATION_COUNTDISTINCT');break;case ExpAPIXml.kEleCountNonZeroAggre:_anp=this._we.GetString('IDS_MEASURE_AGGREGATION_COUNTNONZERO');break;}return _anp;};CUIMetadataTree.prototype.GetRollUpTypeLabel=function(_Ud){var _3j='';switch(_Ud){case ExpAPIXml.kEleRegRollUp:_3j=this._we.GetString('IDS_MEMBER_ROLLUP_TYPE_ROLL_UP');break;case ExpAPIXml.kEleComputed:_3j=this._we.GetString('IDS_MEMBER_ROLLUP_TYPE_COMPUTED');break;}return _3j;};CUIMetadataTree.prototype.GetDescription=function(){var _V7=this.oTree.GetLastSelection();if(!_V7){return "";}var _FZ=this._ob.GetDataById(_V7._ks);if(_FZ&&_FZ.GetDescription&&_FZ.GetDescription()!=null){return _FZ.GetDescription();}return "";};CUIMetadataTree.prototype.ShowPropertyPairs=function(_ET,oMem,_JP){var _GP=false;for(var i in _ET._lG){var _aIT=this._we.ReplaceParam('IDS_INFORMATION_PANE_PROPERTY_NAME',1,_ET.GetProperty(i)._p8);if(_aIT&&_aIT!=""){var _Qs=oMem.GetPropertyValueById(i);if(_Qs==null){_Qs="";_GP=true;}if(_JP){_JP.push(new COTPropertyPair(_aIT,_Qs));}}}if(_GP){oMem.Subscribe(this,ExpEvent.kCDLMember_Merge);this._lo=oMem;}};CUIMetadataTree.prototype.FetchPropertyPairs=function(_ET,oMem,_JP){var _aDc=Utilities.GenerateCallback(this.ShowPropertyPairs,[_ET,oMem],this);this._ob.FetchProperties(new Array(_ET),_aDc);var _KS=this.uiManager.oLeftPaneMenu.oInfoPane;this._ob.Subscribe(_KS,ExpEvent.kCDLMetadata_Merge_Properties);};CUIMetadataTree.prototype.FetchPropertyMetadata=function(_ET,_JP){this._ob.FetchProperties(new Array(_ET),null);var _KS=this.uiManager.oLeftPaneMenu.oInfoPane;this._ob.Subscribe(_KS,ExpEvent.kCDLMetadata_Merge_Properties);};CUIMetadataTree.prototype.PopulateNameAndTypeInfo=function(_Eq,_JP){var _aj9=this._ob.GetDataById(_Eq._ks);if(_aj9){_JP.push(new COTPropertyPair('IDS_SELECTION_NAME',_aj9.GetLabel()));if(this._xf[_Eq._lW]){_JP.push(new COTPropertyPair('IDS_SELECTION_TYPE',this._xf[_Eq._lW]));}}};CUIMetadataTree.prototype.PopulateNamedSetInfo=function(_Eq,_JP){var _V8;if(_Eq._lW==ExpAPIXml.eNamedSet){_V8=this._ob.GetNamedSet(_Eq._ks);}else{_V8=this._ob.GetNamedSet(_Eq._sx);}_JP.push(new COTPropertyPair('IDS_HIERARCHY_INFO',_V8.GetHierarchy().GetLabel()));_JP.push(new COTPropertyPair('IDS_DIMENSION_INFO',_V8.GetDim().GetLabel()));};CUIMetadataTree.prototype.GetDataSourceProperty=function(_OI,_JP){var _an8=this._ob._cm;var _Xh=_OI?_OI:this._we.GetString('IDS_CUBE_SELECT_DATA_SOURCE');if(_an8.length>1){var _Ys=new Array();var _axC=new Array();var _apU=new Array();var _aCv=new Array();for(var i=0;i<_an8.length;i++){_Ys.push(_an8[i][ExpAPIXml.kEleName]);_axC.push(CUIPropertyPane.SafeHandleDataSourceSelection);_apU[i]=new Array();_apU[i].push(_an8[i][ExpAPIXml.kEleName]);_aCv.push(_apU[i]);}_JP.push(new COTDropDownPair(this.uiManager.appobj.appname,'IDS_DATA_SOURCE',_Xh,"",_Ys,_axC,_aCv));}for(var i=0;i<_an8.length;i++){if(_an8.length==1||_an8[i][ExpAPIXml.kEleName]==_OI){if(_an8[i][ExpAPIXml.kEleCubeProperties][ExpAPIXml.kEleCubeName]){_JP.push(new COTPropertyPair('IDS_CUBE_NAME',_an8[i][ExpAPIXml.kEleCubeProperties][ExpAPIXml.kEleCubeName]));}if(_an8[i][ExpAPIXml.kEleCubeProperties][ExpAPIXml.kEleCubeDescription]){_JP.push(new COTPropertyPair('IDS_CUBE_DESCRIPTION',_an8[i][ExpAPIXml.kEleCubeProperties][ExpAPIXml.kEleCubeDescription]));}if(_an8[i][ExpAPIXml.kEleCubeProperties][ExpAPIXml.kEleCubeDataUpdatedOn]){_JP.push(new COTPropertyPair('IDS_CUBE_UPDATED_ON',_an8[i][ExpAPIXml.kEleCubeProperties][ExpAPIXml.kEleCubeDataUpdatedOn]));}if(_an8[i][ExpAPIXml.kEleCubeProperties][ExpAPIXml.kEleCubeCreatedOn]){_JP.push(new COTPropertyPair('IDS_CUBE_CREATED_ON',_an8[i][ExpAPIXml.kEleCubeProperties][ExpAPIXml.kEleCubeCreatedOn]));}if(_an8[i][ExpAPIXml.kEleCubeProperties][ExpAPIXml.kEleCubeSchemaUpdatedOn]){_JP.push(new COTPropertyPair('IDS_CUBE_SCHEMA_UPDATED_ON',_an8[i][ExpAPIXml.kEleCubeProperties][ExpAPIXml.kEleCubeSchemaUpdatedOn]));}if(_an8[i][ExpAPIXml.kEleCubeProperties][ExpAPIXml.kEleCubeCurrentPeriod]){_JP.push(new COTPropertyPair('IDS_CUBE_CURRENT_PERIOD',_an8[i][ExpAPIXml.kEleCubeProperties][ExpAPIXml.kEleCubeCurrentPeriod]));}if(_an8[i][ExpAPIXml.kEleCubeProperties][ExpAPIXml.kEleCubeDefaultMeasure]){_JP.push(new COTPropertyPair('IDS_CUBE_DEFAULT_MEASURE',_an8[i][ExpAPIXml.kEleCubeProperties][ExpAPIXml.kEleCubeDefaultMeasure]));}break;}}};CUIMetadataTree.prototype.GetPropertyList=function(_OI){var _V7=this.oTree.GetLastSelection();var _JP=new Array();Debug.Assert(_V7);if(!_V7){return _JP;}this.PopulateNameAndTypeInfo(_V7,_JP);var oMem=this._ob.GetMember(_V7._ks);if(oMem){var _Z1=oMem.GetLevel();if(_Z1){var _aBP='level_black_sea.gif';_JP.push(new COTDraggablePair('IDS_SELECTION_LEVEL',_Z1._p8,_aBP,_V7._ks));}var _ag5=this.GetRollUpTypeLabel(oMem.GetRollUpType());_JP.push(new COTPropertyPair(this._we.GetString('IDS_MEMBER_AGGREGATION'),_ag5));var _ET=(_Z1!=null?_Z1:oMem.GetHierarchy());if(_ET){if(_ET._lG){this.ShowPropertyPairs(_ET,oMem,_JP);}else{_JP.push(new COTLoadingPair(this._we.GetString('IDS_FETCHING_ATTRIBUTES'),this._we.GetString('IDS_CONTEXTBAR_LOADING'),"icon_loading.gif"));this.FetchPropertyPairs(_ET,oMem);}}}else{var _NS=this._ob.GetMeasure(_V7._ks);if(_NS){var _ag5=this._we.GetString('IDS_MEASURE_AGGREGATION_NONE');if(_NS.IsAggregateable()){var _at7=this._ob.GetMeasure(_V7._ks).GetRegAggregateType();_ag5=this.GetAggregateLabel(_at7);}_JP.push(new COTPropertyPair(this._we.GetString('IDS_MEASURE_AGGREGATION'),_ag5));}else if(_V7._lW==ExpAPIXml.eRoot){this.GetDataSourceProperty(_OI,_JP);}else if(_V7._lW==ExpAPIXml.eNamedSet||_V7._lW==ExpAPIXml.eNamedSetFolderObj){this.PopulateNamedSetInfo(_V7,_JP);}}return _JP;};CUIMetadataTree.prototype.SetSelectBasedInsParam=function(_Lv,_KK,_Eh){var _FK=this.uiManager.GetCurrentWorkSheet().GetSelectedBlock();if(_FK){var _Ti=_FK.GetId();_Lv.sTargetBlock=_Ti;var _aA6=this.uiManager.GetCurrentWorkSheet().GetUIAxesContainer().GetUIAxis(CUIDataMatrix.iRowIndex);var _awE=_aA6.GetDLAxis().GetBlock(_Ti);if(!_awE){_aA6=this.uiManager.GetCurrentWorkSheet().GetUIAxesContainer().GetUIAxis(CUIDataMatrix.iColIndex);_awE=_aA6.GetDLAxis().GetBlock(_Ti);}if((!_awE)||(_awE&&_awE.IsEmptyBlock())){_Eh._eY=true;return;}if(Utilities.bSingleMemExpandEnabled&&_awE.IsExpandedSet()){_Eh._eY=true;return;}var _zA=null;_Eh._eY=false;_Lv.sTargetAxis=_awE.GetAxis().GetId();var _6q=_Lv.GetDimId(this._ob)==_awE.GetDimId();var _aBV=false;if(_6q){_aBV=COTValidation.IsHAMCDrop(this._ob,_awE,_Lv);}var _Jj;if(_KK==CUIUserSelection.AbsPosReplace){_Lv.kAction=ExpAPIXml.kActionReplace;_Eh._eY=!COTValidation.IsValidDrop(_aA6.GetDLAxis(),_Lv,this._ob,ExpAPIXml.kActionReplace,_awE);return _Lv;}if(_aA6.IsRowAxis()){switch(_KK){case CUIUserSelection.AbsPosAbove:_Lv.kPosition=ExpAPIXml.kEleOuter;_Lv.kAction=ExpAPIXml.kAxisOpUnion;var _3y=COTValidation.IsValidDrop(_aA6.GetDLAxis(),_Lv,this._ob,ExpAPIXml.kAxisOpUnion,_awE,ExpAPIXml.kEleOuter);_Eh.SetEnabled(_3y);break;case CUIUserSelection.AbsPosBelow:_Lv.kPosition=ExpAPIXml.kEleInner;_Lv.kAction=ExpAPIXml.kAxisOpUnion;var _am5=COTValidation.IsValidDrop(_aA6.GetDLAxis(),_Lv,this._ob,ExpAPIXml.kAxisOpUnion,_awE,ExpAPIXml.kEleInner);_Eh.SetEnabled(_am5);break;case CUIUserSelection.AbsPosBefore:_Lv.kPosition=ExpAPIXml.kEleOuter;_Lv.kAction=ExpAPIXml.kAxisOpXjoin;var _aba=COTValidation.IsValidDrop(_aA6.GetDLAxis(),_Lv,this._ob,ExpAPIXml.kAxisOpXjoin,_awE,ExpAPIXml.kEleOuter);_Eh.SetEnabled(_aba);break;case CUIUserSelection.AbsPosAfter:_Lv.kPosition=ExpAPIXml.kEleInner;var _atr=COTValidation.IsValidDrop(_aA6.GetDLAxis(),_Lv,this._ob,ExpAPIXml.kAxisOpXjoin,_awE,ExpAPIXml.kEleInner);_Lv.kAction=_Lv._ud?ExpAPIXml.kAxisOpNest:ExpAPIXml.kAxisOpXjoin;_Eh.SetEnabled(_atr);break;case CUIUserSelection.AbsPosIn:if(!_aBV){_Eh.SetEnabled(false);break;}else{_Lv.kAction=ExpAPIXml.kActionAppend;break;}}}else{switch(_KK){case CUIUserSelection.AbsPosAbove:_Lv.kPosition=ExpAPIXml.kEleOuter;_Lv.kAction=ExpAPIXml.kAxisOpXjoin;var _aba=COTValidation.IsValidDrop(_aA6.GetDLAxis(),_Lv,this._ob,ExpAPIXml.kAxisOpXjoin,_awE,ExpAPIXml.kEleOuter);_Eh.SetEnabled(_aba);break;case CUIUserSelection.AbsPosBelow:_Lv.kPosition=ExpAPIXml.kEleInner;var _atr=COTValidation.IsValidDrop(_aA6.GetDLAxis(),_Lv,this._ob,ExpAPIXml.kAxisOpXjoin,_awE,ExpAPIXml.kEleInner);_Lv.kAction=_Lv._ud?ExpAPIXml.kAxisOpNest:ExpAPIXml.kAxisOpXjoin;_Eh.SetEnabled(_atr);break;case CUIUserSelection.AbsPosBefore:_Lv.kPosition=ExpAPIXml.kEleOuter;_Lv.kAction=ExpAPIXml.kAxisOpUnion;var _3y=COTValidation.IsValidDrop(_aA6.GetDLAxis(),_Lv,this._ob,ExpAPIXml.kAxisOpUnion,_awE,ExpAPIXml.kEleOuter);_Eh.SetEnabled(_3y);break;case CUIUserSelection.AbsPosAfter:_Lv.kPosition=ExpAPIXml.kEleInner;_Lv.kAction=ExpAPIXml.kAxisOpUnion;var _am5=COTValidation.IsValidDrop(_aA6.GetDLAxis(),_Lv,this._ob,ExpAPIXml.kAxisOpUnion,_awE,ExpAPIXml.kEleInner);_Eh.SetEnabled(_am5);break;case CUIUserSelection.AbsPosIn:if(!_aBV){_Eh.SetEnabled(false);break;}else{_Lv.kAction=ExpAPIXml.kActionAppend;break;}}}}else{_Eh._eY=true;}return _Lv;};CUIMetadataTree.CreateDropData=function(_Ke,_Lx,_R1,_FD,_y2){var _M0=FindApp(_Ke);var _AT=_M0.dataManager;var _Lv=null;if(_R1&&_R1.length>0){_FD=false;}if(_y2!=null){_Lv=new CUIDragDropLevel(_Lx,_y2);}else if(_AT._kX.GetCustomSet(_Lx)){var _Oj=_AT._kX.GetCustomSet(_Lx);var _J5=_Oj.IsHAMC()?_Oj.GetMemberIds():null;_Lv=new CUIDragDropCustomSet(_Oj._ks,_Oj.GetLevelPtr(),_Oj.GetLastDataMemberId(),_J5);var _FD=!_AT._kX.GetCustomSet(_Lx).IsHAMC();}else if(_AT.metadata.GetNamedSet(_Lx)){var _V8=_AT.metadata.GetNamedSet(_Lx);var _Lv=new CUIDragDropNamedSet(_Lx,_V8.GetDimId(),_V8.GetHierId());}else if(!_R1||_R1.length==0){_Lv=new CUIDragDropMember(_Lx);}else{var _ar6=new Array(_Lx);_ar6=_ar6.concat(_R1);_Lv=new CUIDragDropMemberList(_ar6,false);}_Lv.kPopulation=_FD?ExpAPIXml.kChildrenPopulation:ExpAPIXml.kMemberPopulation;if(_y2!=null){_Lv.kPopulation=ExpAPIXml.kAxisExprLevelMembers;}return _Lv;};CUIMetadataTree.SetBaseXTabInsertionMenuParameters=function(_Ke,_PM,_Lx,_R1,_FD,_Vr,_Sa){var _ajA=false;var _9D=false;var _M0=FindApp(_Ke);var _aes,_BV,_aDz;var _AT=_M0.dataManager;var _Li=_AT.GetCurrentDataMatrix();var _aIU=!_M0.uiManager.GetCurrentWorkSheet().AllowInteraction();var _ak2,_aJk;if(!_Li){return;}_BV=_Li._ks;_ak2=_Li.GetAxis(CUIDataMatrix.iRowIndex);Debug.Assert(_ak2!=null);_ajA=_ak2.IsEmpty();_aes=_ak2.GetId();_aJk=_Li.GetAxis(CUIDataMatrix.iColIndex);Debug.Assert(_aJk!=null);_9D=_aJk.IsEmpty();_aDz=_aJk.GetId();var _CI=_M0.oResources;var _Tc=_M0.uiManager.dataManager.metadata;if(_PM._o6){for(var y=0;y<_PM._o6.items.length;y++){var _Eh=_PM._o6.items[y];var _aEu=_Eh instanceof ContextItem;if(_aEu){if(_Vr){var _agm=new Array(_Ke,_Sa);_Eh.DeferItemAction(CDLMetadata.SafeDoGetLineage,_agm);}var _Lv=null;var _ayt=(_R1&&_R1.length>0);if(_Tc.GetMember(_Lx)&&_Tc.GetMember(_Lx).GetLevel()){var _S8=_Tc.GetMember(_Lx).GetLevel();if(_PM.GetFunctionId()=="insertlevel"){_PM._ny=_CI.ReplaceParam('TRE_METADATA_INSERT_LEVEL',1,_S8.GetLabel());_PM.SetDisplayFlag(true);_Lv=CUIMetadataTree.CreateDropData(_Ke,_Lx,_R1,_FD,_S8._ks);_PM.SetEnabled(true);if(_ayt){_PM.SetEnabled(false);}}if(_PM.GetFunctionId()=="replacelevel"){_PM._ny=_CI.ReplaceParam('TRE_METADATA_REPLACE_LEVEL',1,_S8.GetLabel());_PM.SetDisplayFlag(true);_Lv=CUIMetadataTree.CreateDropData(_Ke,_Lx,_R1,_FD,_S8._ks);_PM.SetEnabled(true);if(_ayt){_PM.SetEnabled(false);}}}else{if(_PM.GetFunctionId()=="insertlevel"){_PM.SetDisplayFlag(false);}if(_PM.GetFunctionId()=="replacelevel"){_PM.SetDisplayFlag(false);}}if(_aIU){_PM.SetEnabled(false);return;}if(_Lv==null){_Lv=CUIMetadataTree.CreateDropData(_Ke,_Lx,_R1,_FD);}var _aod=_Lv.GetDimId(_AT.metadata);var _zA=new Array(_M0.uiManager.GetCurrentWorkSheet(),_Lv);_Eh.SetItemAction(CUIWorkSheet.SafeDoInsertDropData);var _an6=COTValidation.IsValidDrop(_ak2,_Lv,_AT.metadata,ExpAPIXml.kAxisOpXjoin);var _5H=COTValidation.IsValidDrop(_aJk,_Lv,_AT.metadata,ExpAPIXml.kAxisOpXjoin);if(_PM.DoDisplay()&&(_PM.id=='TRE_METADATA_INSERT'||_PM.GetFunctionId()=="insertlevel")){switch(_Eh.id){case 'TRE_METADATA_DEF_ADD_ROW':case 'TRE_METADATA_INSERT_LEVEL_ROWS':_Lv.kAction=ExpAPIXml.kAxisOpXjoin;_Lv.sTargetAxis=_ak2.GetId();_Lv.kPosition=ExpAPIXml.kEleOuter;_Eh._eY=!_ajA||!_an6;break;case 'TRE_METADATA_DEF_ADD_COL':case 'TRE_METADATA_INSERT_LEVEL_COLS':_Lv.kAction=ExpAPIXml.kAxisOpXjoin;_Lv.sTargetAxis=_aJk.GetId();_Lv.kPosition=ExpAPIXml.kEleOuter;_Eh._eY=!_9D||!_5H;break;case 'TRE_METADATA_INS_NESTED_INNER_ROW':case 'TRE_METADATA_INSERT_LEVEL_INNER_ROWS':_Lv.kPosition=ExpAPIXml.kEleInner;_Lv.kAction=ExpAPIXml.kAxisOpXjoin;_Lv.sTargetAxis=_ak2.GetId();_Eh._eY=_ajA||!_an6;break;case 'TRE_METADATA_INS_NESTED_INNER_COL':case 'TRE_METADATA_INSERT_LEVEL_INNER_COLS':_Lv.kPosition=ExpAPIXml.kEleInner;_Lv.kAction=ExpAPIXml.kAxisOpXjoin;_Lv.sTargetAxis=_aJk.GetId();_Eh._eY=_9D||!_5H;break;case 'TRE_METADATA_INS_AFTER_SELECTION':case 'TRE_METADATA_INSERT_LEVEL_AFTER_SEL':_Lv=_M0.uiManager._qi.SetSelectBasedInsParam(_Lv,CUIUserSelection.AbsPosAfter,_Eh);break;case 'TRE_METADATA_INS_BEFORE_SELECTION':case 'TRE_METADATA_INSERT_LEVEL_BEFORE_SEL':_Lv=_M0.uiManager._qi.SetSelectBasedInsParam(_Lv,CUIUserSelection.AbsPosBefore,_Eh);break;case 'TRE_METADATA_INS_ABOVE_SELECTION':case 'TRE_METADATA_INSERT_LEVEL_ABOVE_SEL':_Lv=_M0.uiManager._qi.SetSelectBasedInsParam(_Lv,CUIUserSelection.AbsPosAbove,_Eh);break;case 'TRE_METADATA_INS_BELOW_SELECTION':case 'TRE_METADATA_INSERT_LEVEL_BELOW_SEL':_Lv=_M0.uiManager._qi.SetSelectBasedInsParam(_Lv,CUIUserSelection.AbsPosBelow,_Eh);break;case 'TRE_METADATA_INS_INTO_SEL':_Lv=_M0.uiManager._qi.SetSelectBasedInsParam(_Lv,CUIUserSelection.AbsPosIn,_Eh);break;}}else if(_PM.DoDisplay()&&(_PM.id=='TRE_METADATA_REPLACE'||_PM.GetFunctionId()=="replacelevel")){switch(_Eh.id){case 'TRE_METADATA_REP_ROW':case 'TRE_METADATA_REPLACE_LEVEL_ROWS':_Lv.kAction=ExpAPIXml.kActionReplace;_Lv.sTargetAxis=_ak2.GetId();var _atr=COTValidation.IsValidDrop(_ak2,_Lv,_Tc,ExpAPIXml.kActionReplace);_Eh.SetEnabled(!_ajA&&_atr);break;case 'TRE_METADATA_REP_COL':case 'TRE_METADATA_REPLACE_LEVEL_COLS':_Lv.kAction=ExpAPIXml.kActionReplace;_Lv.sTargetAxis=_aJk.GetId();var _atr=COTValidation.IsValidDrop(_aJk,_Lv,_Tc,ExpAPIXml.kActionReplace);_Eh.SetEnabled(!_9D&&_atr);break;case 'TRE_METADATA_REP_SELECTION':case 'TRE_METADATA_REPLACE_LEVEL_SEL':_Lv=_M0.uiManager._qi.SetSelectBasedInsParam(_Lv,CUIUserSelection.AbsPosReplace,_Eh);break;}}if(!_Eh._eY&&!_aIU){_PM.SetEnabled(true);}_Eh.SetParameterArr(_zA);}}}};CUIMetadataTree.SetBaseMemCntxMenuParameters=function(_Ke,_PM,oMem,_C9,_FD,_Nv){Debug.Assert(_C9.length>0||_Nv.length>0);var _M0=FindApp(_Ke);var _2V=_C9[0];var _Sa=new Array();var _R1=new Array();var _adA=_M0.dataManager.metadata.GetOrphanAncestor(_2V);if(_adA){_Sa.push(_adA);}for(var i=1;i<_C9.length;i++){_R1.push(_C9[i]);if(_M0.dataManager.metadata.GetOrphanAncestor(_C9[i])){_Sa.push(_M0.dataManager.metadata.GetOrphanAncestor(_C9[i]));}}var _Vr=false;if(_Sa.length>0){_Vr=true;}if(_PM._o6){CUIMetadataTree.SetBaseXTabInsertionMenuParameters(_Ke,_PM,_2V,_R1,_FD,_Vr,_Sa);}else{if(_Vr){var _agm=new Array(_Ke,_Sa);if(_PM.DeferItemAction){_PM.DeferItemAction(CDLMetadata.SafeDoGetLineage,_agm);}}var _CI=_M0.oResources;switch(_PM.GetFunctionId()){case 'TRE_TREEVIEW_FILTER_BY_MEMBER':var _Lv=CUIMetadataTree.CreateDropData(_Ke,_2V,_R1,_FD);_zA=new Array(_Ke,_Lv);_PM.SetEnabled(CUIMetadataTree.IsValidFilterMenuItem(_M0,_PM,_Lv));break;case 'IDS_SEARCH':_PM._ny=_CI.ReplaceParam('IDS_SEARCH',1,oMem.GetLabel());_zA=new Array(_Ke,oMem);_PM.SetItemAction(CUIMetadataTree.SafeDoSearchFromData);break;case 'TRE_METADATA_VIEW_SOURCE_INFO':_zA=new Array(_Ke,_C9);break;case 'TRE_METADATA_GLOSSARY':_zA=new Array(_Ke,_Nv);break;}if(_PM.SetParameterArr){_PM.SetParameterArr(_zA);}}};CUIMetadataTree.IsValidFilterMenuItem=function(_M0,_PM,_Lv){var _7k=false;var _Li=_M0.dataManager.GetCurrentDataMatrix();if(_Li&&_Li.IsValidActionForSameHierCompatibilityRule(null,_Lv,null,null,true)){_7k=true;}return _7k;};CUIMetadataTree.SetBaseMeasureCntxMenuParameters=function(_Ke,_Eh,_NS,_TC){var _M0=FindApp(_Ke);var _CI=_M0.oResources;Debug.Assert(_TC.length>0);var _HT=_TC[0];var _R1=new Array();for(var i=1;i<_TC.length;i++){_R1.push(_TC[i]);}var _Li=_M0.uiManager.dataManager.GetCurrentDataMatrix();var _aIU=!_M0.uiManager.GetCurrentWorkSheet().AllowInteraction();var _ak2,_aJk;if(!_Li){return;}var _BV=_Li._ks;_ak2=_Li.GetAxis(CUIDataMatrix.iRowIndex);Debug.Assert(_ak2!=null);var _ajA=_ak2.IsEmpty();var _aes=_ak2.GetId();_aJk=_Li.GetAxis(CUIDataMatrix.iColIndex);Debug.Assert(_aJk!=null);var _9D=_aJk.IsEmpty();var _aDz=_aJk.GetId();var _9f=!_ajA&&!_aJk.HasMeasureBlock();var _Yd=!_9D&&!_ak2.HasMeasureBlock();var _Y7=ExpAPIXml.kMemberPopulation;var _ZW=_Eh instanceof ContextItem;if(_ZW){var _Lv;if(!_R1||_R1.length==0){_Lv=new CUIDragDropMember(_HT);}else{_Lv=new CUIDragDropMemberList(_TC,false);}_Lv.kPopulation=_Y7;var _zA;if(_Eh._p5._xW.id=='TRE_METADATA_INSERT'){switch(_Eh.id){case 'TRE_METADATA_DEF_ADD_ROW':var _adL=_ak2.HasMeasureBlock();if(!_adL&&!_aJk.HasMeasureBlock()){_Lv.kAction=ExpAPIXml.kAxisOpXjoin;_Lv.sTargetAxis=_aes;_Lv.kPosition=ExpAPIXml.kEleInner;_Eh.SetEnabled(true);}else{_Eh.SetEnabled(false);}break;case 'TRE_METADATA_DEF_ADD_COL':var _adL=_aJk.HasMeasureBlock();if(!_adL&&!_ak2.HasMeasureBlock()){_Lv.kAction=ExpAPIXml.kAxisOpXjoin;_Lv.sTargetAxis=_aJk.GetId();_Lv.kPosition=ExpAPIXml.kEleInner;_Eh.SetEnabled(true);}else{_Eh.SetEnabled(false);}break;case 'TRE_METADATA_INS_AFTER_SELECTION':_Lv=_M0.uiManager._qi.SetSelectBasedInsParam(_Lv,CUIUserSelection.AbsPosAfter,_Eh);break;case 'TRE_METADATA_INS_BEFORE_SELECTION':_Lv=_M0.uiManager._qi.SetSelectBasedInsParam(_Lv,CUIUserSelection.AbsPosBefore,_Eh);break;case 'TRE_METADATA_INS_ABOVE_SELECTION':_Lv=_M0.uiManager._qi.SetSelectBasedInsParam(_Lv,CUIUserSelection.AbsPosAbove,_Eh);break;case 'TRE_METADATA_INS_BELOW_SELECTION':_Lv=_M0.uiManager._qi.SetSelectBasedInsParam(_Lv,CUIUserSelection.AbsPosBelow,_Eh);break;case 'TRE_METADATA_INS_INTO_SEL':_Lv=_M0.uiManager._qi.SetSelectBasedInsParam(_Lv,CUIUserSelection.AbsPosIn,_Eh);break;}}else if(_Eh._p5._xW.id=='TRE_METADATA_REPLACE'){switch(_Eh.id){case 'TRE_METADATA_REP_SELECTION':_Lv=_M0.uiManager._qi.SetSelectBasedInsParam(_Lv,CUIUserSelection.AbsPosReplace,_Eh);break;case 'TRE_METADATA_REP_ROW':_Lv.kAction=ExpAPIXml.kActionReplace;_Lv.sTargetAxis=_ak2.GetId();_Eh._eY=!_9f;break;case 'TRE_METADATA_REP_COL':_Lv.kAction=ExpAPIXml.kActionReplace;_Lv.sTargetAxis=_aJk.GetId();_Eh._eY=!_Yd;break;}}_zA=new Array(_M0.uiManager.GetCurrentWorkSheet(),_Lv);_Eh.SetItemAction(CUIWorkSheet.SafeDoInsertDropData);_Eh.SetParameterArr(_zA);}};CUIMetadataTree.SetSortParams=function(_Ke,_T8,_LF,_N3){var _M0=FindApp(_Ke);var _CI=_M0.oResources;var _0y=_M0.uiManager._qi.IsOtherItem(_LF);if(!_LF._uS||(!_0y&&_N3.GetChildCount()==0)||(_0y&&_N3.GetOtherChildCount()==0)){_T8.SetEnabled(false);return;}else{_T8.SetEnabled(true);}Debug.Assert(_T8!=null);for(var y=0;y<_T8._o6.items.length;y++){var _Eh=_T8._o6.items[y];switch(_Eh.id){case 'TRE_METADATA_SORT_ASCEND':var _Ro=new Array(_Ke,_LF,_N3,CUIMetadataTree.kSortAscending);break;case 'TRE_METADATA_SORT_DESCEND':var _Ro=new Array(_Ke,_LF,_N3,CUIMetadataTree.kSortDescending);break;case 'TRE_METADATA_SORT_RECORD_ORDER':var _Ro=new Array(_Ke,_LF,_N3,CUIMetadataTree.kSortRecordOrder);if(_0y){_Eh.SetDisplayFlag(false);}else{_Eh.SetDisplayFlag(true);}break;}_Eh.SetParameterArr(_Ro);}};CUIMetadataTree.SetMeasureCntxMenuParameters=function(_Ke,_Ga,_Lt,_UD,_Eq,_C9,_Nv){var _M0=FindApp(_Ke);var _CI=_M0.oResources;for(var x=0;x<_Ga.items.length;x++){var _7t=_Ga.items[x];if(!(_7t instanceof ContextItem)){continue;}var _zA=null;if(_7t._o6){if(_Eq&&(_7t.id=='TRE_METADATA_SORT')){CUIMetadataTree.SetSortParams(_Ke,_7t,_Eq,_Lt);}else{var _aIU=!_UD.AllowInteraction();for(var y=0;y<_7t._o6.items.length;y++){var _Eh=_7t._o6.items[y];if(!(_Eh instanceof ContextSeparator)){switch(_Eh._ny){default:CUIMetadataTree.SetBaseMeasureCntxMenuParameters(_Ke,_Eh,_Lt,_C9);break;}if(!_Eh._eY&&!_aIU){_7t.SetEnabled(true);}}}}}else{switch(_7t.GetFunctionId()){case 'TRE_METADATA_SET_MAX_CHILD_NUM':if(_Eq){_zA=new Array(_Ke,_Eq);_7t.SetParameterArr(_zA);}break;case 'IDS_SEARCH':_7t._ny=_CI.ReplaceParam('IDS_SEARCH',1,_Lt.GetLabel());_zA=new Array(_Ke,_Lt);_7t.SetParameterArr(_zA);_7t.SetItemAction(CUIMetadataTree.SafeDoSearchFromData);break;case 'OTH_MEASURE_MENU_USE_AS_DEFAULT':_Lv=new CUIDragDropMember(_Lt._ks);_Lv.kPopulation=ExpAPIXml.kMemberPopulation;_Lv.kAction=ExpAPIXml.kActionSetDefMeasure;_7t.SetParameterArr(new Array(_UD,_Lv));break;case 'TRE_METADATA_VIEW_SOURCE_INFO':_zA=new Array(_Ke,_C9);break;case 'TRE_METADATA_GLOSSARY':_zA=new Array(_Ke,_Nv);break;}if(_7t.SetParameterArr){_7t.SetParameterArr(_zA);}}}};CUIMetadataTree.prototype.IsGlossaryEnabled=function(){var _WP=this.uiManager.dataManager;var _Mj=_WP.HasCapability(CDLCapability.K_sCanUseGlossary);var _aka=_WP.GetConfigProperty(CDLConfiguration.K_sGlossaryURL);var _awU=_aka?_aka:CDLConfiguration.K_sDefaultGlossaryURL;if(_awU==""){_Mj=false;}return _Mj;};CUIMetadataTree.prototype.ShowContextMenu=function(e,_Eq){if(_Eq){this.oLastSelNode=_Eq;}else{var _Eq=this.oLastSelNode;}if(e){this.oLastContextMenuEvent=Dom.CloneMouseEvent(e);}else{var e=this.oLastContextMenuEvent;}if(_Eq==null){return;}var _Ke=this.uiManager.appobj.appname;var _FD=this.uiManager._jf.GetIncludeDetailFlag();this._iZ=Dom.CloneMouseEvent(e);var nodeType=_Eq._lW;var _4A=_Eq._ks;var _Jm=(_Eq._lW==ExpAPIXml.eOther)?this._ob.GetDataById(_Eq._qR._ks):this._ob.GetDataById(_Eq._ks);var _C9=new Array();var _Nv=new Array();var _asK=this.oTree.GetSelectedNodes();for(var i in _asK){_C9.push(i);_Nv.push(_asK[i]._p8);}if(_C9.length==0){return;}var _aCF=this._ob.IsFunctionSupported(ExpAPIXml.kQosHierarchySrch);switch(nodeType){case ExpAPIXml.eDimRoot:case ExpAPIXml.eMember:if(_Jm){for(var x=0;x<this.oDimContextMenu.items.length;x++){var _7t=this.oDimContextMenu.items[x];if(!(_7t instanceof ContextItem)){continue;}var _zA=null;switch(_7t.id){case 'TRE_METADATA_SET_MAX_CHILD_NUM':_zA=new Array(_Ke,_Eq);_7t.SetParameterArr(_zA);if(_Eq._qE>0&&_Eq._qE<_Eq._ln&&_Eq._qE<Utilities.GetObjArrayLength(_Eq._dK)){_7t.SetEnabled(false);}else{_7t.SetEnabled(true);}break;case 'TRE_METADATA_SORT':CUIMetadataTree.SetSortParams(_Ke,_7t,_Eq,_Jm);break;case 'TRE_METADATA_VIEW_SOURCE_INFO':var _Mj=this.uiManager.dataManager.HasCapability(CDLCapability.K_sCanViewLineage);var _WP=this.uiManager.dataManager;var _aGb=_WP.GetConfigProperty(CDLConfiguration.K_sLineageURL);var _avi=_aGb?_aGb:CDLConfiguration.K_sDefaultLineageURL;if(_avi==""){_Mj=false;}_7t.SetEnabled(_Mj);CUIMetadataTree.SetBaseMemCntxMenuParameters(_Ke,_7t,_Jm,_C9,_FD);break;case 'TRE_METADATA_GLOSSARY':_7t.SetEnabled(this.IsGlossaryEnabled());CUIMetadataTree.SetBaseMemCntxMenuParameters(_Ke,_7t,_Jm,_C9,_FD,_Nv);break;default:CUIMetadataTree.SetBaseMemCntxMenuParameters(_Ke,_7t,_Jm,_C9,_FD);break;}}this.oDimContextMenu.display(e);}break;case ExpAPIXml.eDim:case ExpAPIXml.eHierarchy:case ExpAPIXml.eFolder:case ExpAPIXml.eNamespace:for(var x=0;x<this.oDimFolderContextMenu.items.length;x++){var _7t=this.oDimFolderContextMenu.items[x];if(_7t.id=='TRE_METADATA_SORT'){CUIMetadataTree.SetSortParams(_Ke,_7t,_Eq,_Jm);}else if(_7t.id=='TRE_METADATA_VIEW_SOURCE_INFO'){var _Mj=this.uiManager.dataManager.HasCapability(CDLCapability.K_sCanViewLineage);_7t.SetEnabled(_Mj);_zA=new Array(_Ke,_C9);_7t.SetParameterArr(_zA);}else if(_7t.id=='TRE_METADATA_GLOSSARY'){_7t.SetEnabled(this.IsGlossaryEnabled());CUIMetadataTree.SetBaseMemCntxMenuParameters(_Ke,_7t,_Jm,_C9,_FD,_Nv);}else{if(_7t.GetFunctionId()=='IDS_SEARCH'){_7t._ny=this._we.ReplaceParam('IDS_SEARCH',1,_Jm.GetLabel());if(!_aCF||(_Jm.ContainsOnlyNamedSets&&_Jm.ContainsOnlyNamedSets())){_7t.SetEnabled(false);}else{_7t.SetEnabled(true);}}var _zA=new Array(_Ke,_Eq);_7t.SetParameterArr(_zA);}}this.oDimFolderContextMenu.display(e);break;case ExpAPIXml.eMeasureRoot:case ExpAPIXml.eMeasureFolder:for(var x=0;x<this.oMeasureFolderContextMenu.items.length;x++){var _7t=this.oMeasureFolderContextMenu.items[x];if(_7t.id=='TRE_METADATA_SORT'){CUIMetadataTree.SetSortParams(_Ke,_7t,_Eq,_Jm);}else if(_7t.id=='TRE_METADATA_VIEW_SOURCE_INFO'){var _Mj=this.uiManager.dataManager.HasCapability(CDLCapability.K_sCanViewLineage);_7t.SetEnabled(_Mj);_zA=new Array(_Ke,_C9);}else if(_7t.id=='TRE_METADATA_GLOSSARY'){_7t.SetEnabled(this.IsGlossaryEnabled());_zA=new Array(_Ke,_Nv);}else{if(_7t.GetFunctionId()=='IDS_SEARCH'){_7t._ny=this._we.ReplaceParam('IDS_SEARCH',1,_Jm.GetLabel());}var _zA=new Array(_Ke,_Eq);}this.oMeasureFolderContextMenu.items[x].SetParameterArr(_zA);}this.oMeasureFolderContextMenu.display(e);break;case ExpAPIXml.eMeasure:case CUIMeasure.kNonAggreMeasure:var _Ga=this.oMeasureContextMenu;for(var x=0;x<_Ga.items.length;x++){var _7t=_Ga.items[x];switch(_7t.id){case 'TRE_METADATA_VIEW_SOURCE_INFO':var _Mj=this.uiManager.dataManager.HasCapability(CDLCapability.K_sCanViewLineage);_7t.SetEnabled(_Mj);break;case 'TRE_METADATA_GLOSSARY':_7t.SetEnabled(this.IsGlossaryEnabled());break;}}var _Lt=this._ob._yb[_Eq._oa];var _UD=this.uiManager._jf;if(_Lt){CUIMetadataTree.SetMeasureCntxMenuParameters(_Ke,_Ga,_Lt,_UD,_Eq,_C9,_Nv);_Ga.display(e);}break;case ExpAPIXml.eRoot:this.oPackageContextMenu.items[0]._ny=this._we.ReplaceParam('IDS_SEARCH',1,_Eq.GetLabel());if(_aCF){var _zA=new Array(_Ke,_Eq);this.oPackageContextMenu.items[0].SetParameterArr(_zA);}else{this.oPackageContextMenu.items[0].SetEnabled(false);}this.oPackageContextMenu.display(e);break;case ExpAPIXml.eNamedSetFolderObj:this.oNamedSetContextMenu.ShowContextMenu(e,_Eq,this.uiManager.dataManager.metadata._f0);break;case ExpAPIXml.eOther:for(var x=0;x<this.oOtherContextMenu.items.length;x++){var _7t=this.oOtherContextMenu.items[x];var _zA=null;switch(_7t.id){case 'TRE_METADATA_SET_MAX_CHILD_NUM':_zA=new Array(_Ke,_Eq);_7t.SetParameterArr(_zA);if(_Eq._qE>0&&_Eq._qE<_Eq._ln&&_Eq._qE<Utilities.GetObjArrayLength(_Eq._dK)){_7t.SetEnabled(false);}else{_7t.SetEnabled(true);}break;case 'TRE_METADATA_SORT':CUIMetadataTree.SetSortParams(_Ke,_7t,_Eq,_Jm);break;}}this.oOtherContextMenu.display(e);break;default:Debug.Assert(false,'unexpected objtype '+nodeType);return;break;}};CUIMetadataTree.SafeResetMaxDisplayNumber=function(_Ke,_Nx){/*@if(!@bering_debug)@*/try{/*@end@*/var _RJ=FindApp(_Ke).uiManager._qi;_RJ.ApplyMaxDisplayNum(_Nx,_Nx._v3,CUISetMaxDisplayNumDlg.kCurntItemScope);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIMetadataTree.SafeShowAll=function(_Ke,_Nx,_zN){/*@if(!@bering_debug)@*/try{/*@end@*/var _RJ=FindApp(_Ke).uiManager._qi;var _K2=false;_RJ.ApplyMaxDisplayNum(_Nx,_zN,CUISetMaxDisplayNumDlg.kCurntItemScope,_K2);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIMetadataTree.SafeSetNodeMaxDisplayNumber=function(_Ke,_Eq){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager._qi.SetNodeMaxDisplayNumber(_Eq);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIMetadataTree.prototype.SetNodeMaxDisplayNumber=function(_Eq){if(!this.oSetMaxChildNumDlg){this.oSetMaxChildNumDlg=new CUISetMaxDisplayNumDlg(_Eq);this.oSetMaxChildNumDlg.Init(this.uiManager.oDialogMgr);this.oSetMaxChildNumDlg.SetScopeOpts();}this.oSetMaxChildNumDlg.SetHostObj(_Eq);var _7f=this._ob.GetMaxExpandSize();var _Jm=this.GetNodeDataById(_Eq);this.oSetMaxChildNumDlg.SetMaxEntry(_7f);this.oSetMaxChildNumDlg.Create();this.oSetMaxChildNumDlg.Display();};CUIMetadataTree.prototype.ApplySingleNode=function(_Eq,_Td,_K2){if(_Eq._qE>0&&_Eq._qE<_Eq._ln&&_Eq._qE<Utilities.GetObjArrayLength(_Eq._dK)){return;}var _azY=parseInt(_Eq._ln);if(_azY==_Td){if(_K2){_Eq._v3=_Td;}return;}var _2F=(_Td>_azY)?true:false;_Eq._ln=_Td;if(_K2){_Eq._v3=_Td;}if(_Eq._qq){var _Jm=this.GetNodeDataById(_Eq);var _OH=this._ov[_Eq._wp];if(_Jm.GetChildArray()){var _atp=this.GetUIChildCount(_Eq,_Jm);if(_Eq._qE<_atp){var _aiF=_Eq._uS?true:false;_OH.AddChildren(_Eq,_Jm,_Eq._qE,_aiF);}}var _amB=0;for(var i in _Eq._dK){var _2H=_Eq._dK[i];var _XN=_2H._lW;if((_XN!=ExpAPIXml.eMore)&&(_XN!=ExpAPIXml.eSearch)){_amB++;var _Iv='none';if(!_2F){if(_amB>_Td){if(this.oTree.IsNodeDisplayed(_2H)){this.oTree.ToggleDisplay(_Eq,_2H,_Iv);}else{this.oTree.DeleteNode(_Eq,_2H);this._hA.RemoveTreeNode(_2H);_Eq._qE=_Td;}}}else{if((_azY<_amB)&&(_amB<=_Td)){if(this.oTree.IsNodeDisplayed(_2H)){_Iv='block';this.oTree.ToggleDisplay(_Eq,_2H,_Iv);}}}}else{this.oTree.DeleteNode(_Eq,_2H);this._hA.RemoveTreeNode(_2H);_Eq._yq=null;}}if((_amB>_Td)||(_amB<_atp)){var _aHN=this.CreateMoreNode(_Eq,_Td);if(_Eq._uS){this.oTree.DrawNode(_aHN);}this.oTree.ShowOtherNode(_Eq,'none');}else if((_amB<=_Td)&&_Jm.IsComplete&&(!_Jm.IsComplete())){if(!this.IsOtherItem(_Eq)){_Eq._ln=_atp;if(_K2){_Eq._v3=_atp;}var _akQ=this.CreateSearchNode(_Eq,_Jm);if(_Eq._uS){this.oTree.DrawNode(_akQ);}var _Xa=this.CreateOtherNode(_Eq);if(_Eq._uS){this.oTree.ShowOtherNode(_Eq,'block');}}}if(this.oTree.IsNodeDisplayed(_Eq)){this.oTree.UpdateNode(_Eq);}}};CUIMetadataTree.prototype.ApplyMaxDisplayNum=function(_Eq,_Td,_FB,_K2){if(_K2==null){var _K2=true;}if(_FB==CUISetMaxDisplayNumDlg.kCurntItemScope){this.ApplySingleNode(_Eq,_Td,_K2);return;}else if(_FB==CUISetMaxDisplayNumDlg.kAllScope){_Eq._xq=true;for(var i in this._hA._nl){var _aAt=this._hA._nl[i];var _aHc=_aAt._lW;if((_aHc!=ExpAPIXml.eMore)&&(_aHc!=ExpAPIXml.eSearch)&&(_aHc!=ExpAPIXml.eRoot)){_aAt._xq=true;this.ApplySingleNode(_aAt,_Td,_K2);}}}else if(_FB==CUISetMaxDisplayNumDlg.kInclChildScope){_Eq._xq=true;this.ApplySingleNode(_Eq,_Td,_K2);for(var i in _Eq._dK){this.ApplySingleNode(_Eq._dK[i],_Td,_K2);}}};CUIMetadataTree.prototype.GetSearchData=function(){var _V7=this.oTree.GetLastSelection();var _aCF=this._ob.IsFunctionSupported(ExpAPIXml.kQosHierarchySrch);if(_V7){var _FZ=new Object();if((_V7._lW==ExpAPIXml.eRoot||_V7._lW==ExpAPIXml.eDim||_V7._lW==ExpAPIXml.eHierarchy||_V7._lW==ExpAPIXml.eFolder||_V7._lW==ExpAPIXml.eNamespace)&&(!_aCF)){_FZ._ll=true;}else{var _6F=this.GetNodeDataById(_V7);_FZ[_6F.GetId()]=_6F;}return _FZ;}return null;};CUIMetadataTree.prototype.GetSearchType=function(){var _V7=this.oTree.GetLastSelection();if(_V7){var _6F=this.GetNodeDataById(_V7);if(_6F instanceof CDLAbsMember){return ExpAPIXml.eMember;}else if(_6F instanceof CDLMeasureDim){return ExpAPIXml.eMeasureRoot;}else if(_6F instanceof CDLDimension){return ExpAPIXml.eDim;}else{return _V7._lW;}}return null;};CUIMetadataTree.SafeDoSearchFromData=function(_Ke,oMem){/*@if(!@bering_debug)@*/try{/*@end@*/if(oMem){var _FZ=new Object();_FZ[oMem.GetId()]=oMem;}else{var _FZ=null;}FindApp(_Ke).uiManager._qi.DoSearchFromData(_FZ);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIMetadataTree.SafeDoSearchFromNode=function(_Ke,_LF){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager._qi.DoSearchFromNode(_LF);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIMetadataTree.prototype.DoSearchFromNode=function(_V7){var _aCF=this._ob.IsFunctionSupported(ExpAPIXml.kQosHierarchySrch);if(_V7){if((_V7._lW==ExpAPIXml.eRoot||_V7._lW==ExpAPIXml.eDim||_V7._lW==ExpAPIXml.eHierarchy||_V7._lW==ExpAPIXml.eFolder||_V7._lW==ExpAPIXml.eNamespace)&&(!_aCF)){this.showSearchDlg(null,null,true);return;}var _6F=this.GetNodeDataById(_V7);var _FZ=new Object();_FZ[_6F.GetId()]=_6F;this.showSearchDlg(_FZ,_V7._lW);}else{this.showSearchDlg(null,null);}};CUIMetadataTree.prototype.DoSearchFromData=function(_FZ,_z9){var _6F=null;for(var i in _FZ){_6F=_FZ[i];break;}if(!_6F){this.showSearchDlg(null,null);}if(_6F instanceof CDLAbsMember){this.showSearchDlg(_FZ,ExpAPIXml.eMember);}else if(_6F instanceof CDLMeasureDim){this.showSearchDlg(_FZ,ExpAPIXml.eMeasureRoot);}else if(_6F instanceof CDLDimension){this.showSearchDlg(_FZ,ExpAPIXml.eDim,null,_z9);}};CUIMetadataTree.prototype.showSearchDlg=function(_FZ,_zx,_Js,_z9){if(!this.oSearchDlg){this.oSearchDlg=new CUISearchDlg();this.oSearchDlg.Init(this.uiManager.oDialogMgr);this.oSearchDlg.Subscribe(this.uiManager,ExpEvent.kCUISearchDlg_StateChange);this.oSearchDlg.Subscribe(this,ExpEvent.kCUISearchDlg_StateChange);}this.oSearchDlg.SetSearchContext(_FZ);this.oSearchDlg.SetSearchType(_zx);this.oSearchDlg.Create(_z9);if(_Js){this.oSearchDlg.Display(_Js);}else{this.oSearchDlg.Display();}};CUIMetadataTree.prototype.SetLastSearchedMember=function(oMem){this._kb=oMem;};CUIMetadataTree.SafeDoShowMore=function(_Ke,_LF,oMem,_B6,_Bz){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager._qi.DoShowMore(_LF,oMem,_B6,_Bz);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIMetadataTree.prototype.DoShowMore=function(_LF,_Jm,_B6,_Bz){this.oTree.DeleteNode(_LF,this._hA.GetNode(_B6));this._hA.RemoveTreeNode(this._hA.GetNode(_B6));_LF._yq=null;var _OH=this._ov[_LF._wp];var _atp=this.GetUIChildCount(_LF,_Jm);var _UI=Math.max(_LF._qE,_LF._ln);_LF._ln+=_LF._v3;_LF._qE=_UI;var _acl=false;var _axu=false;if(_UI<_atp){var _adp=this.GetMetaObjOfUIChild(_Jm);_OH.AddChildren(_LF,_adp,_UI,true,true);_acl=true;this.oTree.UpdateNode(_LF);return;}if(_LF._ln>=_atp){_LF._ln=_atp;_axu=true;}var _amB=0;for(var i in _LF._dK){_amB++;if(_amB>(_LF._ly?_LF._ln+1:_LF._ln)){if(!_acl){var _ax4=this.CreateMoreNode(_LF,_amB);this.oTree.DrawNode(_ax4);_acl=true;}break;}if(!((_LF._dK[i]._lW==ExpAPIXml.eMore)||(_LF._dK[i]._lW==ExpAPIXml.eSearch)||(_LF._dK[i]._lW==ExpAPIXml.eOther))){if(this.oTree.IsNodeDisplayed(_LF)){this.oTree.ToggleDisplay(_LF,_LF._dK[i],'block');}}}if(_axu&&(!_Jm._v1)&&(!_acl)&&!this.IsOtherItem(_LF)){var _aDp=this.CreateSearchNode(_LF,_Jm);this.oTree.DrawNode(_aDp);this.oTree.ShowOtherNode(_LF,'block');}this.oTree.UpdateNode(_LF);};CUIMetadataTree.prototype.GetUIOtherChildCount=function(_Jm){var _atp=(_Jm._hg?_Jm._hg.length:0);return _atp;};CUIMetadataTree.prototype.GetUIChildCount=function(_LF,_Jm){var _atp=_Jm.GetChildCount();if(this.IsOtherItem(_LF)){_atp=_Jm.GetOtherChildCount();}if(_Jm instanceof CDLDimension){var _Ts=_Jm.GetSingleHierarchy();if(_Ts){if(_Jm.isHierarchyHidden(_Ts.GetId())){_atp=0;}else{_atp=(!_Ts.IsSingleRootMember())?_Ts.GetChildCount():1;}}}return _atp;};CUIMetadataTree.prototype.GetMetaObjOfUIChild=function(_Jm){var _aDP=_Jm;if(_Jm instanceof CDLDimension){var _Ts=_Jm.GetSingleHierarchy();if(_Ts&&!_Ts.IsSingleRootMember()){_aDP=_Ts;}}return _aDP;};CUIMetadataTree.prototype.GetUIPopulation=function(_Jm){var _atp=_Jm.GetPopulation();if(_Jm instanceof CDLDimension){var _Ts=_Jm.GetSingleHierarchy();if(_Ts){if(_Jm.isHierarchyHidden(_Ts.GetId())){_atp=0;}else{_atp=(!_Ts.IsSingleRootMember())?_Ts.GetPopulation():1;}}}return _atp;};CUIMetadataTree.prototype.HandleUnselect=function(){this.oTree.ClearSelections();};CUIMetadataTree.prototype.OnTreeDragStart=function(e){if(this.uiManager._jf.AllowInteraction()){var _C9=new Array();var _asK=this.oTree.GetSelectedNodes();for(var i in _asK){_C9.push(i);}var _FZ=null;var _DV=(_asK[_C9[0]]._lW==ExpAPIXml.eMeasure||_asK[_C9[0]]._lW==CUIMeasure.kNonAggreMeasure);if(_C9.length==1){if(_asK[_C9[0]]._lW==ExpAPIXml.eNamedSetFolderObj){var _V8=this._ob.GetNamedSet(_asK[_C9[0]]._sx);_FZ=new CUIDragDropNamedSet(_V8._bb,_V8.GetDimId(),_V8.GetHierId());}else{var _FD=this.uiManager._jf.GetIncludeDetailFlag()&&(!_DV);_FZ=new CUIDragDropMember(_C9[0],_FD);}}else{_FZ=new CUIDragDropMemberList(_C9,false);}var _QX=new Array();var _Bu=new Array();for(var i in _asK){_QX.push(_asK[i].GetImgByType());_Bu.push(_asK[i]._p8);}CUIDragDrop.Start(this,this.uiManager,_FZ,CUIDragDrop.eEffectNone,e);CUIDragDrop.SetTooltipItems(_QX,_Bu);CUIDragDrop.ShowTooltip(e.clientX,e.clientY);}};CUIMetadataTree.prototype.OnDragStart=function(e,id){var _aHf=this._ob.GetData(id);var _S8=_aHf.GetLevel();var _Ye=_aHf.GetRootMember()._ks;var _Lv=new CUIDragDropLevel(_Ye,_S8._ks);CUIDragDrop.Start(this,this.uiManager,_Lv,CUIDragDrop.eEffectNone,e);var oProp=this.uiManager.oLeftPaneMenu.oInfoPane.GetLastSelection();var _Bu=new Array(oProp.sValue);var _QX=new Array(oProp.sIcon);CUIDragDrop.SetTooltipItems(_QX,_Bu);CUIDragDrop.ShowTooltip(e.clientX,e.clientY);};CUIMetadataTree.prototype.OnDragEnd=function(){};CUIMetadataTree.SafeDoSort=function(_Ke,_LF,_Jm,_zx){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager._qi.DoSort(_LF,_Jm,_zx);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIMetadataTree.prototype.DoSort=function(_LF,_Jm,_zx){var _alA=new Array();var _abK=new Object();var _0y=this.IsOtherItem(_LF);var _atu=_0y?_Jm.GetOtherChildArray():_Jm.GetChildArray();_alA.length=_atu.length;if(_0y){for(var i=0;i<_atu.length;i++){var _BM=_atu[i].GetLabel();if(_abK[_BM]){var _Za=_abK[_BM];}else{var _Za=new Array();}_Za.push(i);_abK[_BM]=_Za;_alA[i]=_BM;}}else{for(var i=0;i<_atu.length;i++){var _Ir=_atu[i].GetOriginalRecordOrder();var _BM=_atu[i].GetLabel();if(_atu[i]instanceof CDLFolderObjDimension){var _aci=_atu[i].GetMetadata().GetDimById(_atu[i].GetObjPtr());if(_aci.IsSingleHierarchy()&&_aci.GetChild(0)){_BM=_aci.GetChild(0).GetLabel();}}if(_abK[_BM]){var _Za=_abK[_BM];}else{var _Za=new Array();}_Za.push(i);_abK[_BM]=_Za;_alA[_Ir]=_BM;}}switch(_zx){case CUIMetadataTree.kSortAscending:var _acY=_alA.sort();break;case CUIMetadataTree.kSortDescending:var _acY=_alA.sort(Utilities.ReverseSortCompare);break;case CUIMetadataTree.kSortRecordOrder:var _acY=_alA;break;}var _axa=new Array();for(var j=0;j<_acY.length;j++){var _BM=_acY[j];_axa[j]=_atu[_abK[_BM].pop()];}if(_0y){_Jm.SetOtherChildArray(_axa);}else{_Jm.SetChildArray(_axa);}this.SortChildNodes(_LF,_Jm);};CUIMetadataTree.prototype.IsDrawingStoppable=function(){return true;};CUIMetadataTree.prototype.createExecutionParametersTemplate=function(_Iw){var _6A=CUIMetadataTree.m_sExecutionParametersTemplate;_6A=_6A.replace("@PARAMETERVALUES@",_Iw);return _6A;};CUIMetadataTree.m_sExecutionParametersTemplate='<bus:parameters xmlns:bus="http://developer.cognos.com/schemas/bibus/3/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="SOAP-ENC:Array" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" SOAP-ENC:arrayType="bus:parameterValue[1]">'+'@PARAMETERVALUES@'+'</bus:parameters>';function CUIMissingMetadataTree(_EE,_B2){this.base=CUIMetadataTree;this.base(_EE,_B2);};CUIMissingMetadataTree.prototype=new CUIMetadataTree;CUIMissingMetadataTree.superclass=CUIMetadataTree.prototype;CUIMissingMetadataTree.prototype.Init=function(_BJ){CUIMissingMetadataTree.superclass.Init.call(this,_BJ);this.oNamedSetContextMenu=new CUIContextMenu(this.uiManager.appobj.appname,0);this.oNamedSetContextMenu.oContextMenu=this.oNamedSetContextMenu;this.oTree.SetMultiSelect(false);};CUIMissingMetadataTree.prototype.OnTreeDragStart=function(e){if(this.uiManager._jf.AllowInteraction()){var _C9=new Array();var _asK=this.oTree.GetSelectedNodes();for(var i in _asK){_C9.push(i);}var _FZ=null;var _DV=(_asK[_C9[0]]._lW==ExpAPIXml.eMeasure||_asK[_C9[0]]._lW==CUIMeasure.kNonAggreMeasure);if(_C9.length==1){if(_asK[_C9[0]]._lW==ExpAPIXml.eNamedSetFolderObj){var _V8=this._ob.GetNamedSet(_asK[_C9[0]]._sx);_FZ=new CUIDragDropNamedSet(_V8._bb,_V8.GetDimId(),_V8.GetHierId());}else{var _FD=this.uiManager._jf.GetIncludeDetailFlag()&&(!_DV);_FZ=new CUIDragDropMember(_C9[0],_FD);}}else{Debug.Assert(false);}var _QX=new Array();var _Bu=new Array();for(var i in _asK){_QX.push(_asK[i].GetImgByType());_Bu.push(_asK[i]._ks);}CUIDragDrop.Start(this,this.uiManager,_FZ,CUIDragDrop.eEffectNone,e);CUIDragDrop.SetTooltipItems(_QX,_Bu);CUIDragDrop.ShowTooltip(e.clientX,e.clientY);}};CUIMissingMetadataTree.prototype.showSearchDlg=function(_FZ,_zx,_Js){if(!this.oSearchDlg){this.oSearchDlg=new CUIMissingSearchDlg();this.oSearchDlg.Init(this.uiManager.oDialogMgr);this.oSearchDlg.Subscribe(this.uiManager,ExpEvent.kCUISearchDlg_StateChange);this.oSearchDlg.Subscribe(this,ExpEvent.kCUISearchDlg_StateChange);}this.oSearchDlg.SetSearchContext(_FZ);this.oSearchDlg.SetSearchType(_zx);this.oSearchDlg.Create();if(_Js){this.oSearchDlg.Display(_Js);}else{this.oSearchDlg.Display();}};CUIMissingMetadataTree.SetBaseMemberActionMenu=function(_Ke,_E2,_y3,_Wm){var _aCV=null;var _IS=true;var _CI=FindApp(_Ke).oResources;_BM=_CI.GetString('IDS_SEARCH');var _5L=new ContextItem('icon_search.gif',_BM,CUIMetadataTree.SafeDoSearchFromNode,false,_aCV,_E2);_5L.SetFunctionId("missingsearch");if(_y3){var _BM=_CI.GetString('TRE_METADATA_SET_MAX_CHILD_NUM');var _5L=new ContextItem('',_BM,CUIMetadataTree.SafeSetNodeMaxDisplayNumber,false,_aCV,_E2);_5L.id='TRE_METADATA_SET_MAX_CHILD_NUM';_5L.SetFunctionId("missingsetmaxchild");}var _aIC=new ContextSeparator(_E2);_BM=_CI.GetString('TRE_MISSING_REPLACE_SELECTED');var _5L=new ContextItem('',_BM,null,false,_aCV,_E2);_5L.SetFunctionId("missingreplacesel");if(_Wm){_BM=_CI.GetString('TRE_MISSING_REPLACE_SELECTED_W_LEVEL');var _5L=new ContextItem('',_BM,null,false,_aCV,_E2);_5L.SetFunctionId("missingreplacewlevel");}};CUIMissingMetadataTree.SetBaseNamedSetActionMenu=function(_Ke,_E2){var _aCV=null;var _IS=true;var _CI=FindApp(_Ke).oResources;_BM=_CI.GetString('TRE_MISSING_REPLACE_SELECTED');var _5L=new ContextItem('',_BM,null,false,_aCV,_E2);_5L.SetFunctionId("missingreplacesel");};CUIMissingMetadataTree.prototype.InitContextMenu=function(){var _aCV=null;var _IS=false;this.oDimContextMenu.items=new Array();this.oMeasureContextMenu.items=new Array();this.oMeasureFolderContextMenu.items=new Array();this.oPackageContextMenu.items=new Array();this.oDimFolderContextMenu.items=new Array();var _azv=true;var _aaj=true;CUIMissingMetadataTree.SetBaseMemberActionMenu(this.uiManager.appobj.appname,this.oDimContextMenu,_azv,_aaj);_BM=this._we.GetString('IDS_SEARCH');_PM=new ContextItem('icon_search.gif',_BM,CUIMetadataTree.SafeDoSearchFromNode,false,_aCV,this.oMeasureFolderContextMenu);_PM.SetFunctionId("missingsearch");_PM.Clone(this.oPackageContextMenu);this.oPackageContextMenu.SetChildrenComplete();_PM.Clone(this.oDimFolderContextMenu);var _BM=this._we.GetString('TRE_METADATA_SET_MAX_CHILD_NUM');var _5L=new ContextItem('',_BM,CUIMetadataTree.SafeSetNodeMaxDisplayNumber,false,_aCV,this.oMeasureFolderContextMenu);_5L.id='TRE_METADATA_SET_MAX_CHILD_NUM';_5L.SetFunctionId("missingsetmaxchild");_5L.Clone(this.oDimFolderContextMenu);_BM=this._we.GetString('TRE_METADATA_SORT');var _T8=new ContextItem('',_BM,null,false,_aCV,this.oMeasureFolderContextMenu);_T8.id='TRE_METADATA_SORT';_T8.SetFunctionId("missingsort");var _Mt=_T8.CreateSubMenu(this.uiManager.appobj.appname,this.oMeasureFolderContextMenu._dl+1);_Mt.SetChildrenComplete();_BM=this._we.GetString('TRE_METADATA_SORT_ASCEND');var _PM=new ContextItem('',_BM,CUIMetadataTree.SafeDoSort,false,_aCV,_Mt);_PM.id='TRE_METADATA_SORT_ASCEND';_BM=this._we.GetString('TRE_METADATA_SORT_DESCEND');var _PM=new ContextItem('',_BM,CUIMetadataTree.SafeDoSort,false,_aCV,_Mt);_PM.id='TRE_METADATA_SORT_DESCEND';_BM=this._we.GetString('TRE_METADATA_SORT_RECORD_ORDER');var _PM=new ContextItem('',_BM,CUIMetadataTree.SafeDoSort,false,_aCV,_Mt);_PM.id='TRE_METADATA_SORT_RECORD_ORDER';_T8.Clone(this.oDimContextMenu,2);_T8.Clone(this.oDimFolderContextMenu,2);this.oDimFolderContextMenu.SetChildrenComplete();this.oDimContextMenu.SetChildrenComplete();_aaj=false;CUIMissingMetadataTree.SetBaseMemberActionMenu(this.uiManager.appobj.appname,this.oMeasureContextMenu,_azv,_aaj);_T8.Clone(this.oMeasureContextMenu,2);this.oMeasureContextMenu.SetChildrenComplete();this.oMeasureFolderContextMenu.SetChildrenComplete();CUIMissingMetadataTree.SetBaseNamedSetActionMenu(this.uiManager.appobj.appname,this.oNamedSetContextMenu);};CUIMissingMetadataTree.prototype.ShowContextMenu=function(e,_Eq){if(!this.uiManager.dataManager._vw.IsFixable()){return;}if(_Eq){this.oLastSelNode=_Eq;}else{var _Eq=this.oLastSelNode;}if(e){this.oLastContextMenuEvent=Dom.CloneMouseEvent(e);}else{var e=this.oLastContextMenuEvent;}if(_Eq==null){return;}var _FD=this.uiManager._jf.GetIncludeDetailFlag();this._iZ=Dom.CloneMouseEvent(e);var nodeType=_Eq._lW;var _4A=_Eq._ks;var _Jm=(_Eq._lW==ExpAPIXml.eOther)?this._ob.GetDataById(_Eq._qR._ks):this._ob.GetDataById(_Eq._ks);var _C9=new Array();var _asK=this.oTree.GetSelectedNodes();for(var i in _asK){if(i!=_4A){_C9.push(i);}}var _aCF=this._ob.IsFunctionSupported(ExpAPIXml.kQosHierarchySrch);switch(nodeType){case ExpAPIXml.eDimRoot:case ExpAPIXml.eMember:if(_Jm){for(var x=0;x<this.oDimContextMenu.items.length;x++){var _7t=this.oDimContextMenu.items[x];if(!(_7t instanceof ContextItem)){continue;}var _zA=null;switch(_7t.GetFunctionId()){case 'missingsetmaxchild':_zA=new Array(this.uiManager.appobj.appname,_Eq);_7t.SetParameterArr(_zA);break;case 'missingsort':CUIMetadataTree.SetSortParams(this.uiManager.appobj.appname,_7t,_Eq,_Jm);break;default:CUIMissingMetadataTree.SetCntxMenuParameters(this.uiManager.appobj.appname,_7t,_Jm);break;}}this.oDimContextMenu.display(e);}break;case ExpAPIXml.eDim:case ExpAPIXml.eHierarchy:case ExpAPIXml.eFolder:case ExpAPIXml.eNamespace:for(var x=0;x<this.oDimFolderContextMenu.items.length;x++){var _7t=this.oDimFolderContextMenu.items[x];if(!(_7t instanceof ContextItem)){continue;}var _zA=null;switch(_7t.GetFunctionId()){case 'missingsort':CUIMetadataTree.SetSortParams(this.uiManager.appobj.appname,_7t,_Eq,_Jm);break;case 'missingsetmaxchild':_zA=new Array(this.uiManager.appobj.appname,_Eq);_7t.SetParameterArr(_zA);break;case 'missingsearch':_7t._ny=this._we.ReplaceParam('IDS_SEARCH',1,_Jm.GetLabel());_zA=new Array(this.uiManager.appobj.appname,_Eq);_7t.SetParameterArr(_zA);if(!_aCF){_7t.SetEnabled(false);}break;}}this.oDimFolderContextMenu.display(e);break;case ExpAPIXml.eMeasureRoot:case ExpAPIXml.eMeasureFolder:for(var x=0;x<this.oMeasureFolderContextMenu.items.length;x++){var _7t=this.oMeasureFolderContextMenu.items[x];if(!(_7t instanceof ContextItem)){continue;}var _zA=null;switch(_7t.GetFunctionId()){case 'missingsort':CUIMetadataTree.SetSortParams(this.uiManager.appobj.appname,_7t,_Eq,_Jm);break;case 'missingsetmaxchild':_zA=new Array(this.uiManager.appobj.appname,_Eq);_7t.SetParameterArr(_zA);break;case 'missingsearch':_7t._ny=this._we.ReplaceParam('IDS_SEARCH',1,_Jm.GetLabel());_zA=new Array(this.uiManager.appobj.appname,_Eq);_7t.SetParameterArr(_zA);break;}}this.oMeasureFolderContextMenu.display(e);break;case ExpAPIXml.eMeasure:case CUIMeasure.kNonAggreMeasure:var _Ga=this.oMeasureContextMenu;var _Lt=this._ob._yb[_Eq._oa];var _UD=this.uiManager._jf;if(_Lt){for(var x=0;x<_Ga.items.length;x++){var _7t=_Ga.items[x];if(!(_7t instanceof ContextItem)){continue;}var _zA=null;switch(_7t.GetFunctionId()){case 'missingsetmaxchild':_zA=new Array(this.uiManager.appobj.appname,_Eq);_7t.SetParameterArr(_zA);break;case 'missingsort':CUIMetadataTree.SetSortParams(this.uiManager.appobj.appname,_7t,_Eq,_Jm);break;default:CUIMissingMetadataTree.SetCntxMenuParameters(this.uiManager.appobj.appname,_7t,_Jm);break;}}_Ga.display(e);}break;case ExpAPIXml.eRoot:this.oPackageContextMenu.items[0]._ny=this._we.ReplaceParam('IDS_SEARCH',1,_Eq.GetLabel());if(_aCF){var _zA=new Array(this.uiManager.appobj.appname,_Eq);this.oPackageContextMenu.items[0].SetParameterArr(_zA);}else{this.oPackageContextMenu.items[0].SetEnabled(false);}this.oPackageContextMenu.display(e);break;case ExpAPIXml.eNamedSetFolderObj:_Jm=this._ob.GetNamedSet(_Eq._sx);for(var i=0;i<this.oNamedSetContextMenu.items.length;i++){var _7t=this.oNamedSetContextMenu.items[i];var _amV=_7t instanceof ContextItem;if(_amV){CUIMissingMetadataTree.SetCntxMenuParameters(this.uiManager.appobj.appname,_7t,_Jm);}}this.oNamedSetContextMenu.display(e);break;default:Debug.Assert(false,'unexpected objtype '+nodeType);return false;break;}};CUIMissingMetadataTree.SetCntxMenuParameters=function(_Ke,_PM,_Jm){var _CI=FindApp(_Ke).oResources;var _M0=FindApp(_Ke);var _zA=new Array(_Ke);if(!(_PM instanceof ContextItem)){return;}var _as8=_M0.uiManager.oMissingMunsPane;var _app=_as8.GetLastSelectedMissingItem();switch(_PM.GetFunctionId()){case "missingsearch":_zA=new Array(_Ke,_Jm);_PM._ny=_CI.ReplaceParam('IDS_SEARCH',1,_Jm.GetLabel());_PM.SetItemAction(CUIMetadataTree.SafeDoSearchFromData);break;case "missingreplacesel":var _aHW=CUIMissingMetadataTree.CreateDropData(_Ke,_Jm.GetId());var _Yo=_as8.IsValidDropTarget(_app,_aHW);if(_Yo){_PM.SetEnabled(true);_zA=new Array(_Ke,_aHW);}else{_PM.SetEnabled(false);}_PM.SetItemAction(CUIMissingMunsPane.SafeReplaceLastSelection);break;case "missingreplacewlevel":if(_Jm.GetLevel&&_Jm.GetLevel()!=null){var _S8=_Jm.GetLevel();_PM._ny=_CI.ReplaceParam('TRE_MISSING_REPLACE_SELECTED_W_LEVEL',1,_S8.GetLabel());_PM.SetDisplayFlag(true);var _aHW=CUIMissingMetadataTree.CreateDropData(_Ke,_S8.GetId());var _Yo=_as8.IsValidDropTarget(_app,_aHW);if(_Yo){_PM.SetEnabled(true);_zA=new Array(_Ke,_aHW);}else{_PM.SetEnabled(false);}_PM.SetItemAction(CUIMissingMunsPane.SafeReplaceLastSelection);}else{_PM.SetDisplayFlag(false);}break;}if(_PM.SetParameterArr){_PM.SetParameterArr(_zA);}};CUIMissingMetadataTree.prototype.OnPropertyContextMenu=function(e,_Lx){if(!this.oPropContextMenu){this.oPropContextMenu=new CUIContextMenu(this.uiManager.appobj.appname,0);_BM=this._we.GetString('TRE_MISSING_REPLACE_SELECTED');var _5L=new ContextItem('',_BM,null,false,null,this.oPropContextMenu);_5L.SetFunctionId("missingreplacesel");}if(this._ob.GetData(_Lx)){var oMem=this._ob.GetData(_Lx);var _Z1=oMem.GetLevel();CUIMissingMetadataTree.SetCntxMenuParameters(this.uiManager.appobj.appname,this.oPropContextMenu.items[0],_Z1);}else if(this._ob.GetPropertyById(_Lx)){var oProp=this._ob.GetPropertyById(_Lx);CUIMissingMetadataTree.SetCntxMenuParameters(this.uiManager.appobj.appname,this.oPropContextMenu.items[0],oProp);}this.oPropContextMenu.display(e);};CUIMissingMetadataTree.prototype.CreateDimNode=function(_Eq,_EZ,_Iu){var _HB=new COTTreeNode(ExpAPIXml.eDim,_EZ._ks,_EZ._p8,_EZ._ks,_Eq,null,_EZ._ks);_HB._j4=false;_HB._qq=_EZ._v1;_HB._s5=true;_HB._wp=_Iu;return _HB;};CUIMissingMetadataTree.prototype.CreateRootMemberNode=function(_Eq,_UY,_Iu){var _Ic=_UY._rM?_UY._rM:_UY._p8;var _HB=new COTTreeNode(ExpAPIXml.eDimRoot,_UY._ks,_Ic,_UY._ks,_Eq,null,_UY._ks);_HB._s5=(_UY._v1&&(_UY.GetChildCount()==0))?false:true;_HB._qq=_UY._v1||_UY._ge;_HB._wp=_Iu;return _HB;};CUIMissingMetadataTree.prototype.CreateMemberNode=function(_Eq,_UY,_Iu){var _HB=new COTTreeNode(ExpAPIXml.eMember,_UY._ks,_UY._p8,_UY._ks,_Eq,null,_UY._ks);_HB._s5=(_UY._v1&&(_UY.GetChildCount()==0))?false:true;_HB._qq=_UY._v1||_UY._ge;_HB._wp=_Iu;return _HB;};CUIMissingMetadataTree.prototype.CreateHierNode=function(_Eq,_Ts,_Iu){var _HB=new COTTreeNode(ExpAPIXml.eHierarchy,_Ts._ks,_Ts._p8,_Ts._ks,_Eq,null,_Ts._ks);_HB._s5=(_Ts._v1&&(_Ts.GetChildCount()==0))?false:true;_HB._qq=_Ts._v1;_HB._j4=false;_HB._wp=_Iu;return _HB;};CUIMissingMetadataTree.prototype.CreateMeasureRootNode=function(_Eq,_Ff,_Iu){var _HB=new COTTreeNode(ExpAPIXml.eMeasureRoot,_Ff._ks,_Ff._p8,_Ff._ks,_Eq,null,_Ff._ks);_HB._s5=(_Ff._v1&&(_Ff.GetChildCount()==0))?false:true;_HB._qq=_Ff._v1;_HB._j4=false;_HB._wp=_Iu;return _HB;};CUIMissingMetadataTree.prototype.CreateFolderNode=function(_Eq,_Bi,_Iu){var _HB=new COTTreeNode(ExpAPIXml.eFolder,_Bi._ks,_Bi._p8,_Bi._ks,_Eq,null,_Bi._ks);_HB._s5=(_Bi._v1&&(_Bi.GetChildCount()==0))?false:true;_HB._qq=_Bi._v1;_HB._j4=false;_HB._wp=_Iu;return _HB;};CUIMissingMetadataTree.prototype.CreateMeasureFolderNode=function(_Eq,_Bi,_Iu){var _HB=new COTTreeNode(ExpAPIXml.eMeasureFolder,_Bi._ks,_Bi._p8,_Bi._ks,_Eq,null,_Bi._ks);_HB._s5=(_Bi._v1&&(_Bi.GetChildCount()==0))?false:true;_HB._qq=_Bi._v1;_HB._j4=false;_HB._wp=_Iu;return _HB;};CUIMissingMetadataTree.prototype.CreateMeasureNode=function(_Eq,_SE,_Iu){var _apM=_SE.IsAggregateable()?ExpAPIXml.eMeasure:CUIMeasure.kNonAggreMeasure;var _HB=new COTTreeNode(_apM,_SE._ks,_SE._p8,_SE._ks,_Eq,null,_SE._ks);_HB._s5=(_SE._v1&&(_SE.GetChildCount()==0))?false:true;_HB._qq=_SE._v1||_SE._ge;_HB._j4=true;_HB._wp=_Iu;return _HB;};CUIMissingMetadataTree.prototype.GetPropertyList=function(_OI){var _V7=this.oTree.GetLastSelection();var _JP=new Array();Debug.Assert(_V7);if(!_V7){return _JP;}this.PopulateNameAndTypeInfo(_V7,_JP);var oMem=this._ob.GetMember(_V7._ks);if(oMem){var _Z1=oMem.GetLevel();if(_Z1){var _aBP='level_black_sea.gif';var oProp=new COTDraggablePair('IDS_SELECTION_LEVEL',_Z1._p8,_aBP,_V7._ks,null,_Z1.GetId());oProp.bSupportsContextMenu=true;_JP.push(oProp);}var _ET=(_Z1!=null?_Z1:oMem.GetHierarchy());if(_ET){if(!_ET._lG){_JP.push(new COTLoadingPair(this._we.GetString('IDS_FETCHING_ATTRIBUTES'),this._we.GetString('IDS_CONTEXTBAR_LOADING'),"icon_loading.gif"));this.FetchPropertyMetadata(_ET,_JP);}else{for(var i in _ET._lG){var _aIT=_ET.GetProperty(i)._p8;var _awZ=_ET.GetProperty(i).GetId();if(_aIT&&_aIT!=""){var oProp=new COTDraggablePair('IDS_MISSING_INFO_PANE_PROPERTY',_aIT,"attribute.gif",_awZ,null,_awZ);oProp.bSupportsContextMenu=true;_JP.push(oProp);}}}}}else{var _NS=this._ob.GetMeasure(_V7._ks);if(_NS){var _ag5=this._we.GetString('IDS_MEASURE_AGGREGATION_NONE');if(_NS.IsAggregateable()){var _at7=this._ob.GetMeasure(_V7._ks).GetRegAggregateType();_ag5=this.GetAggregateLabel(_at7);}_JP.push(new COTPropertyPair(this._we.GetString('IDS_MEASURE_AGGREGATION'),_ag5));}else if(_V7._lW==ExpAPIXml.eRoot){this.GetDataSourceProperty(_OI,_JP);}else if(_V7._lW==ExpAPIXml.eNamedSet||_V7._lW==ExpAPIXml.eNamedSetFolderObj){this.PopulateNamedSetInfo(_V7,_JP);}}return _JP;};CUIMissingMetadataTree.prototype.OnDragStart=function(e,id){if(this._ob.GetData(id)){var _aHf=this._ob.GetData(id);var _S8=_aHf.GetLevel();var _Lv=new CUIDragDropLevelOnly(_S8._ks);CUIDragDrop.Start(this,this.uiManager,_Lv,CUIDragDrop.eEffectNone,e);var oProp=this.uiManager.oLeftPaneMenu.oInfoPane.GetLastSelection();var _Bu=new Array(_S8._ks);var _QX=new Array(oProp.sIcon);CUIDragDrop.SetTooltipItems(_QX,_Bu);CUIDragDrop.ShowTooltip(e.clientX,e.clientY);}else if(this._ob.GetPropertyById(id)){var _Lv=new CUIDragDropProperty(id);CUIDragDrop.Start(this,this.uiManager,_Lv,CUIDragDrop.eEffectNone,e);var oProp=this.uiManager.oLeftPaneMenu.oInfoPane.GetLastSelection();var _Bu=new Array(id);var _QX=new Array(oProp.sIcon);CUIDragDrop.SetTooltipItems(_QX,_Bu);CUIDragDrop.ShowTooltip(e.clientX,e.clientY);}};CUIMissingMetadataTree.CreateDropData=function(_Ke,_Lx){var _M0=FindApp(_Ke);var _AT=_M0.dataManager;var _Lv=null;if(_AT.metadata.GetLevel(_Lx)){_Lv=new CUIDragDropLevelOnly(_Lx);}else if(_Lx){if(_AT.metadata.GetNamedSet(_Lx)){var _V8=_AT.metadata.GetNamedSet(_Lx);_Lv=new CUIDragDropNamedSet(_Lx,_V8.GetDimId(),_V8.GetHierId());}else if(_AT.metadata.GetPropertyById(_Lx)){_Lv=new CUIDragDropProperty(_Lx);}else{_Lv=new CUIDragDropMember(_Lx);}}return _Lv;};CUIMissingMetadataTree.prototype.UnLoad=function(){this.uiManager._jf.UnSubscribe(this,ExpEvent.kCUIWorksheet_Free);this.uiManager._jf.UnSubscribe(this,ExpEvent.kCUIWorksheet_Busy);this.uiManager.UnSubscribe(this,ExpEvent.kCUIManager_Unload);this.uiManager.UnSubscribe(this,ExpEvent.kCUIManager_OnSelChange);this._ob.UnSubscribe(this,ExpEvent.kCDLMetadata_Replace);this.uiManager.dataManager.UnSubscribe(this,ExpEvent.kCDLDataManager_UpdateTree);CUIMissingMetadataTree.superclass.UnLoad.call(this);};function CUIAbsMetadataItem(_Jw,_Bi,_B2,_M6){this._qi=_B2;this._ue=_M6;this._xA=_Jw;this._fP=_Bi;this._qu=CUIDimension.eStateInit;};CUIAbsMetadataItem.prototype.AddMemberChildren=function(_Eq,_UY,_Bc){if(_UY){this.AddChildren(_Eq,_UY,null,_Bc);}else{this.AddChildren(_Eq,this._lB);}};CUIAbsMetadataItem.prototype.AddChildren=function(_Eq,_zM,_UI,_Bc,_Sl,_S3){var _akM=false;var _Oi=0;if(!_Eq&&_S3){_akM=true;var _anI=this._qi.GetNodeLogState(_S3);Debug.Assert(_anI);_Eq=_anI._jO;_zM=_anI._tI;_UI=_anI._lc;_Bc=_anI._tz;_Cl=_anI._kf;_Oi=_anI._vS;}Debug.Assert(_Eq);if(_Eq._yq&&_Eq._dK[_Eq._yq]){this._qi.oTree.DeleteNode(_Eq,_Eq._dK[_Eq._yq]);this._qi._hA.RemoveTreeNode(_Eq._dK[_Eq._yq]);_Eq._yq=null;}var _aJg=(this._qi.IsOtherItem(_Eq))?_zM.GetOtherChildCount():_zM.GetChildCount();if(_aJg>0){var _ar4=(_aJg<_Eq._ln)?_aJg:_Eq._ln;if(!_akM){var _aB2=0;if(_UI!=null){_aB2=_UI;}if(_aJg>_Eq._ln){var _ajL=_Eq._v3*Math.ceil(_ar4/_Eq._v3)-_ar4;if(_ajL>0){_ar4=Math.min(_ar4+_ajL,_aJg);_Eq._ln+=_ajL;}}var _aqB=(this._qi.IsOtherItem(_Eq))?_zM.GetOtherChildArray():_zM.GetChildArray();var _Cl=new Array();for(var i=_aB2;i<_ar4;i++){var _aHI=_aqB[i];var _ay6;if(!(_aHI._ks in _Eq._dK)){if(this._qi.IsOtherItem(_Eq)){this._qi.UpdatePrevSibling(_Eq,_zM);_ay6=this._qi.CreateOtherMemberNode(_Eq,_aHI);}else{_ay6=this.AddChildNode(_Eq,_aHI);}if(_Bc){_Cl.push(_ay6);_ay6._pV=true;}}else{_ay6=_Eq._dK[_aHI._ks];if(_Bc){if(_ay6._mO==CUITreeView.invalidHtmlId){_Cl.push(_ay6);_ay6._pV=true;}else{_Cl.push(_ay6);_ay6._pV=false;}}}}}if(_Bc){if((!_Sl&&!_akM)||_Cl.length<CUITreeView.TreeMaxAccLength){for(var n=0;n<_Cl.length;n++){var _1i=_Cl[n];if(_1i._pV){this._qi.oTree.DrawNode(_1i);if(n==_Cl.length-1){_aFh=_1i;}}else{if(this._qi.oTree.IsNodeDisplayed(_Eq)){this._qi.oTree.ToggleDisplay(_Eq,_1i,'block');}}_1i._pV=null;}}else{this._qi.LogChildrenState(this,_Eq,_zM,_UI,_Bc,_Cl,_Oi);this.DrawTmpNodes(_Eq);if(this._qi.GetNodeLogState(_Eq._ks)&&(!this._qi.GetNodeFinishState(_Eq._ks))){return;}this._qi.ClearNodeLogState(_Eq._ks);var _aFh=null;var _aiI=_Cl[_Cl.length-1];if(_aiI&&_aiI._pV){_aFh=_aiI;}}}if(_ar4<_Eq._ln&&_Bc){_Eq._ln=_ar4;}_Eq._qE=_Eq._ln;_Eq._qq=_zM._v1||_zM._ge||this._qi.IsOtherItem(_Eq);_Eq._k4=_zM._v1;if(_aJg>_Eq._ln){var _aHN=this._qi.CreateMoreNode(_Eq,_Eq._ln);if(_Bc){if(_aFh){_aFh._oW=true;this._qi.oTree.UpdateNode(_aFh);}this._qi.oTree.DrawNode(_aHN);}}else if(!_zM._v1&&!(this._qi.IsOtherItem(_Eq))){var _5M=this._qi.CreateSearchNode(_Eq,_zM);if(_Bc){if(_aFh){_aFh._oW=true;this._qi.oTree.UpdateNode(_aFh);}this._qi.oTree.DrawNode(_5M);}var _Xa=this._qi.CreateOtherNode(_Eq);if(_Bc){this._qi.oTree.ShowOtherNode(_Eq,'block');}}if(this._qi.IsOtherItem(_Eq)){if(!_Eq._s5){_Eq._s5=true;}if(this._qi.oTree.IsNodeDisplayed(_Eq)){this._qi.oTree.UpdateNode(_Eq);}}}else{_Eq._qq=_zM._v1||this._qi.IsOtherItem(_Eq);if(_Eq._qq){_Eq._s5=false;_Eq._ln=0;}if(_Bc){this._qi.oTree.UpdateNode(_Eq);}}};CUIAbsMetadataItem.prototype.DrawTmpNodes=function(_Eq){var _anI=this._qi.GetNodeLogState(_Eq._ks);Debug.Assert(_anI);_GG=_anI._wE;_zM=_anI._tI;_UI=_anI._lc;_Bc=_anI._tz;tmpNodeArr=_anI._kf;_Oi=_anI._vS;var _5G=0;for(var i=0;i<tmpNodeArr.length;i++){if(i<_Oi){continue;}var _1i=tmpNodeArr[i];if(_1i._pV){this._qi.oTree.DrawNode(_1i);}else{if(this._qi.oTree.IsNodeDisplayed(_Eq)){this._qi.oTree.ToggleDisplay(_Eq,_1i,'block');}}_1i._pV=null;_Oi++;_5G++;if(_5G>=CUITreeView.TreeStepLength)break;}this._qi.oTree.SyncScroller();this._qi.LogChildrenState(_GG,_Eq,_zM,_UI,_Bc,tmpNodeArr,_Oi);this._qi.oTree.UpdateAdditionalNode(_Eq,_Eq._qE+_5G);this._qi.oTree.UpdateAdditionalCtrlNode(_Eq,_Eq._qE+_5G,true);if(_Oi<(tmpNodeArr.length-1)){_Eq._qE+=_5G;if(this._qi.oTree.GetNodeLogState(_Eq._ks)&&(!(this._qi.oTree.GetNodeStoppingState(_Eq._ks)))){var _6z=Utilities.GenerateCallback(this.SyncAddChildren,[_Eq._ks],this);setTimeout(_6z,this._qi.oTree.GetIntervalLength(_Oi));}}else{_Eq._qE=_Eq._ln;this._qi.oTree.ClearNodeLogState(_Eq._ks);this._qi.SetNodeFinishState(_Eq._ks,true);}};CUIAbsMetadataItem.prototype.CanDisplay=function(_Eq){var _UY=this._qi._ob.GetDataById(_Eq._ks);if(_UY){if(_UY._v1){this._lB=_UY;this._fv=_Eq;_Eq._x8._ee=COTLoadingAgent.CompleteChildren;return true;}var _aIB=(this._qi._ob._cC<CUITreeView.TreeStepLength)?this._qi._ob._cC:CUITreeView.TreeStepLength;if(_UY.GetChildCount()>=_aIB){this._lB=_UY;this._fv=_Eq;_Eq._x8._ee=COTLoadingAgent.IncompleteChildren;return true;}}return false;};CUIAbsMetadataItem.prototype.GetMemberState=function(_Eq){var _UY=this._qi._ob.GetDataById(_Eq._ks);return _UY._qu;};CUIAbsMetadataItem.prototype.FetchChildren=function(_Eq){if(this.CanDisplay(_Eq)){this.AddMemberChildren(_Eq);if(_Eq._x8){this._qu=CUIDimension.eStateLoaded;_Eq._x8._gc=true;_Eq._x8.EndAsyncLoad();}}else{if(this.GetMemberState(_Eq)==CDLAbsMember.eStateFailedResponse){if(_Eq._x8){this._qu=CUIDimension.eStateCantLoad;_Eq._x8._gc=false;_Eq._x8.EndAsyncLoad();}}else if(!_Eq.bCancelled){var _8c=_Eq._pg*100;if(_Eq._pg<20){_Eq._pg++;var _6z=Utilities.GenerateCallback(this.FetchChildren,[_Eq],this);setTimeout(_6z,_8c);}else{_Eq._pg++;if(_Eq._x8&&(!_Eq._de)){_Eq._de=true;_Eq._x8.SetLoadingCancelable();}var _6z=Utilities.GenerateCallback(this.FetchChildren,[_Eq],this);setTimeout(_6z,_8c);}}}};CUIMetadataTree.prototype.SyncAddChildren=function(_S3){var _anI=this.GetNodeLogState(_S3);if(_anI){var _Ke=this.uiManager.appobj.appname;var _GG=_anI._wE;if(_GG){_GG.AddChildren(null,null,0,false,false,_S3);}}};CUIMetadataTree.prototype.LogChildrenState=function(_GG,_Eq,_zM,_UI,_Bc,_Cl,_Oi){this.oTree.LogChildrenState(_Oi,_Eq);if(!(this._hQ[_Eq._ks])){this._hQ[_Eq._ks]=new CUIAddChildrenState(_GG,_Eq,_zM,_UI,_Bc,_Cl,_Oi);}else{this._hQ[_Eq._ks]._vS=_Oi;this._hQ[_Eq._ks]._lc=_UI;this._hQ[_Eq._ks]._kf=_Cl;}};CUIMetadataTree.prototype.GetNodeLogState=function(_RD){return this._hQ[_RD];};CUIMetadataTree.prototype.ClearNodeLogState=function(_RD){this.oTree.ClearNodeLogState(_RD);Utilities.RemoveObjXObjectArray(this._hQ,_RD);};CUIMetadataTree.prototype.GetNodeFinishState=function(_RD){if(!this._hQ[_RD]){return true;}else{return this._hQ[_RD]._n7;}};CUIMetadataTree.prototype.SetNodeFinishState=function(_RD,_DO){if(!this._hQ[_RD]){return;}else this._hQ[_RD]._n7=_DO;};function CUIAddChildrenState(_GG,_Eq,_zM,_UI,_Bc,_Cl,_Oi){this._wE=_GG;this._jO=_Eq;this._tI=_zM;this._tz=_Bc;this._kf=_Cl;this._lc=_UI;this._vS=_Oi;this._n7=false;};function CUIAbsDimension(_NR,_M8,_B2,_HV){this.base=CUIAbsMetadataItem;this.base(_NR,_M8,_B2,_HV);};CUIAbsDimension.prototype=new CUIAbsMetadataItem;CUIAbsDimension.superclass=CUIAbsMetadataItem.prototype;CUIDimension.eStateInit=0;CUIDimension.eStateLoaded=1;CUIDimension.eStateLoading=2;CUIDimension.eStateCantLoad=3;function CUIDimension(_NR,_B2,_HV){this.base=CUIAbsDimension;this.base(_NR,null,_B2,_HV);};CUIDimension.prototype=new CUIAbsDimension;CUIDimension.superclass=CUIAbsDimension.prototype;CUIDimension.prototype.AddChildNode=function(_Eq,_Jm){var _ay6=null;if(_Jm instanceof CDLFolder){var _Iu=this._qi.AddUIItem(_Jm);if(_Jm.IsNamespaceFolder()){_ay6=this._qi.AddNamespaceNodeVO(_Eq,this._qi._ov[_Iu]);}else{_ay6=this._qi.AddFolderNodeVO(_Eq,this._qi._ov[_Iu]);}}else if(_Jm instanceof CDLMember){var _UY=_Jm;_ay6=this._qi.CreateMemberNode(_Eq,_UY,this._ue);this._qi._hA.AddTreeNode(_ay6);}else if(_Jm instanceof CDLHierarchy){var _Ts=_Jm;if(!_Ts._rj.isHierarchyHidden(_Ts._ks)){_ay6=this._qi.HandleHierarchyNode(_Ts,this,_Eq);}}else if(_Jm instanceof CDLDimension){var _Iu=this._qi.AddUIItem(_Jm);_ay6=this._qi.AddDimensionNodeVO(_Eq,this._qi._ov[_Iu]);}else if(_Jm instanceof CDLFolderObjHierarchy){var _Ts=this._qi._ob.GetHierarchyById(_Jm._cH);_ay6=this._qi.HandleHierarchyNode(_Ts,this,_Eq);}return _ay6;};CUIDimension.prototype.AddRootMemberChildren=function(_Eq,oMem){var _aJm=this.AddChildNode(_Eq,oMem);_aJm._s5=true;this.AddMemberChildren(_aJm,oMem);};CUIDimension.prototype.Display=function(){};function CUIMeasureDim(_Gp,_PY,_B2,_PQ){this.base=CUIAbsDimension;this.base(_Gp,_PY,_B2,_PQ);this._xA._fP=_PY;this._qi=_B2;};CUIMeasureDim.prototype=new CUIAbsDimension;CUIMeasureDim.superclass=CUIAbsDimension.prototype;CUIMeasureDim.prototype.AddChildNode=function(_Eq,_U0){var _ay6=null;var _Iu=this._qi.AddUIItem(_U0);if(_U0 instanceof CDLMeasureFolder){_ay6=this._qi.AddMeasureFolderNodeVO(_Eq,this._qi._ov[_Iu]);}else if(_U0 instanceof CDLFolderObjMeasure){_ay6=this._qi.AddMeasureNodeVO(_Eq,this._qi._ov[_Iu]);}else if(_U0 instanceof CDLMeasure){_ay6=this._qi.AddMeasureNodeVO(_Eq,this._qi._ov[_Iu]);}else{Debug.Assert(false);}return _ay6;};function CUIFolder(_UV,_B2,_PQ){this.base=CUIAbsMetadataItem;this.base(null,_UV,_B2,_PQ);};CUIFolder.prototype=new CUIAbsMetadataItem;CUIFolder.superclass=CUIAbsMetadataItem.prototype;CUIFolder.prototype.AddChildNode=function(_Eq,_U0){var _ay6=null;var _Iu;if(_U0 instanceof CDLFolder){_Iu=this._qi.AddUIItem(_U0);if(_U0.IsNamespaceFolder()){_ay6=this._qi.AddNamespaceNodeVO(_Eq,this._qi._ov[_Iu]);}else{_ay6=this._qi.AddFolderNodeVO(_Eq,this._qi._ov[_Iu]);}}else if(_U0 instanceof CDLFolderObjDimension){_Iu=this._qi.AddUIItem(_U0);_ay6=this._qi.AddDimensionNodeVO(_Eq,this._qi._ov[_Iu]);}else if(_U0 instanceof CDLFolderObjMeasureDim){_Iu=this._qi.AddUIItem(_U0);_ay6=this._qi.AddMeasureDimNodeVO(_Eq,this._qi._ov[_Iu]);}else if(_U0 instanceof CDLFolderObjHierarchy){var _Ts=this._qi._ob.GetHierarchyById(_U0._cH);_ay6=this._qi.HandleHierarchyNode(_Ts,this,_Eq);}else if(_U0 instanceof CDLMember){_ay6=this._qi.CreateMemberNode(_Eq,_U0,this._ue);this._qi._hA.AddTreeNode(_ay6);}else if(_U0 instanceof CDLFolderObjNamedSet){_Iu=this._qi.AddUIItem(_U0);_ay6=this._qi.CreateNamedSetNode(_Eq,_U0,_Iu);this._qi._hA.AddTreeNode(_ay6);}else{Debug.Assert(false);}return _ay6;};CUIFolder.prototype.IsNamespaceFolder=function(){return this._fP.IsNamespaceFolder();};function CUIMeasureFolder(_yw,_B2,_PQ){this.base=CUIAbsMetadataItem;this.base(null,_yw,_B2,_PQ);};CUIMeasureFolder.prototype=new CUIAbsMetadataItem;CUIMeasureFolder.superclass=CUIAbsMetadataItem.prototype;CUIMeasureFolder.prototype.AddChildNode=function(_Eq,_U0){var _ay6=null;var _Iu=this._qi.AddUIItem(_U0);if(_U0 instanceof CDLMeasureFolder){_ay6=this._qi.AddMeasureFolderNodeVO(_Eq,this._qi._ov[_Iu]);}else if(_U0 instanceof CDLFolderObjMeasure){_ay6=this._qi.AddMeasureNodeVO(_Eq,this._qi._ov[_Iu]);}else{Debug.Assert(false);}return _ay6;};CUIMeasure.kNonAggreMeasure='non-aggregate';function CUIMeasure(_SE,_B2,_PQ){this.base=CUIAbsMetadataItem;this.base(_SE,null,_B2,_PQ);};CUIMeasure.prototype=new CUIAbsMetadataItem;CUIMeasure.superclass=CUIAbsMetadataItem.prototype;CUIMeasure.prototype.AddChildNode=function(_Eq,_U0){var _ay6=null;if(_U0 instanceof CDLMeasure){var _Iu=this._qi.AddUIItem(_U0);_ay6=this._qi.AddMeasureNodeVO(_Eq,this._qi._ov[_Iu]);}return _ay6;};function CUIAnalysisItemTree(_EE,_B2,_HF){this.uiManager=_EE;this._ob=_B2;this._m9=_HF;this._ey=null;this._f0=null;};CUIAnalysisItemTree.prototype.Init=function(_EP){this._we=this.uiManager.appobj.oResources;this._st=document.createElement('DIV');this._st.id="analysisItem_"+Utilities.GenerateId();_EP.appendChild(this._st);this._st.className="analysis_item";this.oTree=new CUITreeView(this.uiManager);this.oCustomSetContextMenu=new CUIContextMenu(this.uiManager.appobj.appname,0);this.oNamedSetContextMenu=new CUIContextMenu(this.uiManager.appobj.appname,0);this.createCustomSetArray();this.createNamedSetArray();};CUIAnalysisItemTree.prototype.GetDIV=function(){return this._st;};CUIAnalysisItemTree.prototype.GetSearchData=function(){var _V7=this.oTree.GetLastSelection();if(!_V7){return null;}if(_V7._lW==ExpAPIXml.eCustomSet){return this._m9.GetCustomSet(_V7._ks).getBlock().GetSearchData();}else if(_V7._lW==ExpAPIXml.eNamedSet){return null;}};CUIAnalysisItemTree.prototype.SetAssoTabId=function(_If){this._rv=_If;};CUIAnalysisItemTree.prototype.GetAssoTabId=function(){return this._rv;};CUIAnalysisItemTree.prototype.InitSubscriptions=function(){this.uiManager.Subscribe(this,ExpEvent.kCUIManager_Unload);this.uiManager.Subscribe(this,ExpEvent.kCUIManager_OnSelChange);this._m9.Subscribe(this,ExpEvent.kCDLAnalysis_Replace);this._m9._he._ez=new Object();this._m9._he._o5=new CDLTreeCMFolder(this._m9._he,null,null,true);this._m9._he._o5._jj='cmrootintree';this._m9.Subscribe(this,ExpEvent.kCDLAnalysis_FailedResponse);this._m9._he.GetCurrentWorkSheet().Subscribe(this,ExpEvent.kCDLWorksheet_AwaitingResponse);this._m9._he.GetCurrentWorkSheet().Subscribe(this,ExpEvent.kCDLWorksheet_EndProcessing);this._m9._he.GetCurrentWorkSheet().Subscribe(this,ExpEvent.kCDLWorksheet_FailedResponse);this._m9._he.Subscribe(this,ExpEvent.kCDLDataManager_AnalysisCreate);};CUIAnalysisItemTree.prototype.HandleUnselect=function(){this.oTree.ClearSelections();};CUIAnalysisItemTree.prototype.Hide=function(){this._st.style.display='none';};CUIAnalysisItemTree.prototype.Show=function(){this._st.style.display='block';this.uiManager.OnSelChange(this);};CUIAnalysisItemTree.prototype.GetBottom=function(){var _T6=COTStyle.GetDisplayOffsetHeight(this._st);return _T6;};CUIAnalysisItemTree.prototype.SetHeight=function(_T6){COTStyle.SetHeight(this._st,_T6-COTStyle.GetVerticalExtrasHeight(this._st));};CUIAnalysisItemTree.prototype.SetTop=function(_TM){this._st.style.top=_TM+"px";};CUIAnalysisItemTree.prototype.SetWidth=function(_F4){COTStyle.SetWidth(this._st,_F4-COTStyle.GetHorizontalExtrasWidth(this._st));};CUIAnalysisItemTree.prototype.createCustomSetArray=function(){this._ey=new Object();for(var i in this._m9._ey){this._ey[i]=new CUICustomSet(this._m9._ey[i]);}};CUIAnalysisItemTree.prototype.CustomSetNameExists=function(_Qv){for(var i in this._ey){var _ajW=this._ey[i]._ia;if(_Qv==_ajW._p8){return true;}}return false;};CUIAnalysisItemTree.prototype.createNamedSetArray=function(){this._f0=new Object();for(var i in this._ob._f0){if(!this._ob._am[i]){this._f0[i]=new CUINamedSet(this._ob._f0[i],this);}}};CUIAnalysisItemTree.prototype.updateCustomSetArray=function(){var _ajr=new Array();for(var i in this._ey){if(!this._m9._ey[i]){_ajr.push(i);}}Utilities.ClearObjectArray(this._ey);for(var i in this._m9._ey){this._ey[i]=new CUICustomSet(this._m9._ey[i]);}return _ajr;};CUIAnalysisItemTree.prototype.SetUpAnalysisTree=function(){this._qy=document.createElement('div');this._qy.className="tree_div";this._st.appendChild(this._qy);COTStyle.SetHeight(this._qy,100,'%');this._hA=new COTTreeVO(this);this.oTree.SetTreeVO(this._hA);this.InitTreeVO();this.oTree.SetDiv(this._qy);this.oTree.DrawTree();this.InitContextMenu();};CUIAnalysisItemTree.prototype.InitTreeVO=function(){var _BM=this._we.GetString('IDS_ANALYSIS_ITEMS_ROOT_NODE');var _ahP=new COTTreeNode(ExpAPIXml.eInsertableObjects,_BM,_BM,_BM);this._hA.SetTreeRoot(_ahP);_ahP._s5=true;_ahP._j4=false;_ahP._uS=true;_ahP._qq=true;_ahP._k4=true;var _Np=this._we.GetString('IDS_MY_CUSTOM_SETS');var _QT=new COTTreeNode(ExpAPIXml.eCustomSets,_Np,_Np,_Np,_ahP);_QT._qq=false;_QT._s5=false;_QT._uS=false;_QT._j4=false;_QT._k4=false;this._hA.AddTreeNode(_QT);var _Np=this._we.GetString('IDS_OTHER_ANALYSES');var _9r=new COTTreeNode(ExpAPIXml.eAnalysisLib,_Np,_Np,_Np,_ahP);_9r._qq=false;_9r._s5=true;_9r._uS=false;_9r._j4=false;_9r._k4=false;this._hA.AddTreeNode(_9r);if(Utilities.GetObjArrayLength(this._f0)>0){_Np=this._we.GetString('IDS_NAMED_SETS');_QT=new COTTreeNode(ExpAPIXml.eNamedSets,_Np,_Np,_Np,_ahP);_QT._qq=true;_QT._s5=true;_QT._uS=false;_QT._j4=false;_QT._k4=true;this._hA.AddTreeNode(_QT);}for(var i in this._f0){this.AddNamedSet(_QT,this._f0[i]._iB);}};CUIAnalysisItemTree.prototype.UpdateTreeVO=function(_Aw){var _Eq=this._hA._nl[this._we.GetString(_Aw)];var _BF=_Eq._lW;switch(_BF){case ExpAPIXml.eCustomSets:var _ajr=this.updateCustomSetArray();for(var i=0;i<_ajr.length;i++){this.DeleteFromTreeVO(this._hA._nl[_ajr[i]]);}var _FE=true;if(!this._rT){this._rT=false;_FE=false;}var _Tg=new Object();for(var i in this._ey){if(!this._hA._nl[i]){this.AddCustomSet(_Eq,this._ey[i]._ia,_Tg);}else{this.ModifyCustomSet(this._hA._nl[i],this._ey[i]);}}if(this._tH){if(this._tH._x8){this._tH._x8._gc=true;this._tH._x8.EndAsyncLoad();if(Utilities.GetObjArrayLength(this._tH._dK)==0){this._tH._s5=false;this.oTree.UpdateNode(this._tH);this.oTree.DrawChildren(this._tH,true,false);}}}for(var listIdx in _Tg){if(_Tg[listIdx]==this._tH){continue;}_Tg[listIdx]._qq=true;_Tg[listIdx]._uS=true;_Tg[listIdx]._k4=true;this.oTree.UpdateNode(_Tg[listIdx]);this.oTree.DrawChildren(_Tg[listIdx],true,false);}Utilities.ClearObjectArray(_Tg);this._tH=null;this.fetchCustomSet(_Eq,_FE);break;}};CUIAnalysisItemTree.prototype.ModifyCustomSet=function(_Eq,_KI){if(_Eq._p8!=_KI._ia._p8){_Eq.ModifyLabel(_KI._ia._p8);}_Eq.ModifyToolTip(_KI._ia._d0);this.oTree.UpdateNode(_Eq);};CUIAnalysisItemTree.prototype.DeleteFromTreeVO=function(_Eq){var parentNode=_Eq._qR;this.oTree.DeleteNode(parentNode,_Eq);this._hA.RemoveTreeNode(_Eq);var _FE=false;if(parentNode._lW==ExpAPIXml.eOtherAnalysis){parentNode._s5=true;parentNode._qq=false;parentNode._k4=false;parentNode._uS=false;}else{parentNode._s5=(Utilities.GetObjArrayLength(parentNode._dK)==0)?false:true;}if(!parentNode._s5){parentNode._uS=false;this._rT=false;this.oTree.UpdateNode(parentNode);}else{if(parentNode._lW!=ExpAPIXml.eOtherAnalysis){this.fetchCustomSet(parentNode,_FE);}else{this.oTree.UpdateNode(parentNode);}}};CUIAnalysisItemTree.prototype.InitContextMenu=function(){var _aCV=null;var _IS=false;this.oCustomSetContextMenu.items=new Array();_BM=this._we.GetString('TRE_RENAME_NAMED_SET');_afZ=new ContextItem('',_BM,CUIAnalysisItemTree.SafeDoRenameCustomSet,false,_aCV,this.oCustomSetContextMenu);_afZ.id='TRE_RENAME_NAMED_SET';_BM=this._we.GetString('TRE_DEL_NAMED_SET');var _afZ=new ContextItem('',_BM,CUIAnalysisItemTree.SafeDoDelCustomSet,false,_aCV,this.oCustomSetContextMenu);_afZ.id='TRE_DEL_NAMED_SET';var _aIC=new ContextSeparator(this.oCustomSetContextMenu);CUIMetadataTree.SetBaseXTabInsertionMenu(this.uiManager.appobj.appname,this.oCustomSetContextMenu);_BM=this._we.GetString('TRE_TREEVIEW_FILTER_BY_MEMBER');_afZ=new ContextItem('',_BM,CUIFilterContextSet.SafeDoInsertDimFilter,false,_aCV,this.oCustomSetContextMenu);_afZ.id='TRE_TREEVIEW_FILTER_BY_MEMBER';this.oCustomSetContextMenu.SetChildrenComplete();this.oNamedSetContextMenu.items=new Array();CUIMetadataTree.SetBaseXTabInsertionMenu(this.uiManager.appobj.appname,this.oNamedSetContextMenu);_BM=this._we.GetString('TRE_TREEVIEW_FILTER_BY_MEMBER');_afZ=new ContextItem('',_BM,CUIFilterContextSet.SafeDoInsertDimFilter,false,_aCV,this.oNamedSetContextMenu);_afZ.id='TRE_TREEVIEW_FILTER_BY_MEMBER';this.oNamedSetContextMenu.SetChildrenComplete();};CUIAnalysisItemTree.prototype.Refresh=function(){Dom.RemoveAllChildren(this._st);this.SetUpAnalysisTree();};CUIAnalysisItemTree.prototype.UnLoad=function(){Dom.RemoveObject(this._st);this.clearTreeCache();Utilities.RemoveAllChildObjects(this);};CUIAnalysisItemTree.prototype.clearTreeCache=function(){var _aBJ=this._hA._nl;var _LF;for(var i in _aBJ){_LF=_aBJ[i];Utilities.ClearObjectArray(_LF._dK);_LF._dK=null;_LF.Clear();delete _aBJ[i];}this._hA._nl=null;Utilities.RemoveAllChildObjects(this._hA);};CUIAnalysisItemTree.prototype.GetRightPos=function(){return COTStyle.GetDisplayWidth(this._st)+COTStyle.GetPosition(this._st,'left');};CUIAnalysisItemTree.prototype.Notify=function(event){if(event==ExpEvent.kCUIManager_Unload){this.UnLoad();}else if(event==ExpEvent.kCDLAnalysis_Replace){this.UpdateTreeVO(this._we.GetString('IDS_MY_CUSTOM_SETS'));}else if(event==ExpEvent.kCDLDataManager_AnalysisCreate){this.UpdateTreeVO(this._we.GetString('IDS_MY_CUSTOM_SETS'));}else if(event==ExpEvent.kCUIManager_OnSelChange){if(this.uiManager.GetSelPane()!=this){this.oTree.HandleBlur();}}else if(event==ExpEvent.kTreeCDLCMFolder_Replace){this.UpdateAnalyses();}else if(event==ExpEvent.kCDLCMFolder_FailedResponse||event==ExpEvent.kCDLAnalysis_FailedResponse){if(this._tH){if(this._tH._x8){this._tH._x8._gc=false;this._tH._x8.EndAsyncLoad();this._tH=null;}}}else if(event==ExpEvent.kCDLWorksheet_AwaitingResponse){this.oTree.SetStateToBlocked();}else if(event==ExpEvent.kCDLWorksheet_EndProcessing||event==ExpEvent.kCDLWorksheet_FailedResponse){this.oTree.FreeTheTree();}};CUIAnalysisItemTree.GetMemberText=function(_UY){return _UY._p8;};CUIAnalysisItemTree.prototype.FetchChildren=function(_Eq){var _Ke=this.uiManager.appobj.appname;var _BF=_Eq._lW;switch(_BF){case ExpAPIXml.eInsertableObjects:this.fetchSets(_Eq,true);break;case ExpAPIXml.eRoot:return false;break;case ExpAPIXml.eCustomSets:this.fetchCustomSet(_Eq,true);break;case ExpAPIXml.eNamedSets:this.fetchNamedSet(_Eq,true);break;case ExpAPIXml.eAnalysisLib:this.fetchOtherSets(_Eq,true);return true;case ExpAPIXml.eOtherAnalysis:this.fetchCustomSetUnderOtherAnalysis(_Eq);return true;case ExpAPIXml.eCMRegularFolder:this.fetchOtherSets(_Eq,true);return true;case ExpAPIXml.eCMFMPackage:this.fetchOtherSets(_Eq,true);return true;default:Debug.Assert(false,'unexpected objtype '+_BF+' in FetchChildren');return false;}return false;};CUIAnalysisItemTree.prototype.fetchSets=function(_Eq,_FE){_Eq._uS=true;this.oTree.UpdateNode(_Eq);this.oTree.DrawChildren(_Eq,true,_FE);return true;};CUIAnalysisItemTree.prototype.fetchCustomSet=function(_Eq,_FE){if(this._rT){_Eq._uS=true;this.oTree.UpdateNode(_Eq);this.oTree.DrawChildren(_Eq,true,_FE);}return true;};CUIAnalysisItemTree.prototype.fetchCustomSetUnderOtherAnalysis=function(_Eq){var _VP=this.uiManager.dataManager;var _anm=_VP._ez[_Eq._ks]._qI;this._tH=_Eq;_VP._kX.DoLoadCustomSetsFromCM(_anm);};CUIAnalysisItemTree.prototype.fetchNamedSet=function(_Eq,_FE){_Eq._uS=true;this.oTree.UpdateNode(_Eq);this.oTree.DrawChildren(_Eq,true,_FE);return true;};CUIAnalysisItemTree.prototype.fetchOtherSets=function(_Eq,_FE){var _Uw=false;if(_Eq._lW==ExpAPIXml.eAnalysisLib){var _BU=this.uiManager.dataManager._o5;_Uw=true;}else{var _BU=this.uiManager.dataManager._ez[_Eq._ks];this._ms=_Eq._ks;}_BU.Subscribe(this,ExpEvent.kTreeCDLCMFolder_Replace);_BU.Subscribe(this,ExpEvent.kCDLCMFolder_FailedResponse);_BU.RunGetCMFolderForAnalysis(_Uw);this._tH=_Eq;return true;};CUIAnalysisItemTree.ProcessFolderNode=function(_Jn,_U2,_MP){if(_U2){var _atV=false;for(var i in _U2._ih){var _UV=_U2._ih[i];var _W0=new COTTreeNode(_UV._tF,_UV._ks,_UV._p8,_UV._ks,_Jn);_W0._j4=false;_W0._s5=true;_W0._uS=false;_MP.AddTreeNode(_W0);_atV=true;if(_UV._tF==ExpAPIXml.eCMFMPackage){CUIAnalysisItemTree.ProcessFolderNode(_W0,_UV,_MP);}else{_W0._qq=false;_W0._k4=false;}}for(var i in _U2._xX){var _JE=_U2._xX[i];var _afC=new COTTreeNode(ExpAPIXml.eOtherAnalysis,_JE._ks,_JE._p8,_JE._ks,_Jn);_afC._j4=false;_afC._qq=false;_afC._s5=true;_afC._uS=false;_afC._ii=_JE._qI;_MP.AddTreeNode(_afC);_atV=true;}}if(_atV){_Jn._qq=true;_Jn._k4=true;}else{_Jn._s5=false;}};CUIAnalysisItemTree.prototype.UpdateAnalyses=function(_Dw){var _BU=this.uiManager.dataManager._ez[this._ms];CUIAnalysisItemTree.ProcessFolderNode(this._tH,_BU,this._hA);if(this._tH._x8){this._tH._x8._gc=true;this._tH._x8.EndAsyncLoad();this._tH._x8=null;}this._tH=null;this._ms=null;};CUIAnalysisItemTree.prototype.AddCustomSet=function(_Eq,_Oj,_Tg){if(_Oj._ii&&_Oj._ii!==""){var _57=null;for(var anaNodeId in this._hA._nl){var _aGE=this._hA._nl[anaNodeId];if(_aGE._lW!=ExpAPIXml.eOtherAnalysis){continue;}else{if(_aGE._ii==_Oj._ii){_57=_aGE;break;}}}if(!_57){return;}var _Rz=(_Oj._d0=="")?_Oj._p8:_Oj._d0;var _axi=new COTTreeNode(ExpAPIXml.eCustomSet,_Oj._ks,_Oj._p8,_Oj._ks,_57,null,_Rz);this._hA.AddTreeNode(_axi);_axi.expandable=false;_Tg[_57._ks]=_57;}else{var _Rz=(_Oj._d0=="")?_Oj._p8:_Oj._d0;var _axi=new COTTreeNode(ExpAPIXml.eCustomSet,_Oj._ks,_Oj._p8,_Oj._ks,_Eq,null,_Rz);_Eq._s5=true;this._hA.AddTreeNode(_axi);_axi._s5=false;_Eq._qq=true;this._rT=true;}};CUIAnalysisItemTree.prototype.AddNamedSet=function(_Eq,_V8){var _9m=new COTTreeNode(ExpAPIXml.eNamedSet,_V8._bb,_V8._xU,_V8._bb,_Eq,null);this._hA.AddTreeNode(_9m);_9m.expandable=false;_Eq._qq=true;};CUIAnalysisItemTree.prototype.GetLastSelection=function(){if(this.oTree.GetLastSelection()){if(this._ey[this.oTree.GetLastSelection()._ks]){return this._ey[this.oTree.GetLastSelection()._ks];}else{return this;}}return null;};CUIAnalysisItemTree.prototype.GetPropertyList=function(){var _JP=new Array();var _V7=this.oTree.GetLastSelection();if(_V7){_JP.push(new COTPropertyPair('IDS_SELECTION_NAME',_V7._p8));return _JP;}return _JP;};CUIAnalysisItemTree.prototype.GetSelectionLabel=function(){var _V7=this.oTree.GetLastSelection();if(_V7){return _V7._p8;}return "";};CUIAnalysisItemTree.prototype.OnTreeDragStart=function(e){if(this.uiManager._jf.AllowInteraction()){var _LF=this.oTree.GetLastSelection();var _ayz=_LF._lW;if(_ayz==ExpAPIXml.eNamedSet){var _V8=this._ob.GetNamedSet(_LF._ks);var _aiS=new CUIDragDropNamedSet(_V8._bb,_V8.GetDimId(),_V8.GetHierId());CUIDragDrop.Start(this,this.uiManager,_aiS,CUIDragDrop.eEffectNone,e);var _QX=new Array(_LF.GetImgByType());var _Bu=new Array(_LF._p8);CUIDragDrop.SetTooltipItems(_QX,_Bu);CUIDragDrop.ShowTooltip(e.clientX,e.clientY);}else if(_ayz==ExpAPIXml.eCustomSet){var _Oj=this._ob.datamanager._kX.GetCustomSet(_LF._ks);var _J5=_Oj.IsHAMC()?_Oj.GetMemberIds():null;var _aiS=new CUIDragDropCustomSet(_Oj._ks,_Oj.GetLevelPtr(),_Oj.GetLastDataMemberId(),_J5);CUIDragDrop.Start(this,this.uiManager,_aiS,CUIDragDrop.eEffectNone,e);var _QX=new Array(_LF.GetImgByType());var _Bu=new Array(_LF._p8);CUIDragDrop.SetTooltipItems(_QX,_Bu);CUIDragDrop.ShowTooltip(e.clientX,e.clientY);}}};CUIAnalysisItemTree.prototype.ShowContextMenu=function(e,_Eq){Dom.CancelEvent(e);if(_Eq==null){return;}this._iZ=Dom.CloneMouseEvent(e);var nodeType=_Eq._lW;switch(nodeType){case ExpAPIXml.eCustomSet:var _zA=new Array(this.uiManager.appobj.appname,_Eq);for(var i=0;i<this.oCustomSetContextMenu.items.length;i++){var _PM=this.oCustomSetContextMenu.items[i];if(_PM instanceof ContextItem){var _aC2=this._ey[_Eq._ks]._ia;var _Xp=_aC2.IsFromOtherAnalysis();switch(_PM.id){case 'TRE_DEL_NAMED_SET':case 'TRE_RENAME_NAMED_SET':if(_Xp){_PM.SetDisplayFlag(false);break;}else{_PM.SetDisplayFlag(true);}case 'TRE_TREEVIEW_FILTER_BY_MEMBER':if(_PM.id=='TRE_TREEVIEW_FILTER_BY_MEMBER'){var _J5=_aC2.IsHAMC()?_aC2.GetMemberIds():null;var _aiS=new CUIDragDropCustomSet(_aC2._ks,_aC2.GetLevelPtr(),_aC2.GetLastDataMemberId(),_J5);if(!_aC2.CanUseAsBlockFilter()){_PM.SetEnabled(false);}else{_PM.SetEnabled(CUIMetadataTree.IsValidFilterMenuItem(this.uiManager.appobj,_PM,_aiS));}_zA=new Array(this.uiManager.appobj.appname,_aiS);}_PM.SetParameterArr(_zA);break;default:if(_aC2.CanUseOnAxis()){_PM.SetEnabled(true);CUIMetadataTree.SetBaseXTabInsertionMenuParameters(this.uiManager.appobj.appname,_PM,_Eq._ks);}else{if(_PM.GetFunctionId()=="insertlevel"){_PM.SetDisplayFlag(false);}else if(_PM.GetFunctionId()=="replacelevel"){_PM.SetDisplayFlag(false);}else{_PM.SetEnabled(false);}}break;}}}this.oCustomSetContextMenu.display(e);break;case ExpAPIXml.eNamedSet:var _zA=new Array(this.uiManager.appobj.appname,_Eq);for(var i=0;i<this.oNamedSetContextMenu.items.length;i++){var _PM=this.oNamedSetContextMenu.items[i];if(_PM instanceof ContextItem){switch(_PM.id){case 'TRE_TREEVIEW_FILTER_BY_MEMBER':if(_PM.id=='TRE_TREEVIEW_FILTER_BY_MEMBER'){var _aiS=new CUIDragDropNamedSet(_1x._bb,_1x.GetDimId(),_1x.GetHierId());var _1x=this._f0[_Eq._ks]._iB;if(_1x.FromMeasureDim()){_PM.SetEnabled(false);}else{_PM.SetEnabled(CUIMetadataTree.IsValidFilterMenuItem(this.uiManager.appobj,_PM,_aiS));}_zA=new Array(this.uiManager.appobj.appname,_aiS);}_PM.SetParameterArr(_zA);break;default:CUIMetadataTree.SetBaseXTabInsertionMenuParameters(this.uiManager.appobj.appname,_PM,_Eq._ks);break;}}}this.oNamedSetContextMenu.display(e);break;}};CUIAnalysisItemTree.prototype.DeleteSelectedItems=function(){var _aoq=new Array();for(var i in this.oTree._wI){_aoq.push(this.oTree._wI[i]._ks);}this.DoDelCustomSets(_aoq);};CUIAnalysisItemTree.prototype.CanDelete=function(){var _73=this.oTree.GetLastSelection();return(_73&&(_73._lW==ExpAPIXml.eCustomSet));};CUIAnalysisItemTree.prototype.DoDelCustomSets=function(_SV){this._m9.SendDeleteCustomSetsReq(_SV);};CUIAnalysisItemTree.SafeDoDelCustomSet=function(_Ke,_M5){try{FindApp(_Ke).uiManager._np.DoDelCustomSet(_M5);}catch(e){_f.HandleException(e);}};CUIAnalysisItemTree.prototype.DoDelCustomSet=function(_M5){this._m9.SendDeleteCustomSetsReq(new Array(_M5._ks));};CUIAnalysisItemTree.SafeDoRenameCustomSet=function(_Ke,_M5){try{FindApp(_Ke).uiManager._np.DoRenameCustomSet(_M5._ks,_M5._p8,_M5._pL);}catch(e){_f.HandleException(e);}};CUIAnalysisItemTree.prototype.DoRenameCustomSet=function(_LN,_PG,_QI){this.oTree.ClearSelections();if(!this.oRenameCSDlg){this.oRenameCSDlg=new CUIRenameCustomSetDlg();this.oRenameCSDlg.Init(this.uiManager.oDialogMgr);}this.oRenameCSDlg.SetCustomSet(_LN,_PG,_QI);this.oRenameCSDlg.Create();this.oRenameCSDlg.Display();};CUIAnalysisItemTree.prototype.IsDrawingStoppable=function(){return false;};function CUIMissingAnalysisItemTree(_EE,_B2,_HF){this.base=CUIAnalysisItemTree;this.base(_EE,_B2,_HF);};CUIMissingAnalysisItemTree.prototype=new CUIAnalysisItemTree;CUIMissingAnalysisItemTree.superclass=CUIAnalysisItemTree.prototype;CUIMissingAnalysisItemTree.prototype.Init=function(_EP){this._we=this.uiManager.appobj.oResources;this._st=document.createElement('DIV');this._st.id="analysisItem_"+Utilities.GenerateId();_EP.appendChild(this._st);this._st.className="analysis_item";this.oTree=new CUITreeView(this.uiManager);this.oNamedSetContextMenu=new CUIContextMenu(this.uiManager.appobj.appname,0);this.createNamedSetArray();};CUIMissingAnalysisItemTree.prototype.InitSubscriptions=function(){this.uiManager.Subscribe(this,ExpEvent.kCUIManager_Unload);this.uiManager.Subscribe(this,ExpEvent.kCUIManager_OnSelChange);};CUIMissingAnalysisItemTree.prototype.InitTreeVO=function(){var _BM=this._we.GetString('IDS_ANALYSIS_ITEMS_ROOT_NODE');var _ahP=new COTTreeNode(ExpAPIXml.eInsertableObjects,_BM,_BM,_BM);this._hA.SetTreeRoot(_ahP);_ahP._s5=true;_ahP._j4=false;_ahP._uS=true;_ahP._qq=true;_ahP._k4=true;if(Utilities.GetObjArrayLength(this._f0)>0){_Np=this._we.GetString('IDS_NAMED_SETS');_QT=new COTTreeNode(ExpAPIXml.eNamedSets,_Np,_Np,_Np,_ahP);_QT._qq=true;_QT._s5=true;_QT._uS=false;_QT._j4=false;_QT._k4=true;this._hA.AddTreeNode(_QT);}for(var i in this._f0){this.AddNamedSet(_QT,this._f0[i]._iB);}};CUIMissingAnalysisItemTree.prototype.InitContextMenu=function(){this.oNamedSetContextMenu.items=new Array();_BM=this._we.GetString('TRE_MISSING_REPLACE_SELECTED');var _5L=new ContextItem('',_BM,null,false,null,this.oNamedSetContextMenu);_5L.SetFunctionId("missingreplacesel");};CUIMissingAnalysisItemTree.prototype.ShowContextMenu=function(e,_Eq){Dom.CancelEvent(e);if(_Eq==null){return;}this._iZ=Dom.CloneMouseEvent(e);var _Jm=this._ob.GetDataById(_Eq._ks);for(var i=0;i<this.oNamedSetContextMenu.items.length;i++){var _7t=this.oNamedSetContextMenu.items[i];var _amV=_7t instanceof ContextItem;if(_amV){CUIMissingMetadataTree.SetCntxMenuParameters(this.uiManager.appobj.appname,_7t,_Jm);}}this.oNamedSetContextMenu.display(e);};CUIMissingAnalysisItemTree.prototype.OnTreeDragStart=function(e){if(this.uiManager._jf.AllowInteraction()){var _LF=this.oTree.GetLastSelection();var _ayz=_LF._lW;if(_ayz==ExpAPIXml.eNamedSet){var _V8=this._ob.GetNamedSet(_LF._ks);var _aiS=new CUIDragDropNamedSet(_V8._bb,_V8.GetDimId(),_V8.GetHierId());CUIDragDrop.Start(this,this.uiManager,_aiS,CUIDragDrop.eEffectNone,e);var _QX=new Array(_LF.GetImgByType());var _Bu=new Array(_LF._ks);CUIDragDrop.SetTooltipItems(_QX,_Bu);CUIDragDrop.ShowTooltip(e.clientX,e.clientY);}}};CUIMissingAnalysisItemTree.prototype.GetLastSelection=function(){return this;};function CUINamedSet(_Hw,_QA,_Bi,_Re){this._iB=_Hw;this._mR=_QA;this._sG=_Bi;this._oi=_Re;};CUINamedSet.prototype.GetPropertyList=function(){if(!this._gn){this._gn=new Array();this._gn.push(new COTPropertyPair('IDS_NAMED_SET_LABEL',this._iB._xU));}else{this._gn[0].sValue=this._iB._xU;}return this._gn;};function CUINamedSetContextMenu(_zs,_CI){this.appname=_zs;this.oContextMenu=new CUIContextMenu(_zs,0);this.oContextMenu.items=new Array();CUIMetadataTree.SetBaseXTabInsertionMenu(_zs,this.oContextMenu);_BM=_CI.GetString('TRE_TREEVIEW_FILTER_BY_MEMBER');_afZ=new ContextItem('',_BM,CUIFilterContextSet.SafeDoInsertDimFilter,false,null,this.oContextMenu);_afZ.id='TRE_TREEVIEW_FILTER_BY_MEMBER';var _aIC=new ContextSeparator(this.oContextMenu);_BM=_CI.GetString('TRE_METADATA_GLOSSARY');var _aFy=new ContextItem('action_glossary.gif',_BM,CUIMetadataTree.SafeGotoGlossary,true,null,this.oContextMenu);_aFy.id='TRE_METADATA_GLOSSARY';_aFy.SetFunctionId('TRE_METADATA_GLOSSARY');_BM=_CI.GetString('TRE_METADATA_VIEW_SOURCE_INFO');var _9Y=new ContextItem('action_lineage.gif',_BM,CUIMetadataTree.SafeGotoLineage,true,null,this.oContextMenu);_9Y.id='TRE_METADATA_VIEW_SOURCE_INFO';this.oContextMenu.SetChildrenComplete();};CUINamedSetContextMenu.prototype.ShowContextMenu=function(e,_Eq,_JF){var _zA=new Array(this.appname,_Eq);var _aas="";if(_Eq._lW==ExpAPIXml.eNamedSetFolderObj){_aas=_Eq._sx;}else{_aas=_Eq._ks;}for(var i=0;i<this.oContextMenu.items.length;i++){var _PM=this.oContextMenu.items[i];if(_PM instanceof ContextItem){switch(_PM.id){case 'TRE_TREEVIEW_FILTER_BY_MEMBER':var _1x=_JF[_aas];var _aiS=new CUIDragDropNamedSet(_1x._bb,_1x.GetDimId(),_1x.GetHierId());var _N0=FindApp(this.appname);if(_1x.FromMeasureDim()){_PM.SetEnabled(false);}else{_PM.SetEnabled(CUIMetadataTree.IsValidFilterMenuItem(_N0,_PM,_aiS));}_zA=new Array(this.appname,_aiS);_PM.SetParameterArr(_zA);break;case 'TRE_METADATA_VIEW_SOURCE_INFO':var _TC=new Array(_aas);_zA=new Array(this.appname,_TC);_PM.SetParameterArr(_zA);break;case 'TRE_METADATA_GLOSSARY':var _TC=new Array(_aas);_zA=new Array(this.appname,_TC);_PM.SetParameterArr(_zA);break;default:CUIMetadataTree.SetBaseXTabInsertionMenuParameters(this.appname,_PM,_aas);break;}}}this.oContextMenu.display(e);};function CUICustomSet(_GS){this._ia=_GS;};CUICustomSet.prototype.GetPropertyList=function(){if(!this._gn){this._gn=new Array();this._gn.push(new COTPropertyPair('IDS_CUSTOM_SET_LABEL',this._ia._p8));this._gn.push(new COTPropertyPair('IDS_CUSTOM_SET_ANNOTATION',this._ia._d0));this._gn.push(new COTPropertyPair('IDS_CUSTOM_SET_DIMENSION',this._ia.GetDimensionLabel()));this._gn.push(new COTPropertyPair('IDS_CUSTOM_SET_SORT_ORDER',this._ia.GetSortOrder()));}else{this._gn[0].sValue=this._ia._p8;this._gn[1].sValue=this._ia._d0;this._gn[2].sValue=this._ia.GetDimensionLabel();this._gn[3].sValue=this._ia.GetSortOrder();}return this._gn;};CUICustomSet.prototype.GetSelectionLabel=function(){return this._ia._p8;};function CUICMFolderTree(_Hk,_WE){this._j1=_Hk;this._jp=_WE._tF;this._qO=_WE;this._qO.Subscribe(this,ExpEvent.kCDLCMFolder_Replace);this._qO.Subscribe(this,ExpEvent.kCDLCMFolder_FailedResponse);this._e6=new Array();this._e6[ExpEvent.kCUICMFolderTree_Update]=new Array();this._tU=null;this.InitTreeVO();};CUICMFolderTree.prototype.InitTreeVO=function(){if(!this._iN){this._iN=new COTTreeVO(this);var _6i=new COTTreeNode(this._jp,this._qO._ks,this._qO._p8,this._qO._ks,null);_6i._j4=false;_6i._qq=false;_6i._s5=true;_6i._uS=false;this._iN.SetTreeRoot(_6i);}this.ReplaceChildNodes(this._qO);};CUICMFolderTree.prototype.ReplaceChildNodes=function(_BR){var _Ky=this._iN.GetNode(_BR._ks);this._iN.RemoveChildrenNodes(_Ky);for(var i in _BR._ih){_Ky._qq=true;var _UV=_BR._ih[i];var _W0=new COTTreeNode(_UV._tF,_UV._ks,_UV._p8,_UV._ks,_Ky);_W0._j4=false;_W0._qq=false;_W0._s5=true;_W0._uS=false;this._iN.AddTreeNode(_W0);this.ReplaceChildNodes(_UV);}for(var i in _BR._xX){_Ky._qq=true;var _JE=_BR._xX[i];var _afC=new COTTreeNode(ExpAPIXml.eCMAnalysis,_JE._ks,_JE._p8,_JE._ks,_Ky);_afC._j4=false;_afC._qq=false;_afC._s5=false;_afC._uS=false;this._iN.AddTreeNode(_afC);}for(var i in _BR._yo){_Ky._qq=true;var _ahz=_BR._yo[i];var _aFR=new COTTreeNode(ExpAPIXml.eCMReportTemplate,_ahz._ks,_ahz._p8,_ahz._ks,_Ky);_aFR._j4=false;_aFR._qq=false;_aFR._s5=false;_aFR._uS=false;this._iN.AddTreeNode(_aFR);}var _atb=this._j1.dataManager.GetCurrentWorkSheet().GetInitAnalysisFolderPath();Debug.Assert(_atb);if(!this._tU&&_BR._qI==_atb){this._tU=_BR;this._tU.Subscribe(this,ExpEvent.kCDLCMFolder_Replace);this._tU.Subscribe(this,ExpEvent.kCDLCMFolder_FailedResponse);}};CUICMFolderTree.prototype.GetChildren=function(_Nx,_yA){var _awo=this._j1.dataManager._kE[_Nx._oa];if(!_awo instanceof CDLCMFolder||(_awo.HasResults()&&!_yA)){return;}this._tU=_awo;this._tU.Subscribe(this,ExpEvent.kCDLCMFolder_Replace);this._tU.Subscribe(this,ExpEvent.kCDLCMFolder_FailedResponse);_awo.RunGetCMFolder();if(_yA){this._iN.RemoveChildrenNodes(_Nx);_awo.RemoveChild();}var _aqD=Utilities.GenerateId();var _aBd=this._j1.appobj.oResources.GetString('IDS_LOADING');var _W4=new COTTreeNode(ExpAPIXml.eLoadingNode,_aqD,_aBd,_aqD,_Nx);this._iN.AddTreeNode(_W4);};CUICMFolderTree.prototype.GetImageByNodeType=function(_Nx){switch(_Nx._lW){case ExpAPIXml.eLoadingNode:return "icon_loading.gif";case ExpAPIXml.eCMAnalysis:return "icon_ps_analysis.gif";case ExpAPIXml.eCMFMPackage:return "icon_package.gif";case ExpAPIXml.eCMMetricPackage:return "package_metricStudio.gif";case ExpAPIXml.eCMContributorPackage:return "package_planningContributor.gif";case ExpAPIXml.eCMRegularFolder:return "tv_folder.gif";case ExpAPIXml.eCMRootPublicFolder:return 'icon_publicfolder.gif';case ExpAPIXml.eCMRootMyFolder:return "icon_myfolder.gif";case ExpAPIXml.eCMReportTemplate:return "icon_report_template.gif";default:Debug.Assert(false,"invalid type"+_Nx._lW);return "tv_folder.gif";}};CUICMFolderTree.prototype.GetLastLoadedNode=function(){return this._iN.GetNode(this._tU._ks);};CUICMFolderTree.SafeDoDeleteNode=function(_Ke,_Nx){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager.oDialogMgr._jg._fM._hq.DeleteNode(_Nx);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICMFolderTree.prototype.DeleteNode=function(_Nx){var _age;var _VW=_Nx._qR;Debug.Assert(_VW!=null);var _BR=this._j1.dataManager._kE[_VW._oa];Debug.Assert(_BR!=null);if(_Nx._lW==ExpAPIXml.eCMAnalysis){_age=_BR._xX[_Nx._oa];}else if(_Nx._lW==ExpAPIXml.eCMReportTemplate){_age=_BR._yo[_Nx._oa];}else{_age=_BR._ih[_Nx._oa];}this._tU=_age._e8;_age.RunDelete();};CUICMFolderTree.prototype.CreateSubFolder=function(_Nx,_BM){var _aJS=this._j1.dataManager._kE[_Nx._oa];this._tU=_aJS;_aJS.CreateSubFolder(_BM);};CUICMFolderTree.prototype.RenameObject=function(_Nx,_BM){var _age;var _VW=_Nx._qR;Debug.Assert(_VW!=null);var _BR=this._j1.dataManager._kE[_VW._oa];Debug.Assert(_BR!=null);if(_Nx._lW==ExpAPIXml.eCMAnalysis){_age=_BR._xX[_Nx._oa];}else if(_Nx._lW==ExpAPIXml.eCMReportTemplate){_age=_BR._v[_Nx._oa];}else{_age=_BR._ih[_Nx._oa];}this._tU=_age._e8;_age.RunRename(_BM);};CUICMFolderTree.prototype.Notify=function(_Dy,_FA,_LB,_zP){var _aFz=null;if(_Dy==ExpEvent.kCDLCMFolder_Replace){this.HandleReplace();_aFz=ExpEvent.kCUICMFolderTree_Update;}else if(_Dy==ExpEvent.kCDLCMFolder_FailedResponse){if(!_zP){CUIDialogMgr.DisplayMessageBox(CUIMessageBox.kCritical,(_FA)?_FA:'MES_SERVER_ERROR',_LB);}}if(_aFz&&this._e6[_aFz]){for(var i=0;i<this._e6[_aFz].length;i++){this._e6[_aFz][i].Notify(_aFz);}}};CUICMFolderTree.prototype.Subscribe=function(obj,_Dy){if(this._e6[_Dy]){for(var i=0;i<this._e6[_Dy].length;i++){if(this._e6[_Dy]==obj){return;}}this._e6[_Dy].push(obj);}};CUICMFolderTree.prototype.HandleReplace=function(){if(this._tU==null){this.InitTreeVO();}else{this.ReplaceChildNodes(this._tU);}};CUITreeView.NodeHoverState=0;CUITreeView.NodeSelectedState=1;CUITreeView.NodeNormalState=2;CUITreeView.NodeBlurState=4;CUITreeView.NodeClickableState=5;CUITreeView.ClickableNodeHoverState=6;function CUITreeView(_Uk){this._m4=_Uk;this.m_bIsMultiSelect=true;this._wI=new Object();this._qN=null;this.m_doc=document;this._m5=Utilities.IMG_PATH;this._qW=new Image();this._qW.src=this._m5+"tv_white.gif";this._vi=new Image();this._vi.src=this._m5+"tv_I.gif";this._vh=new Image();this._vh.src=this._m5+"tv_T.gif";this._vl=new Image();this._vl.src=this._m5+"tv_L.gif";this._gA=new Image();this._gA.src=this._m5+"tv_L_top.gif";this._a5=new Image();this._a5.src=this._m5+"tv_Lminus_top.gif";this._eO=new Image();this._eO.src=this._m5+"tv_Lplus.gif";this._wz=new Image();this._wz.src=this._m5+"tv_Lplus_top.gif";this._op=new Image();this._op.src=this._m5+"tv_T_top.gif";this._nW=new Image();this._nW.src=this._m5+"tv_Tminus.gif";this._tw=new Image();this._tw.src=this._m5+"tv_Tminus_top.gif";this._jo=new Image();this._jo.src=this._m5+"tv_Tplus_top.gif";this._nm=new Image();this._nm.src=this._m5+"tv_Tplus.gif";this._x6="tv_Lminus_top.gif";var _akq="tree_node";this._gt=new Object();this._ww=_akq+"_normal";this._gt[CUITreeView.NodeNormalState]=this._ww;this._jq=_akq+"_clickable";this._gt[CUITreeView.NodeClickableState]=this._jq;this._is=_akq+"_hover";this._gt[CUITreeView.NodeHoverState]=this._is;this._C=_akq+"_clickable_hover";this._gt[CUITreeView.ClickableNodeHoverState]=this._C;this._lv=_akq+"_selected";this._gt[CUITreeView.NodeSelectedState]=this._lv;this._ew=_akq+"_blur";this._gt[CUITreeView.NodeBlurState]=this._ew;this._vm=this.m_doc.createElement("DIV");this._vm.className="tree_node_div";this._hS=this.m_doc.createElement("IMG");this._hS.className="tree_img";this._qP=this.m_doc.createElement("IMG");this._qP.className="tree_icon";this._b2=this.m_doc.createElement("IMG");this._b2.className="node_type_icon";this._kN=this.m_doc.createElement("IMG");this._kN.className="node_state";this._tn=this.m_doc.createElement("SPAN");this._tn.className="tree_node_normal";var _aBe=this._tn.appendChild(this.m_doc.createElement("A"));_aBe.className='invisible_tree_link';this._dR=this.m_doc.createElement("SPAN");this._dR.className=this._jq;var _aBe=this._dR.appendChild(this.m_doc.createElement("A"));this._kj=new Object();this._vB=false;this._m4.Subscribe(this,ExpEvent.kCUIManager_Unload);this._qU=false;this._hQ=new Object();};CUITreeView.TreeStepLength=20;CUITreeView.TreeMaxAccLength=1000;CUITreeView.prototype.SetMultiSelect=function(_DZ){this.m_bIsMultiSelect=_DZ;};CUITreeView.prototype.GetLastSelection=function(){return this._qN;};CUITreeView.prototype.GetSelectedNodes=function(){return this._wI;};CUITreeView.prototype.HasMultipleSelections=function(){var _Oi=0;for(var i in this._wI){_Oi++;if(_Oi>1){return true;}}return false;};CUITreeView.invalidHtmlId=-1;CUITreeView.prototype.ResetCUIDragDrop=function(){CUITreeView._je=null;this.onmouseout=null;this.onmousemove=null;this.onmouseup=null;};CUITreeView.prototype.SetTreeVO=function(_Of){this._kj=_Of;};CUITreeView.prototype.SetDiv=function(_Ij){this._st=_Ij;this._st.onmousedown=this.SafeHandleMouseDown;this._st.ondblclick=this.SafeHandleDBClick;this._st.onmouseover=this.SafeHandleMouseOver;this._st.oncontextmenu=this.SafeHandleContextMenu;Dom.SetObjRef(this._st,this,"oTreeView");};CUITreeView.prototype.Notify=function(event){if(event==ExpEvent.kCUIManager_Unload){this.Unload();}};CUITreeView.prototype.Unload=function(){this._kj=null;this._qN=null;Utilities.RemoveAllChildObjects(this);};CUITreeView.prototype.DrawTree=function(){this.ClearSelections(true);Dom.RemoveAllChildren(this._st);this._vB=true;this.DrawNode(this._kj._vp);var _Cz=this._kj._vp._qq;this.DrawChildren(this._kj._vp,_Cz,false,true);};CUITreeView.prototype.DrawChildren=function(parentNode,_Cz,_FE,_Sl){if(parentNode._vB){this.DrawBusyNode(parentNode);}else{if(_Cz){if(parentNode._s5){if(_FE){this.ClearSelections();Dom.RemoveAllChildren(this.m_doc.getElementById(parentNode._mO).lastChild);}if((!_Sl)||Utilities.GetObjArrayLength(parentNode._dK)<CUITreeView.TreeMaxAccLength){var _Oi=0;for(var i in parentNode._dK){_Oi++;this.DrawNode(parentNode._dK[i]);}if(_Oi<=parentNode._ln){parentNode._ln=_Oi;}parentNode._qE=parentNode._ln;}else{var _On=Utilities.GetObjArrayLength(parentNode._dK);this.StepDrawChildren(0,parentNode);if(_On<=parentNode._ln){parentNode._ln=_On;}}}else{this.m_doc.getElementById(parentNode._mO).lastChild.style.display="none";}}else{var _1U=new COTLoadingAgent(parentNode,this._kj,this);parentNode._x8=_1U;_1U.FireOnPopulateChildren();}}};CUITreeView.prototype.LogChildrenState=function(_Oi,parentNode){if(!(this._hQ[parentNode._ks])){this._hQ[parentNode._ks]=new CUIChildrenState(_Oi,parentNode);}else{this._hQ[parentNode._ks]._vS=_Oi;}};CUITreeView.prototype.GetNodeStoppingState=function(_RD){if(!this._hQ[_RD]){return false;}else{return this._hQ[_RD]._r2;}};CUITreeView.prototype.SetNodeStoppingState=function(_RD,_CF){if(!this._hQ[_RD]){return;}else{this._hQ[_RD]._r2=_CF;}};CUITreeView.prototype.GetNodeLogState=function(_RD){return this._hQ[_RD];};CUITreeView.prototype.ClearNodeLogState=function(_RD){if(this._hQ){Utilities.RemoveObjXObjectArray(this._hQ,_RD);}};function CUIChildrenState(_Oi,parentNode,_A8,_Q6){this._vS=_Oi;this._cr=parentNode;this._r2=false;};CUITreeView.prototype.StepDrawChildren=function(_Oi,parentNode,_RD){var _akM=false;if(!parentNode&&_RD){var _63=this.GetNodeLogState(_RD);Debug.Assert(_63);parentNode=_63._cr;_Oi=_63._vS;}Debug.Assert(parentNode);var _5G=0;var _awR=0;if(!parentNode||!parentNode._dK)return;for(var i in parentNode._dK){_awR++;if(_awR<=_Oi){continue;}if(this.IsNodeDisplayed(parentNode._dK[i])){continue;}_Oi++;_5G++;this.DrawNode(parentNode._dK[i]);if(_5G>=CUITreeView.TreeStepLength)break;}this.SyncScroller();this.LogChildrenState(_Oi,parentNode);if(_Oi<Utilities.GetObjArrayLength(parentNode._dK)){parentNode._qE=_Oi;this.UpdateAdditionalNode(parentNode,_Oi);if(!_akM){this.UpdateAdditionalCtrlNode(parentNode,_Oi);}if(this.GetNodeLogState(parentNode._ks)&&(!this.GetNodeStoppingState(parentNode._ks))||(Utilities.GetNthFromObjArray(parentNode._dK,(_Oi+1))._ks==parentNode._yq)){var _Ke=this._m4.appobj.appname;var _UA=new Array(_Ke,_Oi,parentNode._ks);var _6z=Utilities.GenerateCallback(CUITreeView.SafeStepDrawChildren,_UA);setTimeout(_6z,this.GetIntervalLength(_Oi));}else{this.UpdateAdditionalCtrlNode(parentNode,_Oi);}}else{parentNode._qE=parentNode._ln;if(_akM){if(Utilities.GetNthFromObjArray(parentNode._dK,Utilities.GetObjArrayLength(parentNode._dK))._ks!=parentNode._yq){this.UpdateAdditionalNode(parentNode,_Oi);}this.ClearNodeLogState(parentNode._ks);this.UpdateAdditionalCtrlNode(parentNode,_Oi);}}return _Oi;};CUITreeView.SafeStepDrawChildren=function(_Ke,_Oi,_RD){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager._qi.oTree.StepDrawChildren(_Oi,null,_RD);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUITreeView.prototype.GetIntervalLength=function(_Oi){if(_Oi<=1000){return 100;}else{return 200;}};CUITreeView.prototype.SetDrawingState=function(_RD,_HI,_Im){this.SetNodeStoppingState(_RD,!(this.GetNodeStoppingState(_RD)));var _anI=this.GetNodeLogState(_RD);Debug.Assert(_anI);this.ClearAdditionalCtrlNode(_anI._cr);if(!(this.GetNodeStoppingState(_RD))){if(!_Im){this.StepDrawChildren(_anI._vS,_anI._cr);}else{this._kj._vd.SyncAddChildren(_RD);}}};CUITreeView.SafeSetDrawingState=function(_Ke,_RD,_HI,_Im){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager._qi.oTree.SetDrawingState(_RD,_HI,_Im);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUITreeView.prototype.DrawNode=function(_QT){var _8y=null;_QT._mO=Utilities.GenerateId();var _FU=_QT._ta;if(_QT._qR){var _Cx=this.m_doc.getElementById(_QT._qR._mO);_8y=this.GetChildDiv(_Cx);}else{_8y=this._st;}var _LH=this._vm.cloneNode(false);_LH.id=_QT._mO;if(_QT._pL){_LH.title=_QT._pL;}Dom.SetObjRef(_LH,_QT,'oTreeNode');Dom.SetObjRef(_LH,this,'oTreeView');var parentNode=_QT._qR;if(parentNode&&parentNode._ly&&_QT._lW!=ExpAPIXml.eMore){var _Xa=parentNode._dK[parentNode._ly];var _6x=this.m_doc.getElementById(_Xa._mO);_8y.insertBefore(_LH,_6x);}else{_8y.appendChild(_LH);}var _aHH=_o.is_ie5_5up;if(_aHH&&((!_QT._bx||(!_QT._x4)))){this.DrawSimpleNode(_QT,_LH);}else{for(var i=1;i<_FU;i++){_LH.appendChild(this._hS.cloneNode(false));}if(_QT._qR){_LH.appendChild(this._qP.cloneNode(false)).bIsExpand=true;}var _aDT=_LH.appendChild(this._b2.cloneNode(false));_aDT.bIsIcon=true;if(_QT._bx){_LH.appendChild(this._dR.cloneNode(true)).onclick=_QT._x4;_aDT.onclick=_QT._x4;}else{_LH.appendChild(this._tn.cloneNode(true)).bIsLabel=true;}var _ZS=_LH.firstChild;for(var _Fd=1;_Fd<_FU;_Fd++){this.updateLineImg(_ZS,_QT,_FU,_Fd);_ZS=_ZS.nextSibling;}if(_QT._qR){this.updateExpandImg(_ZS,_QT);_ZS=_ZS.nextSibling;}this.updateTypeImg(_ZS,_QT);var _Tb=_ZS.nextSibling;this.updateLabel(_Tb,_QT);}if(this._kj._vd.GetAdditionalNodeElement){var _Do=this._kj._vd.GetAdditionalNodeElement(_QT);if(_Do){_LH.appendChild(_Do);}}if(this._kj._vd.GetAdditionalCtrlNodeElement){var _avX=this._kj._vd.GetAdditionalCtrlNodeElement(_QT);if(_avX){_LH.appendChild(_avX);}}};CUITreeView.prototype.DrawSimpleNode=function(_QT,_LH){var _Zc="";var _FU=_QT._ta;for(var _Fd=1;_Fd<_FU;_Fd++){var _Zf=this.getAncestor(_QT,_FU-_Fd+1);var _Tf=_Zf._oW?this._vi.src:this._qW.src;var _ahG="<IMG src='"+_Tf+"' class='tree_img' >";_Zc+=_ahG;}if(_QT._qR){_Zc+=this.getExpandImgStr(_QT);}_Zc+="<IMG bIsIcon='true' src='"+this._m5+_QT.GetImgByType()+"' class='node_type_icon' style='DISPLAY: inline' >";_Zc+=this.getLabelStr(_QT);_LH.innerHTML=_Zc;_Zc=null;};CUITreeView.prototype.getExpandImgStr=function(_Wa){var _akh=(_Wa._qR==null);var _aF9=_Wa._oW;var _ail=this._m5;var _afO="";if(_Wa._s5){if(_Wa._uS){_ail+=(_aF9?(_akh?"tv_Tminus_top.gif":"tv_Tminus.gif"):(_akh?"tv_Lminus_top.gif":"tv_Lminus.gif"));_afO=this._m4.appobj.oResources.GetString("IDS_TREE_NODE_COLLAPSE_ALT");}else{_ail=(_aF9?(_akh?this._jo.src:this._nm.src):(_akh?this._wz.src:this._eO.src));_afO=this._m4.appobj.oResources.GetString("IDS_TREE_NODE_EXPAND_ALT");}}else{_ail+=(_aF9?(_akh?"tv_T_top.gif":"tv_T.gif"):(_akh?"tv_L_top.gif":"tv_L.gif"));}var _aBl="<IMG src='"+_ail+"' alt='"+_afO+"' class='tree_icon' bIsExpand='true' >";return _aBl;};CUITreeView.prototype.getLabelStr=function(_Wa,_SG){var _aBl="";var _aIo="";if(_SG){var _afO=Utilities.HtmlEncode(this._m4.appobj.oResources.GetString("MES_SERVER_ERROR_RETRY"));_aIo="<IMG src='"+this._m5+"critical.gif' border='0' alt='"+_afO+"'>"+Utilities.HtmlEncode(_Wa._p8);}else{_aIo=Utilities.HtmlEncode(_Wa._p8);}if(_Wa._bx){_aBl="<SPAN class='"+this._jq+"' ><A>"+_aIo+"</A></SPAN>";}else{_aBl="<SPAN bIsLabel='true' class='tree_node_normal' ><A class='invisible_tree_link'>"+_aIo+"</A></SPAN>";}return _aBl;};CUITreeView.prototype.GetChildDiv=function(_Cx){var _aFZ=Dom.GetImmediateChildByName(_Cx,"DIV");if(!_aFZ){_aFZ=this._vm.cloneNode(false);_Cx.appendChild(_aFZ);}return _aFZ;};CUITreeView.prototype.getAncestor=function(_Wa,_Dq){while((--_Dq)>0){_Wa=_Wa._qR;}return _Wa;};CUITreeView.prototype.ClearSelections=function(_GF){for(var i in this._wI){this.unselectNode(this._wI[i]);}this._wI=new Object();this._qN=null;if(!_GF){this._m4.OnSelChange(this._kj._vd);}};CUITreeView.prototype.unselectNode=function(_Eq,_yu){if(_yu==null){var _yu=true;}var _Do=document.getElementById(this._wI[_Eq._ks]._mO);Debug.Assert(_Do);if(_Do){_Eq._l1=false;_Eq._dh=false;var _An=Dom.GetImmediateChildByName(_Do,"SPAN");if(_yu){this.SetObjStyleByState(_An,CUITreeView.NodeNormalState);}Utilities.RemoveObjXObjectArray(this._wI,_Eq._ks);if(this._qN==_Eq){this._qN=null;}}};CUITreeView.prototype.selectNode=function(_QT,e){if(!_QT._c0){return false;}this._yn=false;this.oClkNode=_QT;var _aHz=(e.button==CUIDragDrop.rightMouseDown)&&_QT._l1;if(_QT._l1&&(!_aHz)){this.oOrgEvt=Dom.CloneMouseEvent(e);return true;}var _aBL=true;for(var i in this._wI){_aBL=COTValidation.MetaDataSelectValidation(_QT,this._wI[i],this._kj._vd);break;}if(_aBL&&e.shiftKey&&this._qN&&this._qN._qR!=_QT._qR){_aBL=false;}if(!(this.m_bIsMultiSelect&&(e.ctrlKey||e.shiftKey||_aHz)&&_aBL)){var _GF=true;this.ClearSelections(_GF);}var _aBD=0;var _aw7=new Array();if(e.shiftKey&&this._qN){var _XY=_QT._qR._g1;var _aEZ=_QT._qR._dK;var _2C=Utilities.GetObjIndex(_XY,this._qN._ks);var _afI=Utilities.GetObjIndex(_XY,_QT._ks);var x=0;for(var i=Math.min(_2C,_afI);i<=Math.max(_2C,_afI);i++){_aw7[x]=_aEZ[_XY[i]];x++;}}else{_aw7[0]=_QT;}for(var i=0;i<_aw7.length;i++){var _at1=_aw7[i];Debug.Assert(_at1);if(_at1){_at1._l1=true;_at1._dh=false;if(!this._wI[_at1._ks]){this._wI[_at1._ks]=_at1;}var _46=document.getElementById(_at1._mO);var _aGv=Dom.GetImmediateChildByName(_46,'SPAN');this.SetObjStyleByState(_aGv,CUITreeView.NodeSelectedState);Dom.SetFocus(Dom.GetImmediateChildByName(_aGv,"A"));}}for(var i in this._wI){if(this._wI[i]._dh){this._wI[i]._dh=false;var _46=document.getElementById(this._wI[i]._mO);var _aGv=Dom.GetImmediateChildByName(_46,'SPAN');this.SetObjStyleByState(_aGv,CUITreeView.NodeSelectedState);}}this.SetInsertWithChildrenChx();this._qN=_QT;this._m4.OnSelChange(this._kj._vd);return true;};CUITreeView.prototype.SetObjStyleByState=function(_SJ,_Uc){_SJ.className=this._gt[_Uc];};CUITreeView.prototype.ExpandCollapseNode=function(_Uj){if(_Uj.oTreeNode){var _QT=_Uj.oTreeNode;if(_QT._uS){_QT._nv=true;this.CollapseNode(_QT);}else{this.ExpandNode(_QT);}}};CUITreeView.prototype.ExpandNode=function(_QT){if(_QT._s5){_QT._uS=true;if((!(_QT._qq&&_QT._k4))&&(!_QT._nv)){if(!this.IsBlocked()){this.DrawChildren(_QT);this.UpdateNode(_QT);}}else{if(_QT._nv){var _AA=document.getElementById(_QT._mO);_AA.lastChild.style.display="block";if(_QT._ln>_QT._v3){if(this.GetNodeLogState(_QT._ks)&&this.GetNodeStoppingState(_QT._ks)){this.SetNodeStoppingState(_QT._ks,false);}if(_QT._yq&&_QT._dK[_QT._yq]){this.DeleteNode(_QT,_QT._dK[_QT._yq]);this._kj.RemoveTreeNode(_QT._dK[_QT._yq]);_QT._yq=null;}if(this._kj._vd.RemoveStaleItems){this._kj._vd.RemoveStaleItems(_QT);}if(this._kj._vd.CreateMoreNode){var _8x=this._kj._vd.CreateMoreNode(_QT,_QT._v3);this.DrawNode(_8x);}_QT._ln=_QT._v3;}else if(_QT._ln==_QT._v3){if(this.GetNodeLogState(_QT._ks)&&this.GetNodeStoppingState(_QT._ks)){this.SetNodeStoppingState(_QT._ks,false);this.StepDrawChildren(0,null,_QT._ks);}else{for(var i in _QT._dK){if(!this.IsNodeDisplayed(_QT._dK[i])){this.DrawNode(_QT._dK[i]);}}if(_QT._yq&&!(this.IsNodeDisplayed(_QT._dK[_QT._yq]))){this.DrawNode(_QT._dK[_QT._yq]);}}}this.UpdateNode(_QT);}else{var _Cz=true;this.UpdateNode(_QT);this.DrawChildren(_QT,true,false,true);}}}};CUITreeView.prototype.ShowOtherNode=function(_QT,style){if(_QT._ly){var _Xa=_QT._dK[_QT._ly];var _6x=document.getElementById(_Xa._mO);if(_6x.style.display!=style){_6x.style.display=style;this.UpdateNode(_Xa);}}};CUITreeView.prototype.DrawBusyNode=function(_HH){var _AA=document.getElementById(_HH._mO);var _aeh=this._vm.cloneNode(false);_AA.appendChild(_aeh);var _FU=_HH._ta;for(var _Fd=1;_Fd<_FU+1;_Fd++){var _Cb=_aeh.appendChild(this._hS.cloneNode(false));this.updateLineImg(_Cb,_HH,_FU,_Fd);}_aeh.appendChild(this._hS.cloneNode(false)).src=this._vl.src;var _ah0=_aeh.appendChild(this._b2.cloneNode(false));_ah0.src=this._m5+"icon_loading.gif";var _Tb=_aeh.appendChild(this._tn.cloneNode(false));var _aBd=this._m4.appobj.oResources.GetString("IDS_LOADING");_Tb.appendChild(document.createTextNode(_aBd));};CUITreeView.prototype.CollapseNode=function(_QT,_SG){if(this._kj._vd.IsDrawingStoppable()&&(!this.GetNodeStoppingState(_QT._ks))){this.SetNodeStoppingState(_QT._ks,true);Utilities.RemoveObjXObjectArray(this._kj._vd._hQ,_QT._ks);}for(var i in _QT._dK){if(_QT._dK[i]._l1){this.unselectNode(_QT._dK[i]);}}_QT._uS=false;var _AA=document.getElementById(_QT._mO);_AA.lastChild.style.display="none";this.UpdateNode(_QT,_SG);};CUITreeView.prototype.UpdateNode=function(_QT,_SG){var _AA=this.m_doc.getElementById(_QT._mO);Debug.Assert(_AA);var _8p;var _ZY=_AA.childNodes.length;for(var i=0;i<_ZY;i++){_8p=_AA.childNodes[i];if(_8p.tagName=='IMG'){if(_8p.bIsExpand){this.updateExpandImg(_8p,_QT);}else if(_8p.bIsIcon){this.updateTypeImg(_8p,_QT);}}}var _Tb=_AA.getElementsByTagName('SPAN');this.updateLabel(_Tb[0],_QT,_SG);this.UpdateAdditionalNode(_QT,_QT._qE);this.UpdateAdditionalCtrlNode(_QT,_QT._qE);};CUITreeView.prototype.UpdateAdditionalNode=function(_QT,_HI){if(!CUIMetadataTree.CanHaveAdditionalNode(_QT)){return;}var _AA=this.m_doc.getElementById(_QT._mO);Debug.Assert(_AA);var _Tb=_AA.getElementsByTagName('SPAN');if(this._kj._vd.GetAdditionalNodeElement){var _Do=this._kj._vd.GetAdditionalNodeElement(_QT,_HI);if(_Do){_AA.replaceChild(_Do,_Tb[0].nextSibling);}}};CUITreeView.prototype.ClearAdditionalCtrlNode=function(_QT){if(!CUIMetadataTree.CanHaveAdditionalNode(_QT)){return;}var _AA=this.m_doc.getElementById(_QT._mO);Debug.Assert(_AA);var _Tb=_AA.getElementsByTagName('SPAN');_Tb[0].nextSibling.nextSibling.innerHTML="";};CUITreeView.prototype.UpdateAdditionalCtrlNode=function(_QT,_HI,_Im){if(!CUIMetadataTree.CanHaveAdditionalNode(_QT)){return;}var _AA=this.m_doc.getElementById(_QT._mO);Debug.Assert(_AA);var _Tb=_AA.getElementsByTagName('SPAN');if(!_Tb||!_Tb[0]||!_Tb[0].nextSibling||!_Tb[0].nextSibling.nextSibling)return;if(!_QT._uS){_Tb[0].nextSibling.nextSibling.innerHTML="";}else if(Utilities.GetObjArrayLength(_QT._dK)==_HI){_Tb[0].nextSibling.nextSibling.innerHTML="";}else if(_HI>0&&(_HI<_QT._ln)&&(_HI<Utilities.GetObjArrayLength(_QT._dK))){var _avX=this._kj._vd.GetAdditionalCtrlNodeElement(_QT,_HI,(this.GetNodeStoppingState(_QT._ks)),_Im);_AA.replaceChild(_avX,_Tb[0].nextSibling.nextSibling);}else if(_HI>=_QT._ln){_Tb[0].nextSibling.nextSibling.innerHTML="";}};CUITreeView.prototype.SyncScroller=function(){this._st.scrollTop=this._st.scrollHeight;};CUITreeView.prototype.FillChildrenLineImg=function(_QT,_FU){var _HB,_aFZ,_ao2,_ZS;var _ZY=Utilities.GetObjArrayLength(_QT._dK);for(var i=1;i<=_ZY;i++){_HB=Utilities.GetNthFromObjArray(_QT._dK,i);if(this.IsNodeDisplayed(_HB)){_aFZ=this.m_doc.getElementById(_HB._mO);Debug.Assert(_aFZ);_ao2=_HB._ta-_FU;_ZS=_aFZ.firstChild;while((--_ao2)>0){_ZS=_ZS.nextSibling;}_ZS.src=this._vi.src;}this.FillChildrenLineImg(_HB,_FU+1);}_HB=null;_aFZ=null;_ao2=null;_ZS=null;};CUITreeView.prototype.IsNodeDisplayed=function(_Eq){if(this.m_doc.getElementById(_Eq._mO)){return true;}return false;};CUITreeView.prototype.RemoveAllChildrenNodes=function(parentNode){for(var i in parentNode._dK){this.DeleteNode(parentNode,parentNode._dK[i]);}parentNode._qE=0;};CUITreeView.prototype.DeleteNode=function(parentNode,_Eq){var _AA=this.m_doc.getElementById(_Eq._mO);var _ayf=this.m_doc.getElementById(parentNode._mO);if(!_ayf){return;}if(_Eq._l1){this.unselectNode(_Eq,false);}if(_AA){Dom.RemoveAllChildren(_AA);Dom.RemoveObject(_AA);}var _ayp=false;for(var i in parentNode._dK){if(_Eq._mO!=parentNode._dK[i]._mO){_ayp=true;}break;}if(!_ayp){var _aFZ=Dom.GetImmediateChildByName(_ayf,"DIV");if(_aFZ){Dom.RemoveObject(_aFZ);}}return true;};CUITreeView.prototype.ToggleDisplay=function(parentNode,_Eq,_Iv){if(_Eq._l1){this.unselectNode(_Eq,false);}var _AA=this.m_doc.getElementById(_Eq._mO);var _ayf=this.m_doc.getElementById(parentNode._mO);if(_AA&&_AA.style.display!=_Iv){_AA.style.display=_Iv;var _ayp=false;for(var i in parentNode._dK){_ayp=true;break;}if(!_ayp){var _aFZ=Dom.GetImmediateChildByName(_ayf,"DIV");_aFZ.style.display=_Iv;}}return true;};CUITreeView.prototype.updateLineImg=function(_Cb,_Wa,_FU,_Fd){_Cb.src=this.getAncestor(_Wa,_FU-_Fd+1)._oW?this._vi.src:this._qW.src;};CUITreeView.prototype.updateExpandImg=function(_Gk,_Wa){var _akh=(_Wa._qR==null);var _aF9=_Wa._oW;var _ail=this._m5;var _afO="";if(_Wa._s5){if(_Wa._uS){_ail+=(_aF9?(_akh?"tv_Tminus_top.gif":"tv_Tminus.gif"):(_akh?"tv_Lminus_top.gif":"tv_Lminus.gif"));_afO=this._m4.appobj.oResources.GetString("IDS_TREE_NODE_COLLAPSE_ALT");}else{_ail=(_aF9?(_akh?this._jo.src:this._nm.src):(_akh?this._wz.src:this._eO.src));_afO=this._m4.appobj.oResources.GetString("IDS_TREE_NODE_EXPAND_ALT");}}else{_ail+=(_aF9?(_akh?"tv_T_top.gif":"tv_T.gif"):(_akh?"tv_L_top.gif":"tv_L.gif"));}_Gk.src=_ail;_Gk.alt=_afO;_Gk.title=_afO;};CUITreeView.prototype.updateIconImg=function(_yU,_Wa){if(_Wa._uS&&(!_Wa._lZ)){_yU.src=this._m5+this._x6;return;}};CUITreeView.prototype.updateTypeImg=function(_QR,_Wa){_QR.src=this._m5+_Wa.GetImgByType();_QR.style.display="inline";};CUITreeView.prototype.updateLabel=function(_Tb,_Wa,_SG){if(_SG){var _afO=Utilities.HtmlEncode(this._m4.appobj.oResources.GetString("MES_SERVER_ERROR_RETRY"));_Tb.firstChild.innerHTML="<img src='"+this._m5+"critical.gif' border='0' alt='"+_afO+"'>"+Utilities.HtmlEncode(_Wa._p8);}else{_Tb.firstChild.innerHTML=Utilities.HtmlEncode(_Wa._p8);}};CUITreeView.prototype.SetInsertWithChildrenChx=function(){if(Utilities.GetObjArrayLength(this._wI)>1){this._m4._jf.DisableIncludeDetailFlag();}else{this._m4._jf.EnableIncludeDetailFlag();}};CUITreeView.prototype.HandleBlur=function(){for(var i in this._wI){var _46=document.getElementById(this._wI[i]._mO);var _aGv=Dom.GetImmediateChildByName(_46,'SPAN');Debug.Assert(this._wI[i]._l1);if(this._wI[i]._l1){this.SetObjStyleByState(_aGv,CUITreeView.NodeBlurState);this._wI[i]._dh=true;}}};CUITreeView.prototype.SafeHandleMouseOver=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}this.oTreeView.HandleMouseOver(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUITreeView.prototype.HandleMouseOver=function(e){var _IJ=Dom.GetEventTarget(e);var _abZ=null;if(_IJ.parentNode&&_IJ.parentNode.bIsLabel&&_IJ.parentNode.parentNode.oTreeNode){var _QT=_IJ.parentNode.parentNode.oTreeNode;_abZ=_IJ.parentNode.parentNode;}else if((_IJ.bIsIcon)&&_IJ.parentNode.oTreeNode){var _QT=_IJ.parentNode.oTreeNode;_abZ=_IJ.parentNode;}if(this._db&&document.getElementById(this._db._mO)){var _46=document.getElementById(this._db._mO);var _aGv=Dom.GetImmediateChildByName(_46,'SPAN');if(this._db._dh){this.SetObjStyleByState(_aGv,CUITreeView.NodeBlurState);}else if(this._db._l1){this.SetObjStyleByState(_aGv,CUITreeView.NodeSelectedState);}else{if(this._db._bx){this.SetObjStyleByState(_aGv,CUITreeView.NodeClickableState);}else{this.SetObjStyleByState(_aGv,CUITreeView.NodeNormalState);}}}if(_QT){var _An=Dom.GetImmediateChildByName(_abZ,"SPAN");this._db=_QT;if(_QT._bx){this.SetObjStyleByState(_An,CUITreeView.ClickableNodeHoverState);}else{this.SetObjStyleByState(_An,CUITreeView.NodeHoverState);}}};CUITreeView.prototype.SafeHandleDBClick=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}this.oTreeView.HandleDBClick(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUITreeView.prototype.HandleDBClick=function(e){var _IJ=Dom.GetEventTarget(e);if(_IJ.parentNode&&_IJ.parentNode.bIsLabel&&_IJ.parentNode.parentNode.oTreeNode){var _QT=_IJ.parentNode.parentNode.oTreeNode;}else if((_IJ.bIsIcon||_IJ.bIsExpand)&&_IJ.parentNode.oTreeNode){var _QT=_IJ.parentNode.oTreeNode;}if(_QT&&(!_QT._vB)&&(_QT._lW!=ExpAPIXml.eRoot)){var _AA=document.getElementById(_QT._mO);this.ExpandCollapseNode(_AA);}};CUITreeView.prototype.SafeHandleMouseDown=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}this.oTreeView.HandleMouseDown(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUITreeView.prototype.HandleMouseDown=function(e){var _IJ=Dom.GetEventTarget(e);if(_IJ.parentNode&&_IJ.parentNode.bIsLabel&&_IJ.parentNode.parentNode.oTreeNode){var _QT=_IJ.parentNode.parentNode.oTreeNode;}else if((_IJ.bIsIcon||_IJ.bIsExpand)&&_IJ.parentNode.oTreeNode){var _QT=_IJ.parentNode.oTreeNode;}if(!_QT&&(!this.m_bIsMultiSelect||(!e.ctrlKey&&!e.shiftKey))){this.ClearSelections();}else if(_QT&&(!_QT._vB)){if(_IJ.bIsExpand&&Dom.IsLeftButton(e)){this.ExpandCollapseNode(_IJ.parentNode);}else if(_IJ.parentNode.bIsLabel||_IJ.bIsIcon){if(this.selectNode(_QT,e)){CUIDragDropSource.HandleMouseDown(e,_IJ,this,null,_QT._j4);}}}};CUITreeView.prototype.OnDragStart=function(e){this._yn=true;var _4L=null;for(var i in this._wI){_4L=this._wI[i];break;}if(!_4L){return;}else if(this._kj._vd.OnTreeDragStart){this._kj._vd.OnTreeDragStart(e);}};CUITreeView.prototype.OnDragEnd=function(e){if(!this._yn){if(this.oOrgEvt&&!this.oOrgEvt.shiftKey){if(this.oOrgEvt.ctrlKey){this.unselectNode(this.oClkNode);}else{this.ClearSelections(true);this.selectNode(this.oClkNode,this.oOrgEvt);}}}this._yn=false;this.oOrgEvt=null;if(this._kj._vd.OnTreeDragEnd){this._kj._vd.OnTreeDragEnd();}};CUITreeView.prototype.SafeHandleContextMenu=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}this.oTreeView.HandleContextMenu(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUITreeView.prototype.HandleContextMenu=function(e){var _IJ=Dom.GetEventTarget(e);if(_IJ.parentNode&&_IJ.parentNode.bIsLabel&&_IJ.parentNode.parentNode.oTreeNode){var _QT=_IJ.parentNode.parentNode.oTreeNode;}else if((_IJ.bIsIcon)&&_IJ.parentNode.oTreeNode){var _QT=_IJ.parentNode.oTreeNode;}if(_QT){if(Utilities.MethodInObject(this._kj._vd,'ShowContextMenu')){this._kj._vd.ShowContextMenu(e,_QT);}}};CUITreeView.prototype.ShowCancel=function(_AA,_Eq,_ST,_Je){Debug.Assert(_AA);var _aDd=_AA.lastChild;var _Tb=_aDd.getElementsByTagName('SPAN');Debug.Assert(_Tb);if(_Tb&&_Tb[0]){var _S3=_Eq._oa;var _Ke=this._m4.appobj.appname;var _afj=document.getElementById("Cancel"+_S3);if(!_afj){var _auw=document.createElement('A');var _UA=new Array(_Ke,_S3);if(_ST&&_Je){_UA.push(Utilities.RemoveControlChars(_ST));_UA.push(Utilities.RemoveControlChars(_Je));}_Xf=Utilities.GenerateCallback(COTLoadingAgent.SafeDoCancelRequest,_UA);var _aut=this._m4.appobj.oResources.GetString('IDS_WORKSHEET_CANCEL_REQUEST');_auw=COTInputElementFactory.CreateLink(_Xf,_aut,false,"link");_auw.id="Cancel"+_S3;_Tb[0].appendChild(_auw);}else{_afj.onclick=Utilities.GenerateCallback(COTLoadingAgent.SafeDoCancelRequest,[_Ke,_S3,_ST,_Je]);}}};CUITreeView.prototype.SetStateToBlocked=function(){this._qU=true;};CUITreeView.prototype.FreeTheTree=function(){this._qU=false;};CUITreeView.prototype.IsBlocked=function(){return this._qU;};function CUIDragDrop(){};CUIDragDrop.eEffectNone=0;CUIDragDrop.eEffectCopy=1;CUIDragDrop.eEffectMove=2;CUIDragDrop.eStateEnter=1;CUIDragDrop.eStateOver=2;CUIDragDrop.eStateLeave=3;CUIDragDrop.eStateDraging=0;CUIDragDrop.eLocationNone=0;CUIDragDrop.eLocationBefore=1;CUIDragDrop.eLocationInside=2;CUIDragDrop.eLocationAfter=4;CUIDragDrop.eLocationBeforeOrAfter=5;CUIDragDrop.rightMouseDown=2;CUIDragDrop.leftMouseDown=1;CUIDragDrop.Start=function(_G7,_By,_AI,_FS,e){this.m_eAllowableSourceEffects=_FS?_FS:this.eEffectCopy;this.m_eCurrentEffect=this.eEffectNone;this.m_nData=_AI;if(_By.OnDragStart&&_By.OnDragStart(e,this.m_nData,this.m_eAllowableSourceEffects)){this.eStateDraging=1;var _BA=document;_BA.onmousemove=Utilities.EventCallback(this.OnDragOver,[],this,false,true);_BA.onmouseup=CUIDragDrop.SafeHandleMouseUp;_BA.onmouseover=Utilities.EventCallback(this.OnDragOver,[],this,false,true);_BA.onmouseout=Utilities.EventCallback(this.OnDragOver,[],this,false,true);if(!_o.is_ie5_5up){var _aDZ=CUIDragDropSource.bIsLastMouseDragOnLeft;}else{var _aDZ=Dom.IsLeftButton(e);}if(_aDZ){this.m_iMouseButtonDown=CUIDragDrop.leftMouseDown;}else{this.m_iMouseButtonDown=CUIDragDrop.rightMouseDown;}this.m_oSrcListener=_G7;this.m_oDestListener=_By;this.m_imgCursorNoDrop=_BA.getElementById("id_no_drop_cursor");this.m_imgCursorCopy=_BA.getElementById("id_copy_cursor");this.m_imgCursorMove=_BA.getElementById("id_move_cursor");return true;}this.m_nData=null;return false;};CUIDragDrop.Stop=function(){this.eStateDraging=0;this.onLoseCapture();};CUIDragDrop.IsDragging=function(){return this.eStateDraging;};CUIDragDrop.setEffect=function(_zY){this.m_eCurrentEffect=_zY;var _ain;switch(_zY){case this.eEffectCopy:_ain=this.m_imgCursorCopy;this.m_imgCursorMove.style.visibility="hidden";this.m_imgCursorNoDrop.style.visibility="hidden";break;case this.eEffectMove:_ain=this.m_imgCursorMove;this.m_imgCursorCopy.style.visibility="hidden";this.m_imgCursorNoDrop.style.visibility="hidden";break;case this.eEffectNone:_ain=this.m_imgCursorNoDrop;this.m_imgCursorCopy.style.visibility="hidden";this.m_imgCursorMove.style.visibility="hidden";break;}this.m_imgCursor=_ain;this.m_imgCursor.style.visibility="visible";};CUIDragDrop.GetTooltipContainer=function(){if(!this._t8){this._t8=document.body.appendChild(document.createElement('DIV'));var _zr=this._t8.appendChild(document.createElement('TABLE'));_zr.className="tooltipTable";var _RK=_zr.appendChild(document.createElement('TBODY'));this._xS=_RK;this._t8.className="clsDragTooltip";}return this._t8;};CUIDragDrop.SetTooltipItems=function(_QX,_Bu){if(!this._xS){this.GetTooltipContainer();}else{Dom.RemoveAllChildren(this._xS);}for(var i=0;i<_Bu.length;i++){var _NH=this._xS.appendChild(document.createElement('TR'));if(_QX&&_QX[i]){var _aFT=_NH.appendChild(document.createElement('TD'));var _afT=_aFT.appendChild(document.createElement('IMG'));_afT.src=Utilities.IMG_PATH+_QX[i];}var _abc=_NH.appendChild(document.createElement('TD'));_abc.appendChild(document.createTextNode(_Bu[i]));this._fh=true;}};CUIDragDrop.ShowTooltip=function(x,y){this._t8.className="clsDragTooltipVisible";this._t8.style.left=(x+30)+"px";this._t8.style.top=(y)+"px";};CUIDragDrop.SetCursorImgPosition=function(x,y){this.m_imgCursor.style.visibility="visible";this.m_imgCursor.style.left=x+document.documentElement.scrollLeft+7+'px';this.m_imgCursor.style.top=y+document.documentElement.scrollTop+17+'px';this.m_imgCursor.style.zIndex=200;;if(this._fh){this.ShowTooltip(x,y);}};CUIDragDrop.onLoseCapture=function(){this.m_oSrcListener=null;this.m_oDestListener=null;if(this.m_nData instanceof Array){Utilities.DeleteAllFromArray(this.m_nData);}this.m_nData=null;this._fh=false;if(this._t8){this._t8.className="clsDragTooltip";}var _BA=document;_BA.onmousemove=null;_BA.onmouseover=null;_BA.onmouseout=null;_BA.onmouseup=null;_BA.onkeyup=null;_BA.body.onlosecapture=null;if(this.m_imgCursor){this.m_imgCursor.style.visibility="hidden";}return true;};CUIDragDrop.onDragOver=function(e){e=e||window.event;if(this.m_oDestListener.OnDragOver){var _0O=this.m_oDestListener.OnDragOver(e,this.m_nData,this.m_eAllowableSourceEffects);var _zY=this.eEffectNone;if(_0O){if(_0O&this.eEffectMove){if(e.ctrlKey&&(_0O&this.eEffectCopy)){_zY=this.eEffectCopy;}else{_zY=this.eEffectMove;}}else if(_0O&this.eEffectCopy){_zY=this.eEffectCopy;}}this.setEffect(_zY);}if(this.m_imgCursor){this.SetCursorImgPosition(e.clientX,e.clientY);}};CUIDragDrop.SafeHandleMouseUp=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/CUIDragDrop.onMouseUp(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIDragDrop.onMouseUp=function(e){e=e||window.event;var _axU=Dom.IsLeftButton(e)?CUIDragDrop.leftMouseDown:CUIDragDrop.rightMouseDown;if(_axU==this.m_iMouseButtonDown||this.m_iMouseButtonDown==CUIDragDrop.rightMouseDown){if(this.m_oDestListener&&this.m_oDestListener.OnDragDrop){var _zY=this.m_oDestListener.OnDragDrop(e);if(this.m_imgCursor){this.m_imgCursor.style.visibility="hidden";this.m_imgCursor.style.zIndex=-1;}if(this.m_oSrcListener&&this.m_oSrcListener.OnDragComplete){this.m_oSrcListener.OnDragComplete();}}CUIDragDrop.Stop();}return true;};function CUIDragDropSource(){};CUIDragDropSource.HandleMouseDown=function(e,_IJ,_A2,id,_Kd){CUIDragDropSource.oSource=_A2;CUIDragDropSource.id=id;if(_Kd==null){var _Kd=true;}CUIDragDropSource.bIsDraggable=_Kd;Dom.PreventDefault(e);if(_o.is_ie5_5up&&_IJ.setCapture){_IJ.setCapture();_IJ.onlosecapture=CUIDragDropSource.SafeDoResetEventHandlers;_IJ.onmouseup=CUIDragDropSource.SafeHandleMouseUp;_IJ.onmousemove=CUIDragDropSource.SafeOnDetectDragMouseMove;}else{window.captureEvents(Event.MouseMove|Event.MouseUp);window.onmouseup=CUIDragDropSource.SafeDoResetEventHandlers;window.onmousemove=CUIDragDropSource.SafeOnDetectDragMouseMove;}if(!_o.is_ie5_5up){CUIDragDropSource.bIsLastMouseDragOnLeft=Dom.IsLeftButton(e)?true:false;}CUIDragDropSource._tc=e.clientX;CUIDragDropSource._td=e.clientY;};CUIDragDropSource.SafeDoResetEventHandlers=function(e){try{if(!e){var e=window.event;}if(window.releaseEvents){window.onmouseup=null;window.onmousemove=null;window.releaseEvents(Event.MouseMove|Event.MouseUp);}else{this.onmousemove=null;this.onmouseup=null;}if(CUIDragDropSource.oSource&&CUIDragDropSource.oSource.OnDragEnd){CUIDragDropSource.oSource.OnDragEnd();delete CUIDragDropSource.oSource;}}catch(excep){_f.HandleException(excep);}};CUIDragDropSource.SafeHandleMouseUp=function(e){try{if(this.releaseCapture){this.releaseCapture();}else{window.releaseEvents(Event.MouseMove);window.onmousemove=null;window.releaseEvents(Event.MouseUp);window.onmouseup=null;}}catch(e){_f.HandleException(e);}};CUIDragDropSource.SafeOnDetectDragMouseMove=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}if((Math.abs(CUIDragDropSource._tc-e.clientX)>3)||(Math.abs(CUIDragDropSource._td-e.clientY)>3)){if(!CUIDragDropSource.bIsDraggable){if(this.dragDrop){this.ondrag=Dom.CancelBubble;this.dragDrop();}}else{if(CUIDragDropSource.oSource){Debug.Assert(CUIDragDropSource.oSource.OnDragStart);CUIDragDropSource.oSource.OnDragStart(e,CUIDragDropSource.id);}}CUIDragDropSource.SafeDoResetEventHandlers(e);if(this.releaseCapture){this.releaseCapture();}else{window.releaseEvents(Event.MouseMove);window.onmousemove=null;window.releaseEvents(Event.MouseUp);window.onmouseup=null;}}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};function CUIDragDropData(){this.bDelete=false;this.sId=null;this.sBlockId=null;this.sMemId=null;this.sLevId=null;this.aMemberIds=null;this.aOtherMemIds=null;this.sFilterId=null;this.bInsertWithChildren=null;this.sCustomSetId=null;this.sNamedSetId=null;this.kAction=null;this.aDeleteActions=new Array();this.kPosition=null;this.kPopulation=null;this.sTargetBlock=null;this.sTargetAxis=null;};CUIDragDropData.prototype.GetRealMembers=function(_RJ){var _C9=null;if(this.aMemberIds){_C9=new Array();for(var i=0;this.aMemberIds&&i<this.aMemberIds.length;i++){if(_RJ.GetMember(this.aMemberIds[i])){_C9.push(this.aMemberIds[i]);}}}return _C9;};CUIDragDropData.prototype.GetDimId=function(_RJ,_Li){if(this.sMemId){return _RJ.GetData(this.sMemId).GetDimId();}return "";};CUIDragDropData.prototype.GetHierOrDimId=function(_RJ,_Li){if(this.sMemId){var _25=_RJ.GetData(this.sMemId).GetHierId();if(_25==null||_25==""){_25=this.GetDimId(_RJ,_Li);}return _25;}return "";};function CUIDragDropMember(_BX,_D4){this.base=CUIDragDropData;this.base();this.sId=_BX;this.sMemId=_BX;this.bInsertWithChildren=_D4;this.aOrphanAncestor=null;};CUIDragDropMember.prototype=new CUIDragDropData;CUIDragDropMember.prototype.GetDataType=function(_RJ){if(_RJ.GetMember(this.sId)){return ExpAPIXml.eMember;}else if(_RJ.GetMeasure(this.sId)){return ExpAPIXml.eMeasure;}return null;};CUIDragDropMember.prototype.SetOrphanAncestorArr=function(_Rv){this.aOrphanAncestor=_Rv;};CUIDragDropMember.prototype.GetOrphanAncestorArr=function(){return this.aOrphanAncestor;};function CUIDragDropMemberList(_C9,_D4){this.base=CUIDragDropData;this.base();this.aMemberIds=_C9;this.sMemId=_C9[0];this.sId=this.sMemId;this.aOtherMemIds=_C9.slice(1);this.bInsertWithChildren=_D4;this.aOrphanAncestor=null;};CUIDragDropMemberList.prototype=new CUIDragDropData;CUIDragDropMemberList.prototype.GetDataType=function(_RJ){if(_RJ.GetMember(this.sId)){return ExpAPIXml.eMember;}else if(_RJ.GetMeasure(this.sId)){return ExpAPIXml.eMeasure;}return null;};CUIDragDropMemberList.prototype.SetOrphanAncestorArr=function(_Rv){this.aOrphanAncestor=_Rv;};CUIDragDropMemberList.prototype.GetOrphanAncestorArr=function(){return this.aOrphanAncestor;};function CUIDragDropCustomSet(_CJ,_y2,_BX,_C9){this.base=CUIDragDropData;this.base();this.sCustomSetId=_CJ;this.sId=_CJ;this.sLevId=_y2;this.sMemId=_BX;this.aMemberIds=_C9;};CUIDragDropCustomSet.prototype=new CUIDragDropData;CUIDragDropCustomSet.prototype.GetDataType=function(_RJ){return ExpAPIXml.eCustomSet;};CUIDragDropCustomSet.prototype.GetDimId=function(_RJ){var _aC2=_RJ.datamanager._kX.GetCustomSet(this.sCustomSetId);return _aC2.GetDimId();};function CUIDragDropNamedSet(_WC,_TW,_B8){this.base=CUIDragDropData;this.base();this.sNamedSetId=_WC;this.sId=_WC;this.sMemId=_WC;this.sDimId=_TW;this.sHierId=_B8;};CUIDragDropNamedSet.prototype=new CUIDragDropData;CUIDragDropNamedSet.prototype.GetDataType=function(_RJ){return ExpAPIXml.eNamedSet;};CUIDragDropNamedSet.prototype.GetDimId=function(){return this.sDimId;};CUIDragDropNamedSet.prototype.GetHierOrDimId=function(){return this.sHierId;};function CUIDragDropLevel(_Od,_y2){this.base=CUIDragDropData;this.base();this.sLevId=_y2;this.sId=_Od;this.sMemId=_Od;};CUIDragDropLevel.prototype=new CUIDragDropData;CUIDragDropLevel.prototype.GetDataType=function(_RJ){return ExpAPIXml.kLevel;};function CUIDragDropLevelOnly(_y2){this.base=CUIDragDropData;this.base();this.sId=_y2;};CUIDragDropLevelOnly.prototype=new CUIDragDropData;CUIDragDropLevelOnly.prototype.GetDataType=function(_RJ){return ExpAPIXml.kLevel;};function CUIDragDropProperty(_O5){this.base=CUIDragDropData;this.base();this.sId=_O5;};CUIDragDropProperty.prototype=new CUIDragDropData;CUIDragDropProperty.prototype.GetDataType=function(){return ExpAPIXml.kEleProperty;};function CUIDragDropBlock(_L7,_BX,_AJ){this.base=CUIDragDropData;this.base();this.sBlockId=_L7;this.sMemId=_BX;this.bDelete=_AJ;this.bInsertWithChildren=true;this.sId=_BX;};CUIDragDropBlock.prototype=new CUIDragDropData;CUIDragDropBlock.prototype.GetDataType=function(_RJ){return ExpAPIXml.kBlock;};CUIDragDropBlock.prototype.GetDimId=function(_RJ,_Li){var _FK=_Li.GetBlock(this.sBlockId);return _FK.GetDimId();};function CUIDragDropMemListBlock(_L7,_J5,_AJ){this.base=CUIDragDropData;this.base();this.sBlockId=_L7;this.aMemberIds=_J5;this.sMemId=_J5[0];this.aOtherMemIds=_J5.slice(1);this.bDelete=_AJ;this.bInsertWithChildren=false;this.sId=this.sMemId;};CUIDragDropMemListBlock.prototype=new CUIDragDropBlock;function CUIDragDropLevelBlock(_L7,_BX,_y2){this.base=CUIDragDropData;this.base();this.sBlockId=_L7;this.bDelete=true;this.sMemId=_BX;this.sLevId=_y2;this.sId=_BX;};CUIDragDropLevelBlock.prototype=new CUIDragDropBlock;function CUIDragDropDimFilter(_DR,_BX,_AJ){this.base=CUIDragDropData;this.base();this.sFilterId=_DR;this.sMemId=_BX;this.bDelete=_AJ;this.bInsertWithChildren=true;this.sId=_BX;};CUIDragDropDimFilter.prototype=new CUIDragDropData;CUIDragDropDimFilter.prototype.GetDataType=function(_RJ){return ExpAPIXml.kEleFilter;};function CUIDragDropOrListFilter(_DR,_J5,_AJ){this.base=CUIDragDropData;this.base();this.sFilterId=_DR;this.bDelete=_AJ;this.aMemberIds=_J5;this.sMemId=_J5[0];this.aOtherMemIds=_J5.slice(1);this.bInsertWithChildren=false;this.sId=this.sMemId;};CUIDragDropOrListFilter.prototype=new CUIDragDropData;CUIDragDropOrListFilter.prototype.GetDataType=function(_RJ){return ExpAPIXml.kEleFilter;};function COTTreeVO(_S0){this._vd=_S0;this._vp=null;this._nl=new Object();this._si=new Array();};COTTreeVO.prototype.SetTreeRoot=function(_K1){this._vp=_K1;if(!this._nl[_K1._oa]){this._nl[_K1._oa]=_K1;}};COTTreeVO.prototype.AddTreeNode=function(_QT){this._nl[_QT._oa]=_QT;if(_QT._qR){this.SetSibling(_QT,_QT._qR);_QT._qR.AddToOrderedChildIdArray(_QT._oa);}};COTTreeVO.prototype.GetNode=function(id){return this._nl[id];};COTTreeVO.prototype.RemoveTreeNode=function(_QT){Utilities.RemoveObjXObjectArray(_QT._qR._dK,_QT._oa);if((!_QT._oW)&&(_QT._lZ)){_QT._lx._oW=false;_QT._qR._rf=_QT._lx;}else if((_QT._oW)&&(_QT._lZ)){_QT._lx._cy=_QT._cy;_QT._cy._lx=_QT._lx;}Utilities.RemoveObjXObjectArray(this._nl,_QT._oa);if(_QT._qR){var _PQ=Utilities.GetObjIndex(_QT._qR._g1,_QT._ks);Utilities.DeleteNthFromArray(_QT._qR._g1,_PQ);}_QT.Clear();};COTTreeVO.prototype.RemoveChildrenNodes=function(_QT){for(var i in _QT._dK){_QT._dK[i].Clear();Utilities.RemoveObjXObjectArray(this._nl,_QT._dK[i]);delete _QT._dK[i];}_QT._dK=new Object();Utilities.DeleteAllFromArray(_QT._g1);_QT._g1=new Array();_QT._yq=null;_QT._ly=null;};COTTreeVO.prototype.SetSibling=function(_QT,parentNode){parentNode._dK[_QT._oa]=_QT;if(parentNode._ly&&_QT._ks!=parentNode._ly&&_QT._lW!=ExpAPIXml.eMore){_QT._lx=parentNode._rf._lx;_QT._lx._cy=_QT;_QT._cy=parentNode._rf;_QT._lZ=true;_QT._oW=true;parentNode._rf._lx=_QT;}else{if(!parentNode._rf){parentNode._rf=_QT;}else{parentNode._rf._oW=true;_QT._lx=parentNode._rf;_QT._lx._cy=_QT;_QT._lZ=true;parentNode._rf=_QT;}}};COTTreeVO.prototype.GetAncestorNodes=function(_LF){var _F7=new Array();var _Ky=_LF._qR;while(_Ky){_F7.push(_Ky);_Ky=_Ky._qR;}return _F7;};function COTTreeNode(_zx,_C7,_Ic,_CL,parent,_Nz,_y6){this._lW=_zx;this._ks=_C7;this._p8=_Ic;this._oa=_CL;this._dK=new Object();this._g1=new Array();this._ta=0;this._lZ=false;this._oW=false;if(parent){this._qR=parent;this._ta=parent._ta+1;}if(_y6){this._pL=_y6;}this._qq=false;this._k4=false;this._s5=false;this._uS=false;this._nv=false;this._mO=CUITreeView.invalidHtmlId;this._vB=false;var _Td=ExpAPIXml.defaultMaxChildNum;this._xq=false;if(this._qR&&this._qR._xq){_Td=this._qR._v3;this._xq=true;}this._ln=_Td;this._v3=_Td;this._j4=true;this._c0=true;this._l1=false;if(_Nz){this._bx=true;this._x4=_Nz;}this._qE=0;};COTTreeNode.prototype.ModifyLabel=function(_KG){this._p8=_KG;};COTTreeNode.prototype.GetLabel=function(){return this._p8;};COTTreeNode.prototype.ModifyToolTip=function(_KG){this._pL=_KG;};COTTreeNode.prototype.AddToOrderedChildIdArray=function(id){this._g1[this._g1.length]=id;};COTTreeNode.prototype.GetCurrentMaxNum=function(){return this._ln;};COTTreeNode.prototype.SetCurrentMaxNum=function(_Td){this._ln=_Td;};COTTreeNode.prototype.GetImgByType=function(){var nodeType=this._lW;var _4V="";switch(nodeType){case ExpAPIXml.eRoot:_4V="Package.gif";break;case ExpAPIXml.eMeasureRoot:_4V="measure_dimension.gif";break;case ExpAPIXml.eMeasure:_4V="measure.gif";break;case CUIMeasure.kNonAggreMeasure:_4V="Non-aggregated_measure.gif";break;case ExpAPIXml.eMore:_4V="icon_more.gif";break;case ExpAPIXml.eSearch:_4V="search.gif";break;case ExpAPIXml.eDimRoot:_4V="Top_member_node.gif";break;case ExpAPIXml.eInsertableObjects:_4V="Analysis_Items.gif";break;case ExpAPIXml.eNamedSet:case ExpAPIXml.eNamedSetFolderObj:_4V="named_set.gif";break;case ExpAPIXml.eCustomSet:_4V="Custom_set.gif";break;case ExpAPIXml.eOtherAnalysis:_4V="other_analysis.GIF";break;case ExpAPIXml.eCMFMPackage:_4V="icon_package.gif";break;case ExpAPIXml.eDim:case ExpAPIXml.eCustomSets:case ExpAPIXml.eNamedSets:case ExpAPIXml.eHierarchy:case ExpAPIXml.eFolder:case ExpAPIXml.eAnalysisLib:case ExpAPIXml.eMeasureFolder:case ExpAPIXml.eCMRegularFolder:case ExpAPIXml.eNamespace:if(this._uS){_4V="tv_folder_expanded.gif";}else{_4V="tv_folder.gif";}break;case ExpAPIXml.eOther:_4V="retrieved_items.gif";break;default:_4V="member.gif";break;}return _4V;};COTTreeNode.prototype.Clear=function(){Utilities.RemoveAllChildObjects(this);};function COTPropertyPair(_BM,_Af,_zk,_Oz){this.sLabel=_BM;this.sValue=_Af;this.sLabelTooltip=(_zk!=null)?_zk:_BM;this.sValueTooltip=(_Oz!=null)?_Oz:_Af;this.bSupportsContextMenu=false;};function COTDraggablePair(_BM,_Af,_Gm,_Lx,_zk,_Oz){this.base=COTPropertyPair;this.base(_BM,_Af,_zk,_Oz);this.sIcon=_Gm;this.sId=_Lx;};COTDraggablePair.prototype=new COTPropertyPair;function COTLoadingPair(_BM,_Af,_Gm,_Lx,_zk,_Oz){this.base=COTPropertyPair;this.base(_BM,_Af,_zk,_Oz);this.sIcon=_Gm;this.sId=_Lx;};COTLoadingPair.prototype=new COTPropertyPair;COTDropDownPair.kArrowHeight=12;COTDropDownPair.kArrowWidth=11;function COTDropDownPair(_Ke,_BM,_Af,_zk,_A5,_S9,_OJ){this.base=COTPropertyPair;this.base(_BM,_Af,_zk);this._fi='prop_dropdown_arrow';this._wt='ComboBoxArrow.gif';this._p1=_A5;this._wm=_S9;this._jd=_OJ;this._gC=_Ke;};COTDropDownPair.prototype=new COTPropertyPair;COTDropDownPair.prototype.DrawDropDownArrow=function(_EP){var _azP=document.createElement('IMG');_azP.className=this._fi;_EP.appendChild(_azP);_azP.src=Utilities.IMG_PATH+this._wt;_azP.onclick=Utilities.EventCallback(this.HandleClick,[],this);COTStyle.SetSize(_azP,COTDropDownPair.kArrowWidth,COTDropDownPair.kArrowHeight);return _azP;};COTDropDownPair.prototype.HandleClick=function(e,el){var _Qb=Dom.GetRelativeOffset(el,document.body);var x=_Qb.iLeft+COTStyle.GetDisplayOffsetWidth(el);var y=_Qb.iTop+COTStyle.GetDisplayOffsetHeight(el);this.ShowDropDown(e,x,y);};COTDropDownPair.prototype.ShowDropDown=function(e,x,y){var _Kk=new CUIContextMenu(this._gC,0,this);_Kk.SetUnloadOnHide(true);for(var i=0;i<this._p1.length;i++){var _PM=new ContextItem("",this._p1[i],this._wm[i],false,this._jd[i],_Kk);}_Kk.SetChildrenComplete();_Kk.display(e,true,x,y);};function COTLoadingAgent(_V1,_Of,_Q4){this._cJ=_V1;this._gc=false;this._ee=ExpAPIXml.rUnknown;this._kj=_Of;this._kj._si[this._kj._si.length]=this;this.oUITree=_Q4;};COTLoadingAgent.IncompleteChildren=0;COTLoadingAgent.CompleteChildren=1;COTLoadingAgent.prototype.FireOnPopulateChildren=function(){if(Utilities.MethodInObject(this._kj._vd,'FetchChildren')){if(this._kj._vd.FetchChildren(this._cJ)){this.StartAsyncLoad();}}};COTLoadingAgent.prototype.StartAsyncLoad=function(){this._cJ._vB=true;this.oUITree.UpdateNode(this._cJ);this.oUITree.DrawChildren(this._cJ);};COTLoadingAgent.prototype.EndAsyncLoad=function(_BN){this._cJ._vB=false;var _AA=document.getElementById(this._cJ._mO);this._cJ._de=false;_AA.lastChild.innerHTML="";if(this._gc){this._cJ._uS=this._cJ._s5?true:false;var _Cz=true;this.oUITree.UpdateNode(this._cJ);this.oUITree.DrawChildren(this._cJ,_Cz,false,true);}else if(_BN){Dom.RemoveObject(_AA.lastChild);this.oUITree.CollapseNode(this._cJ);}else{Dom.RemoveObject(_AA.lastChild);var _SG=true;this.oUITree.CollapseNode(this._cJ,_SG);}};COTLoadingAgent.prototype.SetLoadingCancelable=function(){var _AA=document.getElementById(this._cJ._mO);this.oUITree.ShowCancel(_AA,this._cJ);};COTLoadingAgent.SafeDoCancelRequest=function(_Ke,_Me,_ST,_Je){try{var _Eq=FindApp(_Ke).uiManager._qi._hA._nl[_Me];if(_Eq._x8){_Eq._x8.CancelCurrentRequest(_ST,_Je);}}catch(e){_f.HandleException(e);}};COTLoadingAgent.prototype.CancelCurrentRequest=function(_ST,_Je){var _azr=this.oUITree._m4._qi._ob.GetData(this._cJ._ks);this.oUITree._m4.appobj.commManager.CancelRequest(_azr,null,_ST,_Je);this.EndAsyncLoad(true);this._cJ.bCancelled=true;};CUIContextMenu.iIconSize=16;CUIContextMenu.iHeight=400;CUIContextMenu.iMaxItems=10;CUIContextMenu.mouseOverTimeoutId=null;CUIContextMenu.mouseOverTimeoutEvt=null;function CUIContextMenu(_Ke,_E1,oOwner,_Hn,_UG){this.oDiv=document.createElement('DIV');this.oDiv.id="context_menu_"+Utilities.GenerateId();this.oDiv.className=Dom.GetStyleByBrowser('contextMenu_body');document.body.appendChild(this.oDiv);this.appObj=FindApp(_Ke);Dom.SetObjRef(this.oDiv,this,'oContextMenu');this._dl=_E1;this.oOwner=oOwner;this.bExclusiveCheckMenu=_UG;this.items=new Array();CUIContextMenu.MenuArr[CUIContextMenu.MenuArr.length]=this;this.bHasSubMenu=false;this.m_doc=document;this._xW=_Hn;this._rp=this.m_doc.createElement("IMG");this._rp.src=Utilities.IMG_PATH+"arrow.gif";this._rp.className="contextMenu_submenu_img";if(!CUIContextMenu._md){this.appObj.uiManager.Subscribe(this,ExpEvent.kCUIManager_Unload);CUIContextMenu._md=true;}this._qm=false;this.oDiv.style.visibility='hidden';this._oO=false;};CUIContextMenu.prototype.SetUnloadOnHide=function(_RR){this._oO=_RR;};CUIContextMenu.prototype.RemoveItem=function(_PQ){this.items.splice(_PQ,1);};CUIContextMenu.prototype.GetItemsByText=function(_F3){var _aBl=new Array();for(var i=0;i<this.items.length;i++){if(this.items[i]._ny==_F3){_aBl.push(this.items[i]);}}return _aBl;};CUIContextMenu.prototype.GetItemById=function(_Lx){for(var i=0;i<this.items.length;i++){if(this.items[i].id==_Lx){return this.items[i];}}return null;};CUIContextMenu.HideVisibleMenu=function(){for(var i=0;i<CUIContextMenu.MenuArr.length;i++){if(CUIContextMenu.MenuArr[i].IsVisible()&&CUIContextMenu.MenuArr[i]._dl==0){CUIContextMenu.MenuArr[i].hideMenuAndChildren();break;}}};CUIContextMenu.IsVisible=function(){for(var i=0;i<CUIContextMenu.MenuArr.length;i++){if(CUIContextMenu.MenuArr[i].IsVisible()&&CUIContextMenu.MenuArr[i]._dl==0){return true;}}return false;};CUIContextMenu.prototype.IsVisible=function(id){if(this.oDiv&&COTStyle.IsVisible(this.oDiv)){return true;}else{return false;}};CUIContextMenu.prototype.SetChildrenComplete=function(){this._qm=true;};CUIContextMenu.prototype.SetAllItemsState=function(_Ss){for(var i=0;i<this.items.length;i++){this.items[i]._eY=_Ss;}};CUIContextMenu.prototype.GetCheckedItem=function(){for(var i=0;i<this.items.length;i++){if(this.items[i].bChecked){return this.items[i];}}return null;};CUIContextMenu.prototype.GetCheckedItems=function(){var _awN=new Array();for(var i=0;i<this.items.length;i++){if(this.items[i].bChecked){_awN.push(this.items[i]);}}return _awN;};CUIContextMenu.prototype.ClearAllChecks=function(){for(var i=0;i<this.items.length;i++){if(this.items[i].SetChecked){this.items[i].SetChecked(false);}}};CUIContextMenu.MenuArr=new Array();CUIContextMenu.prototype.showPopup=function(){this.oDiv.style.visibility="visible";window.oLastActiveContextMenu=this;if(this._dl==0){window.oLastActiveTopLevelMenu=this;}};CUIContextMenu.prototype.display=function(e,_IG,x,y,_I7){Dom.RemoveAllChildren(this.oDiv);if(_I7){this._xW=_I7;}if(this._dl>0){CUIContextMenu.SafeDoHidePopupMenu(e,this._dl-1);Debug.Assert(this._xW);}else if(window.oLastActiveTopLevelMenu&&window.oLastActiveTopLevelMenu!=this){window.oLastActiveTopLevelMenu.hideMenus();}if(!this.items||this.items.length==0){if(this._xW){this._xW.RemoveSubMenu();}return;}Debug.Assert(e);if(!_IG)var _IG=false;this.bDropDown=_IG;this.populateItems();if(this.fixSize()){this.fixPos(e,x,y);var _TM=COTStyle.GetPosition(this.oDiv,'top');var _P6=COTStyle.GetPosition(this.oDiv,'left');var _T6=COTStyle.GetDisplayOffsetHeight(this.oDiv);var _F4=COTStyle.GetDisplayOffsetWidth(this.oDiv);this.oRect=new COTRect(_P6,_TM,_P6+_F4,_TM+_T6);if(e.type!="mouseup"){Dom.CancelEvent(e);}if(this._dl==0||(this._xW&&this._xW._p5.IsVisible())){this.setEventHandlers(e);this.showPopup();}}};CUIContextMenu.prototype.setEventHandlers=function(e){this.oDiv.onmousedown=ContextItem.SafeHandleMouseDown;this.oDiv.onmouseup=ContextItem.SafeHandleMouseUp;this.oDiv.onmouseover=ContextItem.SafeHandleMouseOver;this.oDiv.onmouseout=ContextItem.SafeHandleMouseOut;this.oDiv.onclick=CUIContextMenu.SafeHandleClick;this.oDiv.oncontextmenu=Dom.PreventDefault;this.SetFocusHandlers();CUIManager.HijackKeyDown(CUIContextMenu.SafeHandleKeyDown);CUIManager.CallCurrentMouseDown(e);if(window.captureEvents){window.captureEvents(Event.MouseDown);}CUIManager.HijackMouseDown(CUIContextMenu.SafeDoHidePopupMenu);};CUIContextMenu.prototype.SetFocusHandlers=function(){var _akN;document.body.onfocusout=function(){_akN=setTimeout(CUIContextMenu.SafeDoHidePopupMenu,100);};document.body.onfocusin=function(){window.clearTimeout(_akN);};};CUIContextMenu.ClearMouseOverTimeoutAction=function(){if(CUIContextMenu.mouseOverTimeoutId!==null){window.clearTimeout(CUIContextMenu.mouseOverTimeoutId);CUIContextMenu.mouseOverTimeoutId=null;CUIContextMenu.mouseOverTimeoutEvt=null;}};CUIContextMenu.SafeHandleKeyDown=function(e){try{CUIContextMenu.ClearMouseOverTimeoutAction();if(!e){var e=window.event;}if(e.keyCode==Dom.KeyCodes.Escape){CUIContextMenu.SafeDoHidePopupMenu();}else{CUIManager.HandleCommonKeys(e);}}catch(e){_f.HandleException(e);}};CUIContextMenu.SafeHandleClick=function(e){try{CUIContextMenu.ClearMouseOverTimeoutAction();if(!e){var e=window.event;}CUIContextMenu.HandleClick(e);}catch(excep){_f.HandleException(excep);}};CUIContextMenu.HandleClick=function(e){Dom.CancelEvent(e);};CUIContextMenu.prototype.fixPos=function(e,x,y){if(x==null){var x=e.clientX+Dom.GetScrollTop();}if(y==null){var y=e.clientY+Dom.GetScrollTop();}if(this.bDropDown){x-=COTStyle.GetDisplayOffsetWidth(this.oDiv);}if(y+this._xx>Dom.GetWindowHeight()){if(this._dl>0){y=Math.max(y-this._xx+this._tl,0);}else{y=Math.max(y-this._xx,0);}}if(x+this._nq>Dom.GetWindowWidth()){if(this._dl>0){Debug.Assert(this._xW);x=Math.max(x-this._xW._p5._nq-this._nq,0);}else{x=Math.max(Dom.GetWindowWidth()-3*CUIManager.kiRightWindowMargin-this._nq,0);}}x=Math.max(x,0);this.oDiv.style.left=x+'px';this.oDiv.style.top=y+'px';};CUIContextMenu.prototype.GetLeftPos=function(){return COTStyle.GetPosition(this.oDiv,'left');};CUIContextMenu.prototype.GetTopPos=function(){return COTStyle.GetPosition(this.oDiv,'top');};CUIContextMenu.prototype.fixSize=function(){if(!this.oDiv.lastChild){return false;}var _T6=this.oDiv.lastChild.offsetTop+this.oDiv.lastChild.offsetHeight;var _9y=false;if(_T6>CUIContextMenu.iHeight){_T6=CUIContextMenu.iHeight;_9y=true;}COTStyle.SetHeight(this.oDiv,_T6);this.oDiv.style.width="0px";var _F4=Dom.GetWidthOfWidestChild(this.oDiv);if(_9y){COTStyle.SetWidth(this.oDiv,_F4+CUIManager.kiScrollbarWidth);}else{COTStyle.SetWidth(this.oDiv,_F4);}for(var i=0;i<this.oDiv.childNodes.length;i++){COTStyle.SetWidth(this.oDiv.childNodes[i],_F4);}this._xx=_T6;this._nq=_F4;this._tl=0;if(this.getLastVisibleContextItem()){this._tl=COTStyle.GetDisplayOffsetHeight(this.getLastVisibleContextItem()._p2);}return true;};CUIContextMenu.prototype.NeedsTwoImagePlaceholders=function(){var _G6=false;for(var i=0;i<this.items.length;i++){if(this.items[i].bHasImage&&this.items[i].sCheckImage!="blank.gif"){_G6=true;break;}}return _G6;};CUIContextMenu.prototype.getLastVisibleContextItem=function(){var _PQ=this.items.length-1;while(_PQ>=0){if(this.items[_PQ]instanceof ContextItem&&this.items[_PQ].DoDisplay()){return this.items[_PQ];}_PQ--;}return null;};CUIContextMenu.prototype.populateItems=function(){var _as6;var _BA=this.oDiv.ownerDocument;var _ald=this.NeedsTwoImagePlaceholders();for(var i=0;i<this.items.length;i++){if(this.items[i]instanceof ContextItem&&this.items[i].DoDisplay()){var _zr=document.createElement("TABLE");_zr.cellPadding=0;_zr.cellSpacing=0;_zr.tabIndex=i+2;this.oDiv.appendChild(_zr);if((!this.items[i]._eY)&&this.items[i]._o6&&this.items[i]._o6._qm){this.items[i].SetEnabled(!this.items[i].IsAllSubItemDisabled());}this.items[i].Draw(_zr,_ald);}else if(!(this.items[i]instanceof ContextItem)&&i!=this.items.length-1&&i>0){var n=i-1;var _aAy=false;while(n>=0&&this.items[n]instanceof ContextItem){if(this.items[n].DoDisplay()){_aAy=true;break;}else{n--;}}if(_aAy){var _aq8=this.oDiv.appendChild(_BA.createElement("HR"));COTStyle.SetWidth(_aq8,100,'%');_aq8.size=1;_aq8.className="contextMenu_Separator";}}}this.oDiv.onselectstart=Dom.PreventDefault;};CUIContextMenu.SafeDoHidePopupMenu=function(e,_L6){/*@if(!@bering_debug)@*/try{/*@end@*/if(_L6==null){if(window.oLastActiveTopLevelMenu){window.oLastActiveTopLevelMenu.hideMenuAndChildren();window.oLastActiveTopLevelMenu=null;}}else{for(var i=0;i<CUIContextMenu.MenuArr.length;i++){if(CUIContextMenu.MenuArr[i]._dl>_L6){CUIContextMenu.MenuArr[i].hideMenu();if(CUIContextMenu.MenuArr[i].oOwner&&CUIContextMenu.MenuArr[i].oOwner.OnContextMenuHide){CUIContextMenu.MenuArr[i].oOwner.OnContextMenuHide(CUIContextMenu.MenuArr[i]);}}}}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIContextMenu.prototype.hideMenu=function(){this.oDiv.style.visibility="hidden";if(this._oO){this.Unload();}};CUIContextMenu.prototype.hideMenus=function(){if(!this.items)return;for(var i=0;i<this.items.length;i++){if(this.items[i]._o6){this.items[i]._o6.hideMenus();}}this.hideMenu();if(this.oOwner&&this.oOwner.OnContextMenuHide){this.oOwner.OnContextMenuHide(this);}};CUIContextMenu.prototype.hideMenuAndChildren=function(){document.body.onfocusin=null;document.body.onfocusout=null;this.hideMenus();if(window.releaseEvents){window.releaseEvents(Event.MouseDown);}CUIManager.ReleaseMouseDown();CUIManager.ReleaseKeyDown();};CUIContextMenu.prototype.Notify=function(_Dy){if(_Dy==ExpEvent.kCUIManager_Unload){CUIContextMenu.Unload();}else if(_Dy==ExpEvent.kCUIDialogMgr_HideModalDialog){Utilities.ExecuteHoldingProcedure();if(this.oOwner&&this.oOwner.HideAllDropZones){this.oOwner.HideAllDropZones();}this.appObj.uiManager.oDialogMgr.UnSubscribe(this,ExpEvent.kCUIDialogMgr_HideModalDialog);}};CUIContextMenu.Unload=function(){var _La=true;for(var i=0;i<CUIContextMenu.MenuArr.length;i++){var _zf=CUIContextMenu.MenuArr[i];if(_zf&&_zf.items){_zf.Unload(_La);}}window.oLastActiveContextMenu=null;window.oLastActiveTopLevelMenu=null;};CUIContextMenu.prototype.Unload=function(_La){if(this.items){for(var i=0;i<this.items.length;i++){if(this.items[i]instanceof ContextItem){this.items[i].Unload();if(this.items[i]._o6){this.items[i]._o6.Unload();}}}if(window.oLastActiveContextMenu==this){window.oLastActiveContextMenu=null;}if(window.oLastActiveTopLevelMenu==this){window.oLastActiveTopLevelMenu=null;}Utilities.DeleteAllFromArray(this.items);Utilities.RemoveAllChildObjects(this);}if(!_La){Utilities.DeleteFromArray(CUIContextMenu.MenuArr,this);}};CUIContextMenu.prototype.Clear=function(){if(this.items){for(var i=0;i<this.items.length;i++){if(this.items[i]instanceof ContextItem){this.items[i].Unload();if(this.items[i]._o6){this.items[i]._o6.Unload();}}}Utilities.DeleteAllFromArray(this.items);this.items=new Array();}};CUIContextMenu.prototype.DeleteItem=function(i){if(this.items[i]){this.items[i].Unload();if(this.items[i]._o6){this.items[i]._o6.Unload();}Utilities.DeleteFromArray(this.items,this.items[i]);}};CUIContextMenu.prototype.DeleteSequence=function(_UI,_Nb){var _Oi=0;var _Z5=this.items.length;for(var i=_UI;i<=_Nb;i++){this.items[i].Unload();if(this.items[i]._o6){this.items[i]._o6.Unload();}delete this.items[i];_Oi++;}for(var i=_UI;i<_UI+_Oi;i++){if(i+_Oi<this.items.length){this.items[i]=this.items[i+_Oi];}}this.items.length=_Z5-_Oi;};ContextItem.withSubMEnalbedState=0;ContextItem.withSubMOverState=1;ContextItem.noSubMOverState=2;ContextItem.noSubMEnalbedState=3;ContextItem.noSubMOverState=4;ContextItem.disabledState=5;ContextItem.defaultState=6;ContextItem.defaultOverState=7;ContextItem.kItemTruncLength=75;ContextItem.itemStyleArr=new Array();var _g=navigator.userAgent.toLowerCase().indexOf('firefox')!=-1?'_NS':'';ContextItem.itemStyleArr[ContextItem.withSubMEnalbedState]='contextMenu_item_with_submenu'+_g;ContextItem.itemStyleArr[ContextItem.withSubMOverState]='contextMenu_item_with_submenu_over'+_g;ContextItem.itemStyleArr[ContextItem.noSubMOverState]='contextMenu_item_over'+_g;ContextItem.itemStyleArr[ContextItem.noSubMEnalbedState]='contextMenu_item'+_g;ContextItem.itemStyleArr[ContextItem.disabledOverState]='contextMenu_item_disabled_over'+_g;ContextItem.itemStyleArr[ContextItem.disabledState]='contextMenu_item_disabled'+_g;ContextItem.itemStyleArr[ContextItem.defaultState]='contextMenu_item_default'+_g;ContextItem.itemStyleArr[ContextItem.defaultOverState]='contextMenu_item_default_over'+_g;ContextItem.kNoneValue=-1;function ContextItem(_J7,_Np,_BC,_IS,_zA,_U3,_Mt,_UM){if(_J7==''||!_J7){this.bHasImage=false;this._qk=null;}else{this.bHasImage=true;this._qk=_J7;this._m5=Utilities.IMG_PATH;}this.bHideCheckImage=true;this.sCheckImage="blank.gif";this.bChecked=false;Debug.Assert(_U3!=null);_Co=_U3.appObj.oResources;this._ny=Utilities.GetTruncatedString(_Np,ContextItem.kItemTruncLength,_Co);if(_Np.length>ContextItem.kItemTruncLength){this._da=_Np;}else{this._da='';}this._action=_BC;this._eY=_IS||false;if(_zA){this.aCallbackParams=_zA;}if(_Mt){this._o6=_Mt;}if(_U3&&!_UM){this._p5=_U3;_U3.items[_U3.items.length]=this;}this.bHovered=false;this._nu=false;this._dJ=false;this._fV=true;};ContextItem.prototype.SetImgPath=function(_y8){this._m5=_y8;};ContextItem.prototype.SetTooltip=function(_QI){this._da=_QI;};ContextItem.prototype.AddToParentMenu=function(_Ci,i){this._p5=_Ci;_Ci.items.splice(i,0,this);};ContextItem.prototype.SetFunctionId=function(_O4){this._cp=_O4;};ContextItem.prototype.GetFunctionId=function(){return this._cp;};ContextItem.prototype.SetSkipUncomitChangesChecking=function(){this._dJ=true;};ContextItem.prototype.SetDisplayFlag=function(_z5){this._fV=_z5;};ContextItem.prototype.DoDisplay=function(){return this._fV;};ContextItem.prototype.SetOnDisplayCallback=function(_Ie){this._pu=_Ie;};ContextItem.prototype.Clone=function(_Vv,_M6){if(_M6!=null){var _9R=true;var _ax7=new ContextItem(this._qk,this._ny,this._action,this._eY,Utilities.CopyArray(this.aCallbackParams),_Vv,null,_9R);_ax7.AddToParentMenu(_Vv,_M6);}else{var _ax7=new ContextItem(this._qk,this._ny,this._action,this._eY,Utilities.CopyArray(this.aCallbackParams),_Vv);}_ax7.id=this.id;_ax7.bChecked=this.bChecked;_ax7.bHideImage=this.bHideImage;_ax7._nu=this._nu;_ax7._dJ=this._dJ;_ax7._cp=this._cp;_ax7._fV=this._fV;if(this._o6){var _Mt=_ax7.CreateSubMenu(this._p5.appObj.appname,_Vv._dl+1);for(var i=0;i<this._o6.items.length;i++){this._o6.items[i].Clone(_Mt);}if(this._qm){_Mt.SetChildrenComplete();}}return _ax7;};ContextItem.prototype.AddSubMenu=function(_Mt){this._o6=_Mt;};ContextItem.prototype.CreateSubMenu=function(_Ke,_y1,oOwner,_UG){this._o6=new CUIContextMenu(_Ke,_y1,oOwner,this,_UG);return this._o6;};ContextItem.prototype.RemoveSubMenu=function(){this._o6.Unload();this._o6=null;Dom.RemoveAllChildren(this._p2);this.Draw(this._p2,this._p5.NeedsTwoImagePlaceholders());};ContextItem.prototype.SetParameterArr=function(_zA){if(_zA!=null){this.aCallbackParams=_zA;}};ContextItem.prototype.SetItemAction=function(_BC){this._action=_BC;};ContextItem.prototype.DeferItemAction=function(_CS,_Ro){this._fPrerequisiteCall=_CS;this._aPrereqCallBackParam=_Ro;};ContextItem.prototype.SetAsDefault=function(_MM){this._nu=_MM||false;};ContextItem.prototype.SetEnabled=function(_IF){this._eY=!_IF;};ContextItem.prototype.IsEnabled=function(){return(this._eY==false);};ContextItem.prototype.SetChecked=function(_Ng){this.bHideCheckImage=!_Ng;this.bChecked=_Ng;this.sCheckImage="check.gif";};ContextItem.prototype.SetRadioState=function(_Ng){this.bHideCheckImage=!_Ng;this.bChecked=_Ng;this.sCheckImage="round_check.gif";};ContextItem.prototype.Draw=function(_zr,_G6){this._p2=_zr;this._p2.oContextItem=this;var _RK=document.createElement("TBODY");_zr.appendChild(_RK);var _FW=_RK.appendChild(document.createElement('TR'));if(_G6||!this.bHasImage){var _afT=document.createElement('IMG');_afT.src=this.bHideCheckImage?Utilities.IMG_PATH+"blank.gif":Utilities.IMG_PATH+this.sCheckImage;_afT.className="contextItem_img";var _aGB=_FW.appendChild(document.createElement('TD'));COTStyle.SetSize(_afT,16,16);COTStyle.SetMarginRight(_afT,4);COTStyle.SetWidth(_aGB,20);_aGB.appendChild(_afT);_afT.oContextItem=this;}if(_G6||this.bHasImage){var _afT=document.createElement('IMG');_afT.src=this.bHasImage?this._m5+this._qk:Utilities.IMG_PATH+"blank.gif";_afT.className="contextItem_img";var _aGB=_FW.appendChild(document.createElement('TD'));_aGB.appendChild(_afT);_afT.oContextItem=this;this._jh=_afT;COTStyle.SetMarginRight(_afT,4);COTStyle.SetWidth(_aGB,20);}var _aGB=_FW.appendChild(document.createElement('TD'));_aGB.appendChild(document.createTextNode(this._ny));_aGB.style.whiteSpace="pre";_aGB.oContextItem=this;_aGB.style.textAlign="left";if(this._o6&&(!this._eY)){var _ZS=this._p5._rp.cloneNode(false);var _aGB=_FW.appendChild(document.createElement('TD'));_aGB.appendChild(_ZS);COTStyle.SetMarginLeft(_ZS,4);COTStyle.SetWidth(_aGB,8);_ZS.oContextItem=this;}else{var _aGB=_FW.appendChild(document.createElement("TD"));COTStyle.SetWidth(_aGB,8);}var _Uc=this.GetState();ContextItem.SetObjStyleByState(this._p2,_Uc);if(this._da!=''){this._p2.title=this._da;}if(this._pu){this._pu();}};ContextItem.prototype.GetState=function(){var _Uc=null;if(this.bHovered){if(this._eY){_Uc=ContextItem.disabledOverState;}else if(this._o6){_Uc=ContextItem.withSubMOverState;}else if(this._nu){_Uc=ContextItem.defaultOverState;}else{_Uc=ContextItem.noSubMOverState;}}else{if(this._eY){_Uc=ContextItem.disabledState;}else if(this._o6){_Uc=ContextItem.withSubMEnalbedState;}else if(this._nu){_Uc=ContextItem.defaultState;}else{_Uc=ContextItem.noSubMEnalbedState;}}return _Uc;};ContextItem.prototype.IsAllSubItemDisabled=function(){for(var i=0;i<this._o6.items.length;i++){if(this._o6.items[i]instanceof ContextItem&&!this._o6.items[i]._eY){return false;}}return true;};ContextItem.prototype.Unload=function(){if(this._p2){this._p2.oContextItem=null;var _QX=Dom.GetElementsByTagName(this._p2,'IMG');for(var i=0;i<_QX.length;i++){_QX[i].oContextItem=null;}Dom.RemoveObject(this._p2);}this._p5=null;Utilities.DeleteAllFromArray(this.aCallbackParams);this._pu=null;Utilities.RemoveAllChildObjects(this);};ContextItem.ContinueHandleMouseUp=function(oContextItem,e){if(oContextItem._p5.bExclusiveCheckMenu){var _Ng=oContextItem.bChecked;oContextItem._p5.ClearAllChecks();oContextItem.SetChecked(!_Ng);if(_Ng){return;}}if(oContextItem._fPrerequisiteCall){var _apt=oContextItem._action;oContextItem._aPrereqCallBackParam.push(Utilities.GenerateCallback(_apt,oContextItem.aCallbackParams));Utilities.GenerateCallback(oContextItem._fPrerequisiteCall,oContextItem._aPrereqCallBackParam)();}else{Utilities.GenerateCallback(oContextItem._action,oContextItem.aCallbackParams)();}if(window.oLastActiveTopLevelMenu){window.oLastActiveTopLevelMenu.hideMenuAndChildren();}oContextItem.bHovered=false;Dom.CancelEvent(e);};ContextItem.SafeDoContinueHandleMouseUp=function(oContextItem,e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}ContextItem.ContinueHandleMouseUp(oContextItem,e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};ContextItem.SafeHandleMouseDown=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/CUIContextMenu.ClearMouseOverTimeoutAction();if(!e){var e=window.event;}ContextItem.HandleMouseDown(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};ContextItem.HandleMouseDown=function(e){Dom.CancelEvent(e);};ContextItem.SafeHandleMouseUp=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/CUIContextMenu.ClearMouseOverTimeoutAction();if(!e){var e=window.event;}ContextItem.HandleMouseUp(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};ContextItem.HandleMouseUp=function(e){var _2J=Dom.GetEventTarget(e);var _zf=window.oLastActiveContextMenu;if(!_zf){return;}var oContextItem=Dom.GetEventTarget(e).oContextItem;var _av3=_zf.oRect;var _Qb=new COTPosition(e.clientX,e.clientY);if((oContextItem==null)&&_av3.IsPtInRect(_Qb)){var _T6=COTStyle.GetDisplayHeight(_zf.oDiv);if(_zf.appObj.browserInfo.is_ie5_5up){var _aC8=_zf.oDiv.componentFromPoint(_Qb.left,_Qb.top);if(!(_aC8=='scrollbarUp'&&_zf.oDiv.scrollTop==0)&&!(_aC8=='scrollbarDown'&&(_T6+_zf.oDiv.scrollTop)>=_zf.oDiv.scrollHeight)){_zf.oDiv.releaseCapture();_zf.oDiv.doScroll(_aC8);}}}else if(oContextItem!=null&&oContextItem._action&&(!oContextItem._eY)){var _asI=oContextItem._p5;var _aDE=(_asI.oOwner&&_asI.oOwner._G)?true:false;if(_aDE||oContextItem._dJ){ContextItem.SafeDoContinueHandleMouseUp(oContextItem,e);}else{var _amW=_asI.appObj.uiManager.ConfirmLossOfChanges();if(_amW==Utilities.eStateContinue){ContextItem.SafeDoContinueHandleMouseUp(oContextItem,e);}else if(_amW==Utilities.eStateHold){var _axQ=Dom.CloneMouseEvent(e);var _Ro=new Array(oContextItem,_axQ);Utilities.SetProcedureToHold(ContextItem.SafeDoContinueHandleMouseUp,_Ro);_asI.appObj.uiManager.oDialogMgr.Subscribe(_asI,ExpEvent.kCUIDialogMgr_HideModalDialog);}}}};ContextItem.ContinueSafeHandleMouseOver=function(){try{Debug.Assert(CUIContextMenu.mouseOverTimeoutEvt!=null);ContextItem.HandleMouseOver(CUIContextMenu.mouseOverTimeoutEvt);CUIContextMenu.mouseOverTimeoutId=null;CUIContextMenu.mouseOverTimeoutEvt=null;}catch(excep){_f.HandleException(excep);}};ContextItem.SafeHandleMouseOver=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}CUIContextMenu.ClearMouseOverTimeoutAction();if(ContextItem.RequiresGetSubMenu(e)){CUIContextMenu.mouseOverTimeoutEvt=Dom.CloneMouseEvent(e);CUIContextMenu.mouseOverTimeoutId=setTimeout(ContextItem.ContinueSafeHandleMouseOver,500);}else{ContextItem.HandleMouseOver(e);}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};ContextItem.RequiresGetSubMenu=function(e){if(!e){return false;}var _ao9=Dom.GetEventTarget(e).oContextItem;if(_ao9&&_ao9._o6&&!_ao9._eY){var oOwner=_ao9._p5.oOwner;return(oOwner&&oOwner.GetSubMenuItems&&!_ao9._o6._qm);}return false;};ContextItem.HandleMouseOver=function(e){var _ao9=Dom.GetEventTarget(e).oContextItem;if(_ao9!=null){var _2J=_ao9._p2;_ao9.bHovered=true;var _Uc=_ao9.GetState();ContextItem.SetObjStyleByState(_2J,_Uc);CUIContextMenu.SafeDoHidePopupMenu(e,_ao9._p5._dl);window.oLastActiveContextMenu=_ao9._p5;if(_ao9._o6&&!_ao9._eY){var _IG=false;var _ZC=_ao9._p5.oDiv;var x=COTStyle.GetPosition(_ZC,'left')+COTStyle.GetDisplayOffsetWidth(_ZC)-COTStyle.GetBorderRight(_ZC);var y=_2J.offsetTop+COTStyle.GetPosition(_ZC,'top')-_ZC.scrollTop;var oOwner=_ao9._p5.oOwner;if(oOwner&&oOwner.GetSubMenuItems&&!_ao9._o6._qm){oOwner.GetSubMenuItems(_ao9,e,x,y);}else{_ao9._o6.display(e,_IG,x,y);}}}};ContextItem.SafeHandleMouseOut=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/CUIContextMenu.ClearMouseOverTimeoutAction();if(!e){var e=window.event;}ContextItem.HandleMouseOut(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};ContextItem.HandleMouseOut=function(e){var _ao9=Dom.GetEventTarget(e).oContextItem;if(_ao9!=null){var _2J=_ao9._p2;_ao9.bHovered=false;var _Uc=_ao9.GetState();ContextItem.SetObjStyleByState(_2J,_Uc);}};ContextItem.SetObjStyleByState=function(_SJ,_Uc){_SJ.className=ContextItem.itemStyleArr[_Uc];};function ContextSeparator(_Ci){Debug.Assert(_Ci);_Ci.items.push(this);};ContextSeparator.prototype.Clone=function(_Ci,_M6){if(_M6!=null){var _aIC=new ContextSeparator(_Ci);_Ci.items.splice(_M6,0,_aIC);}else{new ContextSeparator(_Ci);}};CUIDataMatrix.iRowIndex=0;CUIDataMatrix.iColIndex=1;CUIDataMatrix.kInitialDefaultAxisCount=2;function CUIDataMatrix(_IC){this._rh=null;this._s7=_IC;};CUIDataMatrix.prototype.GetRowAxis=function(){if(this._rh){return this._rh.GetAxis(CUIDataMatrix.iRowIndex);}else{if(this._s7.dataManager.GetCurrentDataMatrix()){this._rh=this._s7.dataManager.GetCurrentDataMatrix();return this._rh.GetAxis(CUIDataMatrix.iRowIndex);}else{return null;}}};CUIDataMatrix.prototype.GetColumnAxis=function(){if(this._rh){return this._rh.GetAxis(CUIDataMatrix.iColIndex);}else{if(this._s7.dataManager.GetCurrentDataMatrix()){this._rh=this._s7.dataManager.GetCurrentDataMatrix();return this._rh.GetAxis(CUIDataMatrix.iColIndex);}else{return null;}}};CUIDataMatrix.prototype.GetDefaultAxisCount=function(){return CUIDataMatrix.kInitialDefaultAxisCount;};CUIDataMatrix.prototype.Notify=function(event){if(event==ExpEvent.kCDLDataManager_DataMatrixCreate){this._rh=this._s7.dataManager.GetCurrentDataMatrix();}};CUICrosstab.kiNumRowsToDrawAtATime=15;CUICrosstab.kiMilliSecsWaitBtwRowBlocks=1;CUICrosstab.kiScrollBarWidth=16;CUICrosstab.kiScrollBarBorderWidth=4;CUICrosstab.kiMinHeight=200;CUICrosstab.kiFixedColWidth=90;CUICrosstab.kiFixedMinColWidth=30;CUICrosstab.kiIndentWidth=22;CUICrosstab.kiBlockSelectorStaticDimension=7;CUICrosstab.kMemberCell=1;CUICrosstab.kMemberCellTemplate=2;CUICrosstab.kCentralMeasureCell=3;CUICrosstab.kDataCell=4;CUICrosstab.kDataCellTemplate=5;CUICrosstab.kMemberCellOther=8;CUICrosstab.kNoDataModeCellTemplate=9;CUICrosstab.kXJoinPopParamsIdx=3;CUICrosstab.kAxisXJoinPopParamsIdx=1;CUICrosstab.kAddMemPopParamsIdx=5;CUICrosstab.kReplacePopParamsIdx=3;CUICrosstab.kMemberCellHExtraWidth=13;CUICrosstab.kMemberCellVPadding=10;CUICrosstab.kSampleCharacter="W";CUICrosstab.kSharpSign="#";CUICrosstab.kRowAxisColMinWidth=30;function CUICrosstab(_PX,_Wi,_Iq){this._jN=_PX;this._uq=_Wi;this._tJ=0;this._n5=0;this._w7=false;this._p0=-1;this._e7=-1;this._la=-1;this._jR=-1;this._nz=-1;this._oj=-1;if(_o.is_firefox){CUICrosstab.kiFixedMinColWidth=15;}this.sAppName=this._jN._m4.appobj.appname;this._hL=null;this._nX=null;if(Utilities.bDiffMiningEnabled){this._xj=new Array();}this._pO=0;this._r7=0;this._rz=0;this._aD=0;this._yc=0;this._nj=0;this._fJ=-1;this._ro=null;this._q6(_Wi);Dom.SetObjRef(this._ro,this,'oCrosstab');this._ro.onmouseover=CUICrosstab.SafeHandleMouseOver;this._ro.onmouseout=CUICrosstab.SafeHandleMouseOut;this._ro.onclick=CUICrosstab.SafeHandleMouseClick;this._ro.ondblclick=CUICrosstab.SafeHandleMouseClick;this._ro.onselectstart=CUICrosstab.SafeHandleSelectStart;this._ro.oncontextmenu=CUICrosstab.SafeHandleContextMenu;if(document.attachEvent){document.attachEvent("onmousewheel",CUICrosstab.SafeHandleMouseWheel);}else{window.addEventListener("DOMMouseScroll",CUICrosstab.SafeHandleMouseWheel,false);}this._I=new Array();var _AG=new Array(this.sAppName);this._sp=this._jN._m4.appobj.oResources;this.InitBlockContextMenus();var _UG=true;this.oMoreMenu=new CUIContextMenu(this.sAppName,0,this,_UG);this.CreateBlockSizeMenu(this.oMoreMenu,_AG);this.oCentralMeasureMenu=new CUIContextMenu(this.sAppName,0,this);_zn=this._sp.GetString('OTH_CROSSTAB_DEFMEASUREMENU_SHOWVALUESAS');var _ark=new ContextItem('',_zn,null,false,_AG,this.oCentralMeasureMenu);_Mt=_ark.CreateSubMenu(this.sAppName,this.oCentralMeasureMenu._dl+1);_ark.id='OTH_CROSSTAB_DEFMEASUREMENU_SHOWVALUESAS';_zn=this._sp.GetString('OTH_CROSSTAB_DEFMEASUREMENU_SHOWVALUESAS_VALUES');oContextItem=new ContextItem('',_zn,null,false,_AG,_Mt);oContextItem.id='OTH_CROSSTAB_DEFMEASUREMENU_SHOWVALUESAS_VALUES';_zn=this._sp.GetString('OTH_CROSSTAB_DEFMEASUREMENU_SHOWVALUESAS_ROWTOTAL');oContextItem=new ContextItem('',_zn,null,false,_AG,_Mt);oContextItem.id='OTH_CROSSTAB_DEFMEASUREMENU_SHOWVALUESAS_ROWTOTAL';_zn=this._sp.GetString('OTH_CROSSTAB_DEFMEASUREMENU_SHOWVALUESAS_ROWSUB');oContextItem=new ContextItem('',_zn,null,false,_AG,_Mt);oContextItem.id='OTH_CROSSTAB_DEFMEASUREMENU_SHOWVALUESAS_ROWSUB';_zn=this._sp.GetString('OTH_CROSSTAB_DEFMEASUREMENU_SHOWVALUESAS_COLTOTAL');oContextItem=new ContextItem('',_zn,null,false,_AG,_Mt);oContextItem.id='OTH_CROSSTAB_DEFMEASUREMENU_SHOWVALUESAS_COLTOTAL';_zn=this._sp.GetString('OTH_CROSSTAB_DEFMEASUREMENU_SHOWVALUESAS_COLSUB');oContextItem=new ContextItem('',_zn,null,false,_AG,_Mt);oContextItem.id='OTH_CROSSTAB_DEFMEASUREMENU_SHOWVALUESAS_COLSUB';_zn=this._sp.GetString('OTH_CROSSTAB_DEFMEASUREMENU_SHOWVALUESAS_TOTAL');oContextItem=new ContextItem('',_zn,null,false,_AG,_Mt);_Mt.SetChildrenComplete();oContextItem.id='OTH_CROSSTAB_DEFMEASUREMENU_SHOWVALUESAS_TOTAL';_zn=this._sp.GetString('OTH_CROSSTAB_DEFMEASUREMENU_DEFAULTMEASURE');oContextItem=new ContextItem('',_zn,null,false,_AG,this.oCentralMeasureMenu);oContextItem.id='OTH_CROSSTAB_DEFMEASUREMENU_DEFAULTMEASURE';_Mt=oContextItem.CreateSubMenu(this.sAppName,this.oCentralMeasureMenu._dl+1);_Mt.SetChildrenComplete();this.InitMemberContextMenus();this.oDataCellMenu=new CUIContextMenu(this.sAppName,0,this);_zn=this._sp.GetString('OTH_CROSSTAB_DRILL_DOWN_DATA_CELL');oContextItem=new ContextItem('action_drill_down.gif',_zn,null,false,_AG,this.oDataCellMenu);oContextItem.id='OTH_CROSSTAB_DRILL_DOWN_DATA_CELL';_zn=this._sp.GetString('OTH_CROSSTAB_DRILL_UP_DATA_CELL');oContextItem=new ContextItem('action_drill_up.gif',_zn,null,false,_AG,this.oDataCellMenu);oContextItem.id='OTH_CROSSTAB_DRILL_UP_DATA_CELL';_zn=this._sp.GetString('OTH_CROSSTAB_DRILL_THROUGH');oGoToItem=new ContextItem('icon_go_to_16.gif',_zn,null,false,null,this.oDataCellMenu);oGoToItem.id='OTH_CROSSTAB_DRILL_THROUGH';_Mt=oGoToItem.CreateSubMenu(this.sAppName,this.oDataCellMenu._dl+1);_Mt.SetChildrenComplete();_zn=this._sp.GetString('OTH_CROSSTAB_DRILL_THROUGH_RELATED_CONTENT');oContextItem=new ContextItem('',_zn,null,false,_AG,_Mt);oContextItem.id='OTH_CROSSTAB_DRILL_THROUGH_RELATED_CONTENT';_zn=this._sp.GetString('OTH_CROSSTAB_DRILL_THROUGH_SEARCH');oContextItem=new ContextItem('',_zn,null,false,_AG,_Mt);oContextItem.id='OTH_CROSSTAB_DRILL_THROUGH_SEARCH';if(Utilities.bAutoAnalysisDrillEnabled){_aIC=new ContextSeparator(_Mt);_zn=this._sp.GetString('Analyze');oContextItem=new ContextItem('',_zn,null,false,_AG,_Mt);oContextItem.id='Analyze';oContextItem=new ContextItem('analyze.gif',_zn,null,false,_AG,this.oDataCellMenu);oContextItem.id='Analyze';}if(Utilities.bDiffMiningEnabled){_aIC=new ContextSeparator(_Mt);_zn=this._sp.GetString('Analyze Difference');oContextItem=new ContextItem('',_zn,null,false,_AG,_Mt);oContextItem.id='Analyze Difference';oContextItem=new ContextItem('analysis_items_tab_icon.gif',_zn,null,false,_AG,this.oDataCellMenu);oContextItem.id='Analyze Difference';_aIC=new ContextSeparator(_Mt);_zn=this._sp.GetString('Analyze Difference Setup...');oContextItem=new ContextItem('',_zn,null,false,_AG,_Mt);oContextItem.id='Analyze Difference Setup...';oContextItem=new ContextItem('analysis_items_tab_icon.gif',_zn,null,false,_AG,this.oDataCellMenu);oContextItem.id='Analyze Difference Setup...';}this.oHiddenMenu=new CUIContextMenu(this.sAppName,0,this);this._e6=new Array();this._e6[ExpEvent.kCUICrosstab_DrawComplete]=new Array();this._e6[ExpEvent.kCUICrosstab_DrawStoppable]=new Array();this._jN.Subscribe(this,ExpEvent.kCUIWorksheet_Unload);this._jN.Subscribe(this,ExpEvent.kCUIWorksheet_WindowResize);if(!_PX.GetDataWorkSheet().GetDataManager()._um){this._kK=true;}this._ax=new CUIAxis(this,CUIDataMatrix.iRowIndex);this._ax.Init();this._bz=new CUIAxis(this,CUIDataMatrix.iColIndex);this._bz.Init();this._o2=new CUICellMap(this._jN,this);this._pS=new CUIDropZone(this);this.SetupSizingTestTables();this._aF=_Iq[ExpAPIXml.kAttrFixedXtabColWidth]?true:false;if(this._aF){this.InitColumnResizeBar();}this._mD=null;this._qB=null;this._mY=null;this._nG=null;this._nf=new Array();this._t6=new Array();this._ri=new Array();this._sm=new Array();this._x2=new CUIXtabDataWidthCache();this._x2.LoadFromXml(this._jN._my._ak._kX.GetWidthData());this._nS=new Object();this._wk=new Object();this.iDoubleClickAt=0;this.fDoubleClick=null;if(Utilities.bEnableInnerHTMLRendering&&window["CUIXtabLayout"]){this._lL=true;}this.statsDlg=null;};CUICrosstab.prototype.InitColumnResizeBar=function(){this._xv=new CUIVertResizingBar();this.SetupSizingParams();};CUICrosstab.prototype.InitBlockContextMenus=function(){var _AG=new Array(this.sAppName);this.oChildrenBlockMenu=new CUIContextMenu(this.sAppName,0,this);this.oMemberBlockMenu=new CUIContextMenu(this.sAppName,0,this);var _BM=this._sp.GetString('OTH_CROSSTAB_MENU_BLOCK_PROPERTIES');var _PM=new ContextItem('',_BM,CUICrosstab.SafeDoToggleBlockPropPane,false,_AG,this.oChildrenBlockMenu);_PM.SetFunctionId('blockproperty');_PM.Clone(this.oMemberBlockMenu);_BM=this._sp.GetString('OTH_CROSSTAB_MENU_ADD_CUSTOMSET');var _PM=new ContextItem('Custom_set.gif',_BM,CUICrosstab.SafeDoAddCustomSetFromSelectedBlock,false,_AG,this.oChildrenBlockMenu);_PM.id='OTH_CROSSTAB_MENU_ADD_CUSTOMSET';_PM.Clone(this.oMemberBlockMenu);_zn=this._sp.GetString('OTH_CONTEXTBAR_DELETE_BLOCK');var oContextItem=new ContextItem('tool_main_delete.gif',_zn,CUICrosstab.SafeDoDeleteBlock,false,_AG,this.oChildrenBlockMenu);oContextItem.id='OTH_CONTEXTBAR_DELETE_BLOCK';oContextItem.Clone(this.oMemberBlockMenu);var _aIC=new ContextSeparator(this.oChildrenBlockMenu);_aIC.Clone(this.oMemberBlockMenu);_BM=this._sp.GetString('OTH_CROSSTAB_MENU_FILTER');var _aew=new ContextItem('filter_16.gif',_BM,null,false,null,this.oChildrenBlockMenu);_aew.id='OTH_CROSSTAB_MENU_FILTER';_Mt=_aew.CreateSubMenu(this.sAppName,this.oChildrenBlockMenu._dl+1);_Mt.SetChildrenComplete();_aew.Clone(this.oMemberBlockMenu);_BM=this._sp.GetString('OTH_CROSSTAB_MENU_TOPBOTTOM');var _PM=new ContextItem('icon_topBottom16.gif',_BM,null,false,_AG,this.oChildrenBlockMenu);_PM.id='OTH_CROSSTAB_MENU_TOPBOTTOM';_Mt=_PM.CreateSubMenu(this.sAppName,this.oChildrenBlockMenu._dl+1);CUIWorkSheet.AttachTopBottomMenuItems(this.sAppName,this._sp,_Mt);_Mt.SetChildrenComplete();_PM.Clone(this.oMemberBlockMenu);_BM=this._sp.GetString('OTH_CROSSTAB_MENU_SORT');_T8=new ContextItem('sort_16.gif',_BM,null,false,null,this.oChildrenBlockMenu);_T8.id='OTH_CROSSTAB_MENU_SORT';_Mt=_T8.CreateSubMenu(this.sAppName,this.oChildrenBlockMenu._dl+1);_Mt.SetChildrenComplete();CUIWorkSheet.AttachBlockSortItems(this.sAppName,this._sp,_Mt);_T8.Clone(this.oMemberBlockMenu);_aIC=new ContextSeparator(this.oChildrenBlockMenu);_aIC.Clone(this.oMemberBlockMenu);_BM=this._sp.GetString('OTH_CROSSTAB_MENU_AUTO_SUBTOTAL');_PM=new ContextItem('subtotals.gif',_BM,CUIWorkSheet.SafeDoShowAutoSummaryDialog,false,null,this.oChildrenBlockMenu);_PM.id='OTH_CROSSTAB_MENU_AUTO_SUBTOTAL';var _ax7=_PM.Clone(this.oMemberBlockMenu);_BM=this._sp.GetString('OTH_CROSSTAB_MENU_SUMMARIZE');_PM=new ContextItem('tool_summary_total_16.gif',_BM,null,false,null,this.oChildrenBlockMenu);_PM.id='OTH_CROSSTAB_MENU_SUMMARIZE';_56=_PM.CreateSubMenu(this.sAppName,this.oChildrenBlockMenu._dl+1);var _ax7=_PM.Clone(this.oMemberBlockMenu);var _BM=this._sp.GetString('OTH_CROSSTAB_MENU_CALCULATE_DLG');var _afo=new ContextItem('calculation16x16.gif',_BM,CUICrosstab.SafeDoCustomizeCalc,false,null,this.oChildrenBlockMenu);_afo.id='OTH_CROSSTAB_MENU_CALCULATE_DLG';var _ax7=_afo.Clone(this.oMemberBlockMenu);_aIC=new ContextSeparator(this.oChildrenBlockMenu);_aIC.Clone(this.oMemberBlockMenu);var _BM=this._sp.GetString('OTH_CROSSTAB_MENU_EXPAND');var _ase=new ContextItem('',_BM,CUICrosstab.SafeDoNestDescendants,false,null,this.oChildrenBlockMenu);_ase.SetFunctionId('expandblock');var _ax7=_ase.Clone(this.oMemberBlockMenu);var _BM=this._sp.GetString('OTH_CROSSTAB_MENU_INCREASE_DEPTH');var _ase=new ContextItem('',_BM,CUICrosstab.SafeDoIncreaseDepth,false,null,this.oChildrenBlockMenu);_ase.id='OTH_CROSSTAB_MENU_INCREASE_DEPTH';var _ax7=_ase.Clone(this.oMemberBlockMenu);var _BM=this._sp.GetString('OTH_CROSSTAB_MENU_DECREASE_DEPTH');var _ase=new ContextItem('',_BM,CUICrosstab.SafeDoDecreaseDepth,false,null,this.oChildrenBlockMenu);_ase.id='OTH_CROSSTAB_MENU_DECREASE_DEPTH';var _ax7=_ase.Clone(this.oMemberBlockMenu);/*@if(@bering_debug)@*/if(Debug&&Debug.IsEnabled()){var _BM="Convert to V5 Block";var _aGJ=new ContextItem('',_BM,CUICrosstab.SafeDoConvertToV5Block,false,null,this.oChildrenBlockMenu);_aGJ.id='Convert to V5 Block';_aGJ.Clone(this.oMemberBlockMenu);}/*@end@*/_aIC=new ContextSeparator(this.oChildrenBlockMenu);_aIC.Clone(this.oMemberBlockMenu);_BM=this._sp.GetString('OTH_CROSSTAB_MENU_SHOW_LEVEL_PROPERTIES');_PM=new ContextItem('',_BM,null,true,null,this.oChildrenBlockMenu);_PM.id='OTH_CROSSTAB_MENU_SHOW_LEVEL_PROPERTIES';var _an5=_PM.CreateSubMenu(this.sAppName,this.oChildrenBlockMenu._dl+1);_PM.Clone(this.oMemberBlockMenu);if(Utilities.bScatterPlotGraphsEnabled){_aIC=new ContextSeparator(this.oChildrenBlockMenu);_aIC.Clone(this.oMemberBlockMenu);_BM="Start segmenting wizard...";_PM=new ContextItem('',_BM,null,false,null,this.oChildrenBlockMenu);_PM.id='Start segmenting wizard...';this.oQuadSegBlockMenu=new CUIContextMenu(this.sAppName,0,this);_PM=new ContextItem('',"Set current segment measures...",null,false,null,this.oQuadSegBlockMenu);_PM.id='Set current segment measures...';_PM=new ContextItem('',"Exit quadrant segmenting wizard...",null,false,null,this.oQuadSegBlockMenu);_PM.id='Exit quadrant segmenting wizard...';}};CUICrosstab.prototype.InitMemberContextMenus=function(){var _AG=new Array(this.sAppName);this.oMemberContextMenu=new CUIContextMenu(this.sAppName,0,this);this.oHAMCMemberContextMenu=new CUIContextMenu(this.sAppName,0,this);this.oMeasureHAMCContextMenu=new CUIContextMenu(this.sAppName,0,this);this.oMeasureHierContextMenu=new CUIContextMenu(this.sAppName,0,this);this.oCalcContextMenu=new CUIContextMenu(this.sAppName,0,this);this.oMultiCalcContextMenu=new CUIContextMenu(this.sAppName,0,this);this.oDynamicCalcContextMenu=new CUIContextMenu(this.sAppName,0,this);if(Utilities.bScatterPlotGraphsEnabled){this.oSegmtQuadMemberCntxMenu=new CUIContextMenu(this.sAppName,0,this);this.oSegmtQuadTotalCntxMenu=new CUIContextMenu(this.sAppName,0,this);oContextItem=new ContextItem('','Collapse this segment...',null,false,null,this.oSegmtQuadTotalCntxMenu);oContextItem.id='Collapse this segment...';var _aIC=new ContextSeparator(this.oSegmtQuadTotalCntxMenu);oContextItem=new ContextItem('','Edit segment caption...',null,false,null,this.oSegmtQuadTotalCntxMenu);oContextItem.id='Edit segment caption...';}_zn=this._sp.GetString('OTH_CROSSTAB_MENU_ADD_CUSTOMSET');oContextItem=new ContextItem('Custom_set.gif',_zn,null,false,_AG,this.oMemberContextMenu);oContextItem.id='OTH_CROSSTAB_MENU_ADD_CUSTOMSET';oContextItem.Clone(this.oMeasureHierContextMenu);oContextItem.Clone(this.oHAMCMemberContextMenu);oContextItem.Clone(this.oMeasureHAMCContextMenu);_zn=this._sp.GetString('OTH_CROSSTAB_MENU_HIDE');oContextItem=new ContextItem('',_zn,null,false,_AG,this.oMemberContextMenu);oContextItem.id='OTH_CROSSTAB_MENU_HIDE';oContextItem.Clone(this.oMeasureHierContextMenu);oContextItem.Clone(this.oDynamicCalcContextMenu);_zn=this._sp.GetString('OTH_CROSSTAB_MENU_UNHIDE');oContextItem=new ContextItem('',_zn,null,false,_AG,this.oDynamicCalcContextMenu);oContextItem.id='OTH_CROSSTAB_MENU_UNHIDE';_Mt=oContextItem.CreateSubMenu(this.sAppName,this.oMemberContextMenu._dl+1);_Mt.SetChildrenComplete();var _aIC=new ContextSeparator(this.oMemberContextMenu);_aIC.Clone(this.oDynamicCalcContextMenu);_zn=this._sp.GetString('OTH_CROSSTAB_MENU_VISIBLE_ITEMS');oContextItem=new ContextItem('',_zn,null,false,_AG,this.oDynamicCalcContextMenu);oContextItem.id='OTH_CROSSTAB_MENU_VISIBLE_ITEMS';var _UG=true;_Mt=oContextItem.CreateSubMenu(this.sAppName,1,null,_UG);this.CreateBlockSizeMenu(_Mt,_AG);_Mt.SetChildrenComplete();var _aIC=new ContextSeparator(this.oMemberContextMenu);_aIC.Clone(this.oDynamicCalcContextMenu);_aIC.Clone(this.oMeasureHierContextMenu);_zn=this._sp.GetString('OTH_CROSSTAB_MENU_REPLACE_CUR_BLK_BY_SELECTION');oContextItem=new ContextItem('',_zn,null,false,_AG,this.oMeasureHierContextMenu);oContextItem.id='OTH_CROSSTAB_MENU_REPLACE_CUR_BLK_BY_SELECTION';oContextItem.Clone(this.oMemberContextMenu);oContextItem.Clone(this.oHAMCMemberContextMenu);oContextItem.Clone(this.oMeasureHAMCContextMenu);var _aIC=new ContextSeparator(this.oMemberContextMenu);_aIC.Clone(this.oMeasureHierContextMenu);_aIC.Clone(this.oHAMCMemberContextMenu);_zn=this._sp.GetString('OTH_CROSSTAB_MENU_EXCLUDE');oContextItem=new ContextItem('excluded_items.gif',_zn,null,false,_AG,this.oMemberContextMenu);oContextItem.id='OTH_CROSSTAB_MENU_EXCLUDE';oContextItem.Clone(this.oMeasureHierContextMenu);oContextItem.Clone(this.oHAMCMemberContextMenu);if(Utilities.bScatterPlotGraphsEnabled){oContextItem.Clone(this.oSegmtQuadMemberCntxMenu);}if(Utilities.bSingleMemExpandEnabled){var _aIC=new ContextSeparator(this.oMemberContextMenu);_aIC.Clone(this.oHAMCMemberContextMenu);_zn=this._sp.GetString('Expand');oContextItem=new ContextItem('',_zn,null,false,_AG,this.oMemberContextMenu);oContextItem.id='Expand';oContextItem.Clone(this.oHAMCMemberContextMenu);oContextItem=new ContextItem('','expand/collapse',CUICrosstab.SafeDoToggleExpandedState,false,_AG,this.oMemberContextMenu);oContextItem.SetFunctionId("singleMemExpd");oContextItem.Clone(this.oHAMCMemberContextMenu);}var _aIC=new ContextSeparator(this.oMeasureHierContextMenu);_aIC.Clone(this.oMeasureHAMCContextMenu);_aIC.Clone(this.oMemberContextMenu);_aIC.Clone(this.oHAMCMemberContextMenu);_zn=this._sp.GetString('OTH_CROSSTAB_MENU_RENAME');oContextItem=new ContextItem('',_zn,CUIWorkSheet.SafeOpenRenameCalcDlg,false,_AG,this.oDynamicCalcContextMenu);oContextItem.SetFunctionId("Dyncalc");oContextItem.id='OTH_CROSSTAB_MENU_RENAME';_zn=this._sp.GetString('OTH_CROSSTAB_MENU_DELETE_MEMBER');oContextItem=new ContextItem('tool_main_delete.gif',_zn,null,false,_AG,this.oCalcContextMenu);oContextItem.id='OTH_CROSSTAB_MENU_DELETE_MEMBER';oContextItem.Clone(this.oHAMCMemberContextMenu,1);oContextItem.Clone(this.oMultiCalcContextMenu);oContextItem.Clone(this.oMeasureHAMCContextMenu,1);var _aIC=new ContextSeparator(this.oMemberContextMenu);_aIC.Clone(this.oMeasureHAMCContextMenu);_aIC.Clone(this.oMeasureHierContextMenu);_aIC.Clone(this.oDynamicCalcContextMenu);_zn=this._sp.GetString('OTH_MEASURE_MENU_USE_AS_DEFAULT');oContextItem=new ContextItem('',_zn,CUIWorkSheet.SafeDoInsertDropData,false,_AG,this.oMeasureHAMCContextMenu);oContextItem.id='OTH_MEASURE_MENU_USE_AS_DEFAULT';oContextItem.Clone(this.oMeasureHierContextMenu);_aIC.Clone(this.oHAMCMemberContextMenu,2);_aIC.Clone(this.oCalcContextMenu);_aIC.Clone(this.oMultiCalcContextMenu);_aIC.Clone(this.oMeasureHAMCContextMenu,2);_aIC.Clone(this.oMeasureHierContextMenu);var _zn=this._sp.GetString('OTH_CROSSTAB_MENU_CALC_RENAME');var _PM=new ContextItem('',_zn,CUIWorkSheet.SafeOpenRenameCalcDlg,false,_AG,this.oCalcContextMenu);_PM.id='OTH_CROSSTAB_MENU_CALC_RENAME';_zn=this._sp.GetString('OTH_CROSSTAB_MENU_CAL_EDIT');var _PM=new ContextItem('',_zn,CUICrosstab.SafeDoEditCalc,false,_AG,this.oCalcContextMenu);_PM.id='OTH_CROSSTAB_MENU_CAL_EDIT';_zn=this._sp.GetString('OTH_CROSSTAB_MENU_SORT');oContextItem=new ContextItem('sort_16.gif',_zn,null,false,null,this.oMemberContextMenu);oContextItem.id='OTH_CROSSTAB_MENU_SORT';_Mt=oContextItem.CreateSubMenu(this.sAppName,this.oMemberContextMenu._dl+1);_Mt.SetChildrenComplete();oContextItem.Clone(this.oHAMCMemberContextMenu);oContextItem.Clone(this.oCalcContextMenu);oContextItem.Clone(this.oMeasureHAMCContextMenu);oContextItem.Clone(this.oMeasureHierContextMenu);oContextItem.Clone(this.oDynamicCalcContextMenu);_zn=this._sp.GetString('OTH_CROSSTAB_MENU_USER_DEF_CAL');oContextItem=new ContextItem('calculation16x16.gif',_zn,null,false,_AG,this.oMemberContextMenu);oContextItem.id='OTH_CROSSTAB_MENU_USER_DEF_CAL';_Mt=oContextItem.CreateSubMenu(this.sAppName,this.oMemberContextMenu._dl+1);_Mt.SetChildrenComplete();oContextItem.Clone(this.oHAMCMemberContextMenu);oContextItem.Clone(this.oCalcContextMenu);oContextItem.Clone(this.oMeasureHAMCContextMenu);oContextItem.Clone(this.oMeasureHierContextMenu);oContextItem.Clone(this.oMultiCalcContextMenu);oContextItem.Clone(this.oDynamicCalcContextMenu);var _aIC=new ContextSeparator(this.oMemberContextMenu);_aIC.Clone(this.oHAMCMemberContextMenu);_aIC.Clone(this.oMeasureHAMCContextMenu);_aIC.Clone(this.oMeasureHierContextMenu);_zn=this._sp.GetString('APP_MENUBAR_ZERO_SUPPRESSION');oContextItem=new ContextItem('icon_zero_16.gif',_zn,null,false,null,this.oMemberContextMenu);oContextItem.id='APP_MENUBAR_ZERO_SUPPRESSION';_Mt=oContextItem.CreateSubMenu(this.sAppName,this.oMemberContextMenu._dl+1);_Mt.SetChildrenComplete();oContextItem.Clone(this.oHAMCMemberContextMenu);oContextItem.Clone(this.oDynamicCalcContextMenu);oContextItem.Clone(this.oMeasureHAMCContextMenu);oContextItem.Clone(this.oMeasureHierContextMenu);_aIC=new ContextSeparator(this.oMemberContextMenu);_aIC.Clone(this.oHAMCMemberContextMenu);_aIC.Clone(this.oMeasureHAMCContextMenu);_aIC.Clone(this.oMeasureHierContextMenu);_aIC.Clone(this.oDynamicCalcContextMenu);_zn=this._sp.GetString('OTH_CROSSTAB_MENU_DRILL_DOWN');oContextItem=new ContextItem('action_drill_down.gif',_zn,null,false,null,this.oMemberContextMenu);oContextItem.id='OTH_CROSSTAB_MENU_DRILL_DOWN';oContextItem.Clone(this.oHAMCMemberContextMenu);oContextItem.Clone(this.oMeasureHAMCContextMenu);oContextItem.Clone(this.oMeasureHierContextMenu);_zn=this._sp.GetString('OTH_CROSSTAB_MENU_DRILL_UP');oContextItem=new ContextItem('action_drill_up.gif',_zn,null,true,null,this.oMemberContextMenu);oContextItem.id='OTH_CROSSTAB_MENU_DRILL_UP';oContextItem.Clone(this.oMeasureHierContextMenu);oContextItem.Clone(this.oHAMCMemberContextMenu);oContextItem.Clone(this.oMeasureHAMCContextMenu);_zn=this._sp.GetString('OTH_CROSSTAB_DRILL_THROUGH');oGoToItem=new ContextItem('icon_go_to_16.gif',_zn,null,false,null,this.oMemberContextMenu);oGoToItem.id='OTH_CROSSTAB_DRILL_THROUGH';_Mt=oGoToItem.CreateSubMenu(this.sAppName,this.oMemberContextMenu._dl+1);_Mt.SetChildrenComplete();_zn=this._sp.GetString('OTH_CROSSTAB_DRILL_THROUGH_RELATED_CONTENT');oContextItem=new ContextItem('',_zn,null,false,_AG,_Mt);oContextItem.id='OTH_CROSSTAB_DRILL_THROUGH_RELATED_CONTENT';_zn=this._sp.GetString('OTH_CROSSTAB_DRILL_THROUGH_SEARCH');oContextItem=new ContextItem('',_zn,null,false,_AG,_Mt);oContextItem.id='OTH_CROSSTAB_DRILL_THROUGH_SEARCH';oGoToItem.Clone(this.oMeasureHierContextMenu);oGoToItem.Clone(this.oHAMCMemberContextMenu);oGoToItem.Clone(this.oMeasureHAMCContextMenu);_aIC=new ContextSeparator(this.oMemberContextMenu);_aIC.Clone(this.oHAMCMemberContextMenu);_BM=this._sp.GetString('OTH_CROSSTAB_MENU_SHOW_LEVEL_PROPERTIES');oContextItem=new ContextItem('',_BM,null,true,null,this.oMemberContextMenu);oContextItem.id='OTH_CROSSTAB_MENU_SHOW_LEVEL_PROPERTIES';var _an5=oContextItem.CreateSubMenu(this.sAppName,this.oMemberContextMenu._dl+1);oContextItem.Clone(this.oHAMCMemberContextMenu);_aIC=new ContextSeparator(this.oMemberContextMenu);_aIC.Clone(this.oHAMCMemberContextMenu);_aIC.Clone(this.oMeasureHAMCContextMenu);_aIC.Clone(this.oMeasureHierContextMenu);_aIC.Clone(this.oCalcContextMenu);_aIC.Clone(this.oMultiCalcContextMenu);_aIC.Clone(this.oDynamicCalcContextMenu);if(Utilities.bCalcSlicerEnabled){_zn=this._sp.GetString('Filter as Context');var _PM=new ContextItem('','Filter as Context',CUICrosstab.SafeDoAddCalcToContext,false,_AG,this.oCalcContextMenu);_PM.id='Filter as Context';_aIC=new ContextSeparator(this.oCalcContextMenu);}var _BM=this._sp.GetString('OTH_CROSSTAB_MENU_PROPERTY_PANE');var _PM=new ContextItem('',_BM,CUICrosstab.SafeDoShowBlockPropPane,false,_AG,this.oMemberContextMenu);_PM.SetFunctionId("proppane");_PM.Clone(this.oHAMCMemberContextMenu);_PM.Clone(this.oMeasureHAMCContextMenu);_PM.Clone(this.oMeasureHierContextMenu);_PM.Clone(this.oCalcContextMenu);_PM.Clone(this.oMultiCalcContextMenu);_PM.Clone(this.oDynamicCalcContextMenu);};CUICrosstab.prototype.Create=function(_CC){this._tJ=_CC;if(this._jN._m4.dataManager.IsInMissingMUNState()){this.Notify(ExpEvent.kCUICrosstab_DrawComplete,true);this._jN.OnRefreshFinish();return;}};CUICrosstab.prototype.UpdateHeight=function(_CC,_IL){Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CUICrosstab::UpdateHeight"]);this._tJ=_CC;if(!_IL){this.HandleResize();}Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CUICrosstab::UpdateHeight"]);};CUICrosstab.prototype.GetUIWorkSheet=function(){return this._jN;};CUICrosstab.prototype.GetDataWorkSheet=function(){return this._jN.GetDataWorkSheet();};CUICrosstab.prototype.GetCellMap=function(){return this._o2;};CUICrosstab.prototype.GetUIAxis=function(_M4){if(_M4==CUIDataMatrix.iRowIndex){return this._ax;}else{return this._bz;}};CUICrosstab.prototype.GetAxisCount=function(){return this.GetDataWorkSheet()._rk.GetAxisCount();};CUICrosstab.prototype.GetOppositeAxis=function(_O0){if(_O0.GetAxisIndex()==this._ax.GetAxisIndex()){return this._bz;}else{return this._ax;}};CUICrosstab.prototype.GetSingleSelectedBlockId=function(){if(this._n2){return this._uH;}else{return null;}};CUICrosstab.prototype.GetContextMenuHandler=function(){return CUICrosstab.SafeHandleContextMenu;};CUICrosstab.prototype.GetMouseMoveHandler=function(){return CUICrosstab.SafeHandleMouseMove;};CUICrosstab.prototype.SetDropData=function(_FZ){this._oM=_FZ;};CUICrosstab.prototype.GetNumberOfRowsDisplayed=function(){if(this._fJ!=-1){return this._fJ;}return this._og;};CUICrosstab.prototype.GetTotalNumberOfRows=function(){return this._og;};CUICrosstab.prototype.Refresh=function(){if(this._lL){Debug.Call(Debug.kUnitHooks,Debug.kStartRequest,["Initial Refresh"]);this.calculateAvailableSizes();Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CUICrosstab::Refresh_InnerHtml"]);if(this.xtabTestLayout){this.xtabTestLayout.Clear();CUIObject.Clear();delete this.xtabTestLayout;}this.xtabTestLayout=new CUIXtabLayout(this,this._ro);this.xtabTestLayout.Init();this.xtabTestLayout.Draw();Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CUICrosstab::Refresh_InnerHtml"]);this._w7=false;this.Notify(ExpEvent.kCUICrosstab_DrawComplete,true);this._jN.OnRefreshFinish();Debug.Call(Debug.kUnitHooks,Debug.kStopRequest,["Initial Refresh"]);return;}/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){_d.ClearTimers();g_oRefresh.ClearTimers();g_oDataCell.ClearTimers();g_oPopulateAxisCellMap.ClearTimers();g_oGetXtabData.ClearTimers();_n.StartTimer(true);g_oRefresh.StartGlobalTimer("Refresh crosstab");g_oAxis.StartTimer(true);}/*@end@*/Debug.Call(Debug.kUnitHooks,Debug.kStartRequest,["Initial Refresh"]);Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CUICrosstab::Refresh"]);CUIManager.HideDrillImage();/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oPopulateAxisCellMap.StartGlobalTimer("refresh ui axes & cell map");g_oRowAxis.StartTimer(true);}/*@end@*/this._ax.Populate();/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oRowAxis.StopTimer();}/*@end@*//*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oColAxis.StartTimer(true);}/*@end@*/this._bz.Populate();/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oColAxis.StopTimer();}/*@end@*//*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oCellMap.StartTimer(true);}/*@end@*/this._o2.Refresh();/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oCellMap.StopTimer();}/*@end@*//*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oAxis.StopTimer();g_oPopulateAxisCellMap.StopGlobalTimer();}/*@end@*/Utilities.DeleteAllFromArray(this._nf);Utilities.DeleteAllFromArray(this._t6);Utilities.DeleteAllFromArray(this._ri);this._n2=false;this._uH=null;this._hL=null;this._ro.onmousemove=CUICrosstab.SafeHandleMouseMove;this._ro.onmouseup=null;this._fJ=-1;if(this._jN.IsCrosstabVisible()){this.SetupCrosstabParameters();/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oGetData.StartTimer();g_oGetXtabData.StartGlobalTimer("GetCrosstabData");}/*@end@*/if(this._aF){Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CUICrosstab::SetLiteCrosstabSizeArray"]);Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CUICrosstab::SetLiteCrosstabSizeArray::Remainder"]);this.calculateAvailableSizes(true);this.populateCentralMeasureCell();this.SetCentralMeasureCellStyle();this.TestCellSize(this._mD,0,0,null,true);Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CUICrosstab::SetLiteCrosstabSizeArray::Remainder"]);Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CUICrosstab::SetLiteCrosstabSizeArray::SetFixedColsWidth"]);this.SetFixedColsWidth();Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CUICrosstab::SetLiteCrosstabSizeArray::SetFixedColsWidth"]);Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CUICrosstab::SetLiteCrosstabSizeArray::SetFixedRowHeight"]);this.SetFixedRowsHeight();Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CUICrosstab::SetLiteCrosstabSizeArray::SetFixedRowHeight"]);Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CUICrosstab::SetLiteCrosstabSizeArray"]);this.GetLiteInitialCrosstabData();}else{this.GetCrosstabData(this._ro);}this._w7=false;}else{this._w7=false;this.DrawCrosstab();/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){_n.StopSingleTime();g_oRefresh.StopGlobalTimer();}this._jN.OnRefreshFinish();/*@end@*/Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CUICrosstab::Refresh"]);Debug.Call(Debug.kUnitHooks,Debug.kStopRequest,["XTab Not Visible Refresh"]);if(_q){PerfMonitor.StopPerceivedUserTime();}}};CUICrosstab.prototype.GetTruncationSize=function(_F4,_PW){var _ae3=0;var _aaW=_PW?"3":"m";var _O3=document.createElement('A');_O3.className="MemberCellLabel";_O3.appendChild(document.createTextNode(_aaW));this._kQ(this._be,_O3,"MemberCellLabel");if(!_PW){_F4=_F4/(Utilities.GetCharWidthScaleFactor(this._jN._m4.appobj._gG));}while(this._be.offsetWidth<_F4){_aaW+=_PW?"3":"m";Dom.ReplaceText(_O3,_aaW);this._kQ(this._be,_O3,"MemberCellLabel");_ae3++;}return(_ae3);};CUICrosstab.prototype.SetupSizingTestTables=function(){Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CUICrosstab::SetupSizingTestTables"]);this._nH=document.createElement('TABLE');this._nH.className=Dom.GetStyleByBrowser("sizeTestTable");var _aae=document.createElement('TBODY');_aae.style.visibility="hidden";this._vZ=document.createElement('TR');this._vZ.style.visibility="hidden";_aae.appendChild(this._vZ);this._nH.appendChild(_aae);this._uq.appendChild(this._nH);this._be=document.createElement('TD');this._g0=document.createElement('TABLE');this._g0.className=Dom.GetStyleByBrowser("sizeTestTable");var _axl=document.createElement('TBODY');_axl.style.visibility="hidden";var _3P=document.createElement('TR');_3P.style.visibility="hidden";_3P.appendChild(this._be);_axl.appendChild(_3P);this._g0.appendChild(_axl);this._uq.appendChild(this._g0);this._be.className="ml MemberCell";this._cz=COTStyle.GetPaddingTop(this._be);this._aO=COTStyle.GetPaddingBottom(this._be);this._p0=this._cz+this._aO;this._la=COTStyle.GetPaddingLeft(this._be);this._jR=COTStyle.GetPaddingRight(this._be);this._e7=this._la+this._jR;this._nz=COTStyle.GetBorderRight(this._be);this._cj=document.createElement('TABLE');this._cj.className=Dom.GetStyleByBrowser("sizeTestTable");var _7W=document.createElement('TBODY');_7W.style.visibility="hidden";var _afH=document.createElement('TR');_afH.style.visibility="hidden";this._uV=document.createElement('TD');_afH.appendChild(this._uV);_7W.appendChild(_afH);this._cj.appendChild(_7W);this._uq.appendChild(this._cj);this._uV.innerHTML="$012345.1,6789%";this._lQ=false;var _acX=new Array("cv DataCell","mv DataCell","ov DataCell","iv DataCell","hv DataCell","sv DataCell","nv DataCell","xv DataCell");var _Y1=_acX.length;var _F4=this.GetCellWidth(this._uV);var _83="mv DataCell";for(var i=0;i<_acX.length;i++){this._uV.className=_acX[i];var _Ls=this.GetCellWidth(this._uV);if(_Ls>_F4){_F4=_Ls;_83=_acX[i];}}this._uV.className=_83;this._sR=COTStyle.GetPaddingLeft(this._uV);this._xc=COTStyle.GetPaddingRight(this._uV);this._oj=this._sR+this._xc;Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CUICrosstab::SetupSizingTestTables"]);};CUICrosstab.prototype.SetupSizingParams=function(){var _O3=document.createElement('A');_O3.className="MemberCellLabel";_O3.appendChild(document.createTextNode(CUICrosstab.kSampleCharacter));this._kQ(this._be,_O3,"MemberCellLabel");var _XL=this._be;this._nc=_XL.offsetWidth;this._pX=_XL.offsetHeight;_O3.className="Property";this._be.appendChild(_O3.cloneNode(true));this._jY=this._be.offsetHeight-this._pX;};CUICrosstab.prototype.SetupCrosstabParameters=function(){Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CUICrosstab::SetupCrosstabParameters"]);this._m8=this._bz.GetDepth();this._m1=this._ax.GetDepth();this._t7=this._bz.GetLength();this._og=this._ax.GetLength();this._lw=false;this._tp=false;if(this._m8<1){this._m8=1;}if(this._m1<1){this._m1=1;}if(this._t7<1){this._t7=1;this._tp=true;}if(this._og<1){this._og=1;this._lw=true;}this._t6=new Array();this._sm=new Array();for(var i=0;i<this._t7+this._m1;++i){if(this._aF&&(i>this._m1-1)){this._t6[i]=CUICrosstab.kiFixedColWidth;this._sm[i]=CUICrosstab.kiFixedColWidth;}else{this._t6[i]=0;this._sm[i]=0;}}this._ri=new Array();for(var i=0;i<this._og+this._m8;++i){this._ri[i]=0;}Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CUICrosstab::SetupCrosstabParameters"]);};CUICrosstab.prototype.Unload=function(){Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CUICrosstab::Unload"]);this._ax.Unload();Utilities.RemoveAllChildObjects(this._ax);this._bz.Unload();Utilities.RemoveAllChildObjects(this._bz);this._o2.Refresh();Utilities.RemoveAllChildObjects(this._o2);Dom.RemoveObject(this._ro);Dom.RemoveObject(this._nH);Dom.RemoveObject(this._g0);Dom.RemoveObject(this._cj);Utilities.ClearObjectArray(this._e6);Utilities.DeleteAllFromArray(this._nf);this._x2.Clear();Utilities.ClearObjectArray(this._nS);Utilities.ClearObjectArray(this._wk);Utilities.RemoveAllChildObjects(this);Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CUICrosstab::Unload"]);};CUICrosstab.prototype.SetTop=function(_TM){this._ro.style.top=_TM+"px";};CUICrosstab.prototype.SetLastAxisSelected=function(_Q1){this._hL=_Q1;};CUICrosstab.prototype.removeStaleDisplayElements=function(_MU){this._jN._m4.RemoveDeleteDestination(this._cf);var _Gw=null;var _2r=null;var _3X=_MU.childNodes.length-1;for(var i=_3X;i>=0;i--){_Gw=_MU.childNodes[i];if(_Gw!=this.oScrollVDiv&&_Gw!=this.oScrollHDiv){var _GN=true;Dom.RemoveObject(_Gw,true);}}Dom.RePaint(_MU);};CUICrosstab.prototype.DrawCrosstab=function(){/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oDrawCrosstab.StartTimer(true);}/*@end@*/if(this._aF){Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CUICrosstab::DrawLiteCrosstab"]);}else{Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CUICrosstab::DrawCrosstab"]);}var _MU=this._ro;if(this._w7){return;}this._ax.CleanAnnotations();this._bz.CleanAnnotations();this._ax.CleanBlockSelectors();this._bz.CleanBlockSelectors();this._ax.CleanSuppressionArr();this._bz.CleanSuppressionArr();this.removeStaleDisplayElements(_MU);this._pS.Clear();if(this._aF&&this._xv){this._xv.Clear();}if(!this._jN.IsCrosstabVisible()){this._r7=1;this._yc=1;this._pO=1;this._aD=1;this.UpdateScrollBars(_MU);this.Notify(ExpEvent.kCUICrosstab_DrawComplete,true);return;}var _apz=this._nf;if(_apz.length==0){return;}if(this._aF){this.DrawLiteCrosstab();Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CUICrosstab::DrawLiteCrosstab"]);return;}var _8S=this._m8;var _8w=this._m1;var _aC6=this._bz;var _ar3=this._ax;var _ajR=this._t6;var _agA=this._ri;var _aaz=this._t7;var _atv=this._og;if(this._fJ!=-1){_atv=this._fJ;}var _aF1=this._lw;var _ajZ=this._tp;var _LZ=this._nj;var _HS=this._rz;var _NV;var _1X;var _WF;var _aAj=new Array();this._gw=_aAj;var _F4=0;/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oSizing.StartTimer(true);}/*@end@*/Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CUICrosstab::DrawCrosstab::Sizing"]);var _3A=_8w;for(var i=0;i<_3A;++i){_F4+=_ajR[i];_aAj[i]=_ajR[i];}this._a3=_F4;_NV=0;var _94=false;for(var i=_3A+_LZ;i<_ajR.length&&!_94;++i){_F4+=_ajR[i];_aAj[i-_LZ]=_ajR[i];_NV=i;if(_F4>(this._cI)&&!_ajZ){_94=true;}}var _arN=new Array();this._m2=_arN;var _T6=0;_1X=_8S;for(var i=0;i<_1X;++i){_T6+=_agA[i];_arN[i]=_agA[i];}this._ne=_T6;_WF=0;var _azh=false;for(var i=_1X+_HS;i<_agA.length&&!_azh;++i){_T6+=_agA[i];_WF=i;_arN[i-_HS]=_agA[i];if(_T6>=(this._p3)&&!_aF1){_azh=true;}}this._n5=_T6;if(_azh){this._n5=this._p3;}var _alo=new Array();for(var j=0;j<_3A;++j){for(i=0;i<_agA.length;++i){if(i<_1X){this.AddObjToArray(_apz[j][i],_alo,j,i);}else if(i>=_HS+_1X&&i<=_WF){this.AddObjToArray(_apz[j][i],_alo,_alo.length-1,_alo[_alo.length-1].length);}}}for(var j=_LZ+_3A;j<=_NV;++j){for(i=0;i<_agA.length;++i){if(i<_1X){this.AddObjToArray(_apz[j][i],_alo,j-_LZ,i);}else if(i>=_HS+_1X&&i<=_WF){this.AddObjToArray(_apz[j][i],_alo,_alo.length-1,_alo[_alo.length-1].length);}}}Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CUICrosstab::DrawCrosstab::Sizing"]);/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oSizing.StopTimer(true);}/*@end@*/var _T6=0;if(_aF1&&_ajZ){var _avA=document.createElement('DIV');var _F3=this._sp.GetString('IDS_CROSSTAB_INSTRUCTION_TEXT');var _aa7=document.createTextNode(_F3);_avA.appendChild(_aa7);_avA.className='InstructionText';_MU.appendChild(_avA);_T6=COTStyle.GetDisplayOffsetHeight(_avA)+CUIManager.kiSpaceBtwComponents/2;COTStyle.SetHeight(this._qB,this._p3-_agA[0]-2*this._nz-_T6);}var _aoc=document.createElement('DIV');_aoc.className="pg crosstabTableDiv";_aoc.style.top=_T6+'px';this._cf=_aoc;this._jN._m4.AddDeleteDestination(this._cf);COTStyle.SetHeight(this._ro,this._tJ);COTStyle.SetHeight(_aoc,this._p3);COTStyle.SetWidth(_aoc,this._cI);_MU.appendChild(_aoc);var _zr=document.createElement('TABLE');_zr.className=Dom.GetStyleByBrowser("crosstabTable");this._vO=_zr;var _F0=document.createElement('TBODY');var _awf=0;_zr.style.tableLayout='fixed';var _62=document.createElement('COLGROUP');_F0.appendChild(_62);_62.style.padding='0px';for(var _T4=0;_T4<_alo.length;_T4++){var _aFV=document.createElement('COL');_62.appendChild(_aFV);var _ax6=false;if(_T4>_8w-1){_awf++;_Vl=_alo[_T4][0];var oMem=null;if(_Vl){oMem=_Vl.axisMember;}if(oMem){_ax6=oMem.IsSiblingProxy();}}var _ae1=(_T4>0)&&(_T4<_8w);if(_ae1||_ax6){COTStyle.SetWidth(_aFV,_aAj[_T4],'px');}else{COTStyle.SetWidth(_aFV,_aAj[_T4],'px');}}var _aqd=new Array();Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CUICrosstab::DrawCrosstab::MainLoop"]);for(var j=0;j<_alo[0].length;++j){_aqd[j]=document.createElement('TR');for(var i=0;i<_alo.length;++i){var _Vl=null;if(i==0&&j==0){_Vl=_alo[0][0];COTStyle.SetTDOverflow(_Vl,'hidden');}else if(i<_8w&&j<_8S){continue;}else if(i<_8w){_Vl=_alo[i][j];var oMem=null;if(_Vl){oMem=_Vl.axisMember;COTStyle.SetTDOverflow(_Vl,'hidden');}if(oMem){if(oMem.IsSiblingProxy()&&j!=_8S){_Vl.setAttribute('rowSpan',1);continue;}else if(oMem.IsChildProxy()){continue;}else{var _07=0;if(oMem.IsSiblingProxy()){_Vl=oMem.GetHtmlElement();oMem.SetRowAxisBlockBorder(_Vl,oMem._kG,oMem._rn);_07=oMem.GetSiblingProxyCount()+1-(_HS-oMem.GetMemberPos());if(_HS+_07+(_8S-1)>_WF-1){_07=_WF-_HS-(_8S-1);}_Vl.setAttribute('rowSpan',_07);}else{oMem.SetRowAxisBlockBorder(_Vl,oMem._kG,oMem._rn);_Vl.rowSpan=oMem.GetSiblingProxyCount()+1;_07=oMem.GetSiblingProxyCount()+1;if(_07>1&&oMem.GetMemberPos()+_07+(_8S-1)>(_WF-1)){_07=_WF-oMem.GetMemberPos()-(_8S-1);_Vl.setAttribute('rowSpan',_07);}}}if(_Vl){/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oSizing.StartTimer(true);}/*@end@*//*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oSizing.StopTimer(true);}/*@end@*/}}}else if(j<_8S){_Vl=_alo[i][j];var oMem=null;if(_Vl){oMem=_Vl.axisMember;COTStyle.SetTDOverflow(_Vl,'hidden');}if(oMem){if(oMem.IsSiblingProxy()&&i!=_8w){_Vl.colSpan=1;continue;}else if(oMem.IsChildProxy()){continue;}else{if(oMem.IsSiblingProxy()){_Vl=oMem.GetHtmlElement();oMem.SetColAxisBlockBorder(_Vl,oMem._kG,oMem._rn);_Vl.colSpan=oMem.GetSiblingProxyCount()+1-(_LZ-oMem.GetMemberPos());if(_LZ+_Vl.colSpan+(_8w-1)>_NV){_Vl.colSpan=_NV-_LZ-(_8w-1);}}else{oMem.SetColAxisBlockBorder(_Vl,oMem._kG,oMem._rn);_Vl.colSpan=oMem.GetSiblingProxyCount()+1;if(_Vl.colSpan>1&&_Vl.colSpan+oMem.GetMemberPos()+(_8w-1)>_NV){_Vl.colSpan=_NV-oMem.GetMemberPos()-(_8w-1);}}if(this._aF&&Utilities.bCharBasedTruncation&&(oMem._rn<(_8S-1))){var _aIa=(oMem.GetMemberPos()>_LZ)?oMem.GetMemberPos()+this._m1:_LZ+this._m1;var _anF=0;for(var _ato=0;_ato<_Vl.colSpan;_ato++){_anF+=this._t6[_aIa+_ato];}var _8z=Math.round(this._a9*(_anF/CUICrosstab.kiFixedColWidth));var _WA=oMem.GetLabel();if(_WA.length>(_8z)){_WA=Utilities.GetTruncatedString(_WA,(_8z-2),this._sp);}var _axO=Dom.GetElementsByTagName(_Vl,"A");if(_axO[0]){Dom.ReplaceTextNode(_axO[0],_WA);_axO[0].className='MemberCellLabel';}}}if(_Vl&&_Vl.colSpan==1){/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oSizing.StartTimer(true);}/*@end@*//*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oSizing.StopTimer(true);}/*@end@*/}if(_Vl){/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oSizing.StartTimer(true);}/*@end@*/if(_Vl.axisMember.GetChildProxyCount()==0){var _T6=_arN[j];COTStyle.SetHeight(_Vl,_T6);}else{var _6y=_arN[j];for(var _8s=1;_8s<=_Vl.axisMember.GetChildProxyCount();_8s++){_6y+=_arN[j+_8s];}COTStyle.SetHeight(_Vl,_6y);}/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oSizing.StopTimer(true);}/*@end@*/}}}else if(i==_8w&&j==_8S){_Vl=_alo[i][j];var _aG1=this._o2.GetCentralMeasurePresentationType();if(_Vl){if(!(_aG1==ExpAPIXml.kDefMeaNonePretType)&&(!this._o2.CentralMeasureExists()&&!this._o2.HasData())){_Vl.colSpan=Math.max(_awf,1);_Vl.rowSpan=Math.max(_WF-_HS-(_8S-1),1);}}else if(this._nG){_Vl=this._nG;_Vl.colSpan=Math.max(_awf,1);_Vl.rowSpan=Math.max(_WF-_HS-(_8S-1),1);}}else if(i>=_8w&&j>=_8S){_Vl=_alo[i][j];if(_Vl){_Vl.rowSpan=1;_Vl.colSpan=1;}}else{Debug.Assert(false,"index");}if(_Vl){COTStyle.AddCSSClassToEle(_Vl,"SecondClass");/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oAppendingCells.StartTimer(true);}/*@end@*/_aqd[j].appendChild(_Vl);/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oAppendingCells.StopTimer(true);}/*@end@*/}}/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oAppendingRows.StartTimer(true);}/*@end@*/_F0.appendChild(_aqd[j]);/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oAppendingRows.StopTimer(true);}/*@end@*/}Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CUICrosstab::DrawCrosstab::MainLoop"]);/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oAppendingTable.StartTimer(true);}/*@end@*/Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CUICrosstab::DrawCrosstab::AppendTable"]);_zr.appendChild(_F0);_aoc.appendChild(_zr);Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CUICrosstab::DrawCrosstab::AppendTable"]);/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oAppendingTable.StopTimer(true);}/*@end@*//*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oCustomScroll.StartTimer(true);}/*@end@*/Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CUICrosstab::DrawCrosstab::CustomScroll"]);this._pO=_atv;if(_azh){this._r7=_WF-_1X-_HS;}else{this._r7=_WF-_1X-_HS+1;}this._aD=_aaz;if(_94){this._yc=_NV-_3A-_LZ;}else{this._yc=_NV-_3A-_LZ+1;}this._yc=Math.max(this._yc,1);this._r7=Math.max(this._r7,1);if(!_ajZ&&this._yc+_LZ>=this._aD){this.CheckActualHVisibleUnits(_LZ);}if(!_aF1&&this._r7+_HS>=this._pO){this.CheckActualVVisibleUnits(_HS);}var _59=(_HS+this._r7)<this._pO?1:0;var _ak5=this._r7+_59;_ar3.SetVisibleMembersRange(_HS,_ak5);_59=(_LZ+this._yc)<this._aD?1:0;_ak5=this._yc+_59;_aC6.SetVisibleMembersRange(_LZ,_ak5);this._P=_3A;this._nL=_1X;this.UpdateScrollBars(this._ro);Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CUICrosstab::DrawCrosstab::CustomScroll"]);/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oCustomScroll.StopTimer(true);}/*@end@*/Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CUICrosstab::DrawCrosstab::AddBlockInfo"]);for(var _BZ=0;_BZ<2;_BZ++){var _O0=(_BZ==0)?this._ax:this._bz;var _3I=CUIAxisMember.kTLCorner;for(var i=0;i<_O0.aBlockSelectorMembers.length;i++){if(_O0.IsMemberVisible(_O0.aBlockSelectorMembers[i])){var _ayb=_O0.aBlockSelectorMembers[i];var _Vl=_ayb.GetHtmlElement();var _Gi=0;if(_o.is_ie5_5up){var _F4=(_BZ==0)?_Vl.offsetWidth:CUICrosstab.kiBlockSelectorStaticDimension;var _T6=(_BZ==0)?CUICrosstab.kiBlockSelectorStaticDimension:_Vl.offsetHeight;}else{var _F4=(_BZ==0)?_Vl.offsetWidth-2:CUICrosstab.kiBlockSelectorStaticDimension-2;var _T6=(_BZ==0)?CUICrosstab.kiBlockSelectorStaticDimension-2:_Vl.offsetHeight-2;}var _aa2=(_BZ==0)?"BlockSelectorRows":"BlockSelectorCols";var _anz=COTInputElementFactory.AppendDivOnTop(this._cf,_Vl,_3I,_aa2,_T6,_F4,null,null,0,_Gi,true);_anz.sClass=_aa2;var _Mz=_anz.appendChild(document.createElement('IMG'));var _6R=(_BZ==0)?"level_hover_down.gif":"level_hover_right.gif";_Mz.src=Utilities.IMG_PATH+_6R;_Mz.style.visibility="hidden";if(_BZ==1){_Mz.style.position="absolute";_Mz.style.top=parseInt(_Vl.offsetHeight/2-4)+"px";_Mz.style.left="0px";COTStyle.SetWidth(_Mz,5);COTStyle.SetHeight(_Mz,8);_Mz.style.marginLeft="0px";}else{_Mz.style.marginTop="0px";}_anz.onmouseover=Utilities.EventCallback(CUICrosstab.OnMouseOverBlockSel,[_ayb],null,false,true);_anz.onmouseout=Utilities.EventCallback(CUICrosstab.OnMouseOutBlockSel,[_ayb],null,false,true);_anz._sBlockId=_ayb.GetBlock().GetId();_anz._sBlockMetadataId=_ayb.GetBlock().GetHierarchyOrDimId();Dom.SetObjRef(_anz,_ayb,"axisMember");var _Lx=Utilities.GenerateId();_anz.id=_Lx;_O0.AddBlockSelectorId(_Lx);}}}var _apv=CUIAxisMember.SafeDoShowAnnotation;for(var n=0;n<2;n++){var _O0=(n==0)?this._ax:this._bz;var _8Z=(n==0)?CUIAxisMember.kTRCorner:CUIAxisMember.kTLCorner;var _Tf=(n==0)?'annotation_triangle.gif':'annotation_triangle_columns.gif';for(var i=0;i<_O0._pa.length;i++){var _Vl=_O0._pa[i];if(_Vl.axisMember){var _Vj=_Vl.axisMember.GetBlock().GetName();if(_Vj){var _Rz=_Vj;var _Bf=_Vl.axisMember.GetBlock().GetAnnotation();if(_Bf){_Rz=this._sp.ReplaceParam('IDS_BLOCK_NAME_ANNOTATION_TOOLTIP',1,_Vj);_Rz=this._sp.ReplaceParam(_Rz,2,_Bf);}var _azP=COTInputElementFactory.AppendImgOnTop(this._cf,_Vl,_8Z,_Tf,_Rz,5,5,CUIAxisMember.SafeDoHighlightBlock,CUIAxisMember.SafeDoSetNormalBlock,0,0);_azP.className="Annotation";}}}_8Z=(n==0)?CUIAxisMember.kTLCorner:CUIAxisMember.kTRCorner;_Tf=(n==0)?"Row_member_annotation.gif":"Col_member_annotation.gif";for(var i=0;i<_O0._dS.length;i++){if(_O0.IsMemberVisible(_O0._dS[i])){var _Bf=_O0._dS[i].GetAnnotation();var _Vl=_O0._dS[i].GetHtmlElement();var _afT=COTInputElementFactory.AppendImgOnTop(this._cf,_Vl,_8Z,_Tf,_Bf,5,5,null,null,2,1,true);_afT.className="Annotation";}}var _8Z=CUIAxisMember.kTRCorner;var _Tf='suppression_right.gif';for(var i=0;i<_O0._eA.length;i++){var _y9=this._nz*2;var _Sy=this._nz;var _Vl=_O0._eA[i];if(n==0&&_Vl.axisMember&&_Vl.axisMember._lX){_y9+=CUICrosstab.kiBlockSelectorStaticDimension;}for(var j=0;j<_O0._dS.length;j++){var _aJq=_O0._dS[j].GetHtmlElement();if(_aJq.uniqueID==_Vl.uniqueID){if(_afT){_Sy=_afT.width;}break;}}var _01=_O0.IsRowAxis()?'IDS_CROSSTAB_ROWS_':'IDS_CROSSTAB_COLS_';var _ath=this._jN._my._ak._kX._by;_01+=(_ath?'ZERO_AND_NULL':'NULL')+'_SUPPRESSION_TUPLE_TOOLTIP';var _azP=COTInputElementFactory.AppendImgOnTop(this._cf,_Vl,_8Z,_Tf,this._sp.GetString(_01),6,6,null,null,0,0,true,_y9,_Sy);}}this._pS.CreateSideDZ(this._cf,'drop_caret_2x2.gif');if(this._aF){this._xv.OnCreate('black_dot.gif',this,this._cf);this._xv.HideBar();}this.Notify(ExpEvent.kCUICrosstab_DrawComplete,true);Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CUICrosstab::DrawCrosstab::AddBlockInfo"]);Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CUICrosstab::DrawCrosstab"]);/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oDrawCrosstab.StopTimer();}/*@end@*/};CUICrosstab.OnMouseOverBlockSel=function(e,_IU){this.firstChild.style.visibility="visible";this.className=this.sClass+"Hover";CUIAxisMember.SafeDoHighlightBlockMembers(_IU);};CUICrosstab.OnMouseOutBlockSel=function(e,_IU){this.firstChild.style.visibility="hidden";this.className=this.sClass;CUIAxisMember.SafeDoEndHighlightBlockMembers(_IU);};CUICrosstab.prototype.TestCellSize=function(_Vl,_Wb,_O2,_Tq,_L2,_E3){/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oSizing.StartTimer(true);g_oTestCellSize.StartTimer(true);}/*@end@*/var _5X,_awu;if(_L2){this._vZ.appendChild(_Vl);_5X=this.GetCellWidth(_Vl);_awu=this.GetCellHeight(_Vl);this.RemoveTestTD(this._vZ);}else{this._kQ(this._be,_Tq,_E3);var _XL=this._be;_5X=this.GetCellWidth(_XL);_awu=this.GetCellHeight(_XL);if(_Vl.axisMember&&_Vl.axisMember.GetAxis().IsRowAxis()){_5X+=_Vl.axisMember.GetUIAxisMember().GetIndentWidth();if(_Vl.axisMember._lX){_awu+=CUICrosstab.kiBlockSelectorStaticDimension;}}else if(_Vl.axisMember&&_Vl.axisMember.GetAxis().IsColAxis()){if(_Vl.axisMember._lX){_5X+=CUICrosstab.kiBlockSelectorStaticDimension;}}}if(_O2==this._m8-1&&(_Wb>0)){this._sm[_Wb]=this._t6[_Wb];if(_5X<this._t6[_Wb]){this._t6[_Wb]=_5X;}}if(_5X>this._t6[_Wb]){this._t6[_Wb]=_5X;}if(_awu>this._ri[_O2]){this._ri[_O2]=_awu;}/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oSizing.StopTimer();g_oTestCellSize.StopTimer();}/*@end@*/};CUICrosstab.prototype.TestDynamicCalcCellWidth=function(_ON,_Wb,_O2,_Tq,_E3){this._kQ(this._be,_Tq,_E3);var _XL=this._be;var _5X=this.GetCellWidth(_XL);var _O0=_ON.GetAxis();if(_O0.IsColAxis()){if(_ON._lX){_5X+=CUICrosstab.kiBlockSelectorStaticDimension;}}else if(_O0.IsRowAxis()){_5X+=CUICrosstab.kiIndentWidth;}var _YD=0;if(_O0.IsColAxis()){var _asg=this.GetTupleOnColEdge(_ON.GetUIAxisMember());_YD=this._x2.GetColWidthByTuple(_asg);}else{_YD=this._x2.GetRowHeaderColWidthByBlockId(_ON.GetBlock().GetId());}if(_5X>this._t6[_Wb]&&!_YD){this._t6[_Wb]=_5X;this._oP=true;}};CUICrosstab.prototype.SetColProxyCellSize=function(_VM,_Wb,_O2){if(this._t6[_Wb]<this._t6[_VM.GetMemberPos()+this._m1]){}};CUICrosstab.prototype.TestDataCellTemplateSize=function(_Wb,_O2,_BM){this._wq(this._uV,_BM);var _5X=this.GetCellWidth(this._uV);var _arQ=0;for(var i=1;i<this._t6.length;i++){_arQ+=this._t6[i];}if(_5X>_arQ){var _YM=Math.ceil((_5X-_arQ)/(this._t6.length-1));for(var i=1;i<this._t6.length;i++){this._t6[i]+=_YM;}}var _awu=this.GetCellHeight(this._uV);var _7c=0;for(var i=0;i<this._ri.length;i++){_7c+=this._ri[i];}if(_awu>_7c){var _aAH=Math.ceil((_awu-_7c)/(this._ri.length-1));for(var i=0;i<this._ri.length;i++){this._ri[i]+=_aAH;}}};CUICrosstab.prototype.TestDataCellSize=function(_Wb,_O2,_BM,_E3){/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oSizing.StartTimer(true);g_oTestCellSize.StartTimer(true);}/*@end@*/var _5X,_awu;this._wq(this._uV,_BM,_E3);_5X=this.GetCellWidth(this._uV);if(!this._I[_Wb]){this._I[_Wb]=new Array();}this._I[_Wb][_O2]=_5X;if(_5X>this._t6[_Wb]){this._t6[_Wb]=_5X;}/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oSizing.StopTimer(true);g_oTestCellSize.StopTimer(true);}/*@end@*/};CUICrosstab.prototype._wq=function(_Vl,_BM,_E3){Dom.ReplaceText(_Vl,_BM);};CUICrosstab.prototype._kQ=function(_Vl,_Tq,_E3){var _aJn=_Tq.cloneNode(true);var _aeE=_Vl.firstChild;if(!_aeE){_Vl.appendChild(_aJn);}else{_Vl.replaceChild(_aJn,this._iA);}this._iA=_aJn;_Vl.className=_E3;};CUICrosstab.prototype.GetCellWidth=function(_RS){return _RS.offsetWidth;};CUICrosstab.prototype.GetCellHeight=function(_RS){return _RS.offsetHeight;};CUICrosstab.prototype.RemoveTestTD=function(_NH){if(_NH.childNodes.length>1){Debug.Assert(false);}var _Gw=_NH.firstChild;var _2r=_NH.removeChild(_Gw);_2r=null;_Gw=null;};CUICrosstab.prototype.CreateColMemberCell=function(x,y){var _apz=this._nf;var _aC6=this._bz;var _ar3=this._ax;var _8S=this._m8;var _8w=this._m1;var _aaz=this._t7;var _atv=this._og;if(_apz[x+_8w]&&_apz[x+_8w][y]){return;}var _Vl=document.createElement('TD');var oMem=_aC6.GetMember(x,y);if(oMem&&oMem.IsChildProxy()){var _ON=oMem.GetUIAxisMember();_ON.GetHtmlElement().rowSpan=_ON.GetChildProxyCount()+1;_Vl.axisMember=oMem;var _aoh=oMem.GetHtmlElement();_ON.SetBottomBorder(_aoh,y,false);}else if(oMem&&oMem.IsSiblingProxy()){var _ON=oMem.GetUIAxisMember();_Vl.axisMember=oMem;var _aoh=oMem.GetHtmlElement();_ON.SetRightBorder(_aoh,x+_8w,false);this.SetColProxyCellSize(_ON,x+_8w,y);oMem._kG=x+_8w;oMem._rn=y;}else{/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oCreateRowCol.StartTimer(true);}/*@end@*/if(oMem!=null){var _BM="";var _3f;var _Tq=document.createElement('DIV');_Tq.iDropZoneType=CUIDropZone.kReplaceDrop;_Tq.cellType=CUICrosstab.kMemberCellOther;var _O3=document.createElement('A');_O3.iDropZoneType=CUIDropZone.kReplaceDrop;_O3._jX=true;if(!oMem.CanDrillUpOrDown()){_O3._jX=false;_O3.cellType=CUICrosstab.kMemberCellOther;}_O3._iQ=oMem.GetUniqueID();oMem.SetHtmlElement(_Vl);_Vl.cellType=CUICrosstab.kMemberCell;Dom.SetObjRef(_Vl,oMem,'axisMember');_O3.className="MemberCellLabel";var _aEB=oMem.GetAxisMember();var _abG=_aEB.IsDynamicCalc();oMem.DrawMemberText(_Vl,_Tq,_O3);var _5Z=oMem.GetPropertyCount();for(var i=0;i<_5Z;i++){if(_aEB.GetProperty(i).IsEnabled()){_Tq.appendChild(oMem.DrawProperty(i));}}oMem._kG=x+_8w;oMem._rn=y;this._oZ(_Vl,_Tq);oMem.SetCellStyle();oMem.SetIndent();oMem.SetBlockSelectorPadding();}/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oCreateRowCol.StopTimer(true);}/*@end@*/if(!this._aF){/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oTestColDataSize.StartTimer(true);}/*@end@*/this.TestCellSize(_Vl,x+_8w,y,_Tq,false,_Vl.className);/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oTestColDataSize.StopTimer();}/*@end@*/}else if(_abG){this.TestDynamicCalcCellWidth(oMem,x+_8w,y,_Tq,_Vl.className);}}_Vl.bFstDraw=true;this.AddObjToArray(_Vl,_apz,x+_8w,y);if(oMem==null){this.Refresh();}};CUICrosstab.prototype.CreateRowMemberCell=function(x,y){var _apz=this._nf;var _aC6=this._bz;var _ar3=this._ax;var _8S=this._m8;var _8w=this._m1;var _aaz=this._t7;var _atv=this._og;if(_apz[x]&&_apz[x][y+_8S]){return;}var _Vl=document.createElement('TD');var oMem=_ar3.GetMember(y,x);if(oMem.IsChildProxy()){var _ON=oMem.GetUIAxisMember();_ON.GetHtmlElement().colSpan=_ON.GetChildProxyCount()+1;Dom.SetObjRef(_Vl,oMem,'axisMember');var _aoh=oMem.GetHtmlElement();_ON.SetRightBorder(_aoh,x,true);}else if(oMem.IsSiblingProxy()){var _ON=oMem.GetUIAxisMember();Dom.SetObjRef(_Vl,oMem,'axisMember');var _aoh=oMem.GetHtmlElement();_ON.SetBottomBorder(_aoh,y+_8S,true);oMem._kG=x;oMem._rn=y+_8S;}else{/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oCreateRowCol.StartTimer(true);}/*@end@*/if(oMem!=null){var _BM="";var _3f;var _Tq=document.createElement('DIV');_Tq.iDropZoneType=CUIDropZone.kReplaceDrop;_Tq.cellType=CUICrosstab.kMemberCellOther;var _O3=document.createElement('A');_O3.iDropZoneType=CUIDropZone.kReplaceDrop;_O3._jX=true;if(!oMem.CanDrillUpOrDown()){_O3._jX=false;_O3.cellType=CUICrosstab.kMemberCellOther;}_O3._iQ=oMem.GetUniqueID();oMem.SetHtmlElement(_Vl);_Vl.cellType=CUICrosstab.kMemberCell;Dom.SetObjRef(_Vl,oMem,'axisMember');_O3.className="MemberCellLabel";oMem.DrawMemberText(_Vl,_Tq,_O3);var _aEB=oMem.GetAxisMember();var _abG=_aEB.IsDynamicCalc();var _5Z=oMem.GetPropertyCount();for(var i=0;i<_5Z;i++){if(_aEB.GetProperty(i).IsEnabled()){_Tq.appendChild(oMem.DrawProperty(i));}}oMem._kG=x;oMem._rn=y+_8S;this._oZ(_Vl,_Tq);oMem.SetCellStyle();oMem.SetIndent();oMem.SetBlockSelectorPadding();}/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oCreateRowCol.StopTimer(true);}/*@end@*//*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oTestRowDataSize.StartTimer(true);}/*@end@*/if(!this._aF){this.TestCellSize(_Vl,x,y+_8S,_Tq,false,_Vl.className);}else if(_abG){this.TestDynamicCalcCellWidth(oMem,x,y+_8S,_Tq,_Vl.className);}/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oTestRowDataSize.StopTimer();}/*@end@*/}_Vl.bFstDraw=true;this.AddObjToArray(_Vl,_apz,x,y+_8S);};CUICrosstab.prototype.CreateDataCell=function(x,y){/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oGetDataCellData.StartTimer(true);}/*@end@*/var _apz=this._nf;var _aC6=this._bz;var _ar3=this._ax;var _8S=this._m8;var _8w=this._m1;if(_apz[x+_8w]&&_apz[x+_8w][y+_8S]){return;}var _Vl;/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oCreateDataCell.StartTimer(true);}/*@end@*/_Vl=this._o2.GetCell(x,y);var _asr=_ar3.GetMember(y,_8w-1);var _aFJ=_aC6.GetMember(x,_8S-1);if(_asr&&_aFJ){var _45=_asr.GetAxisMember();var _9H=_aFJ.GetAxisMember();if(_45&&_9H){var _0b=_45.IsSummaryOrNestedSummary();var _auU=_9H.IsSummaryOrNestedSummary();if(_asr&&_0b||_aFJ&&_auU){_Vl.bIsTotal=true;_Vl.bIsInnerTotal=((_0b&&(!_asr.bIsInnerTotal))||(_auU&&(!_aFJ.bIsInnerTotal)))?false:true;}if(_45.IsSummaryMemOrCalc()&&_9H.IsSummaryMemOrCalc()&&(_asr.CanDrillUpOrDown()||_aFJ.CanDrillUpOrDown())){_Vl.bDrillable=true;_Vl.bDrillUp=true;}else if(_asr.CanDrillDown()||_aFJ.CanDrillDown()){_Vl.bDrillable=true;}if(_45.IsCalc()||_9H.IsCalc()){if((_45.IsCustomCalc())||(_9H.IsCustomCalc())){_Vl.bCalc=true;}if(_45.IsRemainder()||_9H.IsRemainder()){_Vl.bRemainder=true;}if(_45.IsSubtotal()||_9H.IsSubtotal()){_Vl.bSubtotalItems=true;}if(_45.IsNotExcludedSubtotal()||_9H.IsNotExcludedSubtotal()){_Vl.bInclSubtotal=true;}if(_45.IsExcludedSubtotal()||_9H.IsExcludedSubtotal()){_Vl.bExclSubtotal=true;}}}}if(_Vl.bDependOnParentMember){var _aG1=this._o2.GetCentralMeasurePresentationType();var _0S=this._o2.GetCentralMeasureLabel();Debug.Assert(!(_asr&&_aFJ));if(_aG1==ExpAPIXml.kDefMeaNonePretType||_aG1==ExpAPIXml.kDefMeaInactivePretType){if(_asr||_aFJ){_0S=_asr?_asr.GetLabel():_aFJ.GetLabel();}}else if(_aG1==ExpAPIXml.kDefMeaSecondaryActivePretType){var _RJ=this._jN._m4.dataManager.metadata;if(_asr&&_RJ.GetMeasure(_asr.GetMemberId())){_0S=_asr.GetLabel();}else if(_aFJ&&_RJ.GetMeasure(_aFJ.GetMemberId())){_0S=_aFJ.GetLabel();}else{_0S=this._o2.GetCentralMeasureLabel();}}_Vl.value=_0S;_Vl.title=_0S;_Vl.appendChild(document.createTextNode(_0S));}this._o2.SetCellStyle(_Vl);if(this._aF){var _F4=this._t6[x+_8w];this.ResetCellLabel(_Vl,_F4);}this.AddObjToArray(_Vl,_apz,x+_8w,y+_8S);/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oGetDataCellData.StopTimer(true);}/*@end@*//*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oCreateDataCell.StopTimer(true);}/*@end@*/if(!this._aF){/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oTestDataCellSize.StartTimer(true);}/*@end@*/this.TestDataCellSize(x+_8w,y+_8S,_Vl.innerHTML,_Vl.className);/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oTestDataCellSize.StopTimer(false);}/*@end@*/}};CUICrosstab.prototype.DrawLiteCrosstab=function(){var _aC6=this._bz;var _ar3=this._ax;var _8S=this._m8;var _8w=this._m1;var _aF1=this._lw;var _ajZ=this._tp;var _LZ=this._nj;var _HS=this._rz;var _MU=this._ro;var _T6=0;if(_aF1&&_ajZ){var _avA=document.createElement('DIV');var _F3=this._sp.GetString('IDS_CROSSTAB_INSTRUCTION_TEXT');var _aa7=document.createTextNode(_F3);_avA.appendChild(_aa7);_avA.className='InstructionText';_MU.appendChild(_avA);_T6=COTStyle.GetDisplayOffsetHeight(_avA)+CUIManager.kiSpaceBtwComponents/2;this._ri[1]=this._kc-_T6;COTStyle.SetHeight(this._qB,this._ri[1]-2*this._nz);}var _aoc=document.createElement('DIV');_aoc.className="pg crosstabTableDiv";_aoc.style.top=_T6+'px';this._cf=_aoc;this._jN._m4.AddDeleteDestination(this._cf);COTStyle.SetHeight(this._ro,this._tJ);COTStyle.SetHeight(_aoc,this._p3);COTStyle.SetWidth(_aoc,this._cI);Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CUICrosstab::DrawLiteCrosstab::PrepareFixedLayOutTableRender"]);_MU.appendChild(_aoc);var _zr=document.createElement('TABLE');_zr.className=Dom.GetStyleByBrowser("crosstabTable");this._vO=_zr;var _F0=document.createElement('TBODY');var _awf=0;_zr.style.tableLayout='fixed';var _arQ=0;var _arW=_F0.appendChild(document.createElement('TR'));for(var _T4=0;_T4<_8w;_T4++){var _arS=_arW.appendChild(document.createElement('TD'));COTStyle.SetWidth(_arS,this._t6[_T4]+2*this._nz,'px');_arQ+=(this._t6[_T4]+2*this._nz);}for(var _T4=_LZ;_T4<this._sW+_LZ;_T4++){var _arS=_arW.appendChild(document.createElement('TD'));COTStyle.SetWidth(_arS,this._t6[_T4+_8w]+2*this._nz,'px');_arQ+=(this._t6[_T4+_8w]+2*this._nz);}if(_o.is_firefox){COTStyle.SetWidth(_zr,_arQ);}var _aqd=new Array();var _9X=_8S+this._ye;var _2n=_8w+this._sW;Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CUICrosstab::DrawLiteCrosstab::PrepareFixedLayOutTableRender"]);Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CUICrosstab::DrawLiteCrosstab::MainLoop"]);for(var _apd=0;_apd<_9X;++_apd){_aqd[_apd]=document.createElement('TR');for(var _al4=0;_al4<_2n;++_al4){var _Vl=null;if(_al4==0&&_apd==0){_Vl=this._nf[0][0];COTStyle.SetTDOverflow(_Vl,'hidden');}else if(_al4<_8w&&_apd<_8S){continue;}else if(_al4<_8w){_Vl=this._nf[_al4][_apd+_HS];var oMem=null;if(_Vl){oMem=_Vl.axisMember;COTStyle.SetTDOverflow(_Vl,'hidden');}if(oMem){if(oMem.IsSiblingProxy()&&_apd!=_8S){continue;}else if(oMem.IsChildProxy()){continue;}else{var _07=0;if(oMem.IsSiblingProxy()){_Vl=oMem.GetHtmlElement();oMem.SetRowAxisBlockBorder(_Vl,oMem._kG,oMem._rn);_07=oMem.GetSiblingProxyCount()+1-(_HS-oMem.GetMemberPos());_Vl.setAttribute('rowSpan',_07);}else{oMem.SetRowAxisBlockBorder(_Vl,oMem._kG,oMem._rn);_Vl.rowSpan=oMem.GetSiblingProxyCount()+1;if(_al4==(_8w-1)){if(_Vl.bFstDraw){COTStyle.SetHeight(_Vl,(this._ri[_apd+_HS]+this._p0+this._nz-(oMem._lX?(CUICrosstab.kiBlockSelectorStaticDimension+this._cz+2):0)));_Vl.bFstDraw=null;}}}}}}else if(_apd<_8S){_Vl=this._nf[_al4+_LZ][_apd];var oMem=null;if(_Vl){oMem=_Vl.axisMember;COTStyle.SetTDOverflow(_Vl,'hidden');}if(oMem){if(oMem.IsSiblingProxy()&&_al4!=_8w){_Vl.colSpan=1;continue;}else if(oMem.IsChildProxy()){continue;}else{if(oMem.IsSiblingProxy()){_Vl=oMem.GetHtmlElement();oMem.SetColAxisBlockBorder(_Vl,oMem._kG,oMem._rn);_Vl.colSpan=oMem.GetSiblingProxyCount()+1-(_LZ-oMem.GetMemberPos());}else{oMem.SetColAxisBlockBorder(_Vl,oMem._kG,oMem._rn);_Vl.colSpan=oMem.GetSiblingProxyCount()+1;}if(_al4==_8w){var _6y=this._ri[_apd]+this._p0+this._nz;for(var _8s=1;_8s<=_Vl.axisMember.GetChildProxyCount();_8s++){_6y+=this._ri[_apd+_8s]+this._p0+this._nz;}if(_Vl.bFstDraw){COTStyle.SetHeight(_Vl,_6y);_Vl.bFstDraw=null;}}}}}else if(_al4==_8w&&_apd==_8S){var _Li=this._jN.GetDataWorkSheet().GetDataManager().GetCurrentDataMatrix();if((!_Li.IsFullDataMode())&&this._nG){_Vl=this._nG;_Vl.colSpan=Math.max(this._sW,1);_Vl.rowSpan=Math.max(this._ye,1);}else{_Vl=this._nf[_al4+_LZ][_apd+_HS];var _aG1=this._o2.GetCentralMeasurePresentationType();if(_Vl){if(!(_aG1==ExpAPIXml.kDefMeaNonePretType)&&(!this._o2.CentralMeasureExists()&&!this._o2.HasData())){_Vl.colSpan=Math.max(this._sW,1);_Vl.rowSpan=Math.max(this._ye,1);}}else if(this._nG){_Vl=this._nG;Debug.Assert(!this._o2.CentralMeasureExists()&&!this._o2.HasData());_Vl.colSpan=Math.max(this._sW,1);_Vl.rowSpan=Math.max(this._ye,1);}}}else if(_al4>=_8w&&_apd>=_8S){_Vl=this._nf[_al4+_LZ][_apd+_HS];if(_Vl){_Vl.rowSpan=1;_Vl.colSpan=1;}}else{Debug.Assert(false,"index");}if(_Vl){COTStyle.AddCSSClassToEle(_Vl,"SecondClass");if(Dom.GetElementsByTagName(_Vl,'A').length==0){var _YX=document.createElement('A');_Vl.appendChild(_YX);}_aqd[_apd].appendChild(_Vl);}}_F0.appendChild(_aqd[_apd]);}Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CUICrosstab::DrawLiteCrosstab::MainLoop"]);Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CUICrosstab::DrawLiteCrosstab::AppendTable"]);_zr.appendChild(_F0);_aoc.appendChild(_zr);Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CUICrosstab::DrawLiteCrosstab::AppendTable"]);Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CUICrosstab::DrawLiteCrosstab::UpdateScrollbar"]);this.UpdateScrollBars(this._ro);Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CUICrosstab::DrawLiteCrosstab::UpdateScrollbar"]);Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CUICrosstab::DrawLiteCrosstab::AddBlockInfo"]);for(var _BZ=0;_BZ<2;_BZ++){var _O0=(_BZ==0)?this._ax:this._bz;var _3I=CUIAxisMember.kTLCorner;for(var i=0;i<_O0.aBlockSelectorMembers.length;i++){if(_O0.IsMemberVisible(_O0.aBlockSelectorMembers[i])){var _ayb=_O0.aBlockSelectorMembers[i];var _Vl=_ayb.GetHtmlElement();var _Gi=0;var _F4=(_BZ==0)?_Vl.offsetWidth:CUICrosstab.kiBlockSelectorStaticDimension;var _T6=(_BZ==0)?CUICrosstab.kiBlockSelectorStaticDimension:_Vl.offsetHeight;var _aa2=(_BZ==0)?"BlockSelectorRows":"BlockSelectorCols";var _anz=COTInputElementFactory.AppendDivOnTop(this._cf,_Vl,_3I,_aa2,_T6,_F4,null,null,0,_Gi,true);_anz.sClass=_aa2;var _Mz=_anz.appendChild(document.createElement('IMG'));var _6R=(_BZ==0)?"level_hover_down.gif":"level_hover_right.gif";_Mz.src=Utilities.IMG_PATH+_6R;_Mz.style.visibility="hidden";if(_BZ==1){_Mz.style.position="absolute";_Mz.style.top=parseInt(_Vl.offsetHeight/2-4)+"px";_Mz.style.left="0px";COTStyle.SetWidth(_Mz,5);COTStyle.SetHeight(_Mz,8);_Mz.style.marginLeft="0px";}else{_Mz.style.marginTop="0px";}_anz.onmouseover=Utilities.EventCallback(CUICrosstab.OnMouseOverBlockSel,[_ayb],null,false,true);_anz.onmouseout=Utilities.EventCallback(CUICrosstab.OnMouseOutBlockSel,[_ayb],null,false,true);_anz._sBlockId=_ayb.GetBlock().GetId();_anz._sBlockMetadataId=_ayb.GetBlock().GetHierarchyOrDimId();Dom.SetObjRef(_anz,_ayb,"axisMember");var _Lx=Utilities.GenerateId();_anz.id=_Lx;_O0.AddBlockSelectorId(_Lx);}}}var _apv=CUIAxisMember.SafeDoShowAnnotation;for(var n=0;n<2;n++){var _O0=(n==0)?this._ax:this._bz;var _8Z=(n==0)?CUIAxisMember.kTRCorner:CUIAxisMember.kTLCorner;var _Tf=(n==0)?'annotation_triangle.gif':'annotation_triangle_columns.gif';for(var i=0;i<_O0._pa.length;i++){var _Vl=_O0._pa[i];if(_Vl.axisMember){var _Vj=_Vl.axisMember.GetBlock().GetName();if(_Vj){var _Rz=_Vj;var _Bf=_Vl.axisMember.GetBlock().GetAnnotation();if(_Bf){_Rz=this._sp.ReplaceParam('IDS_BLOCK_NAME_ANNOTATION_TOOLTIP',1,_Vj);_Rz=this._sp.ReplaceParam(_Rz,2,_Bf);}var _azP=COTInputElementFactory.AppendImgOnTop(this._cf,_Vl,_8Z,_Tf,_Rz,5,5,CUIAxisMember.SafeDoHighlightBlock,CUIAxisMember.SafeDoSetNormalBlock,0,0);_azP.className="Annotation";}}}_8Z=(n==0)?CUIAxisMember.kTLCorner:CUIAxisMember.kTRCorner;_Tf=(n==0)?"Row_member_annotation.gif":"Col_member_annotation.gif";for(var i=0;i<_O0._dS.length;i++){if(_O0.IsMemberVisible(_O0._dS[i])){var _Bf=_O0._dS[i].GetAnnotation();var _Vl=_O0._dS[i].GetHtmlElement();var _afT=COTInputElementFactory.AppendImgOnTop(this._cf,_Vl,_8Z,_Tf,_Bf,5,5,null,null,2,1,true);_afT.className="Annotation";}}var _8Z=CUIAxisMember.kTRCorner;var _Tf='suppression_right.gif';for(var i=0;i<_O0._eA.length;i++){var _y9=this._nz*2;var _Sy=this._nz;var _Vl=_O0._eA[i];if(n==0&&_Vl.axisMember&&_Vl.axisMember._lX){_y9+=CUICrosstab.kiBlockSelectorStaticDimension+this._nz;}for(var j=0;j<_O0._dS.length;j++){var _aJq=_O0._dS[j].GetHtmlElement();if(_aJq.uniqueID==_Vl.uniqueID){if(_afT){_Sy+=_afT.width;}break;}}var _01=_O0.IsRowAxis()?'IDS_CROSSTAB_ROWS_':'IDS_CROSSTAB_COLS_';var _ath=this._jN._my._ak._kX._by;_01+=(_ath?'ZERO_AND_NULL':'NULL')+'_SUPPRESSION_TUPLE_TOOLTIP';var _azP=COTInputElementFactory.AppendImgOnTop(this._cf,_Vl,_8Z,_Tf,this._sp.GetString(_01),6,6,null,null,0,0,true,_y9,_Sy);}}Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CUICrosstab::DrawLiteCrosstab::AddBlockInfo"]);this._pS.CreateSideDZ(this._cf,'drop_caret_2x2.gif');if(this._aF){this._xv.OnCreate('black_dot.gif',this,this._cf);this._xv.HideBar();}this.Notify(ExpEvent.kCUICrosstab_DrawComplete,true);};CUICrosstab.prototype.populateCentralMeasureCell=function(){var _Vl=document.createElement('TD');if(this._m8>0){_Vl.rowSpan=this._m8;}if(this._m1>0){_Vl.colSpan=this._m1;}_Vl.cellType=CUICrosstab.kCentralMeasureCell;var _Li=this._jN.GetDataWorkSheet().GetDataManager().GetCurrentDataMatrix();var _Hr=_Li.GetDisplayProperty();var _0L=_Li.GetCurrentMeasureId();var _aEL=this._o2.GetCentralMeasureLabel();var _5N=Utilities.GetTruncatedString(_aEL,CUIAxisMember.kLabelTruncateLength,this._sp);var _3f=document.createTextNode(_5N);_Vl.appendChild(_3f);if(_0L){_Vl.title=_Li._he.metadata.GetMeasure(_0L).GetLineageLabel();}else{_Vl.title=_aEL;}this._mD=_Vl;if(this._o2.CentralMeasureExists()&&_Hr!=ExpAPIXml.kDefDisplayDsp){var _aHL=document.createElement('DIV');var _7s="";switch(_Li.GetDisplayProperty()){case ExpAPIXml.kPcntRowTotalDsp:_7s='IDS_CROSSTAB_CENTRAL_MEASURE_PCNT_ROWTOTAL';break;case ExpAPIXml.kPcntRowSubTotalDsp:_7s='IDS_CROSSTAB_CENTRAL_MEASURE_PCNT_EACH_ROWTOTAL';break;case ExpAPIXml.kPcntColTotalDsp:_7s='IDS_CROSSTAB_CENTRAL_MEASURE_PCNT_COLTOTAL';break;case ExpAPIXml.kPcntColSubTotalDsp:_7s='IDS_CROSSTAB_CENTRAL_MEASURE_PCNT_EACH_COLTOTAL';break;case ExpAPIXml.kPcntOfTotalDsp:_7s='IDS_CROSSTAB_CENTRAL_MEASURE_PCNT_OVERALL_TOTAL';break;default:Debug.Assert(false);break;}_3f=document.createTextNode(this._sp.GetString(_7s));_aHL.appendChild(_3f);_aHL.className="AssistiveMeasureText";_aHL.cellType=CUICrosstab.kCentralMeasureCell;_Vl.appendChild(_aHL);_Vl.title=_aEL+'\n'+this._sp.GetString(_7s);}};CUICrosstab.prototype.SetAbsColWidth=function(_T4){var _alL=this.GetDLCrosstab();var _LA=_alL._ql[_T4]>CUIAxisMember.kLabelTruncateLength?CUIAxisMember.kLabelTruncateLength:_alL._ql[_T4];var _alk=(this._nc*_LA)+12;var _F4=(_T4==0)?Math.max(_alk,this._t6[0]):_alk;this._t6[_T4]=_F4;if(_T4<this._m1){var _ar3=this._ax;var _aBQ=_ar3.GetMember(0,_T4).GetBlock().GetId();var _YD=this._x2.GetRowHeaderColWidthByBlockId(_aBQ);if(_YD){this._t6[_T4]=_YD;}}else{var _aC6=this._bz;var oMem=_aC6.GetMember(_T4-this._m1,this._m8-1);if(oMem){var _asg=this.GetTupleOnColEdge(oMem);var _YD=this._x2.GetColWidthByTuple(_asg);if(_YD){this._t6[_T4]=_YD;}}}};CUICrosstab.prototype.SetFixedColsWidth=function(_F1){var _aaz=this._t7;var _8w=this._m1;var _aF1=this._lw;var _ajZ=this._tp;var _ajt=0;if(_aF1){if(!_F1){if(!this._o2.CentralMeasureExists()){this._t6[0]=Math.ceil(this._cI/5);}}_ajt+=this._t6[0]+2*this._nz;}else{for(var _Wb=0;_Wb<_8w;_Wb++){if(!_F1){this.SetAbsColWidth(_Wb);}_ajt+=this._t6[_Wb]+2*this._nz;}}this._sJ=this._cI-_ajt;if(_ajZ){this._t6[_8w]=this._sJ-2*this._nz;}else{if(!_F1){for(var _Wb=_8w;_Wb<_aaz+_8w;_Wb++){this.SetAbsColWidth(_Wb);}}}};CUICrosstab.prototype.SetFixedRowsHeight=function(_F1){var _atv=this._og;var _8S=this._m8;var _8w=this._m1;var _ar3=this._ax;var _aF1=this._lw;var _ajZ=this._tp;var _Z3=0;if(_ajZ){if(!this._o2.CentralMeasureExists()){if(!_F1){this._ri[0]=Math.ceil(this._p3*0.15);}_Z3+=this._ri[0];}else{if(!_F1){this._ri[0]=this._pX+this._p0+(2*this._nz);}_Z3+=this._ri[0];}}else{var _aHa=this._bz.GetDLAxis().GetDataObj()._iq;var _aCn=(_aHa.length==0);if(_8S==1){_aAH=_aCn?0:Math.ceil(_aHa[0]*this._jY);if(!_F1){this._ri[0]=(this._ri[0]>this._pX+_aAH+this._p0)?this._ri[0]-this._p0:this._pX+_aAH;}_Z3+=this._ri[0]+this._nz+this._p0;}else{for(var _O2=0;_O2<_8S;_O2++){_aAH=_aCn?0:Math.ceil(_aHa[_O2]*this._jY);if(!_F1){this._ri[_O2]=this._pX+_aAH;}_Z3+=this._ri[_O2]+this._nz+this._p0;}}}this._kc=this._p3-_Z3-1;if(_aF1){this._ri[_8S]=this._kc-2*this._nz;}else{var _aHa=this._ax.GetDLAxis().GetDataObj()._iq;var _aCn=(_aHa.length==0);for(var _O2=_8S;_O2<_atv+_8S;_O2++){var _aAH=_aCn?0:Math.ceil(_aHa[_O2-_8S]*this._jY);if(_O2==_8S){this._ri[_O2]=this._pX+_aAH+CUICrosstab.kiBlockSelectorStaticDimension;}else{for(var _Wb=0;_Wb<_8w;_Wb++){var oMem=_ar3.GetMember(_O2-_8S,_Wb);if(oMem&&oMem._lX){this._ri[_O2]=this._pX+_aAH+CUICrosstab.kiBlockSelectorStaticDimension;}else{this._ri[_O2]=this._pX+_aAH;}}}}this._kc-=(CUICrosstab.kiScrollBarWidth+CUICrosstab.kiScrollBarBorderWidth);}};CUICrosstab.prototype.SetScrollingParams=function(_MV,_Fq,_NV,_WF){this._pO=this._og;this._r7=_WF-(this._wA?1:0);this._aD=this._t7;this._yc=_NV-(this._vL?1:0);;this._yc=Math.max(this._yc,1);this._r7=Math.max(this._r7,1);this._nj=_MV;this._rz=_Fq;this._bz.SetVisibleMembersRange(_MV,_NV);this._ax.SetVisibleMembersRange(_Fq,_WF);};CUICrosstab.prototype.GetTotalVisibleColsInColAxis=function(_MV,_NL){Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CUICrosstab::GetLiteInitialCrosstabData::CalculateTotoalVisibleCols"]);if(_NL){var _aIr=(this._ye<this._og)||((this._ye==this._og)&&this._wA);if(_aIr){this._sJ=this._sJ-(CUICrosstab.kiScrollBarWidth+CUICrosstab.kiScrollBarBorderWidth);}}var _aBw=this._sJ;var _NV=_MV;var _aaz=this._t7;this._vL=false;while((_NV<_aaz)&&(_aBw>0)){_aBw-=(this._t6[_NV+this._m1]+2*this._nz);if(_aBw<0){this._vL=true;}_NV++;}Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CUICrosstab::GetLiteInitialCrosstabData::CalculateTotoalVisibleCols"]);return _NV-_MV;};CUICrosstab.prototype.GetTotalVisibleRowsInRowAxis=function(_Fq){Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CUICrosstab::GetLiteInitialCrosstabData::CalculateTotoalVisibleRows"]);var _9w=this._kc;var _WF=_Fq;var _atv=this._og;this._wA=false;while((_WF<_atv)&&(_9w>0)){_9w-=(this._ri[_WF+this._m8]+this._nz+this._p0);if(_9w<0){this._wA=true;}_WF++;}Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CUICrosstab::GetLiteInitialCrosstabData::CalculateTotoalVisibleRows"]);return _WF-_Fq;};CUICrosstab.prototype.GetMoreHXtabData=function(_MV,_NL){this._sW=this.GetTotalVisibleColsInColAxis(_MV,_NL);if(this._nj>0){var _aBw=this._sJ;var _aeN=0;for(var i=0;i+this._m1<this._t6.length;++i){_aeN+=this._t6[i+this._m1]+2*this._nz;}if(_aeN<_aBw){_MV=0;this._nj=0;this._sW=this._t6.length-this._m1;}}this.SetScrollingParams(_MV,this._rz,this._sW,this._ye,true,true);var _Fq=this._rz;for(var x=0;x<this._sW;x++){Utilities.ClearObjectArray(this._wk);if(!this._nf[x+this._m1+_MV]){this._nf[x+this._m1+_MV]=new Array();}for(var y=0;y<this._m8;y++){if(!this._nf[x+this._m1+_MV][y]){var _aC6=this._bz;var oMem=_aC6.GetMember(x+_MV,y);if(oMem&&oMem.IsSiblingProxy()){var _0g=oMem.GetUIAxisMember();var _aFn=_0g.GetMemberPos();if(!(this._nf[_aFn+this._m1]&&this._nf[_aFn+this._m1][y])){if(!this._nf[_aFn+this._m1]){this._nf[_aFn+this._m1]=new Array();}this.CreateColMemberCell(_aFn,y);}}this.CreateColMemberCell(x+_MV,y);}}if(!this._nG){for(var y=0;y<this._ye;y++){if(!this._nf[x+this._m1+_MV][y+this._m8+_Fq]){this.CreateDataCell(x+_MV,y+_Fq);}}}}};CUICrosstab.prototype.GetMoreVXtabData=function(_Fq){this._ye=this.GetTotalVisibleRowsInRowAxis(_Fq);if(this._rz>0){var _9w=this._kc;var _aoW=0;for(var i=0;i+this._m8<this._ri.length;++i){_aoW+=this._ri[i+this._m8]+this._nz+this._p0;}if(_aoW<_9w){_Fq=0;this._rz=0;this._ye=this._ri.length-this._m8;}}this.SetScrollingParams(this._nj,_Fq,this._sW,this._ye,true,true);var _MV=this._nj;for(var x=0;x<this._m1;x++){for(var y=0;y<this._ye;y++){if(!this._nf[x][y+_Fq+this._m8]){var _ar3=this._ax;var oMem=_ar3.GetMember(y+_Fq,x);if(oMem&&oMem.IsSiblingProxy()){var _0g=oMem.GetUIAxisMember();var _arU=_0g.GetMemberPos();if(!this._nf[x][_arU+this._m8]){this.CreateRowMemberCell(x,_arU);}}this.CreateRowMemberCell(x,y+_Fq);}}}if(!this._nG){for(var x=0;x<this._sW;x++){Utilities.ClearObjectArray(this._wk);for(var y=0;y<this._ye;y++){if(!this._nf[x+_MV+this._m1][y+_Fq+this._m8]){this.CreateDataCell(x+_MV,y+_Fq);}}}}};CUICrosstab.prototype.GetLiteInitialCrosstabData=function(){Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CUICrosstab::GetLiteInitialCrosstabData"]);var _MV=0;var _Fq=0;var _NV=0;var _WF=0;var _8S=this._m8;var _8w=this._m1;var _aF1=this._lw;var _ajZ=this._tp;var _apz=this._nf;this._nG=null;if(!_apz[0]){_apz[0]=new Array();this.AddObjToArray(this._mD,this._nf,0,0);COTStyle.SetHeight(this._mD,this._ri[0]);}var _aaz=this._t7;var _atv=this._og;var oMem;var _Vl=null;this._ye=this.GetTotalVisibleRowsInRowAxis(0);this._sW=this.GetTotalVisibleColsInColAxis(0,true);Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CUICrosstab::GetLiteInitialCrosstabData::GetColData"]);var _Vl=null;for(var y=0;y<_8S;y++){for(var x=0;x<this._sW;x++){var _ah4=_apz[x+_MV+_8w]&&_apz[x+_MV+_8w][y];if(!_ah4){if(_ajZ){var _Vl=document.createElement('TD');var _O3=document.createElement('A');_Vl.className=Dom.GetStyleByBrowser("ColMemberCellTemplate");_Vl.cellType=CUICrosstab.kMemberCellTemplate;_Vl.bColMemCellTemp=true;var _ayI=document.createElement('IMG');_ayI.src=Utilities.IMG_PATH+"drag_drop.gif";_ayI.className='crostab_drop_arrow';_Vl.appendChild(_ayI);var _BM=this._sp.GetString('IDS_WORKSHEET_COLUMNS_INSTRUCTION');var _3f=document.createTextNode(_BM);_O3.appendChild(_3f);this._oZ(_Vl,_O3);this._mY=_Vl;this.AddObjToArray(_Vl,_apz,x+_MV+_8w,y);}else{this.CreateColMemberCell(x+_MV,y);}}}}Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CUICrosstab::GetLiteInitialCrosstabData::SetScrollParams"]);if(this._oP){this._sW=this.GetTotalVisibleColsInColAxis(_MV);this._oP=null;}this.SetScrollingParams(_MV,_Fq,this._sW,this._ye);Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CUICrosstab::GetLiteInitialCrosstabData::SetScrollParams"]);Debug.Call(Debug.kUnitHooks,Debug.kAddTimingInfo,["CUICrosstab::GetLiteInitialCrosstabData::GetColData",Debug.VisibleCols,this._sW]);Debug.Call(Debug.kUnitHooks,Debug.kAddTimingInfo,["CUICrosstab::GetLiteInitialCrosstabData::GetColData",Debug.ColCount,_aaz]);Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CUICrosstab::GetLiteInitialCrosstabData::GetColData"]);Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CUICrosstab::GetLiteInitialCrosstabData::GetRowData"]);for(var x=0;x<_8w;x++){for(var y=0;y<this._ye;y++){var _ah4=_apz[x]&&_apz[x][y+_8S];if(!_ah4){if(_aF1){var _Vl=document.createElement('TD');var _O3=document.createElement('A');_Vl.className="RowMemberCellTemplate";_Vl.bRowMemCellTemp=true;_Vl.cellType=CUICrosstab.kMemberCellTemplate;var _ayI=document.createElement('IMG');_ayI.src=Utilities.IMG_PATH+"drag_drop.gif";_ayI.className='crostab_drop_arrow';_Vl.appendChild(_ayI);_BM=this._sp.GetString('IDS_WORKSHEET_ROWS_INSTRUCTION');var _3f=document.createTextNode(_BM);_O3.appendChild(_3f);COTStyle.SetHeight(_Vl,this._ri[_8S]);this._oZ(_Vl,_O3);this._qB=_Vl;this.AddObjToArray(_Vl,_apz,x,y+_8S);}else{this.CreateRowMemberCell(x,y);}}}}Debug.Call(Debug.kUnitHooks,Debug.kAddTimingInfo,["CUICrosstab::GetLiteInitialCrosstabData::GetRowData",Debug.VisibleRows,this._ye]);Debug.Call(Debug.kUnitHooks,Debug.kAddTimingInfo,["CUICrosstab::GetLiteInitialCrosstabData::GetRowData",Debug.RowCount,_atv]);Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CUICrosstab::GetLiteInitialCrosstabData::GetRowData"]);Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CUICrosstab::GetLiteInitialCrosstabData::GetDataCell"]);Debug.Call(Debug.kUnitHooks,Debug.kAddTimingInfo,["CUICrosstab::GetLiteInitialCrosstabData::GetDataCell",Debug.VisibleCells,(this._sW*this._ye)]);Debug.Call(Debug.kUnitHooks,Debug.kAddTimingInfo,["CUICrosstab::GetLiteInitialCrosstabData::GetDataCell",Debug.CellCount,_aaz*_atv]);var _Li=this._jN.GetDataWorkSheet().GetDataManager().GetCurrentDataMatrix();if(!_Li.IsFullDataMode()){var _Vl=this._o2.CreateNoCellValueTemplate();this.AddObjToArray(_Vl,_apz,_8w,_8S);this._nG=_Vl;}else{for(var x=_MV;x<this._sW;x++){Utilities.ClearObjectArray(this._wk);for(y=_Fq;y<this._ye;y++){var _ah4=_apz[x+_8w]&&_apz[x+_8w][y+_8S];if(!_ah4){var _aG1=this._o2.GetCentralMeasurePresentationType();if(!(_aG1==ExpAPIXml.kDefMeaNonePretType)&&!this._o2.HasData()&&!this._o2.CentralMeasureExists()){var _Vl=document.createElement('TD');_Vl.className=Dom.GetStyleByBrowser("DataCellTemplate");_Vl.cellType=CUICrosstab.kDataCellTemplate;var _ayI=document.createElement('IMG');_ayI.src=Utilities.IMG_PATH+"drag_drop.gif";_ayI.className='crostab_drop_arrow';_Vl.appendChild(_ayI);var _aiP=this._sp.GetString('IDS_WORKSHEET_BASIC_MEASURE');var _3f=document.createTextNode(_aiP);_Vl.appendChild(_3f);_Vl.appendChild(document.createElement('BR'));_Vl.appendChild(document.createElement('BR'));var _Sq="";var _adZ=new Array();var _ak3=null;for(var mDimId in this._jN._m4.dataManager.metadata._xV){_adZ.push(this._jN._m4.dataManager.metadata._xV[mDimId].GetLabel());}if(_adZ.length>1){_ak3=this._sp.ReplaceParamList('IDS_WORKSHEET_BASIC_MULTI_MEASURE_INSTRUCTION',_adZ);}else{if(_adZ[0]){_ak3=_adZ[0];}}if(_ak3){var _Sq=this._sp.ReplaceParam('IDS_WORKSHEET_BASIC_MEASURE_INSTRUCTION',1,_ak3);_3f=document.createTextNode(_Sq);_Vl.appendChild(_3f);}this._o2.AddCell(_Vl,0,0);this.AddObjToArray(_Vl,_apz,_8w,_8S);this._nG=_Vl;}else{this.CreateDataCell(x,y);}}}}}Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CUICrosstab::GetLiteInitialCrosstabData::GetDataCell"]);Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CUICrosstab::GetLiteInitialCrosstabData"]);this.onEndGetCrosstabData();};CUICrosstab.prototype.GetCrosstabData=function(_MU){Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CUICrosstab::GetCrosstabData"]);var _aC6=this._bz;var _ar3=this._ax;var _apz=this._nf;var _8S=this._m8;var _8w=this._m1;var _aaz=this._t7;var _atv=this._og;var _XO=this._vZ;var _aF1=this._lw;var _ajZ=this._tp;this._nj=0;this._rz=0;var _LZ=this._nj;var _HS=this._rz;var _ajR=this._t6;var _agA=this._ri;this.calculateAvailableSizes(true);var _Vl=document.createElement('TD');if(_8S>0){_Vl.rowSpan=_8S;}if(_8w>0){_Vl.colSpan=_8w;}_Vl.cellType=CUICrosstab.kCentralMeasureCell;var _aJr=0;var _aFp=0;if(!this._o2.CentralMeasureExists()){if(_aF1){_aJr=Math.ceil(this._cI/5);this._t6[0]=_aJr;}if(_ajZ){_aFp=Math.ceil(this._p3*0.15);COTStyle.SetHeight(_Vl,_aFp);}}var _Li=this._jN.GetDataWorkSheet().GetDataManager().GetCurrentDataMatrix();var _0L=_Li.GetCurrentMeasureId();var _aEL=this._o2.GetCentralMeasureLabel();var _5N=Utilities.GetTruncatedString(_aEL,CUIAxisMember.kLabelTruncateLength,this._sp);var _3f=document.createTextNode(_5N);_Vl.appendChild(_3f);if(_0L){_Vl.title=_Li._he.metadata.GetMeasure(_0L).GetLineageLabel();}else{_Vl.title=_aEL;}this._mD=_Vl;if(this._o2.CentralMeasureExists()&&_Li.GetDisplayProperty()!=ExpAPIXml.kDefDisplayDsp){var _aHL=document.createElement('DIV');var _7s="";switch(_Li.GetDisplayProperty()){case ExpAPIXml.kPcntRowTotalDsp:_7s='IDS_CROSSTAB_CENTRAL_MEASURE_PCNT_ROWTOTAL';break;case ExpAPIXml.kPcntRowSubTotalDsp:_7s='IDS_CROSSTAB_CENTRAL_MEASURE_PCNT_EACH_ROWTOTAL';break;case ExpAPIXml.kPcntColTotalDsp:_7s='IDS_CROSSTAB_CENTRAL_MEASURE_PCNT_COLTOTAL';break;case ExpAPIXml.kPcntColSubTotalDsp:_7s='IDS_CROSSTAB_CENTRAL_MEASURE_PCNT_EACH_COLTOTAL';break;case ExpAPIXml.kPcntOfTotalDsp:_7s='IDS_CROSSTAB_CENTRAL_MEASURE_PCNT_OVERALL_TOTAL';break;default:Debug.Assert(false);break;}_3f=document.createTextNode(this._sp.GetString(_7s));_aHL.appendChild(_3f);_aHL.className="AssistiveMeasureText";_aHL.cellType=CUICrosstab.kCentralMeasureCell;_Vl.appendChild(_aHL);}this.SetCentralMeasureCellStyle();this.AddObjToArray(_Vl,_apz,0,0);this.TestCellSize(_Vl,0,0,null,true);/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oGetColData.StartTimer(true);}/*@end@*/Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CUICrosstab::GetCrosstabData::GetColData"]);for(var y=0;y<=_8S-1;++y){for(var x=0;x<_aaz;++x){if(_ajZ){var _Vl=document.createElement('TD');var _3f;var _O3=document.createElement('A');_Vl.className=Dom.GetStyleByBrowser("ColMemberCellTemplate");_Vl.cellType=CUICrosstab.kMemberCellTemplate;_Vl.bColMemCellTemp=true;var _ayI=document.createElement('IMG');_ayI.src=Utilities.IMG_PATH+"drag_drop.gif";_ayI.className='crostab_drop_arrow';_Vl.appendChild(_ayI);var _BM=this._sp.GetString('IDS_WORKSHEET_COLUMNS_INSTRUCTION');COTStyle.SetHeight(_Vl,_aFp);var _3f=document.createTextNode(_BM);_O3.appendChild(_3f);this._oZ(_Vl,_O3);this._mY=_Vl;this.AddObjToArray(_Vl,_apz,x+_8w,y);this.TestCellSize(_Vl,x+_8w,y,_O3);}else{this.CreateColMemberCell(x,y);}}}Debug.Call(Debug.kUnitHooks,Debug.kAddTimingInfo,["CUICrosstab::GetCrosstabData::GetColData",Debug.ColCount,_aaz]);Debug.Call(Debug.kUnitHooks,Debug.kAddTimingInfo,["CUICrosstab::GetCrosstabData::GetColData",Debug.ColDepth,_8S]);Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CUICrosstab::GetCrosstabData::GetColData"]);/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oGetColData.StopTimer();}/*@end@*//*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oGetRowData.StartTimer(true);}/*@end@*/Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CUICrosstab::GetCrosstabData::GetRowData"]);for(var x=0;x<=_8w-1;++x){for(var y=0;y<_atv;++y){if(_aF1){var _Vl=document.createElement('TD');var _3f;var _O3=document.createElement('A');_Vl.className="RowMemberCellTemplate";_Vl.bRowMemCellTemp=true;_Vl.cellType=CUICrosstab.kMemberCellTemplate;var _ayI=document.createElement('IMG');_ayI.src=Utilities.IMG_PATH+"drag_drop.gif";_ayI.className='crostab_drop_arrow';_Vl.appendChild(_ayI);_BM=this._sp.GetString('IDS_WORKSHEET_ROWS_INSTRUCTION');var _3f=document.createTextNode(_BM);_O3.appendChild(_3f);this._oZ(_Vl,_O3);this._qB=_Vl;this.AddObjToArray(_Vl,_apz,x,y+_8S);this.TestCellSize(_Vl,x,y+_8S,_O3);}else{this.CreateRowMemberCell(x,y);}}}Debug.Call(Debug.kUnitHooks,Debug.kAddTimingInfo,["CUICrosstab::GetCrosstabData::GetRowData",Debug.RowCount,_atv]);Debug.Call(Debug.kUnitHooks,Debug.kAddTimingInfo,["CUICrosstab::GetCrosstabData::GetRowData",Debug.RowDepth,_8w]);Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CUICrosstab::GetCrosstabData::GetRowData"]);/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oGetRowData.StopTimer();}/*@end@*/if(_ajZ){COTStyle.SetHeight(this._mY,this._ri[0]);if(_aF1){this._t6[1]=this._cI-this._t6[0]-2;}else{var _aFP=this._cI;for(var _awY=0;_awY<_ar3.GetDepth();++_awY){_aFP=_aFP-_ajR[_awY];}this._t6[_ar3.GetDepth()]=_aFP-2;}}if(_aF1){this.setRowTemplateSize();}this._nG=null;if(!_Li.IsFullDataMode()){var _Vl=this._o2.CreateNoCellValueTemplate();this._nG=_Vl;}else{var _aG1=this._o2.GetCentralMeasurePresentationType();if(!(_aG1==ExpAPIXml.kDefMeaNonePretType)&&!this._o2.HasData()&&!this._o2.CentralMeasureExists()){var x=0;var y=0;var _Vl;_Vl=document.createElement('TD');_Vl.className=Dom.GetStyleByBrowser("DataCellTemplate");_Vl.cellType=CUICrosstab.kDataCellTemplate;var _ayI=document.createElement('IMG');_ayI.src=Utilities.IMG_PATH+"drag_drop.gif";_ayI.className='crostab_drop_arrow';_Vl.appendChild(_ayI);var _aiP=this._sp.GetString('IDS_WORKSHEET_BASIC_MEASURE');var _3f=document.createTextNode(_aiP);_Vl.appendChild(_3f);_Vl.appendChild(document.createElement('BR'));_Vl.appendChild(document.createElement('BR'));var _Sq="";var _adZ=new Array();var _ak3=null;for(var mDimId in this._jN._m4.dataManager.metadata._xV){_adZ.push(this._jN._m4.dataManager.metadata._xV[mDimId].GetLabel());}if(_adZ.length>1){_ak3=this._sp.ReplaceParamList('IDS_WORKSHEET_BASIC_MULTI_MEASURE_INSTRUCTION',_adZ);}else{if(_adZ[0]){_ak3=_adZ[0];}}if(_ak3){var _Sq=this._sp.ReplaceParam('IDS_WORKSHEET_BASIC_MEASURE_INSTRUCTION',1,_ak3);_3f=document.createTextNode(_Sq);_Vl.appendChild(_3f);}this._o2.AddCell(_Vl,x,y);this.AddObjToArray(_Vl,_apz,x+_8w,y+_8S);var _avN=_Sq.length>_aiP.length?_Sq:_aiP;this.TestDataCellTemplateSize(x+_8w,y+_8S,_avN);this._nG=_Vl;}else{Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CUICrosstab::GetCrosstabData::GetDataCells"]);Debug.Call(Debug.kUnitHooks,Debug.kAddTimingInfo,["CUICrosstab::GetCrosstabData::GetDataCells",Debug.CellCount,(_atv*_aaz)]);for(var y=0;y<_atv;++y){for(var x=0;x<_aaz;++x){this.CreateDataCell(x,y);}if((y>0)&&((y%CUICrosstab.kiNumRowsToDrawAtATime)==0)){this._fJ=y;var _My=true;this.Notify(ExpEvent.kCUICrosstab_DrawStoppable,true);var _avz=this._sp.ReplaceParam('IDS_WORKSHEET_CURRENT_ROW_STATUS',1,this._fJ);_avz=this._sp.ReplaceParam(_avz,2,_atv);CUIManager.ShowStatusMessage(_avz);var _6z=Utilities.GenerateCallback(this.ContinueGetCrosstabData,[],this);setTimeout(_6z,CUICrosstab.kiMilliSecsWaitBtwRowBlocks);Debug.Call(Debug.kUnitHooks,Debug.kAddTimingInfo,["CUICrosstab::GetCrosstabData::GetDataCells",Debug.VisibleCells,((x+1)*(y+1))]);Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CUICrosstab::GetCrosstabData::GetDataCells"]);Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CUICrosstab::GetCrosstabData"]);return;}}if(y==_atv){this._fJ=_atv;this.onEndGetCrosstabData();Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CUICrosstab::GetCrosstabData::GetDataCells"]);Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CUICrosstab::GetCrosstabData"]);return;}}}this.onEndGetCrosstabData();Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CUICrosstab::GetCrosstabData"]);};CUICrosstab.prototype.onEndGetCrosstabData=function(){/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){var _atv=this._fJ==-1?this._og:this._fJ;g_oGetData.SetComment("No of rows = "+_atv+" No of cols = "+this._t7);g_oGetData.StopTimer();}if(Debug.IsEnabled()&&_d){_n.StopSingleTime();g_oGetXtabData.StopGlobalTimer();}this._jN.OnRefreshFinish();/*@end@*/this._w7=false;this.DrawCrosstab();if(Debug.IsEnabled()&&_d){g_oRefresh.StopGlobalTimer();}Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CUICrosstab::Refresh"]);Debug.Call(Debug.kUnitHooks,Debug.kStopRequest,["End Get Crosstab Data"]);if(_q){PerfMonitor.StopPerceivedUserTime();}CUIManager.ShowStatusMessage("");};CUICrosstab.prototype.ContinueGetCrosstabData=function(){if(this._jN.IsDrawingStopped()){CUIDialogMgr.DisplayMessageBox(CUIMessageBox.kInformation,'IDS_CROSSTAB_DRAWING_STOPPED');this.onEndGetCrosstabData();return;}for(var y=this._fJ+1;y<this._og;++y){for(var x=0;x<this._t7;++x){this.CreateDataCell(x,y);}if((y>0)&&((y%CUICrosstab.kiNumRowsToDrawAtATime)==0)){this._fJ=y;var _avz=this._sp.ReplaceParam('IDS_WORKSHEET_CURRENT_ROW_STATUS',1,this._fJ);_avz=this._sp.ReplaceParam(_avz,2,this._og);CUIManager.ShowStatusMessage(_avz);var _6z=Utilities.GenerateCallback(this.ContinueGetCrosstabData,[],this);setTimeout(_6z,CUICrosstab.kiMilliSecsWaitBtwRowBlocks);return;}}this._fJ=this._og;this.onEndGetCrosstabData();};CUICrosstab.prototype.setRowTemplateSize=function(){var _Z6=this._p3;COTStyle.SetWidth(this._qB,this._t6[0]);if(this._tp){COTStyle.SetHeight(this._qB,_Z6-this._ri[0]);}else{for(var i=0;i<this._bz.GetDepth();++i){_Z6-=(this._ri[i]+2*this._nz);}COTStyle.SetHeight(this._qB,_Z6);}};CUICrosstab.prototype.AddObjToArray=function(_Mv,_PI,x,y){if(!_PI[x]){_PI[x]=new Array();}_PI[x][y]=_Mv;};CUICrosstab.prototype._q6=function(_Wi){var _Ij=document.createElement('DIV');_Ij.className="crosstab";this._ro=_Ij;this._sV="crosstab"+Utilities.GenerateId();this._ro.id=this._sV;_Wi.appendChild(this._ro);};CUICrosstab.prototype._oZ=function(_Vl,_O3){_Vl.appendChild(_O3);};CUICrosstab.prototype.AddPropertyToLevel=function(_zV,_O5,_Go){var _No=this._jN._m4.dataManager._iF[_zV].GetBlock(_Go);Debug.Assert(_No);if(_No.IsPropertyDisplayEnabled(_O5)){_No.DisablePropertyDisplay(_O5);}else{_No.ShowPropertyValue(_O5);}};CUICrosstab.SafeDoAddPropertyToLevel=function(_Ke,_zV,_O5,_Go){try{var _Mg=FindApp(_Ke);_Mg.uiManager._jf.GetUICrosstab().AddPropertyToLevel(_zV,_O5,_Go);}catch(e){_f.HandleException(e);}};CUICrosstab.prototype.UpdateScrollBars=function(_MU){Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CUICrosstab::UpdateScrollBars"]);if(!this._jN.IsCrosstabVisible()){this.RemoveScrollBar(true);this.RemoveScrollBar(false);Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CUICrosstab::UpdateScrollBars"]);return;}if((!this.oScrollVDiv)&&(!this.oScrollHDiv)){this._ij=new CUIScrollControlCallingContext();this._ig=new CUIScrollControl(this._jN._m4.appobj);}var _ag7=this._mD.offsetTop+this._mD.offsetHeight+2;var _aHr=this._mD.offsetLeft+this._mD.offsetWidth+2;var _awM=Dom.GetImmediateChildByName(this._cf,"TABLE");var _awc=COTStyle.GetDisplayOffsetHeight(this._cf)-CUICrosstab.kiScrollBarWidth;var _1D=COTStyle.GetDisplayOffsetHeight(_awM);var _aIv=COTStyle.GetDisplayOffsetWidth(_MU)-CUICrosstab.kiScrollBarWidth;var _3J=COTStyle.GetDisplayOffsetWidth(_awM);var _9E=-2;var _awm=-2;if(!this.oScrollVDiv){var _aEV=_aIv;if(this._pO>this._r7){var _aGG=document.createElement('DIV');this.oScrollVDiv=_aGG;_MU.appendChild(_aGG);_aGG.style.position="absolute";var _2A=new CUIPane();_2A.SetDom(_aGG);var _7l=COTStyle.GetDisplayOffsetHeight(this._cf);if(this.oScrollHDiv){this._ce.SetTopPosition(_awc,'px');this._ig.m_oHScrollbar.setScrollTrackLength();}else{_aEV=Math.min(_3J,_aIv);}_2A.OnResize(CUICrosstab.kiScrollBarWidth,_7l,_aEV,0);this._mW=_2A;this._ij.SetVAttributes(_2A,true,this._pO,this._r7,this._rz,_ag7);if(!this._ig.OnVCreate(this._ij)){throw new COTException("Could not create scroll control");}this._ig.Subscribe(this,ExpEvent.kCUIScrollControl_VScroll);this._mp=this._ig.m_oVScrollbar.CreateSplitter();this._mp.style.top=_ag7+_9E+'px';this._mp.style.left=_aHr+_awm+'px';COTStyle.SetWidth(this._mp,_aEV-_aHr+CUICrosstab.kiScrollBarWidth-_awm);this._cf.appendChild(this._mp);}}else{if(this._pO>this._r7){this._ig.SetVUnits(this._r7,this._rz,this._pO);if(!this.oScrollHDiv){_aEV=Math.min(_3J,_aIv);}else{_aEV=_aIv;}this._mW.SetLeftPosition(_aEV,'px');this._ig.m_oVScrollbar.SetStartPosition(_ag7);this._ig.m_oVScrollbar.setScrollTrackLength();this._ig.m_oVScrollbar.updateVisualComponents();this._cf.appendChild(this._mp);this._mp.style.top=_ag7+_9E+'px';this._mp.style.left=_aHr+_awm+'px';COTStyle.SetWidth(this._mp,_aEV-_aHr+CUICrosstab.kiScrollBarWidth-_awm);}else{this.RemoveScrollBar(true);if(this.oScrollHDiv){var _azn=Math.min(_1D,_awc);this._ce.SetTopPosition(_azn,'px');this._ig.m_oHScrollbar.setScrollTrackLength();COTStyle.SetHeight(this._eG,_azn-_ag7+CUICrosstab.kiScrollBarWidth-_awm);}}}if(!this.oScrollHDiv){var _8L=_awc;if(this._aD>this._yc){var _0D=document.createElement('DIV');this.oScrollHDiv=_0D;_MU.appendChild(_0D);_0D.style.position="absolute";var _Zb=new CUIPane();_Zb.SetDom(_0D);var _avk=COTStyle.GetDisplayOffsetWidth(_MU);if(this.oScrollVDiv){this._mW.SetLeftPosition(_aIv,'px');this._ig.m_oVScrollbar.setScrollTrackLength();}else{_8L=Math.min(_awc,_1D);}_Zb.OnResize(_avk,CUICrosstab.kiScrollBarWidth,0,_8L);this._ce=_Zb;if(!this._ij){this._ij=new CUIScrollControlCallingContext();this._ig=new CUIScrollControl(this._jN._m4.appobj);}this._ij.SetHAttributes(_Zb,true,this._aD,this._yc,this._nj,_aHr);if(!this._ig.OnHCreate(this._ij)){throw new COTException("Could not create scroll control");}this._ig.Subscribe(this,ExpEvent.kCUIScrollControl_HScroll);this._eG=this._ig.m_oHScrollbar.CreateSplitter();this._eG.style.top=_ag7+_9E+'px';this._eG.style.left=_aHr+_awm+'px';COTStyle.SetHeight(this._eG,_8L-_ag7+CUICrosstab.kiScrollBarWidth-_9E);_MU.appendChild(this._eG);}}else{if(this._aD>this._yc){this._ig.SetHUnits(this._yc,this._nj,this._aD);if(!this.oScrollVDiv){_8L=Math.min(_1D,_awc);}else{_8L=_awc;}this._ce.SetTopPosition(_8L,'px');this._ig.m_oHScrollbar.SetStartPosition(_aHr);this._ig.m_oHScrollbar.setScrollTrackLength();this._ig.m_oHScrollbar.updateVisualComponents();_MU.appendChild(this._eG);this._eG.style.top=_ag7+_9E+'px';this._eG.style.left=_aHr+_awm+'px';COTStyle.SetHeight(this._eG,_8L-_ag7+CUICrosstab.kiScrollBarWidth-_9E);}else{this.RemoveScrollBar(false);if(this.oScrollVDiv){var _aGx=Math.min(_3J,_aIv);this._mW.SetLeftPosition(_aGx,'px');this._ig.m_oVScrollbar.setScrollTrackLength();COTStyle.SetWidth(this._mp,_aGx-_aHr+CUICrosstab.kiScrollBarWidth-4);}}}if(this._ig&&this._ig.m_oHScrollbar){this._ig.m_oHScrollbar.updateVisualComponents();}if(this._ig&&this._ig.m_oVScrollbar){this._ig.m_oVScrollbar.updateVisualComponents();}Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CUICrosstab::UpdateScrollBars"]);};CUICrosstab.prototype.RemoveScrollBar=function(_Cv){if(this._ig){if(_Cv){this._ig.VUnload();this.oScrollVDiv=null;this._mp=null;}else{this._ig.HUnload();this.oScrollHDiv=null;this._eG=null;}if((!this.oScrollVDiv)&&(!this.oScrollHDiv)){Utilities.RemoveAllChildObjects(this._ig);this._ij=null;this._ig=null;}}};CUICrosstab.prototype.OnVScrollTo=function(){var _Q2=this._ig.m_oVScrollbar.GetFirstVisibleIndex();if(_Q2<0||_Q2==this._rz){return;}this._rz=_Q2;this._ig.UpdateVScrollPosition(_Q2);if(this._aF){Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CUICrosstab::LiteCrosstabFetchMoreData"]);this.GetMoreVXtabData(this._rz);Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CUICrosstab::LiteCrosstabFetchMoreData"]);}this.DrawCrosstab();if(!this._lw&&(this._r7+this._rz)>=this._pO){this.CheckActualVVisibleUnits(this._rz);}this.ReselectAll();};CUICrosstab.prototype.OnHScrollTo=function(){var _Q2=this._ig.m_oHScrollbar.GetFirstVisibleIndex();if(_Q2<0||_Q2==this._nj){return;}this._nj=_Q2;this._ig.UpdateHScrollPosition(_Q2);if(this._aF){Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CUICrosstab::LiteCrosstabFetchMoreData"]);this.GetMoreHXtabData(this._nj);Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CUICrosstab::LiteCrosstabFetchMoreData"]);}this.DrawCrosstab();this.ReselectAll();};CUICrosstab.isMemberCell=function(el){if(el.cellType&&el.cellType==CUICrosstab.kMemberCell){return true;}else{return false;}};CUICrosstab.prototype.getMemberCell=function(el){while(el&&(el!=this._ro)){if(CUICrosstab.isMemberCell(el)){return el;}if(el.axisMember){return el.axisMember.GetHtmlElement();}el=el.parentNode;}return null;};CUICrosstab.prototype.getMemberFromDropZone=function(el){if(CUICrosstab.isMemberCell(el)){return el;}if(el.cellType&&el.cellType==CUICrosstab.kMemberCellOther){return this.getMemberCell(el);}return null;};CUICrosstab.prototype.getMemberCellTemplate=function(el){while(el&&(el!=this._ro)){if(this.isMemberCellTemplate(el)){return el;}el=el.parentNode;}return null;};CUICrosstab.prototype.isMemberCellTemplate=function(el){if(el.cellType&&el.cellType==CUICrosstab.kMemberCellTemplate){return true;}else{return false;}};CUICrosstab.prototype.isEventOnDataCellText=function(e,_N9){if(this._aF){return true;}if(this._I[_N9.x+this._m1]){var _aqA=this._I[_N9.x+this._m1][_N9.y+this._m8]+this._sR;var _Qb=Dom.GetRelativeOffset(_N9,document.body);var _axb=0;if(this._ax.HasBlockSelectorAtIndex(_N9.y)){_axb=CUICrosstab.kiBlockSelectorStaticDimension;}if(e.clientX>_Qb.iLeft+(_N9.offsetWidth-_aqA)&&e.clientX<_Qb.iLeft+(_N9.offsetWidth-this._xc)&&e.clientY>_Qb.iTop+this._p0/2+_axb&&e.clientY<_Qb.iTop+_N9.offsetHeight-this._p0/2){return true;}}return false;};CUICrosstab.prototype.HandleUnselect=function(e){if(this.oCalcDlg){this.HandleClick(e);return;}var _RE=this._hL;this.UnselectAll();this.UpdateUserSelection(_RE);};CUICrosstab.prototype.ContinueHandleClick=function(_Ke,_N9,e){if(this._lL){var obj=CUIObject.GetObjectByEl(_N9);while(!obj&&_N9){_N9=_N9.parentNode;obj=CUIObject.GetObjectByEl(_N9);}if(obj){obj.OnHandleClick(e.ctrlKey,e.shiftKey);}return;}var _Nh=false;var _RE=this._hL;if(_N9._sBlockId||(_N9.parentNode&&_N9.parentNode._sBlockId)){var _anz=_N9._sBlockId?_N9:_N9.parentNode;if(this._uH==_anz._sBlockId){this.UnselectAll();this.UpdateUserSelection(_RE);}else{this.SelectBlock(_anz);}this.SetSingleClickHandled(_Nh);return;}if(_N9.cellType&&_N9.cellType==CUICrosstab.kDataCell&&(_N9.bRowSel&&_N9.bColSel)&&_N9.bDrillable){if(this.isEventOnDataCellText(e,_N9)){this.DrillOnDataCell(_N9);_Nh=true;}this.SetSingleClickHandled(_Nh);return;}if(this.getMemberFromDropZone(_N9)){_N9=this.getMemberFromDropZone(_N9);}if(_N9._jX==false){_N9=this.getMemberCell(_N9);}if(_N9.cellType&&_N9.cellType==CUICrosstab.kMemberCell&&(!this._n2)&&!e.ctrlKey&&(_N9.axisMember.GetAxis().IsInSelectedMembers(_N9.axisMember))){this.SelectBlock(_N9);this.SetSingleClickHandled(_Nh);return;}if(this._n2||(!e.ctrlKey&&!e.shiftKey)){this.UnselectAll();}if(_N9.cellType&&_N9.cellType==CUICrosstab.kMemberCell){var _zU=_N9.axisMember;if(this._hL==null){this._o2.UnselectAllCells();}_zU.GetAxis().TertiaryUnselectAll();if(e.shiftKey||e.ctrlKey){var _aqe=this.GetOppositeAxis(_zU.GetAxis());_aqe.UnselectAllMembers();var _1d=_zU.GetAxis().GetLastSelection();if(_1d&&_1d.GetBlock()!=_zU.GetBlock()){_zU.GetAxis().UnselectAllMembers();}}if(e.shiftKey){_zU.GetAxis().SequentialSelect(_zU);}else if(e.ctrlKey&&_zU.GetAxis().IsInSelectedMembers(_zU)){_zU.GetAxis().UnselectMember(_zU,true);}else{if(!_zU.IsMemberSelected()){_zU.GetAxis().SelectMember(_zU);}}}else if(_N9._vt||_N9._pZ){this.SelectBlock(this.getMemberCell(_N9));var _FK=this.getMemberCell(_N9).axisMember.GetBlock();this.HandleBlockSizeMenu(this.oMoreMenu,_FK);this.oMoreMenu.display(e);}else if(_N9._et){this.SelectBlock(this.getMemberCell(_N9));var _FK=this.getMemberCell(_N9).axisMember.GetBlock();var _AG=new Array(_Ke,_FK);this.CreateUnhideMenu(_FK,this.oHiddenMenu,_AG);this.oHiddenMenu.display(e);}else if(_N9.cellType&&_N9.cellType==CUICrosstab.kDataCell){if(Utilities.bDiffMiningEnabled){this.SelectDataCell(_N9,e.shiftKey||e.ctrlKey);}else{this.SelectDataCell(_N9);}if(!this._lw&&!this._tp){this._hL=null;}}else if(_N9._jX&&this._jN.AllowInteraction()){_Nh=true;var oMem=this.getMemberFromUniqueId(_N9._iQ);if(oMem&&oMem.IsSummaryMem()){if(!oMem._f1.IsTopMember()){CUICrosstab.SafeDoDrillUp(_Ke,oMem);}}else{CUICrosstab.SafeDoDrillDown(_Ke,oMem);}}else if(_N9.cellType&&_N9.cellType==CUICrosstab.kCentralMeasureCell){this.SelectCentralMeasure();}this.UpdateUserSelection(_RE);this.SetSingleClickHandled(_Nh);};CUICrosstab.prototype.SetSingleClickHandled=function(_Nh){if(!_Nh){this._nC=null;}else{var _akf=Utilities.GenerateCallback(this.SetSingleClickHandled,[],this);setTimeout(_akf,250);}};CUICrosstab.SafeDoContinueHandleClick=function(_Ke,_N9,e){/*@if(!@bering_debug)@*/try{/*@end@*/var _au4=FindApp(_Ke).uiManager._jf.GetUICrosstab();_au4.ContinueHandleClick(_Ke,_N9,e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.prototype.HandleClick=function(e){if(!e){var e=window.event;}this._jN._m4.OnSelChange(this);if(CUIScrollControl.IsScrollEvent(e)){this.SetSingleClickHandled(false);return;}if(!this._jN.AllowInteraction()){this.SetSingleClickHandled(false);return;}var _Ke=this._jN.GetAppName();var _N9=Dom.GetEventTarget(e);var _amW=this._jN._m4.ConfirmLossOfChanges();if(_amW==Utilities.eStateContinue){this.ContinueHandleClick(_Ke,_N9,e);}else if(_amW==Utilities.eStateHold){this.SetSingleClickHandled(false);var _axQ=Dom.CloneMouseEvent(e);var _Ro=new Array(_Ke,_N9,_axQ);Utilities.SetProcedureToHold(CUICrosstab.SafeDoContinueHandleClick,_Ro);this._jN._m4.oDialogMgr.Subscribe(this,ExpEvent.kCUIDialogMgr_HideModalDialog);}};CUICrosstab.prototype.UpdateUserSelection=function(_RE){if(!(this._ax.HasSelection()||this._bz.HasSelection())){this._jN.HandleSelectedAxisCntx(ExpEvent.kCUIWorksheet_NoAxisSel);}else if(this._ax.HasSelection()&&this._bz.HasSelection()){this._jN.HandleSelectedAxisCntx(ExpEvent.kCUIWorksheet_MultiAxisSel);}else{if((!_RE)||(_RE!=this._hL)){this._jN.HandleSelectedAxisCntx(ExpEvent.kCUIWorksheet_ChangedAxisSel);}}};CUICrosstab.prototype.SelectCentralMeasure=function(){var _aGA=this._jN._m4.dataManager.GetCurrentDataMatrix().GetCurrentMeasureId();var _abM=this._ax;var _8T=this._bz;if(_abM&&_abM.GetDLAxis().HasMeasureBlock()){var length=_abM._oo.length;var _QH=_abM.GetDepth();for(var _ayj=0;_ayj<length;++_ayj){for(var d=0;d<_QH;++d){if(_abM.GetMember(_ayj,d).GetMemberId()===_aGA){this._o2.SelectRow(_ayj);break;}}}}else if(_8T&&_8T.GetDLAxis().HasMeasureBlock()){var length=_8T._oo.length;var _QH=_8T.GetDepth();for(var _ayj=0;_ayj<length;++_ayj){for(var d=0;d<_QH;++d){if(_8T.GetMember(_ayj,d).GetMemberId()===_aGA){this._o2.SelectCol(_ayj);break;}}}}else{this._o2.SelectAllCells();}this._mD.bSelected=true;this.SetCentralMeasureCellStyle();this._hL=null;};CUICrosstab.prototype.SetCentralMeasureCellStyle=function(){if(!this._mD){return;}if(this._o2.CentralMeasureExists()){if(this._o2.GetCentralMeasurePresentationType()==ExpAPIXml.kDefMeaInactivePretType){this._mD.className="xm CentralMeasureCellInactive";}else{this._mD.className="xm CentralMeasureCell";}if(this._mD.bHoverOver){this._mD.className+=" CentralMeasureCellHover";}if(this._mD.bSelected){this._mD.className+=" PrimarySelection";}if(this._mD.bDragOver){this._mD.className+=" DragOver";}}else{this._mD.className="xm CentralMeasureCellTemplate";if(this._mD.bDragOver){this._mD.className+=" DragOver";}}};CUICrosstab.prototype.getMemberFromUniqueId=function(_V5){var oMem=null;if(this._bz){oMem=this._bz.GetMemberFromId(_V5);}if(this._ax&&!oMem){oMem=this._ax.GetMemberFromId(_V5);}return oMem;};CUICrosstab.SafeHandleMouseClick=function(e){x=0;/*@if(!@bering_debug)@*/try{/*@end@*/this.oCrosstab.HandleMouseClick(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.prototype.HandleMouseClick=function(e){if(!e){var e=window.event;}if(!this._jN.AllowInteraction()){return;}switch(e.type){case "click":if(Utilities.HadDoubleClick(this.iDoubleClickAt)){return false;}var _axQ=Dom.CloneMouseEvent(e);if(!this._nC){if(!this._jN._rS&&!this._jN._po&&(!this._jN.CheckState(CUIWorkSheet.eStateBusy))){this._nC=Utilities.GenerateCallback(CUICrosstab.SafeHandleSingleClick,[this.sAppName,_axQ]);setTimeout(this._nC,Utilities.iDoubleClickDelay);}}break;case "dblclick":this.HandleDBClick(e);break;default:}};CUICrosstab.SafeHandleSingleClick=function(_Ke,e){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager._jf._dO.HandleClick(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.prototype.HandleDBClick=function(e){if(!this._aF){return false;}var _N9=Dom.GetEventTarget(e);if(_N9&&_N9.axisMember){if(!CUICrosstab.isMemberCell(_N9)||!_N9.axisMember.GetAxis().IsColAxis()){return false;}else if(this.HasDataCellTemplate()){return false;}var d=new Date();this.iDoubleClickAt=d.getTime();if(this._nC!=null){clearTimeout(this._nC);this._nC=null;}this.SetCurrentResizeTrigger(_N9);this.OnColumnResize(true);}};CUICrosstab.prototype.HasDataCellTemplate=function(){return(this._nG!=null);};CUICrosstab.prototype.HandleMouseDown=function(e){if(!e){var e=window.event;}if(e.shiftKey){Dom.CancelEvent(e);}};CUICrosstab.SafeHandleMouseDown=function(e){try{this.oCrosstab.HandleMouseDown(e);}catch(excep){_f.HandleException(excep);}};CUICrosstab.SafeHandleSelectStart=function(e){try{this.oCrosstab.HandleMouseOver(e);if(!e){var e=window.event;}if(e.shiftKey||e.ctrlKey){Dom.CancelEvent(e);return false;}Dom.CancelBubble(e);}catch(excep){_f.HandleException(excep);}};CUICrosstab.SafeHandleContextMenu=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}this.oCrosstab.HandleContextMenu(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.prototype.HandleShowValueAsContextMenu=function(_PM,axisMember){_PM.SetEnabled(true);var _56=_PM._o6;var _zA=null;var _Co=this._sp;var _B0=axisMember?axisMember.GetMemberId():null;var _D2=axisMember?axisMember.GetMemberType():null;var _Ti=axisMember?axisMember.GetBlock().GetId():null;var _TE=axisMember?axisMember.GetAxis().GetId():null;var _Li=this._jN.GetDataWorkSheet().GetDataManager().GetCurrentDataMatrix();var _aeb=_Li.GetDisplayProperty();if(axisMember){_aeb=axisMember.GetDisplayProperty();}for(var x=0;x<_56.items.length;x++){var _apL=_56.items[x];var _Ng=false;switch(_apL.id){case 'OTH_CROSSTAB_DEFMEASUREMENU_SHOWVALUESAS_VALUES':_zA=new Array(this.sAppName,ExpAPIXml.kDefDisplayDsp,_TE,_Ti,_B0,_D2);_Ng=(_aeb==ExpAPIXml.kDefDisplayDsp);_apL.SetRadioState(_Ng);break;case 'OTH_CROSSTAB_DEFMEASUREMENU_SHOWVALUESAS_ROWTOTAL':_zA=new Array(this.sAppName,ExpAPIXml.kPcntRowTotalDsp,_TE,_Ti,_B0,_D2);_Ng=(_aeb==ExpAPIXml.kPcntRowTotalDsp);_apL.SetRadioState(_Ng);_apL.SetEnabled(_Li._d4[ExpAPIXml.kPcntRowTotalDsp]);break;case 'OTH_CROSSTAB_DEFMEASUREMENU_SHOWVALUESAS_ROWSUB':_zA=new Array(this.sAppName,ExpAPIXml.kPcntRowSubTotalDsp,_TE,_Ti,_B0,_D2);_Ng=(_aeb==ExpAPIXml.kPcntRowSubTotalDsp);_apL.SetRadioState(_Ng);_apL.SetEnabled(_Li._d4[ExpAPIXml.kPcntRowSubTotalDsp]);break;case 'OTH_CROSSTAB_DEFMEASUREMENU_SHOWVALUESAS_COLTOTAL':_zA=new Array(this.sAppName,ExpAPIXml.kPcntColTotalDsp,_TE,_Ti,_B0,_D2);_Ng=(_aeb==ExpAPIXml.kPcntColTotalDsp);_apL.SetRadioState(_Ng);_apL.SetEnabled(_Li._d4[ExpAPIXml.kPcntColTotalDsp]);break;case 'OTH_CROSSTAB_DEFMEASUREMENU_SHOWVALUESAS_COLSUB':_zA=new Array(this.sAppName,ExpAPIXml.kPcntColSubTotalDsp,_TE,_Ti,_B0,_D2);_Ng=(_aeb==ExpAPIXml.kPcntColSubTotalDsp);_apL.SetRadioState(_Ng);_apL.SetEnabled(_Li._d4[ExpAPIXml.kPcntColSubTotalDsp]);break;case 'OTH_CROSSTAB_DEFMEASUREMENU_SHOWVALUESAS_TOTAL':_zA=new Array(this.sAppName,ExpAPIXml.kPcntOfTotalDsp,_TE,_Ti,_B0,_D2);_Ng=(_aeb==ExpAPIXml.kPcntOfTotalDsp);_apL.SetRadioState(_Ng);_apL.SetEnabled(_Li._d4[ExpAPIXml.kPcntOfTotalDsp]);break;}_apL.SetParameterArr(_zA);_apL.SetItemAction(CUICrosstab.SafeDoSetDisplayProperty);}};CUICrosstab.prototype.ContinueHandleContextMenu=function(e){var _RE=this._hL;var _N9=Dom.GetEventTarget(e);var _Co=this._sp;var _Tc=this._jN._m4.dataManager.metadata;if(e){this.oLastEvent=Dom.CloneMouseEvent(e,true);}if(this._lL){var obj=CUIObject.GetObjectByEl(_N9);if(obj){obj.OnContextMenu();}return;}if(_N9.cellType&&_N9.cellType==CUICrosstab.kCentralMeasureCell){this.UnselectAll();this.SelectCentralMeasure();for(var i=0;i<this.oCentralMeasureMenu.items.length;i++){var _PM=this.oCentralMeasureMenu.items[i];if(_PM instanceof ContextItem){switch(_PM.id){case 'OTH_CROSSTAB_DEFMEASUREMENU_SHOWVALUESAS':var _Vh=this._jN._m4.dataManager.GetCurrentDataMatrix().CanChangeValueDspSetting();if(_Vh){this.HandleShowValueAsContextMenu(_PM);}else{_PM.SetEnabled(false);}break;case 'OTH_CROSSTAB_DEFMEASUREMENU_DEFAULTMEASURE':_PM._o6.Clear();for(var _Lx in _Tc._yb){var _Lv=new CUIDragDropMember(_Lx);_Lv.kPopulation=ExpAPIXml.kMemberPopulation;_Lv.kAction=ExpAPIXml.kActionSetDefMeasure;var _AG=new Array(this._jN,_Lv);var _NS=_Tc._yb[_Lx];var _ask=_NS.IsAggregateable()?'measure.gif':'Non-aggregated_measure.gif';var _apL=new ContextItem(_ask,_NS.GetExplicitLabel(),CUIWorkSheet.SafeDoInsertDropData,false,_AG,_PM._o6);}break;}}}this.oCentralMeasureMenu.display(e);}if(_N9.cellType&&_N9.cellType==CUICrosstab.kDataCell){if(!_N9.bRowSel||!_N9.bColSel){if(!e.ctrlKey){this.UnselectAll();}if(Utilities.bDiffMiningEnabled){this.SelectDataCell(_N9,false);}else{this.SelectDataCell(_N9);}}var _asr=this._ax.GetMember(_N9.y,this._m1-1);var _aFJ=this._bz.GetMember(_N9.x,this._m8-1);if(!_asr&&!_aFJ){return;}for(var i=0;i<this.oDataCellMenu.items.length;i++){var _PM=this.oDataCellMenu.items[i];if(_PM instanceof ContextItem){switch(_PM.id){case 'OTH_CROSSTAB_DRILL_DOWN_DATA_CELL':if((_asr&&_asr.CanDoSecondaryDrillDown())||(_aFJ&&_aFJ.CanDoSecondaryDrillDown())){_PM.SetEnabled(true);var _zA=new Array(this.sAppName,_N9);_PM.SetParameterArr(_zA);_PM.SetItemAction(CUICrosstab.SafeDoDrillDownOnCell);}else{_PM.SetEnabled(false);}break;case 'Analyze':_PM.SetEnabled(true);var _zA=new Array(this.sAppName,_N9);_PM.SetParameterArr(_zA);_PM.SetItemAction(CUICrosstab.SafeDoDrillToAnalysis2);break;case 'Analyze Difference':if(this._xj.length>1){_PM.SetEnabled(true);var _zA=new Array(this.sAppName,this._xj);_PM.SetParameterArr(_zA);_PM.SetItemAction(CUICrosstab.SafeDoDiffMining);break;}case 'Analyze Difference Setup...':if(this._xj.length>1){Debug.Assert(this._xj.length==2);_PM.SetEnabled(true);var _zA=new Array(this.sAppName,this._xj);_PM.SetParameterArr(_zA);_PM.SetItemAction(CUICrosstab.SafeDoAnalyzeDifferenceSetup);break;}case 'OTH_CROSSTAB_DRILL_UP_DATA_CELL':if((_asr&&_asr.CanDoSecondaryDrillUp())||(_aFJ&&_aFJ.CanDoSecondaryDrillUp())){_PM.SetEnabled(true);var _zA=new Array(this.sAppName,_N9);_PM.SetParameterArr(_zA);_PM.SetItemAction(CUICrosstab.SafeDoDrillUpOnCell);}else{_PM.SetEnabled(false);}break;case 'OTH_CROSSTAB_DRILL_THROUGH':var _aI7=new Array();var _afG=new Array();var _amk;var _9M=this.GetDLCrosstab()._i0;if(_asr){_amk=_asr.GetAxis()._eh;if(_amk.GetAxisDepth()>0){_aI7=_amk.GetSelectedTuple(_asr.GetMemberPos(),_asr.GetDepth(),_9M,CDLAxisMember.CanBeUseAsDrillThroughContext);}}if(_aFJ){_amk=_aFJ.GetAxis()._eh;if(_amk.GetAxisDepth()>0){_afG=_amk.GetSelectedTuple(_aFJ.GetMemberPos(),_aFJ.GetDepth(),_9M,CDLAxisMember.CanBeUseAsDrillThroughContext);}}if(_9M&&((_afG.length==0)||(_aI7.length==0))){_PM.SetEnabled(false);break;}var _zA=new Array(this.sAppName,"true");_PM.SetParameterArr(_zA);_PM.SetItemAction(CUICrosstab.SafeDoDrillThrough);var _aHn=new Array(_aI7,_afG);this.HandleGoToContextMenu(_PM,_aHn);break;}}}this.oDataCellMenu.display(e);}var _Zm=this._n2;if(_N9._sBlockId||(_N9.parentNode&&_N9.parentNode._sBlockId)){var _anz=_N9._sBlockId?_N9:_N9.parentNode;this.SelectBlock(_anz);_Zm=true;}_N9=this.getMemberCell(_N9);if(!_N9){this.UpdateUserSelection(_RE);return;}CUIManager.HideDrillImage();var _zC=_N9.axisMember;var _FK=_zC.GetAxisMember().GetBlock();if(this._n2){var _L7=_FK.GetId();if(_L7==this._uH){_Zm=true;}else{_Zm=false;}}var _O0=_zC.GetAxis();if(!_Zm&&!_zC.IsMemberSelected()){if((!(e.ctrlKey||e.shiftKey))||(this._hL==null)){this.UnselectAll();}else{var _aqe=this.GetOppositeAxis(_O0);_aqe.UnselectAllMembers();var _1d=_O0.GetLastSelection();if(_1d&&_1d.GetBlock()!=_FK){_O0.UnselectAllMembers();}}if(e.shiftKey){_O0.SequentialSelect(_zC);}else{_O0.SelectMember(_zC);}}if(!this._n2&&_zC.IsMemberSelected()){var _Hp=_O0.GetSelectedMembers();var _aCH=_O0.GetNumberOfSelections();var _Ga=this.oMemberContextMenu;var _apw=false;if(Utilities.bScatterPlotGraphsEnabled&&_FK.IsSegmentQuadrant()){if(_zC.GetAxisMember().IsQuadSegmentTotal()){_Ga=this.oSegmtQuadTotalCntxMenu;}else{_Ga=this.oSegmtQuadMemberCntxMenu;}}else if(_O0.HasDynamicCalcSelected()){_Ga=this.oDynamicCalcContextMenu;_apw=_O0.HasRemainderSelected();}else if(_O0.HasCalcSelected()){_Ga=(_aCH===1)?this.oCalcContextMenu:this.oMultiCalcContextMenu;}else if(_FK.IsHAMC()){_Ga=this.oHAMCMemberContextMenu;if(_Tc.GetMeasure(_zC.GetMemberId())){_Ga=this.oMeasureHAMCContextMenu;}}else if(_Tc.GetMeasure(_zC.GetMemberId())){_Ga=this.oMeasureHierContextMenu;}for(var j=0;j<_Ga.items.length;j++){var _PM=_Ga.items[j];var _alb=null;var _AT=this._jN.GetDataWorkSheet().GetDataManager();var _Li=_AT.GetCurrentDataMatrix();if(_PM instanceof ContextItem){switch(_PM.id){case 'OTH_CROSSTAB_MENU_HIDE':if(_O0.CanHideSelectedMembers()){_PM.SetEnabled(true);_PM.SetItemAction(CUICrosstab.SafeDoHide);}else{_PM.SetEnabled(false);}break;case 'OTH_CROSSTAB_MENU_UNHIDE':if(_apw){_PM.SetDisplayFlag(true);var _FK=this.getMemberCell(_N9).axisMember.GetBlock();var _AG=new Array(this.sAppName,_FK);if(!_FK.HasHiddenMembers()){_PM.SetEnabled(false);break;}_PM.SetEnabled(true);var _56=_PM._o6;this.CreateUnhideMenu(_FK,_56,_AG);}else{_PM.SetDisplayFlag(false);}break;case 'OTH_CROSSTAB_MENU_VISIBLE_ITEMS':if(_apw){_PM.SetDisplayFlag(true);_56=_PM._o6;this.HandleBlockSizeMenu(_56,_FK);}else{_PM.SetDisplayFlag(false);}break;case 'OTH_CROSSTAB_MENU_RENAME':if(_PM.GetFunctionId()!="Dyncalc"||(_N9.axisMember.CanRenameSelectedDynamicCalc()&&_aCH==1)){_PM.SetDisplayFlag(true);}else{_PM.SetDisplayFlag(false);}break;case 'Filter as Context':if(_N9.axisMember.CanUseAsDimFilter()){_PM.SetEnabled(true);_zA=new Array(this.sAppName,_FK,_N9.axisMember.GetMemberId());_PM.SetParameterArr(_zA);}else{_PM.SetEnabled(false);}break;case 'OTH_CROSSTAB_MENU_DELETE_MEMBER':if(_O0.CanDeleteSelectedMembers()){_PM.SetEnabled(true);_PM.SetItemAction(CUICrosstab.SafeDoDelete);}else{_PM.SetEnabled(false);}break;case 'OTH_CROSSTAB_MENU_EXCLUDE':if(_O0.CanExcludeSelectedMembers()){_PM.SetEnabled(true);_PM.SetItemAction(CUICrosstab.SafeDoExclude);}else{_PM.SetEnabled(false);}break;case 'OTH_CROSSTAB_MENU_DRILL_UP':var _zA;var _aGl=_Tc.GetMemberOrMeasure(_N9.axisMember.GetMemberId());_PM.SetDisplayFlag(true);if(_aCH>1){_PM.SetDisplayFlag(false);break;}if(!_aGl||!_N9.axisMember.CanDoSecondaryDrillUp()){_PM.SetEnabled(false);break;}else{_PM.SetEnabled(true);}_zA=new Array(this.sAppName,_N9.axisMember);_PM.SetItemAction(CUICrosstab.SafeDoDrillUp);_PM.SetParameterArr(_zA);break;case 'OTH_CROSSTAB_MENU_DRILL_DOWN':var _zA=new Array(this.sAppName,_N9.axisMember);_PM.SetDisplayFlag(true);if(_aCH>1){_PM.SetDisplayFlag(false);break;}if(!_N9.axisMember.CanDoSecondaryDrillDown()){_PM.SetEnabled(false);}else{_PM.SetEnabled(true);_PM.SetItemAction(CUICrosstab.SafeDoDrillDown);}_PM.SetParameterArr(_zA);break;case 'OTH_CROSSTAB_DRILL_THROUGH':var _9M=this.GetDLCrosstab()._i0;var _anR=false;for(var _BX in _Hp){if(_Hp[_BX].GetAxisMember().CanBeUseAsDrillThroughContext()){_anR=true;break;}}if(!_anR){_PM.SetEnabled(false);break;}var _zA=new Array(this.sAppName,"true");_PM.SetParameterArr(_zA);_PM.SetItemAction(CUICrosstab.SafeDoDrillThrough);var _aHn=new Array(_N9.axisMember);this.HandleGoToContextMenu(_PM,_aHn);break;case 'OTH_CROSSTAB_MENU_SHOW_LEVEL_PROPERTIES':_PM._o6.Clear();if(_N9.axisMember.IsSummaryMem()){_PM._eY=true;break;}var _BV=_Li.GetDataMatrixId();var _Ti=_FK.GetId();this.HandleMemberPropListMenu(_PM,_Tc,_Hp,_BV,_Ti);break;case 'OTH_CROSSTAB_MENU_SORT':_PM.SetDisplayFlag(true);if(_aCH>1){_PM.SetDisplayFlag(false);break;}var _4S=_N9.axisMember;var _amk=_O0._eh;var _YW=_amk.GetSelectedTuple(_4S.GetMemberPos(),_4S.GetDepth(),true,CDLAxisMember.CanBeUsedInSort);var _acR=this._jN.CanCreateSortExpression(_4S,_O0,_YW);if(!_acR){_PM.SetEnabled(false);break;}_PM.SetEnabled(true);_auD=_FK.GetOppositeAxis(_4S);var _56=_PM._o6;_56.Clear();var _zA=new Array(this.sAppName,_auD,_YW,ExpAPIXml.kEleAxisOpExprSorttypeDefault);_zn=this._sp.GetString('OTH_BLOCKPROP_SORTMENU_NONE');var oContextItem=new ContextItem('',_zn,CUICrosstab.SafeSortMembers,false,_zA,_56);_zA=new Array(this.sAppName,_auD,_YW,ExpAPIXml.kEleAxisOpExprSorttypeTop);_zn=this._sp.GetString('OTH_CROSSTAB_MENU_SORT_TOP');oContextItem=new ContextItem('',_zn,CUICrosstab.SafeSortMembers,false,_zA,_56);_zA=new Array(this.sAppName,_auD,_YW,ExpAPIXml.kEleAxisOpExprSorttypeBottom);_zn=this._sp.GetString('OTH_CROSSTAB_MENU_SORT_BOTTOM');oContextItem=new ContextItem('',_zn,CUICrosstab.SafeSortMembers,false,_zA,_56);break;case 'OTH_CROSSTAB_MENU_CAL_EDIT':_Vh=(this._jN.HasValidCalcSelection()&&this._jN.canDoEditCalc());_PM.SetEnabled(_Vh);if(_Vh){_PM.SetParameterArr(new Array(this.sAppName,_O0._az));}break;case 'OTH_CROSSTAB_MENU_USER_DEF_CAL':_Vh=this._jN.HasValidCalcSelection();_PM.SetEnabled(_Vh);if(_Vh){var _56=_PM._o6;_56.Clear();if(!(this._jN._wa instanceof CDLBlock)){_O0._az.PopulateCalOptions();var _aJs=_O0._az._e4;for(var i in _aJs){var _zA=new Array(this.sAppName,_aJs[i],_FK,_O0._az);var _PM=new ContextItem(null,_aJs[i].GetMenuLabel(),CUICrosstab.SafeDoUserDefCalculation,false,_zA,_56);_PM.SetTooltip(_aJs[i].GetLabel());}}var _zA=new Array(this.sAppName,_O0._az);var _PM=new ContextItem(null,_Co.GetString('OTH_CROSSTAB_MENU_CAL_CUSTOMIZE'),CUICrosstab.SafeDoCustomizeCalc,false,_zA,_56);}break;case 'OTH_MEASURE_MENU_USE_AS_DEFAULT':if(_aCH>1){_PM.SetEnabled(false);}else{_Lv=new CUIDragDropMember(_N9.axisMember.GetMemberId());_Lv.kPopulation=ExpAPIXml.kMemberPopulation;_Lv.kAction=ExpAPIXml.kActionSetDefMeasure;_PM.SetParameterArr(new Array(this._jN,_Lv));}break;case 'OTH_CROSSTAB_MENU_REPLACE_CUR_BLK_BY_SELECTION':_PM.SetDisplayFlag(true);if(_O0.CanHamcizeSelectedMembers()){_PM.SetEnabled(true);var _C9=new Array();for(id in _O0._hb){var _aiQ=_O0._hb[id];if(_aiQ){_C9.push(_aiQ.GetMemberId());}}_PM.SetParameterArr(new Array(this.sAppName,_FK,_C9));_PM.SetItemAction(CUICrosstab.SafeDoKeepSelectedMembers);}else{_PM.SetEnabled(false);}break;case 'OTH_CROSSTAB_MENU_ADD_CUSTOMSET':if(_O0.CanHamcizeSelectedMembers()){_PM.SetEnabled(true);var _C9=new Array();for(id in _O0._hb){var _aiQ=_O0._hb[id];if(_aiQ){_C9.push(_aiQ.GetMemberId());}}_PM.SetParameterArr(new Array(this.sAppName,_C9));_PM.SetItemAction(CUICrosstab.SafeDoAddCustomSetFromSelectedMembers);}else{_PM.SetEnabled(false);}break;case 'OTH_CROSSTAB_DESCRIPTIVE_STATISTICS':_PM.SetEnabled(true);if(!this._jN.IsDescriptiveStatisticsEnabled()){_PM.SetEnabled(false);}else{_PM.SetEnabled(true);}break;case 'Expand':var _C9=new Array();if(_FK.IsOuterNestedBlock()||_FK.IsGroupedDescendantsAtDepth()){_PM.SetEnabled(false);}else{_PM.SetEnabled(true);for(id in _O0._hb){var _aiQ=_O0._hb[id];if(_aiQ){_C9.push(_aiQ.GetMemberId());}}_PM.SetParameterArr(new Array(this.sAppName,_FK,_C9));_PM.SetItemAction(CUICrosstab.SafeDoExpandMember);}break;case 'Collapse this segment...':break;case 'Edit segment caption...':var _Q8=_zC.GetAxisMember()._a1;_PM.SetItemAction(Utilities.GenerateCallback(this.OpenSegCaptionEditDlg,[_FK,_Q8],this));break;case 'APP_MENUBAR_ZERO_SUPPRESSION':var _56=_PM._o6;_56.Clear();if(_O0.IsRowAxis()){_zn=_Co.GetString('IDS_TOOLBAR_SUPPRESS_COLS_OFSELECTION');}else{_zn=_Co.GetString('IDS_TOOLBAR_SUPPRESS_ROWS_OFSELECTION');}var _amk=_O0._eh;var _aqe=this.GetOppositeAxis(_O0);var _aqO=_aqe._eh;var _z5=this._jN._my.IsSparsityRemovalEnabled();if(_z5){var _S6=null;if(_aCH>1){_z5=false;}else if(!_AT.GetCurrentDataMatrix().HasMeasure()){_z5=false;}else{_S6=_amk.GetSelectedSuppressionTuple(_N9.axisMember.GetMemberPos(),_N9.axisMember.GetDepth(),true,CDLAxisMember.CanBeUsedInSuppression);_z5=_S6?true:false;}}if(!_z5){_PM.SetDisplayFlag(_z5);break;}_PM.SetDisplayFlag(_z5);if(_N9.axisMember._f1._un){var _UH=new Array();_UH.push(_N9.axisMember._f1._un);var _zA=new Array(this.sAppName,_aqO,_UH);var oContextItem=new ContextItem('',_zn,CUICrosstab.SafeRemoveSuppressionTuples,false,_zA,_56);oContextItem.SetChecked(true);}else{var _zA=new Array(this.sAppName,_amk,_S6);var oContextItem=new ContextItem('',_zn,CUICrosstab.SafeDoSuppression,false,_zA,_56);oContextItem.SetChecked(false);}var _zA=new Array(this.sAppName);var oContextItem=new ContextItem('',_Co.GetString('IDS_TOOLBAR_SUPPRESS_CUSTOM'),CUIWorkSheet.SafeCustomizeSuppression,false,_zA,_56);break;default:if(_PM.GetFunctionId&&_PM.GetFunctionId()=="proppane"){_PM._ny=_Co.ReplaceParam('OTH_CROSSTAB_MENU_PROPERTY_PANE',1,_FK.GetLabel());var _AG=new Array(this.sAppName,_FK.GetId());_PM.SetParameterArr(_AG);}else if(_PM.GetFunctionId&&_PM.GetFunctionId()=="singleMemExpd"){var _alu=_N9.axisMember.GetAxisMember();if(_alu._ie){_PM.SetDisplayFlag(true);_PM._ny=_alu._hG?'Close Expanded Set':'Reopen Expanded Set';var _ZK=this._jN._m4.dataManager._kX.getBlock(_alu._ie);var _6K=_alu._hG?'false':'true';var _AG=new Array(this.sAppName,_ZK,_6K);_PM.SetParameterArr(_AG);}else{_PM.SetDisplayFlag(false);}}break;}}}_Ga.display(e);}else if(this._n2){if(!this._jN.AllowInteraction()){return;}var _YZ=_N9.axisMember.GetAxis().GetAxisId();var _L7=_N9.axisMember.GetAxisMember().GetBlock().GetId();if(_L7==this._uH){this.ShowBlockContextMenu(_N9.axisMember.GetAxisMember().GetBlock(),e);}}if(!this._n2){this.UpdateUserSelection(_RE);}};CUICrosstab.SafeDoContinueHandleContextMenu=function(_Ok,e){/*@if(!@bering_debug)@*/try{/*@end@*/_Ok.ContinueHandleContextMenu(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.prototype.HandleContextMenu=function(e){Dom.CancelEvent(e);if(!this._jN.AllowInteraction()||CUIDragDrop.IsDragging()||CUIContextMenu.IsVisible()){return;}this._jN._m4.OnSelChange(this);var _amW=this._jN._m4.ConfirmLossOfChanges();if(_amW==Utilities.eStateContinue){this.ContinueHandleContextMenu(e);}else if(_amW==Utilities.eStateHold){var _axQ=Dom.CloneMouseEvent(e);var _Ro=new Array(this,_axQ);Utilities.SetProcedureToHold(CUICrosstab.SafeDoContinueHandleContextMenu,_Ro);this._jN._m4.oDialogMgr.Subscribe(this,ExpEvent.kCUIDialogMgr_HideModalDialog);}};CUICrosstab.prototype.UpdatePropertiesFlyoutMenu=function(){var _JJ=this._fa;if(_JJ.IsVisible()){if(this._vo){_JJ.Clear();this._vo();}_JJ.display(this.oLastEvent,false,_JJ.GetLeftPos(),_JJ.GetTopPos());this._vo=null;this._fa=null;this.oLastEvent=null;}};CUICrosstab.prototype.AttachProperties=function(_Ga,_Hp,_BV,_Ti){var _aoR=false;var _aGY=this._ev.GetExistProps();for(var _O5 in _aGY){var _AG=new Array(this.sAppName,_BV,_O5,_Ti);var _aIT=_aGY[_O5].GetBreadCrumbText();var _aIn=new ContextItem('',_aIT,CUICrosstab.SafeDoAddPropertyToLevel,false,_AG,_Ga);var _ayd=null;for(var _BX in _Hp){_ayd=_Hp[_BX].GetPropertyById(_O5);if(_ayd&&_ayd.IsEnabled()){_aIn.SetChecked(true);break;}}_aoR=true;}if(!_aoR){var _aqf=new ContextItem('',this._sp.GetString('OTH_CROSSTAB_MENU_LEVEL_PROPERTIES_NONE'),null,true,null,_Ga);}};CUICrosstab.prototype.FetchPropertiesOnFly=function(_Tc,_JJ){if(!this._fa){this._fa=_JJ;_Tc.FetchProperties(this._ev.GetIncompletePropOwner());_Tc.Subscribe(this._ev,ExpEvent.kCDLMetadata_Merge_Properties);this._ev.Subscribe(this,ExpEvent.kCOTPropsLoadingMgr_Merge_Complete);}};CUICrosstab.prototype.HandleMemberPropListMenu=function(_PM,_Tc,_Hp,_BV,_Ti,e){_PM.SetEnabled(true);var _Ki=new Array();var _ET=null;var oMem=null;var _abv=false;var _JP=new Object();var _5S=new Object();var _abj=new Array();for(var _BX in _Hp){if(_Hp[_BX].IsSummaryMem()){continue;}_abj.push(_Hp[_BX].GetAxisMember());oMem=_Tc.GetMember(_Hp[_BX].GetMemberId());if(oMem){var _Z1=oMem.GetLevel();_ET=_Z1?_Z1:oMem.GetHierarchy();if(!(_ET.GetId()in _5S)){_5S[_ET.GetId()]=_ET;if(!_ET._lG){_abv=true;_Ki.push(_ET);}else{Utilities.CopyObjArray(_ET._lG,_JP);}}}}this._ev=new COTPropertiesLoadingManager(_JP,_Ki);if(!this._ev.IsAllPropsRetrieved()){var _agz=new ContextItem('',this._sp.GetString('IDS_CONTEXTBAR_LOADING'),null,true,null,_PM._o6);var _5x=Utilities.GenerateCallback(this.FetchPropertiesOnFly,[_Tc,_PM._o6],this);_agz.SetOnDisplayCallback(_5x);this._vo=Utilities.GenerateCallback(this.AttachProperties,[_PM._o6,_abj,_BV,_Ti],this);}else{this.AttachProperties(_PM._o6,_abj,_BV,_Ti);}};CUICrosstab.prototype.CreateUnhideMenu=function(_FK,_Ga,_AG){var _aeO=CUIHiddenItemProperty.kMaxItemsToShow;var _axL=false;if(_FK.GetHiddenMemberIds().length>_aeO){_axL=true;}_aeO=Math.min(_FK.GetHiddenMemberIds().length,_aeO);_Ga.Clear();var _BM=this._sp.GetString('OTH_BLOCKPROP_HIDDEN_ITEM_UNHIDE_ALL');var _PM=new ContextItem('',_BM,CUICrosstab.SafeDoUnhideAll,false,_AG,_Ga);var _aIC=new ContextSeparator(_Ga);var _aBk='OTH_CROSSTAB_HIDDEN_MEMBERS_MENU_UNHIDE';var _RJ=this._jN._m4.dataManager.metadata;for(var i=0;i<_aeO;i++){var _BM=this._sp.ReplaceParam(_aBk,1,_RJ.GetDataLabel(_FK.GetHiddenMemberIds()[i]));var _AG=new Array(this.sAppName,_FK,_FK.GetHiddenMemberIds()[i]);var _PM=new ContextItem('',_BM,CUICrosstab.SafeDoUnhideMember,false,_AG,_Ga);}};CUICrosstab.prototype.CreateBlockSizeMenu=function(_Ga,_AG){_BM=this._sp.GetString('OTH_CROSSTAB_MENU_BLOCK_SIZE_DEFAULT');var _PM=new ContextItem('',_BM,CUICrosstab.SafeDoSetBlockSize,false,_AG,_Ga);_PM.id='OTH_CROSSTAB_MENU_BLOCK_SIZE_DEFAULT';_PM.SetAsDefault(true);_PM.SetRadioState(true);_BM=this._sp.GetString('OTH_CROSSTAB_MENU_BLOCK_SIZE_5');_PM=new ContextItem('',_BM,CUICrosstab.SafeDoSetBlockSize,false,_AG,_Ga);_PM.id='OTH_CROSSTAB_MENU_BLOCK_SIZE_5';_PM.SetRadioState(false);_PM.SetFunctionId('5');_BM=this._sp.GetString('OTH_CROSSTAB_MENU_BLOCK_SIZE_10');_PM=new ContextItem('',_BM,CUICrosstab.SafeDoSetBlockSize,false,_AG,_Ga);_PM.id='OTH_CROSSTAB_MENU_BLOCK_SIZE_10';_PM.SetRadioState(false);_PM.SetFunctionId('10');_BM=this._sp.GetString('OTH_CROSSTAB_MENU_BLOCK_SIZE_15');_PM=new ContextItem('',_BM,CUICrosstab.SafeDoSetBlockSize,false,_AG,_Ga);_PM.id='OTH_CROSSTAB_MENU_BLOCK_SIZE_15';_PM.SetRadioState(false);_PM.SetFunctionId('15');_BM=this._sp.GetString('OTH_CROSSTAB_MENU_BLOCK_SIZE_20');_PM=new ContextItem('',_BM,CUICrosstab.SafeDoSetBlockSize,false,_AG,_Ga);_PM.id='OTH_CROSSTAB_MENU_BLOCK_SIZE_20';_PM.SetRadioState(false);_PM.SetFunctionId('20');_BM=this._sp.GetString('OTH_CROSSTAB_MENU_BLOCK_SIZE_CUSTOMIZE');_PM=new ContextItem('',_BM,CUICrosstab.SafeDoCustomizeSize,false,_AG,_Ga);_PM.id='OTH_CROSSTAB_MENU_BLOCK_SIZE_CUSTOMIZE';_PM.SetRadioState(false);};CUICrosstab.prototype.CreateIncludeMenu=function(_FK,_Ga,_AG){var _axL=false;_Ga.Clear();var _BM=this._sp.GetString('OTH_BLOCKPROP_INCLUDE_ALL');var _AG=new Array(this._gC,_FK);var _PM=new ContextItem("",_BM,CUICrosstab.SafeDoIncludeAll,false,_AG,_Ga);var _aIC=new ContextSeparator(_Ga);var _af6=_FK.GetExcludedMemberIds();var _asO='OTH_BLOCKPROP_INCLUDE';var _RJ=this._jN._m4.dataManager.metadata;for(var i=0;i<_af6.length;i++){var _BM=this._sp.ReplaceParam(_asO,1,_RJ.GetDataLabel(_af6[i]));var _AG=new Array(this.sAppName,_FK,_af6[i]);var _PM=new ContextItem('',_BM,CUICrosstab.SafeDoIncludeMember,false,_AG,_Ga);}};CUICrosstab.prototype.HandleBlockSizeMenu=function(_Ga,_FK){var _Co=this._sp;for(var i=0;i<_Ga.items.length;i++){var _apL=_Ga.items[i];var _Ng=false;var _zA;var _Cg=_FK.GetBlockSize();switch(_apL.id){case 'OTH_CROSSTAB_MENU_BLOCK_SIZE_DEFAULT':_Ng=(_Cg==_FK._yf);_zA=new Array(this.sAppName,_FK,String(_FK._yf));break;case 'OTH_CROSSTAB_MENU_BLOCK_SIZE_5':case 'OTH_CROSSTAB_MENU_BLOCK_SIZE_10':case 'OTH_CROSSTAB_MENU_BLOCK_SIZE_15':case 'OTH_CROSSTAB_MENU_BLOCK_SIZE_20':_Ng=(_Cg==parseInt(_apL.GetFunctionId(),10));_apL.SetDisplayFlag(true);if(parseInt(_apL.GetFunctionId(),10)>ExpAPIXml.maxBlockSize){_apL.SetDisplayFlag(false);}_zA=new Array(this.sAppName,_FK,_apL.GetFunctionId());break;case 'OTH_CROSSTAB_MENU_BLOCK_SIZE_CUSTOMIZE':default:var _av4=(_Cg==5||_Cg==10||_Cg==15||_Cg==20||_Cg==_FK._yf);_Ng=!_av4;_apL.id='OTH_CROSSTAB_MENU_BLOCK_SIZE_CUSTOMIZE';if(_Ng){var _aiJ='OTH_CROSSTAB_MENU_BLOCK_SIZE_CUSTOMIZE_CURRENT_SIZE';_apL._ny=_Co.ReplaceParam(_aiJ,1,String(_Cg));}_zA=new Array(this.sAppName,_FK);break;}_apL.SetRadioState(_Ng);_apL.SetParameterArr(_zA);}};CUICrosstab.prototype.ShowBlockContextMenu=function(_FK,e){var _L7=_FK.GetId();var _Co=this._sp;var _O0=_FK.GetAxis();var _Li=this._jN.GetDataWorkSheet().GetDataManager().GetCurrentDataMatrix();var _BV=_Li.GetDataMatrixId();var _Ga;if(_FK.IsHAMC()){_Ga=this.oMemberBlockMenu;}else if(_FK.GetType()===CDLAbsBlock.eTypeSegmtQuadrant){_Ga=this.oQuadSegBlockMenu;}else{_Ga=this.oChildrenBlockMenu;}for(var j=0;j<_Ga.items.length;j++){var _PM=_Ga.items[j];if(_PM instanceof ContextItem){if(_PM.GetFunctionId()=="blockproperty"){_PM.SetDisplayFlag(true);_PM._ny=_Co.ReplaceParam('OTH_CROSSTAB_MENU_BLOCK_PROPERTIES',1,_FK.GetLabel());var _TD=this._jN._m4.oBlockPropsPane.bExpanded;_PM.SetChecked(_TD);}switch(_PM.id){case 'OTH_CONTEXTBAR_DELETE_BLOCK':if(_FK.CanDelete()){_PM.SetParameterArr(new Array(this.sAppName,_FK));_PM.SetEnabled(true);}else{_PM.SetEnabled(false);}break;case "Convert to V5 Block":_PM.SetParameterArr(new Array(this.sAppName,_FK));_PM.SetEnabled(true);break;case 'OTH_CROSSTAB_MENU_SHOW_LEVEL_PROPERTIES':_PM.SetEnabled(true);_PM._o6.Clear();this._ev=_FK.GetAllDistinctProps();var _aCC=_FK.GetAxis().GetAllNodesInBlock(_FK);if(this._ev.IsAllPropsRetrieved()){this.AttachProperties(_PM._o6,_aCC,_BV,_FK.GetId());}else{if(!this.oLastEvent){this.oLastEvent=Dom.CloneMouseEvent(e,true);}var _agz=new ContextItem('',_Co.GetString('IDS_CONTEXTBAR_LOADING'),null,true,null,_PM._o6);var _Tc=this._jN._m4.dataManager.metadata;var _5x=Utilities.GenerateCallback(this.FetchPropertiesOnFly,[_Tc,_PM._o6],this);_agz.SetOnDisplayCallback(_5x);this._vo=Utilities.GenerateCallback(this.AttachProperties,[_PM._o6,_aCC,_BV,_FK.GetId()],this);break;}break;case 'OTH_CROSSTAB_MENU_SORT':_PM.SetDisplayFlag(true);CUIWorkSheet.UpdateSortItems(_PM._o6,this.sAppName,_FK);var _6o=false;if(!_FK.CanSort()){_PM.SetEnabled(false);break;}else{_PM.SetEnabled(true);_6o=true;}break;case 'OTH_CROSSTAB_MENU_ADD_CUSTOMSET':if(_PM){if(!_FK.CanSaveAsCustomSet()){_PM.SetEnabled(false);}else{_PM.SetEnabled(true);var _zA=new Array(this.sAppName,_FK);_PM.SetParameterArr(_zA);}}break;case 'OTH_CROSSTAB_MENU_FILTER':_PM.SetDisplayFlag(true);if(!_FK.CanApplyUserDefFilter()){_PM.SetEnabled(false);break;}else{_PM._o6.Clear();_PM._o6=CUIWorkSheet.AttachUserDefinedFilterItems(_Co,_PM._o6,this.sAppName,_FK);_PM.SetEnabled(true);}break;case 'OTH_CROSSTAB_MENU_TOPBOTTOM':_PM.SetDisplayFlag(true);if(!_FK.CanApplyTopBottom()){_PM.SetEnabled(false);break;}else{CUIWorkSheet.UpdateTopBottomMenuItems(_Co,_PM._o6,this.sAppName,_FK);_PM.SetEnabled(true);}break;case "OTH_CROSSTAB_MENU_AUTO_SUBTOTAL":if(!_FK.CanApplyAutoSubtotals()){_PM.SetEnabled(false);}else{_PM.SetEnabled(true);var _zA=new Array(this.sAppName,_FK);_PM.SetParameterArr(_zA);}break;case "OTH_CROSSTAB_MENU_SUMMARIZE":_PM.SetDisplayFlag(true);if(_FK.CanApplySetBasedCalc()){_PM.SetEnabled(true);_PM._o6.Clear();CUIWorkSheet.AttachSetBasedCalcItems(_Co,_PM._o6,this.sAppName,_FK);}else{_PM.SetEnabled(false);}break;case "OTH_CROSSTAB_MENU_CALCULATE_DLG":var _ag9=_FK.CanApplyUserDefCalculation();_PM.SetEnabled(_ag9);if(_ag9){var _BZ=_FK.GetAxis()._l7;var _Q1=this._jN.GetUIAxesContainer().GetUIAxis(_BZ);var _AG=new Array(this.sAppName,_Q1._az);_PM.SetParameterArr(_AG);}break;case 'OTH_CROSSTAB_MENU_INCREASE_DEPTH':var _aGC=_FK.CanDescend();_PM.SetEnabled(_aGC);var _AG=new Array(this.sAppName,_FK,1);_PM.SetParameterArr(_AG);break;case 'OTH_CROSSTAB_MENU_DECREASE_DEPTH':var _aiK=_FK.CanAscend();_PM.SetEnabled(_aiK);var _AG=new Array(this.sAppName,_FK,-1);_PM.SetParameterArr(_AG);break;case "Start segmenting wizard...":_PM.SetItemAction(Utilities.GenerateCallback(this.StartSegmentWizard,[_FK],this));break;case "Set current segment measures...":_PM.SetItemAction(Utilities.GenerateCallback(this.ModifySegmentRule,[_FK],this));break;}if(_PM.GetFunctionId&&_PM.GetFunctionId()=="expandblock"){_PM._ny=_Co.ReplaceParam('OTH_CROSSTAB_MENU_EXPAND',1,_FK.GetLabel());var _5k=_FK.CanExpand();_PM.SetEnabled(_5k);var _AG=new Array(this.sAppName,_FK);_PM.SetParameterArr(_AG);}}}_Ga.display(e);};CUICrosstab.prototype.HandleDragOver=function(e){if(!e){var e=window.event;}Dom.CancelEvent(e);if(!this._jN.AllowInteraction()){return;}var _yG=(e.button==CUIDragDrop.rightMouseDown);this._t1=false;var _N9=Dom.GetEventTarget(e);var _XG=(this.getMemberCell(_N9)!=null)?true:false;if(_N9.tagName=='IMG'){_N9=_N9.parentNode;}_XG=_N9._oDropTgt?true:_XG;this.HideAllDropZones(_XG);if(this._oM.bDelete){CUIDragDrop.setEffect(CUIDragDrop.eEffectMove);}else{CUIDragDrop.setEffect(CUIDragDrop.eEffectCopy);}var _RJ=this._jN._m4.dataManager.metadata;var _Li=this._jN._m4.dataManager.GetCurrentDataMatrix();if(this.getMemberCell(_N9)){CUIDragDrop.SetCursorImgPosition(e.clientX,e.clientY);var _Vl=this.getMemberCell(_N9);var oMem=_Vl.axisMember;if(!oMem||!oMem.GetAxisMember()){this.handleInvalidDZ(e);}else{var _FK=oMem.GetAxisMember().GetBlock();this._t1=COTValidation.IsHAMCDrop(_RJ,_FK,this._oM);this._rl=new Object();this._rl.oMem=oMem;this._rl.iDropZoneType=this._pS.ShowDropZone(_Vl,e,this._rl,this._t1,_yG,this._oM);if(this._rl.iDropZoneType==CUIDropZone.kInvalidDrop){this.handleInvalidDZ(e);}}}else if(this.getMemberCellTemplate(_N9)){CUIDragDrop.SetCursorImgPosition(e.clientX,e.clientY);var _X5=this.getMemberCellTemplate(_N9);var _YZ=null;if(_X5.bColMemCellTemp){_YZ=this._bz.GetAxisId();}else if(_X5.bRowMemCellTemp){_YZ=this._ax.GetAxisId();}Debug.Assert(_YZ!=null);var _Ib=_Li.GetAxisById(_YZ);var _atr=COTValidation.IsValidDrop(_Ib,this._oM,_RJ,ExpAPIXml.kAxisOpXjoin);if(!_atr){this.handleInvalidDZ(e);}else{this._rl=new Object();this._rl.oMem=_X5;this._rl.iDropZoneType=CUIDropZone.kReplaceDrop;this._pS.ShowReplaceDZCell(_X5);}}else if(_N9.cellType&&(_N9.cellType==CUICrosstab.kCentralMeasureCell||_N9.cellType==CUICrosstab.kDataCell||_N9.cellType==CUICrosstab.kDataCellTemplate)){var _7a=this._oM.sId;var _Tc=this._jN._m4.dataManager.metadata;var _NS=_Tc.GetMeasure(_7a);var _agD=this._ax.GetDLAxis().HasMeasureBlock()||this._bz.GetDLAxis().HasMeasureBlock();var _arY=false;var _akm=false;if(this._oM.aMemberIds!=null){_akm=this._oM.aMemberIds&&this._oM.aMemberIds.length>1;}else if(this._oM.sBlockId!=null){var _ak7=this._jN._m4.dataManager._kX.getBlock(this._oM.sBlockId);_akm=_ak7.IsMeasureBlock()||_ak7.IsChildrenMeasureBlock();}if(_NS){if(_N9.cellType==CUICrosstab.kCentralMeasureCell){if(!_akm){this._mD.bDragOver=true;this.SetCentralMeasureCellStyle();_arY=true;if(!_agD){this._o2.HighlightDropZone();}}}else if(!_agD&&!_akm){this._o2.HighlightDropZone();_arY=true;this._mD.bDragOver=true;this.SetCentralMeasureCellStyle();}}if(_arY){this._rl=new Object();this._rl.oMem=this._mD;this._rl.iDropZoneType=CUIDropZone.kMeasureDrop;}else{this.handleInvalidDZ(e);}CUIDragDrop.SetCursorImgPosition(e.clientX,e.clientY);}else{if(!_XG){this.handleInvalidDZ(e);}else{CUIDragDrop.setEffect(CUIDragDrop.eEffectCopy);}CUIDragDrop.SetCursorImgPosition(e.clientX,e.clientY);}};CUICrosstab.prototype.handleInvalidDZ=function(e){CUIDragDrop.setEffect(CUIDragDrop.eEffectNone);this._rl=new Object();this._rl.iDropZoneType=CUIDropZone.kInvalidDrop;CUIDragDrop.SetCursorImgPosition(e.clientX,e.clientY);};CUICrosstab.prototype.SafeHandleDragOver=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}this.oCrosstab.HandleDragOver(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.prototype.SafeHandleDragDrop=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}this.oCrosstab.HandleDragDrop(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.prototype.ContinueHandleDragDrop=function(_Ke,e){var _Hb=ExpAPIXml.kChildrenPopulation;if(!this._oM.bInsertWithChildren){_Hb=ExpAPIXml.kMemberPopulation;}if(this._oM.sLevId){_Hb=ExpAPIXml.kAxisExprLevelMembers;}this._oM.kPopulation=_Hb;var _yQ=this._rl.oMem;var _YZ=null;if(_yQ.bColMemCellTemp){_YZ=this._bz.GetAxisId();}else if(_yQ.bRowMemCellTemp){_YZ=this._ax.GetAxisId();}else if(_yQ&&_yQ.GetAxis){_YZ=_yQ.GetAxis().GetAxisId();}if(_YZ!=null){this._oM.sTargetAxis=_YZ;}if(_yQ&&_yQ.GetBlock&&COTValidation.IsDropFromSameBlock(this._oM,_yQ.GetBlock())){this.HideAllDropZones();return;}var _Nm=this._rl.iDropZoneType;switch(_Nm){case CUIDropZone.kReplaceDrop:if(_yQ.cellType==CUICrosstab.kMemberCellTemplate){this.AxisXJoinProxy(e,_Nm,_yQ);}else{this.RepLevelByMemberProxy(e,_yQ);}break;case CUIDropZone.kBottomLongDrop:if(this._oM._ud){this.SDNProxy(e);break;}case CUIDropZone.kTopLongDrop:var _O0=_yQ.GetAxis();if(_O0.IsColAxis()){this.AxisXJoinProxy(e,_Nm);}else{this.AddMemberProxy(e,_Nm,_yQ);}break;case CUIDropZone.kRightLongDrop:if(this._oM._ud){this.SDNProxy(e);break;}case CUIDropZone.kLeftLongDrop:var _O0=_yQ.GetAxis();if(_O0.IsColAxis()){this.AddMemberProxy(e,_Nm,_yQ);}else{this.AxisXJoinProxy(e,_Nm);}break;case CUIDropZone.kRightShortDrop:if(this._oM._ud){this.SDNProxy(e);break;}case CUIDropZone.kLeftShortDrop:var _O0=_yQ.GetAxis();this.XJoinProxy(e,_Nm,_yQ);break;case CUIDropZone.kBottomShortDrop:if(this._oM._ud){this.SDNProxy(e);break;}case CUIDropZone.kTopShortDrop:var _O0=_yQ.GetAxis();this.XJoinProxy(e,_Nm,_yQ);break;case CUIDropZone.kMeasureDrop:var _F8=this._oM.sId;var _R1=this._oM.aOtherMemIds;this._oM.kAction=ExpAPIXml.kActionSetDefMeasure;this._jN.InsertDropData(this._oM,e);break;case CUIDropZone.kAppendDrop:this._oM.sTargetBlock=_yQ.GetAxisMember().GetBlock().GetId();this._oM.kAction=ExpAPIXml.kActionAppend;this._jN.InsertDropData(this._oM,e);break;}this._jN._m4._qi.oTree.SetInsertWithChildrenChx();};CUICrosstab.prototype.DeferHandleDragDrop=function(_Ke,_Lv,e){var _BC=Utilities.GenerateCallback(CUICrosstab.SafeDoContinueHandleDragDrop,[_Ke,e]);var _Tc=FindApp(_Ke).uiManager.dataManager.metadata;_Tc.GetLineage(_Lv.GetOrphanAncestorArr(),_BC);};CUICrosstab.SafeDoContinueHandleDragDrop=function(_Ke,e){/*@if(!@bering_debug)@*/try{/*@end@*/var _au4=FindApp(_Ke).uiManager._jf.GetUICrosstab();_au4.ContinueHandleDragDrop(_Ke,e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.prototype.HandleDragDrop=function(e){if(!this._jN.AllowInteraction()||!this._rl||this._rl.iDropZoneType==CUIDropZone.kInvalidDrop){return;}if(this._oM.sCustomSetId){var _HF=this._jN._m4.dataManager._kX;if(!_HF.GetCustomSet(this._oM.sCustomSetId).CanUseOnAxis()){CUIDialogMgr.DisplayMessageBox(CUIConfirmDlg._hw,"MES_CANNOT_INSERT_CUSTOM_SET");this.HideAllDropZones();return;}}var _Ke=this._jN._m4.appobj.appname;var _amW=this._jN._m4.ConfirmLossOfChanges();var _axQ=Dom.CloneMouseEvent(e);if(_amW==Utilities.eStateContinue){if(this._oM.GetOrphanAncestorArr&&this._oM.GetOrphanAncestorArr()){this.DeferHandleDragDrop(_Ke,this._oM,_axQ);}else{this.ContinueHandleDragDrop(_Ke,e);}}else if(_amW==Utilities.eStateHold){var _Ro=new Array(_Ke,_axQ);Utilities.SetProcedureToHold(CUICrosstab.SafeDoContinueHandleDragDrop,_Ro);this._jN._m4.oDialogMgr.Subscribe(this,ExpEvent.kCUIDialogMgr_HideModalDialog);}};CUICrosstab.prototype.AddMemberProxy=function(e,_Nm,_yQ){var _YZ;var _aGm=ExpAPIXml.kEleOuter;var _ajV=false;switch(_Nm){case CUIDropZone.kRightShortDrop:_aGm=ExpAPIXml.kEleInner;_ajV=true;break;case CUIDropZone.kLeftShortDrop:_aGm=ExpAPIXml.kEleOuter;_ajV=true;break;case CUIDropZone.kTopShortDrop:_aGm=ExpAPIXml.kEleOuter;_ajV=true;break;case CUIDropZone.kBottomShortDrop:_aGm=ExpAPIXml.kEleInner;_ajV=true;break;case CUIDropZone.kRightLongDrop:_aGm=ExpAPIXml.kEleInner;break;case CUIDropZone.kLeftLongDrop:_aGm=ExpAPIXml.kEleOuter;break;case CUIDropZone.kTopLongDrop:_aGm=ExpAPIXml.kEleOuter;break;case CUIDropZone.kBottomLongDrop:_aGm=ExpAPIXml.kEleInner;break;}var _L7=(_ajV||this._t1)?_yQ.GetAxisMember().GetBlock().GetId():null;this._oM.sTargetBlock=_L7;this._oM.kPosition=_aGm;this._oM.kAction=ExpAPIXml.kAxisOpUnion;this._jN.InsertDropData(this._oM,e);};CUICrosstab.prototype.RepLevelByMemberProxy=function(e,_yQ){this._oM.sTargetBlock=_yQ.GetAxisMember().GetBlock().GetId();this._oM.kAction=ExpAPIXml.kActionReplace;this._jN.InsertDropData(this._oM,e);};CUICrosstab.prototype.AxisXJoinProxy=function(e,_Nm){switch(_Nm){case CUIDropZone.kRightLongDrop:_aGm=ExpAPIXml.kEleInner;break;case CUIDropZone.kLeftLongDrop:_aGm=ExpAPIXml.kEleOuter;break;case CUIDropZone.kTopLongDrop:_aGm=ExpAPIXml.kEleOuter;break;case CUIDropZone.kBottomLongDrop:_aGm=ExpAPIXml.kEleInner;break;default:_aGm=ExpAPIXml.kEleInner;break;}this._oM.kPosition=_aGm;this._oM.kAction=ExpAPIXml.kAxisOpXjoin;this._jN.InsertDropData(this._oM,e);};CUICrosstab.prototype.XJoinProxy=function(e,_Nm,_yQ){var _FK=_yQ.GetAxisMember().GetBlock();var _L7=_FK.GetId();var _aGm;switch(_Nm){case CUIDropZone.kRightShortDrop:_aGm=ExpAPIXml.kEleInner;break;case CUIDropZone.kLeftShortDrop:_aGm=ExpAPIXml.kEleOuter;break;case CUIDropZone.kTopShortDrop:_aGm=ExpAPIXml.kEleOuter;break;case CUIDropZone.kBottomShortDrop:_aGm=ExpAPIXml.kEleInner;break;}this._oM.kPosition=_aGm;this._oM.kAction=ExpAPIXml.kAxisOpXjoin;this._oM.sTargetBlock=_L7;this._jN.InsertDropData(this._oM,e);};CUICrosstab.prototype.SDNProxy=function(e){this._oM.kPosition=ExpAPIXml.kEleInner;this._oM.kAction=ExpAPIXml.kAxisOpNest;this._oM.sTargetBlock=this._oM._b5;this._jN.InsertDropData(this._oM,e);};CUICrosstab.prototype.HideAllDropZones=function(_KX){if(!this._jN.IsCrosstabVisible()||this._lL){return;}if(!_KX){this._pS.HideAllAxisDropZones();}if(this._qB){this.HideMemTemplateDropZones(this._qB);}if(this._mY){this.HideMemTemplateDropZones(this._mY);}if(this._o2){this._o2.HideDropZone();}if(this._mD&&this._mD.bDragOver){this._mD.bDragOver=false;this.SetCentralMeasureCellStyle();}};CUICrosstab.prototype.HideMemTemplateDropZones=function(_VL){if(_VL.bRowMemCellTemp){_VL.className="RowMemberCellTemplate";}else{_VL.className="ColMemberCellTemplate";}};CUICrosstab.prototype.SelectDataCell=function(_N9,_N1){if(Utilities.bDiffMiningEnabled){if(!_N1){this.UnselectAll();}}else{this.UnselectAll();}if(_N9.lastChild&&_N9.lastChild.focus)_N9.lastChild.focus();var _atX=(this._ax.GetDepth()-1);var _alr=this._ax.GetMember(_N9.y,_atX);if(_alr){this._ax.TertiarySelectMember(_alr);}var _asv=this._bz.GetMember(_N9.x,this._bz.GetDepth()-1);if(_asv){this._bz.TertiarySelectMember(_asv);}this._ao=true;this._nX=_N9;if(Utilities.bDiffMiningEnabled){if(this._xj.length>=2){this._xj.shift();}this._xj.push(_N9);}};CUICrosstab.prototype.HasDataCellSelected=function(){return this._ao;};CUICrosstab.SafeDoDrillThrough=function(_Ke,_Pc){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.DrillThrough(_Pc);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.SafeDoDrillThroughSearch=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.DrillThroughSearch();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.SafeDoDrillToAnalysis=function(_Ke,_Vg){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);LaunchNewWindow(_Vg);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.SafeDoDrillUpOnCell=function(_Ke,_yW){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.uiManager._jf.GetUICrosstab().DrillUpOnDataCell(_yW);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.prototype.DrillUpOnDataCell=function(_N9){var _alr=this._ax.GetMember(_N9.y,this._ax.GetDepth()-1);var _asv=this._bz.GetMember(_N9.x,this._bz.GetDepth()-1);var _RJ=this._jN.GetDataWorkSheet().GetDataManager().metadata;var _zt=new Array();if(_alr&&_alr.CanDoSecondaryDrillUp()){_zt.push(_alr);}if(_asv&&_asv.CanDoSecondaryDrillUp()){_zt.push(_asv);}var dm=this._jN.GetDataWorkSheet().GetDataManager().GetCurrentDataMatrix();dm.DrillUpOnCell(_zt);};CUICrosstab.SafeDoDrillDownOnCell=function(_Ke,_yW){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.uiManager._jf.GetUICrosstab().DrillDownOnDataCell(_yW);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.prototype.DrillDownOnDataCell=function(_N9){var _alr=this._ax.GetMember(_N9.y,this._ax.GetDepth()-1);var _asv=this._bz.GetMember(_N9.x,this._bz.GetDepth()-1);var _al1=new Array();var _RJ=this._jN.GetDataWorkSheet().GetDataManager().metadata;if(_alr&&_alr.CanDoSecondaryDrillDown()){_al1.push(_alr.GetAxisMember());}if(_asv&&_asv.CanDoSecondaryDrillDown()){_al1.push(_asv.GetAxisMember());}var dm=this._jN.GetDataWorkSheet().GetDataManager().GetCurrentDataMatrix();dm.DrillOnCell(_al1);};CUICrosstab.SafeDoDrillOnCell=function(_Ke,_N9){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.uiManager._jf.GetUICrosstab().DrillOnDataCell(_N9);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.prototype.DrillOnDataCell=function(_N9){var _alr=this._ax.GetMember(_N9.y,this._ax.GetDepth()-1);var _asv=this._bz.GetMember(_N9.x,this._bz.GetDepth()-1);var _al1=new Array();if(_N9.bDrillUp){if(_alr&&_alr.CanDrillUp()){_al1.push(_alr.GetAxisMember());}if(_asv&&_asv.CanDrillUp()){_al1.push(_asv.GetAxisMember());}}else{if(_alr&&_alr.CanDrillDown()){_al1.push(_alr.GetAxisMember());}if(_asv&&_asv.CanDrillDown()){_al1.push(_asv.GetAxisMember());}}var dm=this._jN.GetDataWorkSheet().GetDataManager().GetCurrentDataMatrix();dm.DrillOnCell(_al1,_N9.bDrillUp);};CUICrosstab.SafeDoDrillToAnalysis2=function(_Ke,_yW){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.uiManager._jf.GetUICrosstab().DrillToAnalysis2(_yW);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.prototype.DrillToAnalysis2=function(_N9){var _alr=this._ax.GetMember(_N9.y,this._ax.GetDepth()-1);var _asv=this._bz.GetMember(_N9.x,this._bz.GetDepth()-1);var _al1=new Array();var _RJ=this._jN.GetDataWorkSheet().GetDataManager().metadata;if(_asv&&_asv.CanDoSecondaryDrillDown()){_al1.push(_asv.GetAxisMember());}if(_alr&&_alr.CanDoSecondaryDrillDown()){_al1.push(_alr.GetAxisMember());}this._jN.GetDataWorkSheet().DrillToAnalysis(_al1,false);};CUICrosstab.SafeDoAnalyzeDifferenceSetup=function(_Ke,_E6){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.uiManager._jf.GetUICrosstab().DoAnalyzeDifferenceSetup(_E6);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.prototype.DoAnalyzeDifferenceSetup=function(_E6){var _9n=this.CreateDiffMiningParams(_E6);this._jN.GetDataWorkSheet().GetDataManager().GetCurrentDataMatrix().showAnalyzeDiffDlg(_9n.tuple1,_9n.value1,_9n.tuple2,_9n.value2);};CUICrosstab.SafeDoDiffMining=function(_Ke,_E6){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.uiManager._jf.GetUICrosstab().DiffMining(_E6);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.prototype.CreateDiffMiningParams=function(_E6){var _aGk=this._ax.GetMember(_E6[0].y,this._ax.GetDepth()-1)._f1._uT;var _aGu=this._bz.GetMember(_E6[0].x,this._bz.GetDepth()-1)._f1._uT;var _Dz=new Array();_Dz=[_aGk,_aGu];var _Fz=this._o2.GetCell(_E6[0].x,_E6[0].y,0).title;var _ap7=this._ax.GetMember(_E6[1].y,this._ax.GetDepth()-1)._f1._uT;var _aJo=this._bz.GetMember(_E6[1].x,this._bz.GetDepth()-1)._f1._uT;_DA=[_ap7,_aJo];var _Fy=this._o2.GetCell(_E6[1].x,_E6[1].y,0).title;return{_Dz:_Dz,_Fz:_Fz,_DA:_DA,_Fy:_Fy};};CUICrosstab.prototype.DiffMining=function(_E6){var _9n=this.CreateDiffMiningParams(_E6);this._jN.GetDataWorkSheet().DiffMining(_9n.tuple1,_9n.value1,_9n.tuple2,_9n.value2);};CUICrosstab.prototype.DisplayProperty=function(_Hr,_TE,_Ti,_B0,_D2){var dm=this._jN.GetDataWorkSheet().GetDataManager().GetCurrentDataMatrix();dm.SetDisplayProperty(_Hr,_TE,_Ti,_B0,_D2);};CUICrosstab.SafeDoSetDisplayProperty=function(_Ke,_Hr,_TE,_Ti,_B0,_D2){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.uiManager._jf.GetUICrosstab().DisplayProperty(_Hr,_TE,_Ti,_B0,_D2);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.prototype.SelectBlock=function(_N9){var _zU=_N9.axisMember;var _FK=_zU.GetAxisMember().GetBlock();var _JI=_FK.GetId();this.UnselectAll(true);_zU.GetAxis().SelectBlock(_zU,_FK);this._n2=true;this._uH=_JI;this._jN.HandleBlockSelection(this,_FK);};CUICrosstab.prototype.SecondarySelectBlock=function(_No,_U7){this.UnselectAll(true);var _aAG=_U7?true:false;var _RM=false;if(this._ax.GetBlock(_No.GetId())){this._ax.SelectBlock(null,_No,_aAG);_RM=true;}else if(this._bz.GetBlock(_No.GetId())){this._bz.SelectBlock(null,_No,_aAG);_RM=true;}if(_RM){this._n2=true;this._uH=_No.GetId();}};CUICrosstab.prototype.DeleteSelectedItems=function(){if(!this._jN.AllowInteraction()){return;}if(this._n2){if(this._ax.GetBlock(this._uH)){var _FK=this._ax.GetBlock(this._uH);this._ax.GetDLAxis().DoDeleteMultipleBlocks(new Array(_FK));}else if(this._bz.GetBlock(this._uH)){var _FK=this._bz.GetBlock(this._uH);this._bz.GetDLAxis().DoDeleteMultipleBlocks(new Array(_FK));}}else{if(this._ax.CanDeleteSelectedMembers()){this.DoDelete();}else if(this._bz.CanDeleteSelectedMembers()){this.DoDelete();}}};CUICrosstab.prototype.CanDelete=function(){if(this._n2){if(this._ax.GetBlock(this._uH)){return this._ax.GetBlock(this._uH).CanDelete();}else{return this._bz.GetBlock(this._uH).CanDelete();}}else{if(this._ax.CanDeleteSelectedMembers()){return true;}else if(this._bz.CanDeleteSelectedMembers()){return true;}}return false;};CUICrosstab.prototype.GetSearchData=function(){var _FZ=null;var _AT=this._jN._m4.dataManager;var _RJ=_AT.metadata;if(this._n2){var _avG=null;if(this._ax.GetBlock(this._uH)){_avG=this._ax.GetBlock(this._uH);}else if(this._bz.GetBlock(this._uH)){_avG=this._bz.GetBlock(this._uH);}else{Debug.Assert(false);}if(_avG){_FZ=_avG.GetSearchData();}return _FZ;}else{var _FZ=new Object();if(this._ax.GetLastSelection()||this._bz.GetLastSelection()){var _V7=null;if(this._ax.GetLastSelection()){_V7=this._ax.GetLastSelection();}else{_V7=this._bz.GetLastSelection();}if(!_V7.IsCalc()){if(!_RJ.GetMember(_V7.GetMemberId())){var _Uv=_RJ.GetMeasure(_V7.GetMemberId()).GetDimId();_FZ[_Uv]=_RJ.GetMeasureDimById(_Uv);}else{_FZ[_V7.GetMemberId()]=_RJ.GetMember(_V7.GetMemberId());}}else{_FZ=_V7.GetBlock().GetSearchData();}return _FZ;}else if(this._mD.bSelected){var _NS=_RJ.GetMeasure(_AT.GetCurrentDataMatrix().GetCurrentMeasureId());if(_NS){var _aj3=_NS.GetDimId();_FZ[_aj3]=_RJ.GetMeasureDimById(_aj3);return _FZ;}}}return null;};CUICrosstab.prototype.UnselectAll=function(_RY){var _Lk=false;if(this._n2&&!_RY){_Lk=true;}if(this._ax){this._ax.UnselectAllMembers();}if(this._bz){this._bz.UnselectAllMembers();}this._n2=false;this._uH=null;if(this._jN.IsCrosstabVisible()){if(this._mD){this._mD.bSelected=false;this.SetCentralMeasureCellStyle();}this._o2.UnselectAllCells();}if(!_RY){this._jN.HandleUnselect(this,_Lk);}this._ao=false;this._oe=null;this._nX=null;};CUICrosstab.prototype.ReselectAll=function(){if(this._w7){return;}if(this._mD&&this._mD.bSelected){this.GetCellMap().ReselectSelectAllCells();return;}if(this.GetCellMap()){this.GetCellMap().UnselectAllCells();}if(this._ax){this._ax.ReselectAllMembers();}if(this._bz){this._bz.ReselectAllMembers();}};CUICrosstab.SafeDoDrillDown=function(_Ke,_zU){try{var _Mg=FindApp(_Ke);_Mg.uiManager._jf.GetUICrosstab().DrillDown(_zU);}catch(e){_f.HandleException(e);}};CUICrosstab.prototype.DrillDown=function(_ON){_ON.DrillDown();};CUICrosstab.SafeDoDrillUp=function(_Ke,_zU){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.uiManager._jf.GetUICrosstab().DrillUp(_zU);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.prototype.DrillUp=function(_ON){if(!_ON.IsSummaryMem()){var _FK=_ON.GetBlock();if(!_FK.IsChildren()&&!_FK.IsChildrenMeasureBlock()){_ON.DrillUp();}else{var _RJ=this._jN._m4.dataManager.metadata;var _axm=_RJ.GetMemberOrMeasure(_ON.GetMemberId()).GetParent();Debug.Assert(_axm);if(_axm){_ON.GetAxisMember().DrillUp(_axm.GetId());}}}else{_ON.DrillUp();}};CUICrosstab.prototype.HandleMouseOver=function(e){if(!e){var e=window.event;}var _N9=Dom.GetEventTarget(e);if(CUIDragDrop.IsDragging()){this.HandleDragOver(e);return;}else{if(!this._jN.AllowInteraction()){return;}if(_N9.cellType&&_N9.cellType==CUICrosstab.kCentralMeasureCell){this._mD.bHoverOver=true;this.SetCentralMeasureCellStyle();return;}var _abh=this.getMemberCell(_N9);if(_abh){var _zU=_abh.axisMember;if(_zU){_zU.HoverOver(e);}}}};CUICrosstab.SafeHandleMouseOver=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/this.oCrosstab.HandleMouseOver(e);/*@if(!@bering_debug)@*/}catch(excep){_f.HandleException(excep);}/*@end@*/};CUICrosstab.SafeHandleMouseMove=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}this.oCrosstab.HandleMouseMove(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.prototype.HandleMouseMove=function(e){if(!this._jN.AllowInteraction()){return;}var _yW=Dom.GetEventTarget(e);if(!_yW)return;var _abh=this.getMemberCell(_yW);if(_abh){var _zU=_abh.axisMember;if(_zU){_zU.HoverOver(e);}}else if(_yW.bRowSel&&_yW.bColSel&&this.isEventOnDataCellText(e,_yW)){this._o2.HoverOver(_yW,e);}else if(_yW.bHover){this._o2.EndHoverOver(_yW,e);}else if(this._aF){this._o2.ResizeingHoverOver(_yW,e);}if((!_yW.bRowSel||!_yW.bColSel||!this.isEventOnDataCellText(e,_yW))&&!_yW.bHover&&!_abh){CUIManager.HideDrillImage();}};CUICrosstab.prototype.isLeavingActiveDropZone=function(e){var _yW=Dom.GetEventTarget(e);if(CUIDragDrop.IsDragging()){var _aqw=Dom.GetToElement(e);if(!Dom.IsDescendant(this._ro,_aqw)){return true;}}return false;};CUICrosstab.prototype.HandleMouseOut=function(e){if(!e){var e=window.event;}var _N9=Dom.GetEventTarget(e);if(!this._jN.AllowInteraction()){return;}if(this.isLeavingActiveDropZone(e)){this.HideAllDropZones();return;}if(_N9.cellType&&_N9.cellType==CUICrosstab.kCentralMeasureCell){this._mD.bHoverOver=false;this.SetCentralMeasureCellStyle();return;}var _abh=this.getMemberCell(_N9);if(_abh){var _zU=_abh.axisMember;if(_zU){_zU.EndHoverOver();}}};CUICrosstab.SafeHandleMouseOut=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/this.oCrosstab.HandleMouseOut(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.prototype.HasVerticalScrollbar=function(){if(this._ig){var _ali=this._ig.GetScrollCtrlCType();if(_ali==CUIScrollControl.kVertOnly||_ali==CUIScrollControl.kBothVH){return true;}}return false;};CUICrosstab.prototype.GetCrosstabHeight=function(){if(this._jN.IsCrosstabVisible()&&(this._n5!=0)){var _afp=50;return this._n5+CUICrosstab.kiScrollBarWidth+CUICrosstab.kiScrollBarBorderWidth+_afp;}return 0;};CUICrosstab.SafeHandleMouseWheel=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp('main').uiManager._jf._dO.HandleMouseWheel(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.prototype.HandleMouseWheel=function(e){if(!e){var e=window.event;}var _N9=Dom.GetEventTarget(e);if(!this._jN.AllowInteraction()){return;}if(this._ig){var _ali=this._ig.GetScrollCtrlCType();var _aws=null;var _aA5=null;if(_ali==CUIScrollControl.kVertOnly||_ali==CUIScrollControl.kBothVH){_aws=this._ig.m_oVScrollbar;_aA5=ExpEvent.kCUIScrollControl_VScroll;}else if(_ali==CUIScrollControl.kHoriOnly){if(this._jN.HasScrollbar()){return;}_aws=this._ig.m_oHScrollbar;_aA5=ExpEvent.kCUIScrollControl_HScroll;}if(_aws&&_aA5){var _amp=_aws.GetFirstVisibleIndex();if(e.wheelDelta<=-120||e.detail==3){if(_amp>=_aws.m_iTotalUnits-_aws.m_iVisibleUnits){return;}_amp++;_aws.SetFirstVisibleIndex(_amp);}else if(e.wheelDelta>=120||e.detail==-3){if(_amp<=0){return;}_amp--;_aws.SetFirstVisibleIndex(_amp--);}this.Notify(_aA5,true);Dom.CancelEvent(e);}}};CUICrosstab.prototype.Subscribe=function(obj,event){if(this._e6[event]){this._e6[event].push(obj);}};CUICrosstab.prototype.OnWSRefresh=function(){if(!this._w7){this._w7=true;var _6z=Utilities.GenerateCallback(this.Refresh,[],this);setTimeout(_6z,1);}};CUICrosstab.prototype.Notify=function(event,_My){var _alZ=null;var _aiz=null;if(event==ExpEvent.kCUIScrollControl_HScroll){this.OnHScrollTo();}else if(event==ExpEvent.kCUIScrollControl_VScroll){this.OnVScrollTo();}else if(event==ExpEvent.kCUIWorksheet_Unload){this.Unload();}else if(event==ExpEvent.kCUIWorksheet_WindowResize){this.HandleResize();}else if(event==ExpEvent.kCUIDialogMgr_HideModalDialog){Utilities.ExecuteHoldingProcedure();this.HideAllDropZones();this._jN._m4.oDialogMgr.UnSubscribe(this,ExpEvent.kCUIDialogMgr_HideModalDialog);}else if(event==ExpEvent.kCUICrosstab_ColResize){this.OnColumnResize();}else if(_My){_aiz=event;}else if(event==ExpEvent.kCOTPropsLoadingMgr_Merge_Complete){this.UpdatePropertiesFlyoutMenu();this._jN._m4.dataManager.metadata.UnSubscribe(this._ev,ExpEvent.kCDLMetadata_Merge_Properties);this._ev.UnSubscribe(this,ExpEvent.kCOTPropsLoadingMgr_Merge_Complete);}if(_aiz){_alZ=this._e6[_aiz];for(var i=0;i<_alZ.length;i++){_alZ[i].Notify(_aiz);}}};CUICrosstab.prototype.calculateAvailableSizes=function(_BP){var _awm=0;var _9E=0;if(!_BP&&!this._lL){if(this.oScrollVDiv){_awm=CUICrosstab.kiScrollBarWidth+CUICrosstab.kiScrollBarBorderWidth;}if(this.oScrollHDiv){_9E=CUICrosstab.kiScrollBarWidth+CUICrosstab.kiScrollBarBorderWidth;}}this._cI=Math.max(this._nq-_awm,0);this._p3=Math.max(this._tJ-_9E,0);};CUICrosstab.prototype.SetWidth=function(_F4){COTStyle.SetWidth(this._ro,_F4);this._nq=_F4;};CUICrosstab.prototype.HandleResize=function(){if(!this._cf||!this._jN.IsCrosstabVisible()){return;}this.RemoveScrollBar(true);this.RemoveScrollBar(false);COTStyle.SetHeight(this._ro,this._tJ);this.calculateAvailableSizes(false);COTStyle.SetHeight(this._cf,this._p3);COTStyle.SetWidth(this._cf,this._cI);if(this._w7){return;}if(this._aF){this.SetFixedColsWidth(true);this.SetFixedRowsHeight(true);this.GetMoreVXtabData(this._rz);this.GetMoreHXtabData(this._nj,true);}else{if(this._qB){this.setRowTemplateSize();}}this.DrawCrosstab();this.ReselectAll();};CUICrosstab.prototype.GetDIVObj=function(){return this._ro;};CUICrosstab.prototype.DoSubTotal=function(_FK){_FK.ToggleProperty("subtotal");};CUICrosstab.SafeDoSubTotal=function(_Mx,_FK){try{var _Mg=FindApp(_Mx);_Mg.uiManager._jf.SetLastBlockSelectionId(_FK.GetId());_Mg.uiManager._jf.GetUICrosstab().DoSubTotal(_FK);}catch(e){_f.HandleException(e);}};CUICrosstab.SafeDoContinueHierarchize=function(oCrosstab,_FK,_Vh){/*@if(!@bering_debug)@*/try{/*@end@*/oCrosstab.ContinueDoHierarchize(_FK,_Vh);CUIDialogMgr.SafeHideCurrentDialog(oCrosstab.sAppName);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.prototype.DoHierarchize=function(_FK,_Vh){if(_Vh&&_FK.IsExplicitSort()){CUIDialogMgr._U.SetCallBackFuntion(Utilities.ExecuteHoldingProcedure);CUIDialogMgr._U.Display('IDS_VIEW_HIER_SORT_WARNING','',CUIConfirmDlg._hw);var _Ro=new Array(this,_FK,_Vh);Utilities.SetProcedureToHold(CUICrosstab.SafeDoContinueHierarchize,_Ro);return;}else{this.ContinueDoHierarchize(_FK,_Vh);}};CUICrosstab.prototype.ContinueDoHierarchize=function(_FK,_Vh){var _VI=new Array();if(_FK.IsExplicitSort()){_VI.push(_FK.SetProperty(ExpAPIXml.kEleAxisOpExprSortMeasure,null,true));_VI.push(_FK.SetSortMembers(new Array(),true));_VI.push(_FK.SetProperty(ExpAPIXml.kEleAxisOpExprSortProperty,null,true));_VI.push(_FK.SetProperty(ExpAPIXml.kEleAxisOpExprSortLabel,false,true));_VI.push(_FK.SetProperty(ExpAPIXml.kEleAxisOpExprSorttype,ExpAPIXml.kEleAxisOpExprSorttypeDefault,true));}_VI.push(_FK.getSetPropertyAction("hierarchy",_Vh));var _Li=this._jN.GetDataWorkSheet().GetDataManager().GetCurrentDataMatrix();_Li.SendDMActionArray(_VI);};CUICrosstab.SafeDoHierarchize=function(_Mx,_IU,_Vh){try{var _Mg=FindApp(_Mx);_Mg.uiManager._jf.GetUICrosstab().DoHierarchize(_IU,_Vh);}catch(e){_f.HandleException(e);}};CUICrosstab.SafeDoNestDescendants=function(_Ke,_FK){/*@if(!@bering_debug)@*/try{/*@end@*/_FK.Nest();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.SafeDoConvertToV5Block=function(_Ke,_FK){/*@if(!@bering_debug)@*/try{/*@end@*/_FK.MakeV5Block();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.SafeDoIncreaseDepth=function(_Ke,_FK,_FU){/*@if(!@bering_debug)@*/try{/*@end@*/_FK.DescendAscendDepth(_FU);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.SafeDoDecreaseDepth=function(_Ke,_FK,_FU){/*@if(!@bering_debug)@*/try{/*@end@*/_FK.DescendAscendDepth(_FU);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.prototype.DoSetBlockSize=function(_FK,_UN){if(String(_UN)!=_FK.GetBlockSize()){_FK.SetProperty(ExpAPIXml.kEleAxisOpExprBlockSize,String(_UN));}};CUICrosstab.SafeDoSetBlockSize=function(_Mx,_FK,_UN){try{var _Mg=FindApp(_Mx);_Mg.uiManager._jf.GetUICrosstab().DoSetBlockSize(_FK,_UN);}catch(e){_f.HandleException(e);}};CUICrosstab.prototype.DoSortInnerBlocks=function(_O0,_C9,_Fk){_O0.SortInnerBlocks(_C9,_Fk);};CUICrosstab.SafeSortMembers=function(_Mx,_O0,_C9,_UN){try{var _Mg=FindApp(_Mx);_Mg.uiManager._jf.GetUICrosstab().DoSortInnerBlocks(_O0,_C9,_UN);}catch(e){_f.HandleException(e);}};CUICrosstab.prototype.DoSetSortType=function(_FK,_UN){_FK.SetProperty(ExpAPIXml.kEleAxisOpExprSorttype,_UN);};CUICrosstab.SafeDoSetSortType=function(_Mx,_FK,_UN){try{var _Mg=FindApp(_Mx);_Mg.uiManager._jf.GetUICrosstab().DoSetSortType(_FK,_UN);}catch(e){_f.HandleException(e);}};CUICrosstab.SafeDoCustomizeSize=function(_Mx,_FK){try{var _Mg=FindApp(_Mx);var _Ok=_Mg.uiManager._jf.GetUICrosstab();_Mg.uiManager.oDialogMgr.HideCurrentModalessDialog(true);if(_FK!=_Ok._n2){var _Bm=false;_Ok.SecondarySelectBlock(_FK,_Bm);_Ok._jN.HandleBlockSelection(_Ok,_FK);}if(!_Mg.uiManager.oBlockPropsPane.bExpanded){_Mg.uiManager.oBlockPropsPane.ToggleDisplay();}_Mg.uiManager.oBlockPropsPane.GetCurrentPropSet().PreSelectProp(CUIVisibleItemProperty,CUIVisibleItemProperty.kCustomize);}catch(e){_f.HandleException(e);}};CUICrosstab.SafeDoToggleBlockPropPane=function(_Mx){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Mx);_Mg.uiManager.oBlockPropsPane.ToggleDisplay();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.SafeDoShowBlockPropPane=function(_Mx,_L7){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Mx);_Mg.uiManager._jf.ApplyBlockSelection(_L7);_Mg.uiManager.oBlockPropsPane.ShowPane();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.prototype.CanHide=function(){if(this._ax.GetLastSelection()){if(this._ax.CanHideSelectedMembers()){return true;}}if(this._bz.GetLastSelection()){if(this._bz.CanHideSelectedMembers()){return true;}}return false;};CUICrosstab.prototype.CanExclude=function(){if(this._ax.GetLastSelection()){if(this._ax.CanExcludeSelectedMembers()){return true;}}if(this._bz.GetLastSelection()){if(this._bz.CanExcludeSelectedMembers()){return true;}}return false;};CUICrosstab.prototype.DoDelete=function(){var _DF=new Array();for(var _BZ=0;_BZ<2;_BZ++){var _O0=_BZ==0?this._ax:this._bz;var _aF2=_O0.GetSelectedMembers();for(var i in _aF2){var _J3=_aF2[i].GetAxisMember().GetDeleteAction();if(_J3){_DF.push(_aF2[i].GetAxisMember().GetDeleteAction());}}}if(_DF.length>0){var _Li=this._jN.GetDataWorkSheet().GetDataManager().GetCurrentDataMatrix();_Li.SendDMActionArray(_DF);}};CUICrosstab.prototype.DoHide=function(){var _DF=new Array();for(var _BZ=0;_BZ<2;_BZ++){var _O0=_BZ==0?this._ax:this._bz;var _aF2=_O0.GetSelectedMembers();for(var i in _aF2){var _J3=_aF2[i].GetAxisMember().GetHideAction();if(_J3){_DF.push(_aF2[i].GetAxisMember().GetHideAction());}}}if(_DF.length>0){var _Li=this._jN.GetDataWorkSheet().GetDataManager().GetCurrentDataMatrix();_Li.SendDMActionArray(_DF);}};CUICrosstab.SafeDoHide=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.uiManager._jf.GetUICrosstab().DoHide();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.SafeDoDelete=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.uiManager._jf.GetUICrosstab().DoDelete();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.prototype.DoUnhideMember=function(_FK,_HY){var _aHZ=new Array(_HY);_FK.AppendMembers(_aHZ);};CUICrosstab.SafeDoUnhideMember=function(_Mx,_FK,_HY){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Mx);_Mg.uiManager._jf.GetUICrosstab().DoUnhideMember(_FK,_HY);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.SafeDoUnhideAll=function(_Mx,_FK){/*@if(!@bering_debug)@*/try{/*@end@*/_FK.AppendMembers(_FK.GetHiddenMemberIds());/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.SafeDoIncludeAll=function(_Mx,_FK){/*@if(!@bering_debug)@*/try{/*@end@*/_FK.AppendMembers(_FK.GetExcludedMemberIds());/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.SafeDoIncludeMember=function(_Mx,_FK,_HY){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Mx);_Mg.uiManager._jf.GetUICrosstab().DoIncludeMember(_FK,_HY);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.prototype.DoIncludeMember=function(_FK,_HY){var _aHZ=new Array(_HY);_FK.AppendMembers(_aHZ);};CUICrosstab.prototype.DoExclude=function(){var _7Z=new Array();for(var _BZ=0;_BZ<2;_BZ++){var _O0=(_BZ==0)?this._ax:this._bz;var _aF2=_O0.GetSelectedMembers();for(var i in _aF2){var _1K=_aF2[i].GetAxisMember().GetExcludeAction();if(_1K){_7Z.push(_1K);}}}if(_7Z.length>0){var _Li=this._jN.GetDataWorkSheet().GetDataManager().GetCurrentDataMatrix();_Li.SendDMActionArray(_7Z);}};CUICrosstab.SafeDoExclude=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.uiManager._jf.GetUICrosstab().DoExclude();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.prototype.DoRepBLKWithHAMCSet=function(_FK,_Lv){if(_FK.IsGroupedDescendantsAtDepth()){_FK=_FK.GetRootParentBlock();}_FK.DoReplace(_Lv.sId,_Lv.kPopulation,_Lv.aDeleteActions,_Lv.aOtherMemIds,_Lv.sBlockId,_Lv.sLevId,_Lv.sFilterId);};CUICrosstab.prototype.DoSetSortMembers=function(_FK,_C9){_FK.SetSortMembers(_C9);};CUICrosstab.SafeDoSetSortMembers=function(_Ke,_FK,_C9){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.uiManager._jf.GetUICrosstab().DoSetSortMembers(_FK,_C9);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.SafeDoUserDefFLT=function(_Ke){try{CUIWorkSheet.SafeOpenFilterDlg(_Ke);}catch(e){_f.HandleException(e);}};CUICrosstab.SafeDoSetSummaryProp=function(_Ke,_FK){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.uiManager._jf.SetLastBlockSelectionId(_FK.GetId());_FK.ToggleProperty("summary");/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.SafeDoSetRemainderProp=function(_Ke,_FK){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.uiManager._jf.SetLastBlockSelectionId(_FK.GetId());_FK.ToggleProperty("remainder");/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.SafeDoSetVisibleProp=function(_Ke,_FK){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.uiManager._jf.SetLastBlockSelectionId(_FK.GetId());_FK.ToggleProperty("visible");/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.SafeDoSetFilterAggr=function(_Ke,_FK){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.uiManager._jf.SetLastBlockSelectionId(_FK.GetId());_FK.ToggleProperty("filteraggregate");/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.SafeDoSetPassFilterAggr=function(_Ke,_FK){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.uiManager._jf.SetLastBlockSelectionId(_FK.GetId());_FK.ToggleProperty("passedfilteraggregate");/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.prototype.DoAddCustomSet=function(){var _FK=this._jN.GetSelectedBlock();if(_FK){this.DoAddCustomSetFromSelectedBlock(_FK);}else{var _Yj=this._jN.GetUIAxesContainer().GetSelectedAxis();if(_Yj&&_Yj.CanHamcizeSelectedMembers()){var _C9=new Array();for(id in _Yj._hb){var _aiQ=_Yj._hb[id];if(_aiQ){_C9.push(_aiQ.GetMemberId());}}this.DoAddCustomSetFromSelectedMembers(_C9);}else{if(!this.oSaveCustomSetDlg){this.oSaveCustomSetDlg=new CUISaveCustomSetDlg();this.oSaveCustomSetDlg.Init(this._jN._m4.oDialogMgr);this.oSaveCustomSetDlg.Create();}var _M3=true;this.oSaveCustomSetDlg.Display(_M3);}}};CUICrosstab.prototype.DoAddCustomSetFromSelectedBlock=function(_FK){if(!this.oSaveCustomSetDlg){this.oSaveCustomSetDlg=new CUISaveCustomSetDlg();this.oSaveCustomSetDlg.Init(this._jN._m4.oDialogMgr);this.oSaveCustomSetDlg.Create();}if(!_FK){var _FK=this._jN.GetSelectedBlock();}if(!_FK||(!_FK.CanSaveAsCustomSet())){var _M3=true;this.oSaveCustomSetDlg.Display(_M3);}else{this.oSaveCustomSetDlg.SetHostObj(_FK);this.oSaveCustomSetDlg.SetSelectedMembers(null);this.oSaveCustomSetDlg.Display();}};CUICrosstab.SafeDoDescriptiveStatistics=function(_Ke,_zt){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.uiManager._jf.GetDataWorkSheet().DoDescriptiveStatistics();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.SafeDoAddCustomSetFromSelectedBlock=function(_Mx,_FK){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Mx);_Mg.uiManager._jf.GetUICrosstab().DoAddCustomSetFromSelectedBlock(_FK);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.prototype.DoAddCustomSetFromSelectedMembers=function(_zt){if(!this.oSaveCustomSetDlg){this.oSaveCustomSetDlg=new CUISaveCustomSetDlg();this.oSaveCustomSetDlg.Init(this._jN._m4.oDialogMgr);this.oSaveCustomSetDlg.Create();}this.oSaveCustomSetDlg.SetHostObj(null);this.oSaveCustomSetDlg.SetSelectedMembers(_zt);this.oSaveCustomSetDlg.Display();};CUICrosstab.SafeDoAddCustomSetFromSelectedMembers=function(_Mx,_zt){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Mx);_Mg.uiManager._jf.GetUICrosstab().DoAddCustomSetFromSelectedMembers(_zt);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.prototype.DoUserDefCalculation=function(_Bg,_FK,_VC){var _J9=_Bg._s4;var _Ct=_Bg._fL;var _Ic=_Bg.GetLabel();_VC._ni=new CDLMathMLExprNode(_J9,true,true);_VC._ni=_VC.GenerateMathMLExpr(_J9,_Ct,_VC._ni);_FK.CreateMathMLCalcExpr(_Ic,_VC._ni,_Ic);};CUICrosstab.SafeDoUserDefCalculation=function(_Ke,_Bg,_FK,_VC){try{var _Mg=FindApp(_Ke);_Mg.uiManager._jf.GetUICrosstab().DoUserDefCalculation(_Bg,_FK,_VC);}catch(e){_f.HandleException(e);}};CUICrosstab.SafeDoDeleteBlock=function(_Ke,_FK){/*@if(!@bering_debug)@*/try{/*@end@*/_FK.oAxis.DoDeleteMultipleBlocks(new Array(_FK));/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.SafeDoCustomizeCalc=function(_Ke,_VC){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.uiManager._jf.GetUICrosstab().DoCustomizeCalc(_VC);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.prototype.SafeInsertDescriptiveStats=function(_OA,_KW,_V7,_FK,_M3){var _Vc=this._jN._my._ak._i4.GetCommandByIndex(_KW['index']);if(!this._jN._my._ak.descriptiveStatsInserted){this.statsDlg=new CUIDescriptiveStatsDlg(this._jN._m4,_Vc,_OA,_KW,_V7,_FK,_M3);this.statsDlg.Init(this._jN._m4.oDialogMgr);this.statsDlg.Display();}else{var _Ke=this.sAppName;var _aAS=Utilities.GenerateCallback(CUIWorkSheet.SafeRemoveDescriptiveStatsRequest,[_Ke,_OA,_KW]);var _anu=Utilities.GenerateCallback(CUIDialogMgr.SafeHideCurrentDialog,[_Ke]);var _aAo=Utilities.GenerateCallback(CUIDialogMgr.SafeHideCurrentDialog,[_Ke]);CUIDialogMgr._q5.SetCallBackFuntion(_aAS,_aAo);CUIDialogMgr._q5.Display("You have already added a different Stats object. If you continue, you will lose the previous ...",'',CUIConfirmDlg._hw);}};CUICrosstab.prototype.SafeShowDescriptiveStatsError=function(_OY){var _aEm=new CUIDescriptiveStatsDlg(this._jN._m4);_aEm.Init(this._jN._m4.oDialogMgr);_aEm.Display(true);};CUICrosstab.prototype.DoCustomizeCalc=function(_VC){var _GP=false;if(!this.oCalcDlg){this.oCalcDlg=new CUICalculationDlg();this.oCalcDlg.Init(this._jN._m4.oDialogMgr);this.oCalcDlg.InitOPTypeArr();_GP=true;this.oCalcDlg.SubscribeWSEvent();}if(_VC){this.oCalcDlg.SetUserSelection(_VC,_GP);this.oCalcDlg.SetStartEditing(false);this.oCalcDlg.Create();this.oCalcDlg.Display();if(_VC.GetUnit()==ExpUserSelection.MemberUnit){this.oCalcDlg.SetPreSelections();}else{this.oCalcDlg.SyncExpression(true);}}else{this.oCalcDlg.ClearDlg();var _M3=true;this.oCalcDlg.Display(_M3);}};CUICrosstab.SafeDoEditCalc=function(_Ke,_VC){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.uiManager._jf.GetUICrosstab().DoEditCalc(_VC);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.prototype.DoEditCalc=function(_VC){var _GP=false;if(!this.oCalcDlg){this.oCalcDlg=new CUICalculationDlg();this.oCalcDlg.Init(this._jN._m4.oDialogMgr);this.oCalcDlg.InitOPTypeArr();_GP=true;this.oCalcDlg.SubscribeWSEvent();}if(_VC){this.oCalcDlg.SetUserSelection(_VC,_GP);this.oCalcDlg.SetStartEditing(true);this.oCalcDlg.EditCalculation(_VC._us[0].GetMemberId());this.oCalcDlg.RenderCalcDlg();this.oCalcDlg.Display();}else{Debug.Assert(false);}};CUICrosstab.prototype.CheckActualHVisibleUnits=function(_LZ){var _amq=this._m1+_LZ;if(this._nf[_amq]&&this._nf[_amq][this._m8-1]){var _0j=this._nf[_amq][this._m8-1].axisMember;var _apT=false;Debug.Assert(_0j);if(this._t6[_amq]<this._sm[_amq]){var _alz=this._sm[_amq]-this._t6[_amq];while(_0j.Next()!=null){_0j=_0j.Next();var _arj=_0j.GetMemberPos()+this._m1;_alz-=this._t6[_arj];if(_alz<0){break;}}if(_alz>0){for(var i=this._t6.length-1;(i>0&&_alz>0);i--){_alz-=this._t6[i];this._yc-=1;this._yc=Math.max(this._yc,1);_apT=true;}}}if(!_apT){var _ajv=this._nf.length-1;var _aj8=this._nf[_ajv][this._m8-1].axisMember.GetHtmlElement();var _8m=COTStyle.GetDisplayOffsetWidth(_aj8);var _ajz=Dom.GetRelativeOffset(_aj8,this._vO);var _aAQ=_8m+_ajz.iLeft;if(_aAQ>=this._cI-CUICrosstab.kiScrollBarWidth){this._yc--;this._yc=Math.max(this._yc,1);}}}};CUICrosstab.prototype.CheckActualVVisibleUnits=function(_HS){var _amq=this._m8+_HS;if(this._nf[this._m1-1]&&this._nf[this._m1-1][_amq]){var _ajv=this._nf[0].length-1;var _aj8=this._nf[this._m1-1][_ajv].axisMember.GetHtmlElement();var _05=COTStyle.GetDisplayOffsetHeight(_aj8);var _ajz=Dom.GetRelativeOffset(_aj8,this._vO);var _7O=_05+_ajz.iTop;if(_7O>=this._p3-CUICrosstab.kiScrollBarWidth){this._r7--;this._r7=Math.max(this._r7,1);}}};CUICrosstab.prototype.GetSelectedAxis=function(){var _8i=-1;var _Q1=null;if(this.GetUIAxis(CUIDataMatrix.iRowIndex).HasSelection()){_8i=CUIDataMatrix.iRowIndex;_Q1=this.GetUIAxis(CUIDataMatrix.iRowIndex);}else if(this.GetUIAxis(CUIDataMatrix.iColIndex).HasSelection()){_8i=CUIDataMatrix.iColIndex;_Q1=this.GetUIAxis(CUIDataMatrix.iColIndex);}return _Q1;};CUICrosstab.prototype.AddDrillThroughContextMembers=function(_zT,_Tz,_Bh){var _RJ=this._jN._m4.dataManager.metadata;var _FU=_Tz.GetDepth();var _ayD=_Tz.GetMemberPos();for(var i=_FU;i>=0;i--){var _ate=_zT.GetMember(_ayD,i);var _alu=_ate.GetAxisMember();if(_alu&&_alu.CanBeUseAsDrillThroughContext()){var _azm=_RJ.GetMember(_alu.GetMemberId());if(_azm){_Bh.push(_azm);}}}};CUICrosstab.prototype.AddDrillThroughContextMembersNew=function(_BZ,_Tz,_Nu){var _zT=_BZ==0?this._ax:this._bz;var _RJ=this._jN._m4.dataManager.metadata;var _FU=_Tz.GetDepth();var _ayD=_Tz.GetMemberPos();var _aEh="memberUniqueName";var _akv=null;for(var i=_FU;i>=0;i--){var _ate=_zT.GetMember(_ayD,i);var _alu=_ate.GetAxisMember();if(_alu&&_alu.CanBeUseAsDrillThroughContext()){var _2u=_alu.GetMemberId();var _DV=_alu.GetMemberType()===ExpAxisObjType.Measure;var _azm=_DV?_RJ.GetMeasure(_2u):_RJ.GetMember(_2u);if(_azm){var _aiD=_DV?CANSSelectionContext.kMeasureUsage:CANSSelectionContext.kNonMeasureUsage;var _ax3=_azm.GetLabel();var _GG;if(_DV){_GG=_azm.GetDim();}else{_GG=_azm.GetLevel();if(!_GG){_GG=_azm.GetHierarchy();}}var _aGO=_GG.GetLabel();var _am2=_GG.GetId();if(i==_FU){_akv=_Nu.addSelectedCell(_aGO,Utilities.Descheme(_am2),Utilities.Descheme(_2u),_aEh,_ax3,_aiD);}else{_akv=_akv.addDefiningCell(_aGO,Utilities.Descheme(_am2),Utilities.Descheme(_2u),_aEh,_ax3,_aiD);}_akv.addProperty('ordinal',_BZ);}}}};CUICrosstab.prototype.SetSelectionContext=function(_Nu){var _aEh="memberUniqueName";var _aGO,metadataModelItem,_2u,_ax3,_aiD;var _RJ=this._jN._m4.dataManager.metadata;if(this._nX){_Nu._ep=true;var _Li=this._jN.GetDataWorkSheet().GetDataManager().GetCurrentDataMatrix();var _aG1=this._o2.GetCentralMeasurePresentationType();metadataModelItem=_Li.GetCurrentMeasureId();var _aoB=null;_2u=this._nX.innerHTML;if(metadataModelItem&&_aG1==ExpAPIXml.kDefMeaActivePretType){_aGO=_Li.GetCurrentMeasureLabel();_aoB=_Nu.addSelectedCell(_aGO,Utilities.Descheme(metadataModelItem),_2u,"Decimal",_2u,CANSSelectionContext.kMeasureUsage);}else{_aoB=_Nu.addSelectedCell(null,null,_2u,"Decimal",_2u,CANSSelectionContext.kMeasureUsage);}if(this._nX.y>=0){var _1b=_aoB;var _ahC=null;for(var i=this._ax.GetDepth()-1;i>=0;i--){var _alr=this._ax.GetMember(this._nX.y,i);var _aqN=_alr?_alr.GetAxisMember():null;if(_aqN&&_aqN.CanBeUseAsDrillThroughContext()){_2u=_aqN.GetMemberId();if(_aqN.GetMemberType()===ExpAxisObjType.Measure){var _NS=_RJ.GetMeasure(_2u);_aoB.setDataItemName(_NS?_NS.GetLabel():'');_aoB.setMetadataModelItem(_2u);}else{var _aiQ=_RJ.GetMember(_2u);if(_aiQ){_ax3=_aiQ.GetLabel();var _7J=_aiQ.GetLevel();if(!_7J){_7J=_aiQ.GetHierarchy();}_aGO=_7J.GetLabel();metadataModelItem=_7J.GetId();_ahC=_1b.addDefiningCell(_aGO,Utilities.Descheme(metadataModelItem),Utilities.Descheme(_2u),_aEh,_ax3,CANSSelectionContext.kNonMeasureUsage);_1b.addProperty('ordinal',0);_1b=_ahC;}}}}}if(this._nX.x>=0){var _1b=_aoB;var _ahC=null;for(var i=this._bz.GetDepth()-1;i>=0;i--){var _asv=this._bz.GetMember(this._nX.x,i);var _aqN=_asv?_asv.GetAxisMember():null;if(_aqN&&_aqN.CanBeUseAsDrillThroughContext()){_2u=_aqN.GetMemberId();if(_aqN.GetMemberType()===ExpAxisObjType.Measure){var _NS=_RJ.GetMeasure(_2u);_aoB.setDataItemName(_NS?_NS.GetLabel():'');_aoB.setMetadataModelItem(_2u);}else{var _aiQ=_RJ.GetMember(_2u);if(_aiQ){_ax3=_aiQ.GetLabel();var _7J=_aiQ.GetLevel();if(!_7J){_7J=_aiQ.GetHierarchy();}_aGO=_7J.GetLabel();metadataModelItem=_7J.GetId();_1b.addProperty('ordinal',1);_ahC=_1b.addDefiningCell(_aGO,Utilities.Descheme(metadataModelItem),Utilities.Descheme(_2u),_aEh,_ax3,CANSSelectionContext.kNonMeasureUsage);_1b=_ahC;}}}}}}else{for(var _BZ=0;_BZ<2;_BZ++){var _O0=_BZ==0?this._ax:this._bz;var _aF2=_O0.GetSelectedMembers();for(var i in _aF2){this.AddDrillThroughContextMembersNew(_BZ,_aF2[i],_Nu);}}}};CUICrosstab.prototype.GetDrillThroughContext=function(_Ow){var _RJ=this._jN._m4.dataManager.metadata;var _Y6=_RJ.IsFunctionSupported(ExpAPIXml.kQosMultiHierOfSameDim);if(this._nX){var _aH2=true;var _aCh=new Array();var _aGt=this.GetDLCrosstab()._i0;if(this._nX.y>=0){var _awg=null;var _az3=null;for(var i=this._ax.GetDepth()-1;i>=0;i--){var _alr=this._ax.GetMember(this._nX.y,i);var _aqN=_alr?_alr.GetAxisMember():null;if(_aqN&&_aqN.CanBeUseAsDrillThroughContext()){var _BX=_aqN.GetMemberId();var _alM=_RJ.GetMember(_BX);if(_alM){if(_Y6){_az3=_alM.GetHierId();}else{_az3=_alM.GetDimId();}if(!_awg||_awg!=_az3){_aCh.push(_alM);}_awg=_az3;}}else{_aH2=false;}}}if(this._nX.x>=0){var _axZ=null;var _av7=null;for(var i=this._bz.GetDepth()-1;i>=0;i--){var _asv=this._bz.GetMember(this._nX.x,i);var _aqN=_asv?_asv.GetAxisMember():null;if(_aqN&&_aqN.CanBeUseAsDrillThroughContext()){var _BX=_aqN.GetMemberId();var _alM=_RJ.GetMember(_BX);if(_alM){if(_Y6){_av7=_alM.GetHierId();}else{_av7=_alM.GetDimId();}if(!_axZ||_axZ!=_av7){_aCh.push(_alM);}_axZ=_av7;}}else{_aH2=false;}}}if((!_aGt)||(_aH2)){for(var _PQ=0;_PQ<_aCh.length;_PQ++){_Ow.push(_aCh[_PQ]);}}}else{for(var _BZ=0;_BZ<2;_BZ++){var _O0=_BZ==0?this._ax:this._bz;var _aF2=_O0.GetSelectedMembers();for(var i in _aF2){this.AddDrillThroughContextMembers(_O0,_aF2[i],_Ow);}}}};CUICrosstab.prototype.GetImmediateSelectedContext=function(_Ow){var _RJ=this._jN._m4.dataManager.metadata;if(this._nX){if(this._nX.y>=0){var _alr=this._ax.GetMember(this._nX.y,this._ax.GetDepth()-1);if(_alr){var _alM=_RJ.GetMemberOrMeasure(_alr.GetAxisMember().GetMemberId());if(_alM){_Ow.push(_alM);}}}if(this._nX.x>=0){var _asv=this._bz.GetMember(this._nX.x,this._bz.GetDepth()-1);if(_asv){var _alM=_RJ.GetMemberOrMeasure(_asv.GetAxisMember().GetMemberId());if(_alM){_Ow.push(_alM);}}}}else{for(var _BZ=0;_BZ<2;_BZ++){var _O0=_BZ==0?this._ax:this._bz;for(id in _O0._hb){var _aiQ=_O0._hb[id];if(_aiQ){var _akE=_RJ.GetMemberOrMeasure(_aiQ.GetMemberId());if(_akE){_Ow.push(_akE);}}}}}};CUICrosstab.prototype.SetDLCrosstab=function(_Ok){this._fX=_Ok;};CUICrosstab.prototype.GetDLCrosstab=function(){return this._fX;};CUICrosstab.prototype.HandleGoToContextMenu=function(_PM,_IW){_PM.SetEnabled(true);var _56=_PM._o6;var _zA=null;var _Co=this._sp;var _AT=this._jN._m4.dataManager;for(var x=0;x<_56.items.length;x++){var _apL=_56.items[x];switch(_apL.id){case 'OTH_CROSSTAB_DRILL_THROUGH_RELATED_CONTENT':_zA=new Array(this.sAppName,"false");_apL.SetParameterArr(_zA);_apL.SetItemAction(CUICrosstab.SafeDoDrillThrough);break;case 'OTH_CROSSTAB_DRILL_THROUGH_SEARCH':if(_AT.HasCapability(CDLCapability.K_sCanIndexSearch)){_zA=new Array(this.sAppName);_apL.SetParameterArr(_zA);_apL.SetItemAction(CUICrosstab.SafeDoDrillThroughSearch);}else{_apL.SetEnabled(false);}break;case 'Analyze':var _5s=false;for(var _2g=0;_2g<_IW.length;_2g++){if(_AT._kX.GetCalculation(_IW[_2g])){_5s=true;_apL.SetEnabled(false);break;}}if(_5s){break;}_apL.SetEnabled(true);var _Ke=this.sAppName;_zA=new Array(_Ke,_IW);_apL.SetParameterArr(_zA);_apL.SetItemAction(CUICrosstab.SafeDoDrillToAnalysis);var _agm=new Array(_Ke);_apL.DeferItemAction(CUIWorkSheet.SafeGetHLS,_agm);break;}}};CUICrosstab.SafeDoAddCalcToContext=function(_Ke,_FK,_Fo){/*@if(!@bering_debug)@*/try{/*@end@*/var _as2=FindApp(_Ke).dataManager.GetCurrentWSFilterSet();_as2.InsertCalcFilter(_FK,_Fo);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.SafeDoExpandMember=function(_Ke,_FK,_C9){/*@if(!@bering_debug)@*/try{/*@end@*/_FK.DoSingleMemberExpand(_C9);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.SafeDoCollapseExpandedSet=function(_Ke,_FK,_C9){/*@if(!@bering_debug)@*/try{/*@end@*/_FK.DoSingleMemberCollapse(_C9);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.SafeDoEnableIndentedView=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.uiManager._jf.GetUICrosstab().EnableIndentedView();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.prototype.EnableIndentedView=function(){this._fX.EnableIndentedView();};CUICrosstab.SafeDoEnableNestedView=function(_Ke,_FK,_C9){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.uiManager._jf.GetUICrosstab().EnableNestedView();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.prototype.EnableNestedView=function(){this._fX.EnableNestedView();};CUICrosstab.SafeDoToggleExpandedState=function(_Ke,_FK,_Gc){/*@if(!@bering_debug)@*/try{/*@end@*/_FK.SetProperty(ExpAPIXml.kAttrExpanded,_Gc);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.SafeDoKeepSelectedMembers=function(_Ke,_FK,_C9){/*@if(!@bering_debug)@*/try{/*@end@*/_FK.DoKeepSelectedMembers(_C9);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.prototype.SetCurrentResizeTrigger=function(_Vl){this._ck=_Vl;};CUICrosstab.prototype.GetTupleOnColEdge=function(_Tz){var _asg=new Array();var _FU=_Tz.GetDepth();var oMem,_Hx;for(var i=0;i<=_FU;i++){oMem=this._bz.GetMember(_Tz.GetMemberPos(),i);_Hx=ExpAxisObjType.Member;if(oMem.IsCalc()){_Hx=ExpAxisObjType.Calc;}else if(oMem.GetBlock().IsMeasureBlock()||oMem.GetBlock().IsChildrenMeasureBlock()){_Hx=ExpAxisObjType.Measure;}_asg.push(new CUIEdgeTupleMember(oMem.GetMemberId(),_Hx));}return _asg;};CUICrosstab.prototype.OnColumnResize=function(_LL){var oMem=this._ck.axisMember;if(oMem){var _Qw;if(oMem.GetAxis().IsRowAxis()){_Qw=oMem.GetDepth();this._sJ=this._sJ-this._ck._lU;}else{_Qw=oMem.GetMemberPos()+this._m1;}this._t6[_Qw]=this._ck._lU+this._t6[_Qw];if(!oMem.GetAxis().IsRowAxis()){var _au7=this._t6[_Qw];var _F4=_LL?this.GetColumnAutoFitWidth(_Qw):_au7;var _1v=this.TestCellLabelWidth(CUICrosstab.kSharpSign);this._t6[_Qw]=Math.max(_F4,_1v);Utilities.ClearObjectArray(this._wk);this.UpdateLabelInRelatedColumn(_Qw,_LL);var _aIL=oMem;if(oMem.GetDepth()<(this._m8-1)){_aIL=this._bz.GetMember(_Qw-this._m1,this._m8-1);}var _Sp=this.GetTupleOnColEdge(_aIL);this._x2.CreateColRecord(_Sp,this._t6[_Qw]);}else{if(this._t6[_Qw]<CUICrosstab.kRowAxisColMinWidth){this._t6[_Qw]=CUICrosstab.kRowAxisColMinWidth;}this._x2.CreateRowHeaderRecord(oMem.GetBlock().GetId(),this._t6[_Qw]);}this.GetMoreHXtabData(this._nj);}this.DrawCrosstab();this.ReselectAll();};CUICrosstab.prototype.UpdateLabelInRelatedColumn=function(_Qw,_LL){var _8S=this._m8;var _atv=this._og;var _aC6=this._bz;for(var y=0;y<_8S;y++){var oMem=_aC6.GetMember(_Qw-this._m1,y);var _anF=0;var _ON=oMem;var _Vl=this._nf[_Qw][y];if(oMem.IsSiblingProxy()){_ON=oMem.GetUIAxisMember();_Vl=oMem.GetHtmlElement();var _aIa=_ON.GetMemberPos()+this._m1;for(var i=0;i<_Vl.colSpan;i++){_anF+=this._t6[_aIa+i];}}else{_anF=this._t6[_Qw]>CUICrosstab.kiFixedMinColWidth?this._t6[_Qw]:CUICrosstab.kiFixedMinColWidth;}if(this._aF&&Utilities.bCharBasedTruncation){var _WA=_ON.GetLabel();var _8z=Math.round(this._a9*(_anF/CUICrosstab.kiFixedColWidth));if(_WA.length>_8z){_WA=Utilities.GetTruncatedString(_WA,(_8z-2),this._sp);}var _axO=Dom.GetElementsByTagName(_Vl,"A");if(_axO[0]){Dom.ReplaceTextNode(_axO[0],_WA);_axO[0].className='MemberCellLabel';}}var _F4=_anF-this._nz-this._e7;COTStyle.SetWidth(_Vl,_F4,'px');var _aaV=Dom.GetElementsByTagName(_Vl,'DIV');for(var i=0;i<_aaV.length;i++){COTStyle.SetWidth(_aaV[i],_F4,'px');}}if(!this.HasDataCellTemplate()){for(var y=0;y<_atv;y++){var _Pg=this._o2.GetCell(_Qw-this._m1,y,this._ml);var _F4=this._t6[_Qw];this.ResetCellLabel(_Pg,_F4,_LL);if(_Pg&&_Pg.value){if(this._aF&&Utilities.bCharBasedTruncation){var _ap2=Math.round(this._ml*(this._t6[_Qw]/CUICrosstab.kiFixedColWidth));var _WA=_Pg.value;if(_WA.length>_ap2){_WA=Utilities.GetTruncatedString(_WA,(_ap2-3),this._sp);}Dom.ReplaceText(_Pg,_WA);}}if(_Pg){var _F4=this._t6[_Qw]-this._nz-this._e7;COTStyle.SetWidth(_Pg,_F4,'px');}}}this._ck=null;};CUICrosstab.prototype.TestCellLabelWidth=function(_BM,_Vl){this._wq(this._uV,_BM);if(_Vl){this._uV.className=_Vl.className;}else{this._uV.className="DataCell";}return this.GetCellWidth(this._uV);};CUICrosstab.prototype.ResetCellLabel=function(_Pg,_F4,_LL){var _Xn=_Pg.title;if(_LL){Dom.ReplaceText(_Pg,_Xn);return;}var _WA=CUICrosstab.kSharpSign;var _adf=this.TestCellLabelWidth(_Xn,_Pg);var _0w=_Pg.className;if(_adf>_F4){var _arl=this._wk[_0w];if(!_arl){var _KB,_SF;_KB=this.GetReplaceInitialWidth(_0w);if(_KB==-1){_KB=this.TestCellLabelWidth(CUICrosstab.kSharpSign,_Pg);_SF=this.TestCellLabelWidth(CUICrosstab.kSharpSign+CUICrosstab.kSharpSign,_Pg)-_KB;this.AddIntoBaseReplacementMap(_0w,_KB,_SF);}else{_SF=this.GetReplaceCharWidth(_0w);}for(var i=0;i<(_F4-_KB)/_SF;i++){_WA+=CUICrosstab.kSharpSign;}this._wk[_0w]=_WA;}else{_WA=_arl;}Dom.ReplaceText(_Pg,_WA);}else{Dom.ReplaceText(_Pg,_Xn);}};CUICrosstab.prototype.GetColumnAutoFitWidth=function(_Qw){var _8S=this._m8;var _atv=this._og;var _aqt=0;for(var y=0;y<_atv;y++){var _Pg=this._o2.GetCell(_Qw-this._m1,y,this._ml);var _Xn=_Pg.title;var _adf=this.TestCellLabelWidth(_Xn,_Pg);if(_adf>_aqt){_aqt=_adf;}}return _aqt;};CUICrosstab.prototype.GetReplaceInitialWidth=function(_O8){var _3u=this._nS[_O8];var _aBl=_3u?_3u._oQ:-1;return _aBl;};CUICrosstab.prototype.GetReplaceCharWidth=function(_O8){var _3u=this._nS[_O8];var _aBl=_3u?_3u._dH:-1;return _aBl;};CUICrosstab.prototype.AddIntoBaseReplacementMap=function(_O8,_KB,_SF){_3u=new CUIDataCellBaseReplacement(_KB,_SF);this._nS[_O8]=_3u;};CUICrosstab.SafeDoSuppression=function(_Ke,_O0,_S6){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager._jf.GetUICrosstab().Suppress(_O0,_S6);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.SafeRemoveSuppressionTuples=function(_Ke,_O0,_UH){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager._jf.GetUICrosstab().RemoveSuppressionTuples(_O0,_UH);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUICrosstab.prototype.Suppress=function(_O0,_S6){_O0.SuppressTuples(_S6._cb);};CUICrosstab.prototype.RemoveSuppressionTuples=function(_O0,_UH){_O0.RemoveSuppressionTuples(_UH);};CUICrosstab.prototype.StartSegmentWizard=function(_FK){if(!this.oQuadSegWizardDlg){this.oQuadSegWizardDlg=new CUIQuadrantSegmentingDlg();this.oQuadSegWizardDlg.Init(this._jN._m4.oDialogMgr);}this.oQuadSegWizardDlg.SetHostBlock(_FK);this.oQuadSegWizardDlg.Display();};CUICrosstab.prototype.OpenSegCaptionEditDlg=function(_FK,_Q8){if(!this.oSegEditingDlg){this.oSegEditingDlg=new CUIQuadSegmentEditingDlg();this.oSegEditingDlg.Init(this._jN._m4.oDialogMgr);}this.oSegEditingDlg.SetSelection(_FK,_Q8);this.oSegEditingDlg.Create();this.oSegEditingDlg.Display();};CUICrosstab.prototype.ModifySegmentRule=function(_FK){_FK.ModifySegmentMeasureValue();};CUICrosstab.prototype.IsValidSelectedSuppression=function(_Jb){var _Q1=this._ax;var _al3=_Q1.GetNumberOfSelections();var _aeZ=true;if(_al3<=0){_Q1=this._bz;_al3=_Q1.GetNumberOfSelections();_aeZ=false;}if(_al3>1||_al3<=0){return-1;}var _TJ=_Q1.GetLastSelection();if(_TJ){if(_TJ._f1&&_TJ._f1.CanBeUsedInSuppression()){var _ago=_TJ._f1._un;var _amk=_Q1._eh;var _aqe=this.GetOppositeAxis(_Q1);var _aqO=_aqe._eh;if(_ago){_Jb.push(this.sAppName,_aqO,new Array(_ago));return(_aeZ?1:3);}else{_S6=_Q1._eh.GetSelectedSuppressionTuple(_TJ.GetMemberPos(),_TJ.GetDepth(),true,CDLAxisMember.CanBeUsedInSuppression);if(_S6){_Jb.push(this.sAppName,_amk,_S6);return(_aeZ?0:2);}}}}return-1;};function CUIEdgeTupleMember(id,_zx){this._ve=id;this._lW=_zx;};function CUIColWidthRecord(_Sp,_F4){this._ng=_Sp;this._nq=_F4;};CUIColWidthRecord.prototype.WriteToXml=function(){var _6W='<columnWidth width="';_6W+=this._nq.toString();_6W+='">';_6W+='<edgeTuple>';var _aDo;for(var i=0;i<this._ng.length;i++){_aDo=this._ng[i];switch(_aDo._lW){case ExpAxisObjType.Member:_6W+='<member>';_6W+=Utilities.HtmlEncode(_aDo._ve);_6W+='</member>';break;case ExpAxisObjType.Measure:_6W+='<measure>';_6W+=Utilities.HtmlEncode(_aDo._ve);_6W+='</measure>';break;case ExpAxisObjType.Calc:_6W+='<calc>';_6W+=_aDo._ve;_6W+='</calc>';break;}}_6W+='</edgeTuple>';_6W+='</columnWidth>';return _6W;};function CUIRowHeaderWidthRecord(_Ti,_F4){this._aw=_Ti;this._nq=_F4;};CUIRowHeaderWidthRecord.prototype.WriteToXml=function(){var _6W='<columnWidth width="';_6W+=this._nq.toString();_6W+='">';_6W+='<block>';_6W+=this._aw;_6W+='</block>';_6W+='</columnWidth>';return _6W;};function CUIXtabDataWidthCache(){this._pk=new HashTableArray();this._sa=new HashTableArray();};CUIXtabDataWidthCache.prototype.LoadFromXml=function(_D1){if(_D1){var _4O,_2I,_6Z;var _aoI=Dom.GetImmediateChildByNameNoNS(_D1,ExpAPIXml.kEleRowEdge);if(_aoI){var _ao8,_YP;_4O=Dom.GetElementsByTagName(_aoI,ExpAPIXml.kEleColWidth);for(var _B7=0;_B7<_4O.length;_B7++){_2I=_4O[_B7];_6Z=parseInt(_2I.getAttribute(ExpAPIXml.kEleWidth));_ao8=Dom.GetImmediateChildByNameNoNS(_2I,ExpAPIXml.kBlock);_YP=Dom.GetNodeText(_ao8);this.CreateRowHeaderRecord(_YP,_6Z);}}var _6O=Dom.GetImmediateChildByNameNoNS(_D1,ExpAPIXml.kEleColEdge);if(_6O){var _3k,_XR,_aG3,_aHl;_4O=Dom.GetElementsByTagName(_6O,ExpAPIXml.kEleColWidth);for(var _Jf=0;_Jf<_4O.length;_Jf++){_2I=_4O[_Jf];_6Z=parseInt(_2I.getAttribute(ExpAPIXml.kEleWidth));_3k=Dom.GetImmediateChildByNameNoNS(_2I,ExpAPIXml.kEleEdgeTuple);var _asg=new Array();_XR=_3k.childNodes;for(var _aJI=0;_aJI<_XR.length;_aJI++){_aG3=_XR[_aJI];_aHl=Dom.GetNodeText(_aG3);switch(_aG3.nodeName){case ExpAPIXml.kEleMember:_asg.push(new CUIEdgeTupleMember(_aHl,ExpAxisObjType.Member));break;case ExpAPIXml.kEleMeasure:_asg.push(new CUIEdgeTupleMember(_aHl,ExpAxisObjType.Measure));break;case ExpAPIXml.kEleCalc:_asg.push(new CUIEdgeTupleMember(_aHl,ExpAxisObjType.Calc));break;}}this.CreateColRecord(_asg,_6Z);}}}};CUIXtabDataWidthCache.prototype.GenerateEdgeTupleId=function(_Sp){var _Lx="";var _aDo;for(var i=0;i<_Sp.length;i++){_aDo=_Sp[i];_Lx+=_aDo._ve;}return _Lx;};CUIXtabDataWidthCache.prototype.CreateColRecord=function(_Sp,_F4){var _yz=this.GenerateEdgeTupleId(_Sp);this._sa.Put(_yz,new CUIColWidthRecord(_Sp,_F4));};CUIXtabDataWidthCache.prototype.CreateRowHeaderRecord=function(_Ti,_F4){this._pk.Put(_Ti,new CUIRowHeaderWidthRecord(_Ti,_F4));};CUIXtabDataWidthCache.prototype.GetColWidthByTupleId=function(_yz){var _WV=this._sa.Get(_yz);if(_WV){return _WV._nq;}return 0;};CUIXtabDataWidthCache.prototype.GetColWidthByTuple=function(_Sp){var _yz=this.GenerateEdgeTupleId(_Sp);return this.GetColWidthByTupleId(_yz);};CUIXtabDataWidthCache.prototype.GetRowHeaderColWidthByBlockId=function(_To){var _WV=this._pk.Get(_To);if(_WV){return _WV._nq;}return 0;};CUIXtabDataWidthCache.prototype.Clear=function(){this._sa.Clear();this._pk.Clear();};CUIXtabDataWidthCache.prototype.IsEmpty=function(){return(this._sa.Length()==0&&this._pk.Length()==0);};CUIXtabDataWidthCache.prototype.WriteToXml=function(_I2){var _6W="";var _aHe=this._pk.Length();var _anb=this._sa.Length();if(_aHe>0||_anb>0){var _WV;var _acU,_T4;_6W+="<widthData>";for(_acU=0;_acU<_aHe;_acU++){if(_acU==0){_6W+="<rowEdge>";}_WV=this._pk.GetAtIndex(_acU);_6W+=_WV.WriteToXml();if(_acU==_aHe-1){_6W+="</rowEdge>";}}_T4=_anb>_I2?_anb-_I2:0;var _abN=_T4;for(_T4;_T4<_anb;_T4++){if(_T4==_abN){_6W+="<colEdge>";}_WV=this._sa.GetAtIndex(_T4);_6W+=_WV.WriteToXml();if(_T4==_anb-1){_6W+="</colEdge>";}}_6W+="</widthData>";}return _6W;};function CUIDataCellBaseReplacement(_KB,_SF){this._oQ=_KB;this._dH=_SF;};function CUIDropZone(_KE){this._vQ=_KE;};CUIDropZone.kTopShortDrop=1;CUIDropZone.kTopLongDrop=2;CUIDropZone.kRightShortDrop=3;CUIDropZone.kRightLongDrop=4;CUIDropZone.kBottomShortDrop=5;CUIDropZone.kBottomLongDrop=6;CUIDropZone.kLeftShortDrop=7;CUIDropZone.kLeftLongDrop=8;CUIDropZone.kReplaceDrop=9;CUIDropZone.kMeasureDrop=10;CUIDropZone.kInvalidDrop=11;CUIDropZone.kAppendDrop=12;CUIDropZone.kWidth=6;CUIDropZone.kBorderWidth=2;CUIDropZone.kTopPadding=2;CUIDropZone.kLeftPadding=2;CUIDropZone.kiAppendIndiStaticDimension=5;CUIDropZone.prototype.Clear=function(){Dom.RemoveObject(this._rV);Utilities.RemoveAllChildObjects(this._oDropTgt);};CUIDropZone.prototype.CreateSideDZ=function(_UE,_Tf){var _ZH=document.createElement("DIV");_ZH.style.position='absolute';_ZH.className="crosstab_dropzone";_ZH.style.top=-1000+'px';_ZH.style.left=-1000+'px';var _azP=document.createElement("IMG");_azP.src=Utilities.IMG_PATH+_Tf;_azP.style.position='absolute';_azP.style.top=CUIDropZone.kTopPadding+'px';_azP.style.left=CUIDropZone.kLeftPadding+'px';_ZH.appendChild(_azP);_UE.appendChild(_ZH);Dom.SetObjRef(_ZH,_azP,'_oDropCaret');_ZH.onmouseup=CUIDropZone.SafeHandleDragDrop;Dom.SetObjRef(_ZH,this._vQ,'oCrosstab');this._rV=_ZH;this._oDropTgt=new Object();Dom.SetObjRef(_ZH,this._oDropTgt,'_oDropTgt');};CUIDropZone.prototype.ShowLeftRightDropZone=function(_P6,_TM,_T6){this._rV.className='dz_div_LR';this._rV.style.left=_P6+'px';this._rV.style.top=_TM+'px';COTStyle.SetHeight(this._rV,_T6);COTStyle.SetWidth(this._rV,2);COTStyle.SetWidth(this._rV._oDropCaret,2,'px');COTStyle.SetHeight(this._rV._oDropCaret,_T6,'px');this._rV.style.display='block';};CUIDropZone.prototype.ShowTopBottomDropZone=function(_P6,_TM,_F4){this._rV.className='dz_div_TB';this._rV.style.left=_P6+'px';this._rV.style.top=_TM+'px';COTStyle.SetHeight(this._rV,2);COTStyle.SetWidth(this._rV,_F4);COTStyle.SetHeight(this._rV._oDropCaret,2,'px');COTStyle.SetWidth(this._rV._oDropCaret,_F4,'px');this._rV.style.display='block';};CUIDropZone.prototype.HideSideDropZone=function(){if(this._rV!=null){this._rV.style.display='none';}};CUIDropZone.prototype.showReplaceDZBlock=function(oMem,_FC,_yG,_Ag){var _O0=oMem.GetAxis();var _FK=oMem.GetBlock();if(!_FC){if(!_Ag){this._oDropTgt.iDropZoneType=CUIDropZone.kInvalidDrop;return this._oDropTgt.iDropZoneType;}}for(var i=0;i<_O0._oo.length;i++){var _ON=_O0.GetVisibleMember(i,oMem.GetDepth());if(_ON&&(!_ON.IsSiblingProxy())&&_ON.GetAxisMember().GetBlock()==_FK){this.ShowReplaceDZCell(_ON.GetHtmlElement(),_FC,_yG);}}if(_FC){this._oDropTgt.iDropZoneType=CUIDropZone.kAppendDrop;}else{this._oDropTgt.iDropZoneType=CUIDropZone.kReplaceDrop;}return this._oDropTgt.iDropZoneType;};CUIDropZone.prototype.ShowReplaceDZCell=function(_Vl,_FC,_yG){if(_FC){_Vl.className+=' hamc_replace_dz';if(_Vl.axisMember&&(_Vl.axisMember.IsLastHAMCBlockMember())){var _F4=(this._xp.IsRowAxis())?_Vl.offsetWidth:CUIDropZone.kiAppendIndiStaticDimension;var _T6=(this._xp.IsRowAxis())?CUIDropZone.kiAppendIndiStaticDimension:_Vl.offsetHeight;if(this._xp.IsRowAxis()){var _3I=CUIAxisMember.kTLCorner;var _axg=_Vl.offsetHeight-_T6;var _ays=COTInputElementFactory.AppendDivOnTop(this._vQ._cf,_Vl,_3I,"appendIndicator",_T6,_F4,null,null,_axg,0);}else{var _3I=CUIAxisMember.kTRCorner;var _ays=COTInputElementFactory.AppendDivOnTop(this._vQ._cf,_Vl,_3I,"appendIndicator",_T6,_F4,null,null,0,0);}Dom.SetObjRef(_Vl,_ays,"_appdIndi");}}else{_Vl.className+=' replace_dz';}};CUIDropZone.prototype.HideReplaceDZ=function(_Vl){if((_Vl.className.indexOf(' replace_dz')>-1)||(_Vl.className.indexOf(' hamc_replace_dz')>-1)){var re=null;if(_Vl.className.indexOf(' replace_dz')>-1){re=/replace_dz/;}else{re=/hamc_replace_dz/g;}_Vl.className=_Vl.className.replace(re,'');}if(_Vl._appdIndi){Dom.RemoveObject(_Vl._appdIndi);_Vl._appdIndi=null;}};CUIDropZone.prototype.HideAxisReplaceDZ=function(_O0){for(var i=0;i<_O0._oo.length;i++){for(var j=0;j<_O0.GetDepth();j++){var _ON=_O0.GetVisibleMember(i,j);if(_ON&&(!_ON.IsSiblingProxy())){var _ayO=_ON.GetHtmlElement();this.HideReplaceDZ(_ayO);}}}};CUIDropZone.prototype.HideAllAxisDropZones=function(){this.HideSideDropZone();this.HideAxisReplaceDZ(this._vQ._bz);this.HideAxisReplaceDZ(this._vQ._ax);};CUIDropZone.prototype.HideAxisDropZones=function(_O0){this.HideSideDropZone();this.HideAxisReplaceDZ(_O0);};CUIDropZone.prototype.ShowDropZone=function(_Vl,e,_Ww,_FC,_yG,_Lv){var _2s=e.clientX;var _aw2=e.clientY;var _atE=_Lv.sId;var oMem=_Vl.axisMember;var _FK=oMem.GetAxisMember().GetBlock();this._oDropTgt.oMem=oMem;var _O0=oMem.GetAxis();this._xp=_O0;var _AT=this._vQ._jN._m4.dataManager;this.dropDataDimId=_Lv.GetDimId(_AT.metadata,_AT.GetCurrentDataMatrix());var _Ag=COTValidation.IsValidDrop(_O0.GetDLAxis(),_Lv,_AT.metadata,ExpAPIXml.kActionReplace,_FK);this.HideAllAxisDropZones();if(_FC&&!COTValidation.IsDropWithNewMembers(_Lv,_FK)){this._oDropTgt.iDropZoneType=CUIDropZone.kInvalidDrop;return this._oDropTgt.iDropZoneType;}var _Qb=Dom.GetRelativeOffset(_Vl,document.body);var _aEs=_Qb.iLeft;var _afE=_Qb.iTop;var _7G=_Qb.iLeft+_Vl.offsetWidth;var _aJv=_Qb.iTop+_Vl.offsetHeight;var _akY;var _P6,_TM,_aiL,_am8;var _afk=_O0.GetVisibleMember(0,0).GetHtmlElement().offsetTop;var _aCT=_O0.GetVisibleMember(0,0).GetHtmlElement().offsetLeft;if(((_2s-_aEs)>10)&&((_7G-_2s)>10)){var _F4=0;var _aDA=0;if(_O0.IsRowAxis()){var _aD1=_O0.GetDepth();for(var i=0;i<_O0.GetDepth()&&_aD1>0;i++){var _ON=_O0.GetVisibleMember(0,i);var _ayO=_ON.GetHtmlElement();_aD1-=_ayO.colSpan;if(i==0){_P6=_ayO.offsetLeft;_TM=_ayO.offsetTop;}_F4+=_ayO.offsetWidth;}if((_aw2-_afE)<10){if(_Vl._sq&&(!_FC)){var _Ym=COTValidation.IsValidDrop(_O0.GetDLAxis(),_Lv,_AT.metadata,ExpAPIXml.kAxisOpUnion);if(_Vl.offsetTop!=_afk||!_Ym){return this.showReplaceDZBlock(oMem,_FC,_yG,_Ag);}this._oDropTgt.iDropZoneType=CUIDropZone.kTopLongDrop;this.ShowTopBottomDropZone(_P6,_TM,_F4-CUIDropZone.kWidth+CUIDropZone.kBorderWidth);}else{return this.showReplaceDZBlock(oMem,_FC,_yG,_Ag);}}else if((_aJv-_aw2)<10){var _Ym=COTValidation.IsValidDrop(_O0.GetDLAxis(),_Lv,_AT.metadata,ExpAPIXml.kAxisOpUnion);if(_Vl._dU&&(!_FC)&&_Ym){_TM=_Vl.offsetTop+_Vl.offsetHeight-CUIDropZone.kWidth-CUIDropZone.kBorderWidth;this._oDropTgt.iDropZoneType=CUIDropZone.kBottomLongDrop;this.ShowTopBottomDropZone(_P6,_TM,_F4-CUIDropZone.kWidth+CUIDropZone.kBorderWidth);}else{return this.showReplaceDZBlock(oMem,_FC,_yG,_Ag);}}else{return this.showReplaceDZBlock(oMem,_FC,_yG,_Ag);}}else{for(var i=0;i<_O0._oo.length;i++){var _ON=_O0.GetVisibleMember(i,oMem.GetDepth());var _ayO=_ON.GetHtmlElement();if(i==0){_P6=_ayO.offsetLeft;_TM=(oMem.GetDepth()==0)?_ayO.offsetTop:_ayO.offsetTop-CUIDropZone.kWidth/2;}_F4=_ayO.offsetLeft+_ayO.offsetWidth-_P6;}if(_FC){return this.showReplaceDZBlock(oMem,_FC,_yG,_Ag);}else{if((_aw2-_afE)<10){if(!(oMem.GetDepth()==0)){var _aem=COTValidation.IsValidDrop(_O0.GetDLAxis(),_Lv,_AT.metadata,ExpAPIXml.kAxisOpXjoin,_FK,ExpAPIXml.kEleOuter);if(_FK.IsUnioned()||!_aem){return this.showReplaceDZBlock(oMem,_FC,_yG,_Ag);}else{this._oDropTgt.iDropZoneType=CUIDropZone.kTopShortDrop;this.ShowTopBottomDropZone(_P6,_TM,_F4-CUIDropZone.kWidth+CUIDropZone.kBorderWidth);}}else{var _ahf=COTValidation.IsValidDrop(_O0.GetDLAxis(),_Lv,_AT.metadata,ExpAPIXml.kAxisOpXjoin,null,ExpAPIXml.kEleOuter);if(!_ahf){return this.showReplaceDZBlock(oMem,_FC,_yG,_Ag);}this._oDropTgt.iDropZoneType=CUIDropZone.kTopLongDrop;this.ShowTopBottomDropZone(_P6,_TM,_F4-CUIDropZone.kWidth+CUIDropZone.kBorderWidth);}}else if((_aJv-_aw2)<10){_TM=_Vl.offsetTop+_Vl.offsetHeight-CUIDropZone.kWidth-CUIDropZone.kBorderWidth/2;if(!(oMem.GetDepth()==_O0.GetDepth()-1)){var _az7=COTValidation.IsValidDrop(_O0.GetDLAxis(),_Lv,_AT.metadata,ExpAPIXml.kAxisOpXjoin,_FK,ExpAPIXml.kEleInner);if(_FK.IsUnioned()||!_az7){return this.showReplaceDZBlock(oMem,_FC,_yG,_Ag);}else{_TM+=CUIDropZone.kWidth/2+CUIDropZone.kBorderWidth/2;this._oDropTgt.iDropZoneType=CUIDropZone.kBottomShortDrop;this.ShowTopBottomDropZone(_P6,_TM,_F4-CUIDropZone.kWidth+CUIDropZone.kBorderWidth);}}else{var _ZX=_FK.IsUnioned()?null:_FK;var _3V=COTValidation.IsValidDrop(_O0.GetDLAxis(),_Lv,_AT.metadata,ExpAPIXml.kAxisOpXjoin,_ZX,ExpAPIXml.kEleInner);if(!_3V){return this.showReplaceDZBlock(oMem,_FC,_yG,_Ag);}else{this._oDropTgt.iDropZoneType=CUIDropZone.kBottomLongDrop;this.ShowTopBottomDropZone(_P6,_TM,_F4-CUIDropZone.kWidth+CUIDropZone.kBorderWidth);}}}else{return this.showReplaceDZBlock(oMem,_FC,_yG,_Ag);}}}}else{if(_FC&&_O0.IsRowAxis()){this.showReplaceDZBlock(oMem,_FC,_yG,_Ag);}else{var _T6=0;var _0R=0;if(_O0.IsRowAxis()){for(var i=0;i<_O0._oo.length;i++){var _ON=_O0.GetVisibleMember(i,oMem.GetDepth());var _ayO=_ON.GetHtmlElement();if(i==0){_TM=_ayO.offsetTop;_P6=(oMem.GetDepth()==0)?_ayO.offsetLeft:_ayO.offsetLeft-CUIDropZone.kWidth/2;}_T6=_ayO.offsetTop+_ayO.offsetHeight-_TM;}if((_2s-_aEs)<=10){if(oMem.GetDepth()==0){var _2p=COTValidation.IsValidDrop(_O0.GetDLAxis(),_Lv,_AT.metadata,ExpAPIXml.kAxisOpXjoin,null,ExpAPIXml.kEleOuter);if(!_2p){return this.showReplaceDZBlock(oMem,_FC,_yG,_Ag);}this._oDropTgt.iDropZoneType=CUIDropZone.kLeftLongDrop;this.ShowLeftRightDropZone(_P6,_TM,_T6-CUIDropZone.kWidth+CUIDropZone.kBorderWidth);}else{var _axT=COTValidation.IsValidDrop(_O0.GetDLAxis(),_Lv,_AT.metadata,ExpAPIXml.kAxisOpXjoin,_FK,ExpAPIXml.kEleOuter);if(_FK.IsUnioned()||!_axT){return this.showReplaceDZBlock(oMem,_FC,_yG,_Ag);}else{this._oDropTgt.iDropZoneType=CUIDropZone.kLeftShortDrop;this.ShowLeftRightDropZone(_P6,_TM,_T6-CUIDropZone.kWidth+CUIDropZone.kBorderWidth);}}}else if((_7G-_2s)<=10){if(oMem.GetDepth()==(_O0.GetDepth()-1)){var _ZX=_FK.IsUnioned()?null:_FK;var _aap=COTValidation.IsValidDrop(_O0.GetDLAxis(),_Lv,_AT.metadata,ExpAPIXml.kAxisOpXjoin,_ZX,ExpAPIXml.kEleInner);if(!_aap){return this.showReplaceDZBlock(oMem,_FC,_yG,_Ag);}else{_P6=_Vl.offsetLeft+_Vl.offsetWidth-CUIDropZone.kWidth;this._oDropTgt.iDropZoneType=CUIDropZone.kRightLongDrop;this.ShowLeftRightDropZone(_P6,_TM,_T6-CUIDropZone.kWidth+CUIDropZone.kBorderWidth);}}else{var _5W=COTValidation.IsValidDrop(_O0.GetDLAxis(),_Lv,_AT.metadata,ExpAPIXml.kAxisOpXjoin,_FK,ExpAPIXml.kEleInner);if(_FK.IsUnioned()||!_5W){return this.showReplaceDZBlock(oMem,_FC,_yG,_Ag);}else{_P6=_Vl.offsetLeft+_Vl.offsetWidth-CUIDropZone.kWidth/2;this._oDropTgt.iDropZoneType=CUIDropZone.kRightShortDrop;this.ShowLeftRightDropZone(_P6,_TM,_T6-CUIDropZone.kWidth+CUIDropZone.kBorderWidth);}}}}else{for(var i=0;i<_O0.GetDepth();i++){var _ON=_O0.GetVisibleMember(0,i);var _ayO=_ON.GetHtmlElement();if(i==0){_P6=_ayO.offsetLeft;_TM=_ayO.offsetTop;}_T6=_ayO.offsetTop+_ayO.offsetHeight-_TM;}this._oDropTgt.iDropZoneType=(_FC&&(!_yG))?CUIDropZone.kLeftShortDrop:CUIDropZone.kLeftLongDrop;var _Ym=COTValidation.IsValidDrop(_O0.GetDLAxis(),_Lv,_AT.metadata,ExpAPIXml.kAxisOpUnion);var _z5=(_Vl._dN&&(!_FC)&&(_aCT==_Vl.offsetLeft)&&_Ym)?true:false;if((_7G-_2s)<=10){_P6=_Vl.offsetLeft+_Vl.offsetWidth-CUIDropZone.kWidth-CUIDropZone.kBorderWidth;this._oDropTgt.iDropZoneType=(_FC&&(!_yG))?CUIDropZone.kRightShortDrop:CUIDropZone.kRightLongDrop;_z5=(_Vl._lO&&(!_FC)&&_Ym)?true:false;}if(_z5){this.ShowLeftRightDropZone(_P6,_TM,_T6-CUIDropZone.kWidth+CUIDropZone.kBorderWidth);}else{return this.showReplaceDZBlock(oMem,_FC,_yG,_Ag);}}}}_akY=this._oDropTgt.iDropZoneType;return _akY;};CUIDropZone.SafeHandleDragDrop=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}this.oCrosstab.HandleDragDrop(e);CUIDragDrop.SafeHandleMouseUp(e);Dom.CancelBubble(e);return true;/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIUserSelection.ExprMap=new Object();CUIUserSelection.ExprMap[ExpUserSelection.Uniary]=new Array(ExpAPIXml.kAbsFunc,ExpAPIXml.kRoundFunc,ExpAPIXml.kRoundDownFunc,ExpAPIXml.kSquareRootFunc);CUIUserSelection.ExprMap[ExpUserSelection.UniaryFactor]=new Array(ExpAPIXml.kPowerFunc);CUIUserSelection.ExprMap[ExpUserSelection.UniaryScope]=new Array(ExpAPIXml.kRankFunc,ExpAPIXml.kPercentileFunc,ExpAPIXml.kQuartileFunc,ExpAPIXml.kPcntOfTotalFunc);CUIUserSelection.ExprMap[ExpUserSelection.PcntBasedUniaryScope]=new Array(ExpAPIXml.kPcntOfTotalFunc);CUIUserSelection.ExprMap[ExpUserSelection.UniaryScopeFactor]=new Array(ExpAPIXml.kQuantile);CUIUserSelection.ExprMap[ExpUserSelection.Binary]=new Array(ExpAPIXml.kMinusFunc,ExpAPIXml.kDiffFunc,ExpAPIXml.kDividFunc,ExpAPIXml.kPercentFunc,ExpAPIXml.kPcntOfDiffFunc);CUIUserSelection.ExprMap[ExpUserSelection.N_ary]=new Array(ExpAPIXml.kSumFunc,ExpAPIXml.kPlusFunc,ExpAPIXml.kProdFunc,ExpAPIXml.kAvgFunc,ExpAPIXml.kMedianFunc,ExpAPIXml.kMinFunc,ExpAPIXml.kMaxFunc,ExpAPIXml.kRollUpFunc);CUIUserSelection.FastCalcOptionArr=new Object();if(!Utilities.bCalcCentroidEnabled){CUIUserSelection.FastCalcOptionArr[ExpUserSelection.Uniary]=new Array(ExpAPIXml.kRankFunc,ExpAPIXml.kPcntOfTotalFunc,ExpAPIXml.kRoundFunc,ExpAPIXml.kRoundDownFunc,ExpAPIXml.kAbsFunc);}else{CUIUserSelection.FastCalcOptionArr[ExpUserSelection.Uniary]=new Array(ExpAPIXml.kRankFunc,ExpAPIXml.kPcntOfTotalFunc,ExpAPIXml.kRoundFunc,ExpAPIXml.kRoundDownFunc,ExpAPIXml.kCentroidFunc,ExpAPIXml.kAbsFunc);};CUIUserSelection.FastCalcOptionArr[ExpUserSelection.Binary]=new Array(ExpAPIXml.kPlusFunc,ExpAPIXml.kMinusFunc,ExpAPIXml.kProdFunc,ExpAPIXml.kDividFunc,ExpAPIXml.kPercentFunc,ExpAPIXml.kPcntOfDiffFunc);CUIUserSelection.FastCalcOptionArr[ExpUserSelection.N_ary]=new Array(ExpAPIXml.kSumFunc,ExpAPIXml.kAvgFunc,ExpAPIXml.kMinFunc,ExpAPIXml.kMaxFunc);CUIUserSelection.aResSuffixMap=new Object();CUIUserSelection.aResSuffixMap[ExpAPIXml.kRankFunc]="RANK";CUIUserSelection.aResSuffixMap[ExpAPIXml.kPcntOfTotalFunc]="PCNTOFTOTAL";CUIUserSelection.aResSuffixMap[ExpAPIXml.kPercentileFunc]="PERCENTILE";CUIUserSelection.aResSuffixMap[ExpAPIXml.kQuartileFunc]="QUARTILE";CUIUserSelection.aResSuffixMap[ExpAPIXml.kQuantile]="QUANTILE";CUIUserSelection.aResSuffixMap[ExpAPIXml.kSumFunc]="SUM";CUIUserSelection.aResSuffixMap[ExpAPIXml.kDiffFunc]="DIFF";CUIUserSelection.aResSuffixMap[ExpAPIXml.kAvgFunc]="AVG";CUIUserSelection.aResSuffixMap[ExpAPIXml.kVarFunc]="VAR";CUIUserSelection.aResSuffixMap[ExpAPIXml.kStddevFunc]="STDDEV";CUIUserSelection.aResSuffixMap[ExpAPIXml.kMedianFunc]="MEDIAN";CUIUserSelection.aResSuffixMap[ExpAPIXml.kMinFunc]="MIN";CUIUserSelection.aResSuffixMap[ExpAPIXml.kMaxFunc]="MAX";CUIUserSelection.aResSuffixMap[ExpAPIXml.kRollUpFunc]="ROLLUP";CUIUserSelection.aResSuffixMap[ExpAPIXml.kRoundFunc]="ROUND";CUIUserSelection.aResSuffixMap[ExpAPIXml.kRoundDownFunc]="ROUNDDOWN";CUIUserSelection.aResSuffixMap[ExpAPIXml.kCentroidFunc]="CENTROID";CUIUserSelection.aResSuffixMap[ExpAPIXml.kSquareRootFunc]="SQRROOT";CUIUserSelection.aResSuffixMap[ExpAPIXml.kPercentFunc]="PERCENT";CUIUserSelection.aResSuffixMap[ExpAPIXml.kPcntOfDiffFunc]="PCNTOFDIFF";CUIUserSelection.aResSuffixMap[ExpAPIXml.kCountFunc]="COUNT";CUIUserSelection.aResSuffixMap[ExpAPIXml.kAbsFunc]="ABS";CUIUserSelection.AbsPosAbove=0;CUIUserSelection.AbsPosBelow=1;CUIUserSelection.AbsPosBefore=2;CUIUserSelection.AbsPosAfter=3;CUIUserSelection.AbsPosIn=4;CUIUserSelection.AbsPosReplace=5;function CUIUserSelection(_O0){this._qw=_O0;this._lW=ExpUserSelection.Uniary;this._qx=ExpUserSelection.MemberUnit;this._us=new Array();this._e4=new Object();this._bC=new Array();var _Hk=this._qw.GetUIReportObj()._jN._m4;this.oRes=_Hk.appobj.oResources;this._e6=new Array();this._e6[ExpEvent.kUserSelection_BlockChange]=new Array();this._e6[ExpEvent.kUserSelection_Clear]=new Array();this._e6[ExpEvent.kUserSelection_MemberChange]=new Array();this._mS=new Object();this._rE=new Object();this._gW=new Object();this._mS[ExpAPIXml.kDividFunc]=this.oRes.GetString("OTH_CROSSTAB_MENU_CAL_DIVID");this._rE[ExpAPIXml.kDividFunc]=this.oRes.GetString("IDS_CALCU_DLG_ITEM_DIVID");this._mS[ExpAPIXml.kPlusFunc]=this.oRes.GetString("OTH_CROSSTAB_MENU_CAL_ADD");this._rE[ExpAPIXml.kPlusFunc]=this.oRes.GetString("IDS_CALCU_DLG_ITEM_ADD");this._mS[ExpAPIXml.kSumFunc]=this.oRes.GetString("OTH_CROSSTAB_MENU_CAL_SUM");this._mS[ExpAPIXml.kAvgFunc]=this.oRes.GetString("OTH_CROSSTAB_MENU_CAL_AVG");this._mS[ExpAPIXml.kMedianFunc]=this.oRes.GetString("OTH_CROSSTAB_MENU_CAL_MEDIAN");this._mS[ExpAPIXml.kMinFunc]=this.oRes.GetString("OTH_CROSSTAB_MENU_CAL_MIN");this._mS[ExpAPIXml.kMaxFunc]=this.oRes.GetString("OTH_CROSSTAB_MENU_CAL_MAX");this._mS[ExpAPIXml.kRollUpFunc]=this.oRes.GetString("OTH_CROSSTAB_MENU_CAL_ROLLUP");this._mS[ExpAPIXml.kMinusFunc]=this.oRes.GetString("OTH_CROSSTAB_MENU_CAL_MINUS");this._rE[ExpAPIXml.kMinusFunc]=this.oRes.GetString("IDS_CALCU_DLG_ITEM_MINUS");this._mS[ExpAPIXml.kDiffFunc]=this.oRes.GetString("OTH_CROSSTAB_MENU_CAL_DIFF");this._mS[ExpAPIXml.kProdFunc]=this.oRes.GetString("OTH_CROSSTAB_MENU_CAL_MULTIPLY");this._rE[ExpAPIXml.kProdFunc]=this.oRes.GetString("IDS_CALCU_DLG_ITEM_MULTIPLY");this._mS[ExpAPIXml.kRankFunc]=this.oRes.GetString("OTH_CROSSTAB_MENU_CAL_RANK");this._mS[ExpAPIXml.kAbsFunc]=this.oRes.GetString("OTH_CROSSTAB_MENU_CAL_ABS");this._mS[ExpAPIXml.kRoundFunc]=this.oRes.GetString("OTH_CROSSTAB_MENU_CAL_ROUND");this._mS[ExpAPIXml.kRoundDownFunc]=this.oRes.GetString("OTH_CROSSTAB_MENU_CAL_ROUNDDOWN");this._mS[ExpAPIXml.kCentroidFunc]=this.oRes.GetString("OTH_CROSSTAB_MENU_CAL_CENTROID");this._mS[ExpAPIXml.kSquareRootFunc]=this.oRes.GetString("IDS_CROSSTAB_MENU_CAL_SQRROOT");this._mS[ExpAPIXml.kPercentFunc]=this.oRes.GetString("IDS_CROSSTAB_MENU_CAL_PERCENT");this._mS[ExpAPIXml.kPcntOfTotalFunc]=this.oRes.GetString("IDS_CROSSTAB_MENU_CAL_PCNTOFTOTAL");this._mS[ExpAPIXml.kPcntOfDiffFunc]=this.oRes.GetString("OTH_CROSSTAB_MENU_CAL_PCNTOFDIFF");this._rE[ExpAPIXml.kPcntOfDiffFunc]=this.oRes.GetString("IDS_CALCU_DLG_ITEM_PCNTOFDIFF");this._mS[ExpAPIXml.kPercentileFunc]=this.oRes.GetString("IDS_CROSSTAB_MENU_CAL_PERCENTILE");this._mS[ExpAPIXml.kQuartileFunc]=this.oRes.GetString("IDS_CROSSTAB_MENU_CAL_QUARTILE");this._mS[ExpAPIXml.kQuantile]=this.oRes.GetString("IDS_CROSSTAB_MENU_CAL_QUANTILE");this._mS[ExpAPIXml.kSingleItemFunc]=this.oRes.GetString("IDS_CALCU_DLG_SINGLE_ITME_OP");this._mS[CUICalculationDlg.kStaticNumCalc]=this.oRes.GetString("IDS_CALCU_DLG_STATIC_NUMBER");this._mS[ExpAPIXml.kPowerFunc]=this.oRes.GetString("IDS_CALCU_DLG_POWER");this._rE[ExpAPIXml.kPowerFunc]=this.oRes.GetString("IDS_CALCU_DLG_ITEM_POWER");this._cu=null;this._hm=new Object();var _aIh=this._qw.GetUIReportObj().GetDataWorkSheet();if(_aIh&&_aIh.IsSumDiffFastCalcEnabled()){CUIUserSelection.FastCalcOptionArr[ExpUserSelection.Binary].splice(0,2,ExpAPIXml.kSumFunc,ExpAPIXml.kDiffFunc);}};CUIUserSelection.prototype.AddTempCalc=function(_M7){this._hm[_M7.GetId()]=_M7;};CUIUserSelection.prototype.GetTempCalc=function(id){if(this._hm[id]){return this._hm[id];}return null;};CUIUserSelection.prototype.GetUIAxis=function(){return this._qw;};CUIUserSelection.prototype.Unload=function(){Utilities.DeleteAllFromArray(this._us);Utilities.ClearObjectArray(this._e4);this._lW=ExpUserSelection.Uniary;this._qx=ExpUserSelection.MemberUnit;};CUIUserSelection.prototype.SetType=function(_zx){if(_zx){this._lW=_zx;}else{if(this._us.length==1){this._lW=ExpUserSelection.Uniary;}else if(this._us.length==2){this._lW=ExpUserSelection.Binary;}else if(this._us.length>2){this._lW=ExpUserSelection.N_ary;}}};CUIUserSelection.prototype.GetType=function(){return this._lW;};CUIUserSelection.prototype.SetUnit=function(_Jh){this._qx=_Jh;};CUIUserSelection.prototype.GetUnit=function(){return this._qx;};CUIUserSelection.prototype.AddNewSelection=function(_Tr,_Bm){if(!Utilities.IsInArray(this._us,_Tr)){if(this._us.length>0){if(this._us[this._us.length-1].GetBlock()!=_Tr.GetBlock()){this._cu=null;}else{if(!_Bm){var _6z=Utilities.GenerateCallback(this.Notify,[ExpEvent.kUserSelection_MemberChange],this);setTimeout(_6z,1);}}this._us[this._us.length]=_Tr;this.SetType();}else{this._us[this._us.length]=_Tr;this.SetType();if((this._cu&&(this._cu!=_Tr.GetBlock()))||(this._uI)){this._cu=_Tr.GetBlock();if(!_Bm){var _6z=Utilities.GenerateCallback(this.Notify,[ExpEvent.kUserSelection_BlockChange],this);setTimeout(_6z,1);}}else{this._cu=_Tr.GetBlock();if(!_Bm){var _6z=Utilities.GenerateCallback(this.Notify,[ExpEvent.kUserSelection_MemberChange],this);setTimeout(_6z,1);}}}}};CUIUserSelection.prototype.RemoveSelection=function(obj){Utilities.DeleteFromArray(this._us,obj);this.SetType();};CUIUserSelection.prototype.PopulateCalOptions=function(){Utilities.ClearObjectArray(this._e4);var _ao0=CUIUserSelection.FastCalcOptionArr[this._lW];var _RJ=this._qw.GetUIReportObj().GetDataWorkSheet()._ak.metadata;for(var i=0;i<_ao0.length;i++){var _Ct=new Array();if(!_RJ.IsFunctionSupported(_ao0[i])){continue;}if(_ao0[i]==ExpAPIXml.kRankFunc||_ao0[i]==ExpAPIXml.kPcntOfTotalFunc){var _L3=this.GetUIAxis().GetUIReportObj();var _VP=_L3.GetDataWorkSheet().GetDataManager();var _aEp=this._cu.GetOppositeAxis().HasHAMCMeasureBlocksOnly();var _8O=_VP.GetCurrentDataMatrix().HasMeasureBlock();var _aeI=_VP.GetCurrentDataMatrix().GetCurrentMeasure();var _00=this._cu.HasMeasures();if((((!_aeI)&&(!_8O))||_aEp)&&(_ao0[i]==ExpAPIXml.kPcntOfTotalFunc)){continue;}else{var _BM='';var _aqj=new COTLiteralOperands(ExpAxisObjType.Measure,ExpAPIXml.kEleCurrentMeasure);if(_00){_aqj=new COTLiteralOperands(ExpAxisObjType.Measure,CUICalculationDlg.kDupMeasure);}_Ct.push(_aqj);}_Ct.push(this._us[0]);if(_ao0[i]==ExpAPIXml.kPcntOfTotalFunc){var _Yz=CUICalculationDlg.kDirectionNA;}else{var _Yz=new COTOrdinalOperands(ExpAPIXml.kOrdinalDirection,ExpAPIXml.kDefaultOrdiDirection);}_Ct.push(_Yz);var _ap4=_L3.GetUIWorkSheet().GetUIAxesContainer();var _aqv=_ap4.GetOppositeAxis(this.GetUIAxis());_Ct.push(_aqv);}else{_Ct=Utilities.CopyArray(this._us);}var _Dt=this.CreateExpression(_ao0[i],_Ct);}};CUIUserSelection.prototype.CreateExpression=function(_J9,_C8,_Vy){var _axo=Utilities.GenerateId();this._e4[_axo]=new CUICalculationExpr(_axo,this);this._e4[_axo].AddOperation(_J9,_C8);this._e4[_axo].SetTooltip(_J9,_C8);return this._e4[_axo];};CUIUserSelection.prototype.GenerateMathMLExpr=function(_J9,_Ct,_IP){var _ab0=null;for(var i=0;i<_Ct.length;i++){_ab0=_Ct[i];if(_ab0==CUICalculationDlg.kDirectionNA){continue;}if(_ab0._jb||(this._e4[_Ct[i]]!=null)){_IP._cS=false;if(_ab0._jb){var _1A=this._e4[_ab0._at];}else{var _1A=this._e4[_ab0];}var _amC=_1A._s4;var _aDO=new CDLMathMLExprNode(_amC,true,true);var _75=_1A._fL;_aDO=this.GenerateMathMLExpr(_amC,_75,_aDO);_IP.AddOperands(_aDO,null,CDLMathMLOperands.Apply);}else{if(_ab0 instanceof COTLiteralOperands){var _UN=_ab0.GetValue();var _Ic=_ab0.GetLabel();if(_UN==CUICalculationDlg.kDupMeasure){continue;}if(_ab0._lW==ExpAPIXml.kNumberOperands){_IP.AddOperands(_UN,_Ic,CUICalculationExpr.CNOperand,-1,_ab0._lW);}else{_IP.AddOperands(_UN,_Ic,CUICalculationExpr.CIOperand,-1,_ab0._lW);}}else if(_ab0 instanceof COTSegmentOperand){var _HP=_ab0.GetSegObjId();var _Ck=_ab0.GetSegValue();_IP._cS=false;var _aot=Utilities.IsInArray(CUIUserSelection.ExprMap[ExpUserSelection.PcntBasedUniaryScope],_J9)?ExpAPIXml.kSegmentSumFunc:ExpAPIXml.kSegmentFunc;var _8I=new CDLMathMLExprNode(_aot,true,false);_8I.AddOperands(_HP,_HP,CDLMathMLOperands.CIOperand,-1,ExpAPIXml.kBlock);_8I.AddOperands(_Ck,_Ck,CDLMathMLOperands.CIOperand,-1,ExpAPIXml.kAttrSegment);_IP.AddOperands(_8I,null,CDLMathMLOperands.Apply);}else{var _UN=_ab0;var _zx=ExpAxisObjType.Measure;if(this._qw.GetDLAxis()._rk.GetAxisById(_UN)){_zx=ExpAPIXml.kAxis;_UN=(this._qw.GetAxisId()!=_UN)?ExpAPIXml.kOppositeAxis:ExpAPIXml.kCurrentAxis;}else{var oMem=this._qw._eh._rk.GetFirstAxisMember(_UN);if(!oMem){oMem=this._qw._eh._rk._he.metadata.GetMember(_UN);}if(!oMem){oMem=this._qw._eh._rk._he._kX.GetCalculation(_UN);}if(!oMem){oMem=this.GetTempCalc(_UN);}if(oMem){if(oMem instanceof CDLAbsMember){_zx=ExpAxisObjType.Member;}else if(oMem instanceof CDLAxisCalc){_zx=ExpAxisObjType.Calc;}else if(oMem instanceof CTempCalc){_zx=ExpAxisObjType.TempCalc;}else{if(oMem.IsCalc()){_zx=ExpAxisObjType.Calc;}else{if(!oMem.GetBlock().HasMeasures()){_zx=ExpAxisObjType.Member;}}}}}_IP.AddOperands(_UN,'',CUICalculationExpr.CIOperand,-1,_zx);}}}return _IP;};CUIUserSelection.prototype.Subscribe=function(obj,event){if(this._e6[event]){this._e6[event].push(obj);}};CUIUserSelection.prototype.Notify=function(event){var _alZ=this._e6[event];for(var i=0;i<_alZ.length;i++){_alZ[i].Notify(event);}};CUIUserSelection.prototype.IsRenamable=function(){var _aBW=false;if((this._us.length==1)&&(this.GetUnit()==ExpUserSelection.MemberUnit)){var oMem=this._us[0];_aBW=oMem.GetAxisMember().IsCalc()&&(!oMem.GetAxisMember().IsDynamicCalc());}return _aBW;};CUICalculationExpr.Operator="operator";CUICalculationExpr.CIOperand="ci";CUICalculationExpr.CNOperand="cn";CUICalculationExpr.ExprBegin="applybegin";CUICalculationExpr.ExprEnd="applyend";CUICalculationExpr.kDefaultSegment='defaultsegment';CUICalculationExpr.kRPCalcMeasureOpdIdx=0;CUICalculationExpr.kRPCalcMemberOpdIdx=1;CUICalculationExpr.kRPCalcOrdinalOpdIdx=2;CUICalculationExpr.kRPCalcFirstSegOpdIdx=3;CUICalculationExpr.kRPCalcNumOpdIdx=1;CUICalculationExpr.kItemTruncLength=18;function CUICalculationExpr(id,_VC,_Vy){this._c2=_VC;this._qw=_VC._qw;this._s4=null;this._fL=new Array();this._at=id;this._p8='';this._pl=null;this._uM='';this._qT=document.createElement('DIV');};CUICalculationExpr.prototype.GetLabel=function(){return this._p8;};CUICalculationExpr.prototype.GetLabelDiv=function(){return this._qT;};CUICalculationExpr.prototype.SetTooltip=function(_J9,_C8){var _Rz='';var _Co=this._c2.oRes;switch(_J9){case ExpAPIXml.kPercentFunc:var _8R=CUICalculationExpr.GetOperandsLabel(_C8[0]);var _anQ=CUICalculationExpr.GetOperandsLabel(_C8[1]);_Rz=_Co.ReplaceParam('IDS_CROSSTAB_MENU_CAL_PERCENT_TOOLTIP',1,_8R);_Rz=_Co.ReplaceParam(_Rz,2,_anQ);break;case ExpAPIXml.kPcntOfDiffFunc:var _8R=CUICalculationExpr.GetOperandsLabel(_C8[0]);var _anQ=CUICalculationExpr.GetOperandsLabel(_C8[1]);_Rz=_Co.ReplaceParam('IDS_CROSSTAB_MENU_CAL_PCNTOFDIFF_TOOLTIP',1,_8R);_Rz=_Co.ReplaceParam(_Rz,2,_anQ);_Rz=_Co.ReplaceParam(_Rz,3,_anQ);break;default:_Rz=this._p8;break;}this._da=_Rz;};CUICalculationExpr.prototype.GetTooltip=function(_Ct){return this._da;};CUICalculationExpr.prototype.GetMenuLabel=function(){if(this._uM!=''){this._pl=this._uM;}else{this._pl=this._p8;}return this._pl;};CUICalculationExpr.prototype.GetId=function(){return this._at;};CUICalculationExpr.GetOperandsLabel=function(_LE,_Mi,_Co){var _99='';if(_LE instanceof CUIAxisMember){_99=_LE.GetLabel();}else if(_LE instanceof CUIListCtrlItem){if(_Mi){_99=_LE.GetLabel();}else{_99=((_LE._jb||_LE._vg)?'(':'')+_LE.GetLabel()+((_LE._jb||_LE._vg)?')':'');}}else if(_LE instanceof CUICalculationExpr){_99=_LE.GetLabel();}else if(_LE instanceof COTLiteralOperands){_99=_LE.GetLabel();}else if(_LE instanceof CUIAxis){_99="";}else if(_LE instanceof COTSegmentOperand){_99=_LE.GetLabel(_Co);}else{_99=_LE._p8?_LE._p8:'';}return _99;};CUICalculationExpr.prototype.GetOperandsLabelObj=function(_LE,_EF){var _aAC=null;if(_LE instanceof CUIListCtrlItem||_LE instanceof CUIAxisMember){var _C7=_LE.sValue;if(_LE instanceof CUIAxisMember){var _zU=_LE._f1;_C7=_zU._uT;}var oMem=this._qw._eh._rk._he.metadata.GetData(_C7);if(oMem){_aAC=document.createTextNode(_EF);}else{oMem=this._qw._eh._rk._he._kX.GetCalculation(_C7);if(oMem){if(!oMem.IsDynamicCalc()&&oMem.IsEditable()){var _9h=Utilities.GenerateCallback(CUICalculationDlg.SafeDoEditCalc,[this._c2.GetUIAxis().GetUIReportObj().sAppName,_C7]);if(oMem.IsValid()){_aAC=COTInputElementFactory.CreateLink(_9h,_EF,true);}else{invalidLink=document.createElement('A');invalidLink.onclick=_9h;invalidLink.className="calcExprBoardInvalidLink";invalidLink.appendChild(document.createTextNode(_EF));_aAC=document.createElement('SPAN');_aAC.appendChild(invalidLink);}}else{_aAC=document.createTextNode(_EF);}}else{oMem=this._c2.GetTempCalc(_C7);if(oMem){var _9h=Utilities.GenerateCallback(CUICalculationDlg.SafeDoEditCalc,[this._c2.GetUIAxis().GetUIReportObj().sAppName,_C7]);if(oMem.IsEditable()){if(oMem.IsValid()){_aAC=COTInputElementFactory.CreateLink(_9h,_EF,true);}else{invalidLink=document.createElement('A');invalidLink.onclick=_9h;invalidLink.className="calcExprBoardInvalidLink";invalidLink.appendChild(document.createTextNode(_EF));_aAC=document.createElement('SPAN');_aAC.appendChild(invalidLink);}}}else{_aAC=document.createTextNode(_EF);}}}}else if(_LE instanceof CUICalculationExpr){_aAC=document.createTextNode(_EF);}else if(_LE instanceof COTLiteralOperands){_aAC=document.createTextNode(_EF);}else if(_LE instanceof CUIAxis){_aAC=document.createTextNode(_EF);}else if(_LE instanceof COTSegmentOperand){_aAC=document.createTextNode(_EF);}else{_aAC=document.createTextNode(_EF);}return _aAC;};CUICalculationExpr.prototype.GetExprLabelDiv=function(_Hq,_Fb){var _aBl=document.createElement('DIV');var _aHB=this._c2.oRes.GetString(_Hq);var _arD=_aHB;for(var i=0;;i++){var _aEI=_arD.split(this._c2.oRes.GetParameterForReplace(i+1));if(_aEI[0]==_arD){break;}else{_arD=_aEI[0];}}for(var i=0;i<_Fb.length;i++){if(_Fb[i]){_aBl.appendChild(_Fb[i]);if(_arD&&(i<_Fb.length-1)){var _adl=document.createTextNode(_arD);_aBl.appendChild(_adl);}_aHB=this._c2.oRes.ReplaceParam(_Hq,i,'');}}return _aBl;};CUICalculationExpr.prototype.SetExprLabelDivParam=function(_Hq,_Kg,_MU){Dom.RemoveAllChildren(this._qT);var _BM=this._c2.oRes.GetString(_Hq);var _1C=_BM.split(this._c2.oRes.GetParameterForReplace(_Kg));for(var i=0;i<_1C.length;i++){if(_1C[i]&&_1C[i]!=''){var _adl=document.createTextNode(_1C[i]);this._qT.appendChild(_adl);}if(i==0&&_MU&&_MU.hasChildNodes()){while(_MU.childNodes.length>0){this._qT.appendChild(_MU.firstChild);}}}};CUICalculationExpr.GetOperandsId=function(_LE){var _abe='';if(_LE instanceof CUIAxisMember){_abe=_LE.GetMemberId();}else if(_LE instanceof CUIListCtrlItem){_abe=_LE.GetValue();}else if(_LE instanceof CUICalculationExpr){_abe=_LE.GetId();}else if(_LE instanceof COTLiteralOperands||_LE instanceof COTSegmentOperand){_abe=_LE;}else if(_LE instanceof CUIAxis){_abe=_LE.GetDLAxis().GetId();}else{_abe=_LE._jU?_LE._jU:'';}return _abe;};CUICalculationExpr.prototype.CreateAggregateFormatLabel=function(_SO,_Ct){var _99;var _EF='';var _LE=null;var _apE=new Array();var _aIA='';this._p8='IDS_CALC_EXPR_AGGR_FORMAT_'+CUIUserSelection.aResSuffixMap[_SO];var _MU=null;if(_Ct.length==1){_EF=CUICalculationExpr.GetOperandsLabel(_Ct[0]);this._fL[0]=CUICalculationExpr.GetOperandsId(_Ct[0]);_aIA=Utilities.GetTruncatedString(_EF,CUICalculationExpr.kItemTruncLength,this._c2.oRes);_LE=this.GetOperandsLabelObj(_Ct[0],_EF);_apE[0]=_LE;_MU=this.GetExprLabelDiv('IDS_CALC_EXPR_AGGR_FORMAT_'+CUIUserSelection.aResSuffixMap[_SO],_apE);}else{var _alN=new Array();var _amK=new Array();for(var i=0;i<_Ct.length;i++){var _ahg=CUICalculationExpr.GetOperandsLabel(_Ct[i]);_alN[i]=_ahg;var _amG=Utilities.GetTruncatedString(_ahg,CUICalculationExpr.kItemTruncLength,this._c2.oRes);_LE=this.GetOperandsLabelObj(_Ct[i],_ahg);if(_LE){_apE[_apE.length]=_LE;}_amK[i]=_amG;this._fL[i]=CUICalculationExpr.GetOperandsId(_Ct[i]);}_EF=this._c2.oRes.ReplaceParamList('IDS_CALC_EXPR_AGGR_MULTI_OPERANDS',_alN);_aIA=this._c2.oRes.ReplaceParamList('IDS_CALC_EXPR_AGGR_MULTI_OPERANDS',_amK);_MU=this.GetExprLabelDiv('IDS_CALC_EXPR_AGGR_MULTI_OPERANDS',_apE);}if(_MU){this.SetExprLabelDivParam(this._p8,2,_MU);}var _5n=this._p8;this._p8=this._c2.oRes.ReplaceParam(this._p8,2,_EF);this._uM=this._c2.oRes.ReplaceParam(_5n,2,_aIA);};CUICalculationExpr.prototype.CreateRepeatFormatLabel=function(_SO,_Ct){for(var i=0;i<_Ct.length;i++){_99=CUICalculationExpr.GetOperandsLabel(_Ct[i]);this._fL[i]=CUICalculationExpr.GetOperandsId(_Ct[i]);var _aDM=((i==(_Ct.length-1))?'':' '+this._c2._mS[_SO]+' ');this._p8+=_99+_aDM;var _amG=Utilities.GetTruncatedString(_99,CUICalculationExpr.kItemTruncLength,this._c2.oRes);this._uM+=_amG+((i==(_Ct.length-1))?'':' '+this._c2._mS[_SO]+' ');var _apf=this.GetOperandsLabelObj(_Ct[i],_99);if(_apf){this._qT.appendChild(_apf);}this._qT.appendChild(document.createTextNode(_aDM));}};CUICalculationExpr.kRPCalcMeasureOpdIdx=0;CUICalculationExpr.kRPCalcMemberOpdIdx=1;CUICalculationExpr.kRPCalcOrdinalOpdIdx=2;CUICalculationExpr.kRPCalcFirstSegOpdIdx=3;CUICalculationExpr.prototype.CreateRelPositionFormatLabel=function(_SO,_Ct,_zo){var _as5=this._c2._mS[_SO];var _aCu=(_SO==ExpAPIXml.kQuantile)?true:false;var _agT=false;var _adj=CUICalculationExpr.GetOperandsId(_Ct[CUICalculationExpr.kRPCalcMeasureOpdIdx]);if(_adj instanceof COTLiteralOperands){if(ExpAPIXml.kEleCurrentMeasure==_adj.GetValue()||CUICalculationDlg.kDupMeasure==_adj.GetValue()){_agT=true;}}if(!_zo){this._fL[CUICalculationExpr.kRPCalcOrdinalOpdIdx]=CUICalculationExpr.GetOperandsId(_Ct[CUICalculationExpr.kRPCalcOrdinalOpdIdx]);}else{this._fL[CUICalculationExpr.kRPCalcOrdinalOpdIdx]=_Ct[CUICalculationExpr.kRPCalcOrdinalOpdIdx];}var _anU=_Ct[CUICalculationExpr.kRPCalcFirstSegOpdIdx];this._fL[CUICalculationExpr.kRPCalcMeasureOpdIdx]=CUICalculationExpr.GetOperandsId(_Ct[CUICalculationExpr.kRPCalcMeasureOpdIdx]);var _XI=this._c2.oRes.GetString('IDS_CALC_EXPR_DEFAULT_MEASURE');if(!(ExpAPIXml.kEleDefault==CUICalculationExpr.GetOperandsId(_Ct[CUICalculationExpr.kRPCalcMeasureOpdIdx]))){_XI=CUICalculationExpr.GetOperandsLabel(_Ct[CUICalculationExpr.kRPCalcMeasureOpdIdx]);}this._fL[CUICalculationExpr.kRPCalcMemberOpdIdx]=CUICalculationExpr.GetOperandsId(_Ct[CUICalculationExpr.kRPCalcMemberOpdIdx]);var _ank=CUICalculationExpr.GetOperandsLabel(_Ct[CUICalculationExpr.kRPCalcMemberOpdIdx]);var _Wu='';var _MU=null;var _apE=new Array();_apE[0]=this.GetOperandsLabelObj(_Ct[CUICalculationExpr.kRPCalcMemberOpdIdx],_ank);if(_anU instanceof COTSegmentOperand){if(!_zo){_Wu='IDS_CALC_EXPR_'+CUIUserSelection.aResSuffixMap[_SO];var _aJF=_Ct[CUICalculationExpr.kRPCalcOrdinalOpdIdx].GetResSuffix();_Wu+=_aJF;_Wu+=_agT?'_APP_MEASURE':'';}else{_Wu=_agT?'IDS_CALC_EXPR_PCNTOFTOTAL_CUSTOM_APP_MEASURE':'IDS_CALC_EXPR_PCNTOFTOTAL_CUSTOM';}var _aro=this._p8;this._p8=_Wu;_MU=this.GetExprLabelDiv(_Wu,_apE);if(!_agT){this._p8=this._c2.oRes.ReplaceParam(this._p8,3,_XI);if(_MU&&(_aro!=this._p8)){this.SetExprLabelDivParam(this._p8,3,_MU);}}var _EF='';if(_Ct.length>3){var _alN=new Array();var _6c=_aCu?1:0;for(var i=CUICalculationExpr.kRPCalcFirstSegOpdIdx;i<(_Ct.length-_6c);i++){_alN[i-CUICalculationExpr.kRPCalcFirstSegOpdIdx]=CUICalculationExpr.GetOperandsLabel(_Ct[i],null,this._c2.oRes);this._fL[i]=CUICalculationExpr.GetOperandsId(_Ct[i]);}_EF=this._c2.oRes.ReplaceParamList('IDS_CALC_EXPR_MULTI_SEGMENTS',_alN);}else{this._fL[CUICalculationExpr.kRPCalcFirstSegOpdIdx]=CUICalculationExpr.GetOperandsId(_Ct[CUICalculationExpr.kRPCalcFirstSegOpdIdx]);_EF=CUICalculationExpr.GetOperandsLabel(_Ct[CUICalculationExpr.kRPCalcFirstSegOpdIdx],null,this._c2.oRes);}_aro=this._p8;this._p8=this._c2.oRes.ReplaceParam(this._p8,5,_EF);if(_MU&&(_aro!=this._p8)){this.SetExprLabelDivParam(this._p8,5,_MU);}}else if(_anU instanceof CUIAxis){this._fL[CUICalculationExpr.kRPCalcFirstSegOpdIdx]=CUICalculationExpr.GetOperandsId(_Ct[CUICalculationExpr.kRPCalcFirstSegOpdIdx]);if(this._qw==_anU){_Wu='IDS_CALC_EXPR_SAME_AXIS_'+CUIUserSelection.aResSuffixMap[_SO];_Wu+=_agT?'_APP_MEASURE':'';this._p8=_Wu;}else{_Wu='IDS_CALC_EXPR_'+CUIUserSelection.aResSuffixMap[_SO];var _aE0=_Ct[CUICalculationExpr.kRPCalcOrdinalOpdIdx];_Wu+=_agT?'_APP_MEASURE':'';if((!_zo)&&(ExpAPIXml.kDefaultOrdiDirection!=_aE0.GetValue())){var _aJF='_OPPO_AXIS'+_aE0.GetResSuffix();_Wu+=_aJF;}this._p8=_Wu;}if(!_agT){this._p8=this._c2.oRes.ReplaceParam(this._p8,3,_XI);}}var _aro=this._p8;this._p8=this._c2.oRes.ReplaceParam(this._p8,2,_ank);_MU=this.GetExprLabelDiv(_Wu,_apE);if(_MU&&(_aro!=this._p8)){this.SetExprLabelDivParam(_aro,2,_MU);}_aro=this._p8;var _amG=Utilities.GetTruncatedString(_ank,CUICalculationExpr.kItemTruncLength,this._c2.oRes);this._uM=this._c2.oRes.ReplaceParam(_aro,2,_amG);this._p8=this._c2.oRes.ReplaceParam(this._p8,5,this._c2._cu.GetLabel());if(_MU&&(_aro!=this._p8)){this.SetExprLabelDivParam(this._p8,5,_MU);}if(_aCu){var _arP=_Ct[_Ct.length-1];Utilities.InsertToNthInArray(this._fL,_arP,CUICalculationExpr.kRPCalcNumOpdIdx);_aro=this._p8;this._p8=this._c2.oRes.ReplaceParam(this._p8,6,_arP.GetLabel());if(_MU&&(_aro!=this._p8)){this.SetExprLabelDivParam(this._p8,6,_MU);}}};CUICalculationExpr.prototype.AddOperation=function(_SO,_Ct){this._s4=_SO;var _99='';switch(_SO){case ExpAPIXml.kMinusFunc:case ExpAPIXml.kDividFunc:case ExpAPIXml.kPowerFunc:this.CreateRepeatFormatLabel(_SO,_Ct);break;case ExpAPIXml.kPlusFunc:case ExpAPIXml.kProdFunc:this.CreateRepeatFormatLabel(_SO,_Ct);break;case ExpAPIXml.kRankFunc:case ExpAPIXml.kPercentileFunc:case ExpAPIXml.kQuartileFunc:case ExpAPIXml.kQuantile:this.CreateRelPositionFormatLabel(_SO,_Ct);break;case ExpAPIXml.kPcntOfTotalFunc:this.CreateRelPositionFormatLabel(_SO,_Ct,true);break;case ExpAPIXml.kAbsFunc:case ExpAPIXml.kRoundFunc:case ExpAPIXml.kRoundDownFunc:case ExpAPIXml.kSquareRootFunc:case ExpAPIXml.kCentroidFunc:this.CreateAggregateFormatLabel(_SO,_Ct);break;case ExpAPIXml.kPercentFunc:case ExpAPIXml.kPcntOfDiffFunc:case ExpAPIXml.kSumFunc:case ExpAPIXml.kDiffFunc:case ExpAPIXml.kAvgFunc:case ExpAPIXml.kVarFunc:case ExpAPIXml.kStddevFunc:case ExpAPIXml.kMedianFunc:case ExpAPIXml.kMinFunc:case ExpAPIXml.kMaxFunc:case ExpAPIXml.kCountFunc:case ExpAPIXml.kRollUpFunc:this.CreateAggregateFormatLabel(_SO,_Ct);break;}};CUISetBasedCalcExpression.SetBasedCalcOptArray=new Array(ExpAPIXml.kSumFunc,ExpAPIXml.kAvgFunc,ExpAPIXml.kMaxFunc,ExpAPIXml.kMinFunc,ExpAPIXml.kMedianFunc,ExpAPIXml.kVarFunc,ExpAPIXml.kStddevFunc,ExpAPIXml.kCountFunc);function CUISetBasedCalcExpression(_IP,_Co,_FK){this._ni=_IP;this._at=Utilities.GenerateId();this._sp=_Co;this._rB=_FK;this._p8='IDS_CALC_EXPR_AGGR_FORMAT_'+CUIUserSelection.aResSuffixMap[_IP.GetOperator()];this._p8=_Co.ReplaceParam(this._p8,2,_FK.GetLabel());};CUISetBasedCalcExpression.prototype.GetLabel=function(){return this._p8;};function CUIAbsAxis(_L3,_M4){this._oz=_M4;this._S=_L3;this._j8=new Array();this._eh=null;this._bo=new Object();this._dT="";};CUIAbsAxis.prototype.IsColAxis=function(){return this._oz==CUIDataMatrix.iColIndex;};CUIAbsAxis.prototype.IsRowAxis=function(){return this._oz==CUIDataMatrix.iRowIndex;};CUIAbsAxis.prototype.Populate=function(){Debug.Assert(false);};CUIAbsAxis.prototype.GetUIReportObj=function(){return this._S;};CUIAbsAxis.prototype.GetAxisIndex=function(){return this._oz;};CUIAbsAxis.prototype.Init=function(){this._az=new CUIUserSelection(this);var _Li=this._S.GetDataWorkSheet()._ak.GetCurrentDataMatrix();if(!_Li){this._S.GetDataWorkSheet()._ak.Subscribe(this,ExpEvent.kCDLDataManager_DataMatrixCreate);}else{_Li.Subscribe(this,ExpEvent.kCDLDataMatrix_AxisCreation);}};CUIAbsAxis.prototype.GetAxisId=function(){if(!this._eh){return null;}return this._eh._ks;};CUIAbsAxis.prototype.GetLength=function(){if(!this._eh){return 0;}return this._eh.GetLength();};CUIAbsAxis.prototype.GetDepth=function(){if(!this._eh){return 0;}return this._eh.GetAxisDepth();};CUIAbsAxis.prototype.SetDLAxis=function(_Ib){this._eh=_Ib;};CUIAbsAxis.prototype.GetDLAxis=function(){if(!this._eh){this._eh=this._S.GetDataWorkSheet()._ak.GetCurrentDataMatrix().GetAxis(this._oz);}return this._eh;};CUIAbsAxis.prototype._qZ=function(){this._eh=this._S.GetDataWorkSheet()._ak.GetCurrentDataMatrix().GetAxis(this._oz);};CUIAbsAxis.prototype.AddMember=function(_KO,_EJ,_QH){if(!this._j8[_EJ]){this._j8[_EJ]=new Array();}this._j8[_EJ][_QH]=_KO;};CUIAbsAxis.prototype.GetMember=function(_EJ,_QH){if(!this._j8[_EJ]||!this._j8[_EJ][_QH]){return null;}return this._j8[_EJ][_QH];};CUIAbsAxis.prototype.GetMemberFromId=function(_RP){if(this._bo[_RP]){return this._bo[_RP];}return null;};CUIAbsAxis.prototype.GetBlock=function(_L7){return this._eh.GetBlock(_L7);};CUIAbsAxis.prototype.IsSameLogicalMember=function(_El,_Ek){if(_El.GetMemberId()==_Ek.GetMemberId()&&_El.GetBlock()==_Ek.GetBlock()){return true;}return false;};CUIAbsAxis.prototype.GetUIMember=function(_I9){if(!_I9){return null;}return this._bo[_I9.GetUniqueID()];};CUIAbsAxis.prototype.SelectBlock=function(_zU,_No,_U7){if(!_No){var _No=_zU.GetBlock();}var _aaK=false;if(this._S._n2){_aaK=_No.GetAxis().GetBlock(this._S._uH)?true:false;}this._az.SetUnit(ExpUserSelection.BlockUnit);this._az.SetType(ExpUserSelection.Uniary);this._dT=_No.GetId();this._az._cu=_No;this._S.SetLastAxisSelected(this);if(!_U7){if(!_aaK){this._S._jN.HandleSelectedAxisCntx(ExpEvent.kCUIWorksheet_ChangedAxisSel);}else{this._az.Notify(ExpEvent.kUserSelection_BlockChange);}}};CUIAbsAxis.prototype.UnselectAllMembers=function(){this._az.SetUnit(ExpUserSelection.MemberUnit);this._az._uI=true;this._S._hL=null;};CUIAbsAxis.prototype.Notify=function(event){var _aab=null;if(event==ExpEvent.kCDLDataMatrix_AxisCreation){this._qZ();}else if(event==ExpEvent.kCDLDataManager_DataMatrixCreate){this._S.GetDataWorkSheet()._ak.GetCurrentDataMatrix().Subscribe(this,ExpEvent.kCDLDataMatrix_AxisCreation);}};CUIAbsAxis.prototype.Clear=function(){this.ClearMemberArray();if(this._az){this._az.Unload();}this.CleanBlockSelectors();Utilities.ClearObjectArray(this._bo);};CUIAbsAxis.prototype.CleanBlockSelectors=function(){};CUIAbsAxis.prototype.Unload=function(){this.Clear();if(this._S.GetDataWorkSheet()&&this._S.GetDataWorkSheet()._ak.GetCurrentDataMatrix()){this._S.GetDataWorkSheet()._ak.GetCurrentDataMatrix().UnSubscribe(this,ExpEvent.kCDLDataMatrix_AxisCreation);}};CUIAbsAxis.prototype.ClearMemberArray=function(){if(this._j8){var _ae6=this._j8.length;var _ae5=(this._j8[0])?this._j8[0].length:0;var oMem=null;for(var i=0;i<_ae6;i++){for(var j=0;j<_ae5;j++){oMem=this.GetMember(i,j);if(oMem&&oMem._aA){oMem._aA.axisMember=null;}}}Utilities.DeleteAllFromArray(this._j8);}};function CUIAxis(_Fh,_M4){this.base=CUIAbsAxis;this.base(_Fh,_M4);this.aBlockSelectorMembers=new Array();this._bK=new Array();this._qa=new Array();this._nQ=new Array();this._au=new Array();this._hb=new Object();this._ir=new Array();this._gR=-1;this._gz=-1;this._wB=new Array();this._hh=new Array();this._oo=new Array();this._lE=0;this._sH=0;this._pa=new Array();this._eA=new Array();this._dS=new Array();};CUIAxis.prototype=new CUIAbsAxis;CUIAxis.superclass=CUIAbsAxis.prototype;CUIAxis.prototype.GetCrosstab=function(){return this._S;};CUIAxis.prototype.GetResourceSuffix=function(){if(this._oz==CUIDataMatrix.iRowIndex){return 'ROWS';}else{return 'COLS';}};CUIAxis.prototype.GetNumberOfSelections=function(){return Utilities.GetObjArrayLength(this._hb);};CUIAxis.prototype.HasDynamicCalcSelected=function(){for(var i in this._hb){if(this._hb[i].GetAxisMember().IsDynamicCalc()){return true;}}return false;};CUIAxis.prototype.HasRemainderSelected=function(){for(var i in this._hb){if(this._hb[i].GetAxisMember().IsRemainder()){return true;}}return false;};CUIAxis.prototype.HasCalcSelected=function(){for(var i in this._hb){if(this._hb[i].IsCalc()){return true;}if(this._hb[i].GetAxisMember().IsDynamicCalc()){return true;}}return false;};CUIAxis.prototype.GetVisibleMember=function(_EJ,_QH){if(!this._oo[_EJ]||!this._oo[_EJ][_QH]){return null;}return this._oo[_EJ][_QH];};CUIAxis.prototype.SetVisibleMembersRange=function(_yT,_TF){this._lE=_yT;this._sH=_yT+_TF;this.UpdateVisibleMembers();};CUIAxis.prototype.IsMemberVisible=function(_zU){if(_zU._qH>=this._lE&&_zU._qH<this._sH){return true;}return false;};CUIAxis.prototype.UpdateVisibleMembers=function(){var _axE=this._sH-this._hh.length;this._oo.length=0;for(var i=0;this._wB&&i<this._wB.length;i++){this._oo[i]=this._j8[this._wB[i]];}for(i=this._lE;i<_axE;i++){this._oo.push(this._j8[i]);}for(i=0;this._hh&&i<this._hh.length;i++){this._oo.push(this._j8[this._hh[i]]);}};CUIAxis.prototype.AddToMemberAnnotationList=function(_zU){this._dS.push(_zU);};CUIAxis.prototype.SetBegPinnedMembers=function(){this._wB=aBegPinnedMembers;};CUIAxis.prototype.Clear=function(){CUIAxis.superclass.Clear.call(this);Utilities.DeleteAllFromArray(this.aBlockSelectorMembers);Utilities.DeleteAllFromArray(this._bK);Utilities.DeleteAllFromArray(this._au);Utilities.DeleteAllFromArray(this._oo);Utilities.ClearObjectArray(this._hb);Utilities.DeleteAllFromArray(this._nQ);for(var i=0;i<this.GetDepth();i++){this._nQ[i]=new Array();}this._ir=new Array();this._az.Unload();this._gR=-1;this._gz=-1;this._dT="";Utilities.DeleteAllFromArray(this._cV);Utilities.ClearObjectArray(this._bo);this.CleanAnnotations(true);this.CleanBlockSelectors();this.CleanSuppressionArr();};CUIAxis.prototype.AddBlockSelectorId=function(_Lx){this._qa.push(_Lx);};CUIAxis.prototype.HasBlockSelectorAtIndex=function(_PQ){if(this._bK[_PQ]){return true;}return false;};CUIAxis.prototype.Populate=function(){Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CUICrosstab::PopulateUIAxis"]);Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CUICrosstab::PopulateUIAxis::ClearOldAxisObjs"]);this.Clear();Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CUICrosstab::PopulateUIAxis::ClearOldAxisObjs"]);var _aEj=false;if(!this._eh.GetXtabData()){Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CUICrosstab::PopulateUIAxis"]);return;}Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CUICrosstab::PopulateUIAxis::CreateNewAxisObjs"]);for(var j=0;j<this.GetDepth();++j){for(var i=0;i<this.GetLength();++i){_aEj=false;var a=new Array();a[0]=i;a[1]=j;var _zU=this._eh.GetXtabData().GetAxisMemberCell(a);if(!_zU){var _aF8=j-1;while(!_zU&&_aF8>=0){a[1]=_aF8;_zU=this._eh.GetAxisMemberCell(a);_aF8--;}Debug.Assert(_zU);_aEj=true;}var _akV;var id=_zU.GetUniqueID();if(_aEj){var _0g=this._bo[id];_akV=new CUIAxisMemberProxy(_0g,CUIAxisMemberProxy.eChildProxy,i);_0g.SetChildProxyCount(_0g.GetChildProxyCount()+1);}else{if(!this._bo[id]){_akV=new CUIAxisMember(this);_akV.SetAxisMember(_zU);_akV.SetMemberPos(i);this._bo[id]=_akV;_akV._lX=this.isBlockSelectorMember(_zU,i,j);if(_akV._lX){this._bK[i]=true;}}else{var _0g=this._bo[id];_akV=new CUIAxisMemberProxy(_0g,CUIAxisMemberProxy.eSiblingProxy,i);_0g.SetSiblingProxyCount(_0g.GetSiblingProxyCount()+1);}}this.AddMember(_akV,i,j);if(_akV._lX){this.aBlockSelectorMembers.push(_akV);}}}Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CUICrosstab::PopulateUIAxis::CreateNewAxisObjs"]);Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CUICrosstab::PopulateUIAxis"]);};CUIAxis.prototype.isBlockSelectorMember=function(_zU,_B7,_FU){var b=new Array();b[0]=_B7-1;b[1]=_FU;var _axN=null;if(_B7>0){_axN=this._eh.GetAxisMemberCell(b);}if(!_axN){return true;}else{if(_axN.GetBlock()!=_zU.GetBlock()){return true;}else{var c=new Array();c[0]=_B7;c[1]=_FU-1;var _acE=null;if(_FU>0){_acE=this._eh.GetAxisMemberCell(c);}var d=new Array();d[0]=_B7-1;d[1]=_FU-1;var _3l=null;if(_B7>0&&_FU>0){_3l=this._eh.GetAxisMemberCell(d);}if(_acE&&_3l&&_acE.GetUniqueID()!=_3l.GetUniqueID()){return true;}}}return false;};CUIAxis.prototype.GetVisibleItemCount=function(_ON){var _Yf=0;var _aEA=_ON.Previous();while(_aEA&&_aEA.GetBlock()==_ON.GetBlock()){if(!_aEA.IsCalc()&&!_aEA.IsSummaryMem()){_Yf++;}_aEA=_aEA.Previous();}var _aa9=_ON.Next();while(_aa9&&_aa9.GetBlock()==_ON.GetBlock()){if(!_aa9.IsCalc()&&!_aa9.IsSummaryMem()){_Yf++;}_aa9=_aa9.Next();}return _Yf;};CUIAxis.prototype.IsVisibleItemCountReliable=function(_ON){var _akW=false;var _FK=_ON.GetBlock();var _Fh=this.GetCrosstab();var _ah9=_FK.oDataMgr.GetCurrentCrosstab();if(_ah9.IsTopPage()){_akW=true;}else{var _aEA=_ON.Previous();while(_aEA&&_aEA.GetBlock()==_ON.GetBlock()){_aEA=_aEA.Previous();}if(_aEA){_akW=true;}}return _akW;};CUIAxis.prototype.GetLastSelection=function(){if(this._gR!=-1){return this.GetMember(this._gR,this._gz);}return null;};CUIAxis.prototype.HasMultipleSelections=function(){var _Oi=0;for(var _Lx in this._hb){_Oi++;if(_Oi>1){return true;}}return false;};CUIAxis.prototype.HasSelectionsAcrossParents=function(){var _arv=null;for(var i in this._hb){if(!this._hb[i].GetParent()){Debug.Assert(false);return false;}if(_arv==null){_arv=this._hb[i].GetParent();}else if(this._hb[i].GetParent()!=_arv){return true;}}return false;};CUIAxis.prototype.HasSelection=function(){if(!this.GetLastSelection()){return false;}else{if(Utilities.IsInArray(this._az._us,this.GetLastSelection())){return true;}}return false;};CUIAxis.prototype.IsInSelectedMembers=function(_zU){if(this._hb[_zU.GetUniqueID()]){return true;}else if(_zU.IsMemberSelected()&&this._nQ[_zU.GetDepth()]&&Utilities.IsInArray(this._nQ[_zU.GetDepth()],_zU.GetMemberPos())){return true;}return false;};CUIAxis.prototype.TertiarySelectMember=function(_zU){_zU.SetTertiarySelection();_zU.SetCellStyle();this._au.push(_zU.GetUniqueID());if(this._oz==CUIDataMatrix.iRowIndex){this._S.GetCellMap().SelectRow(_zU.GetMemberPos());}else{this._S.GetCellMap().SelectCol(_zU.GetMemberPos());}var _VW=_zU.GetParent();if(_VW&&!_VW.IsMemberSelected()&&!_zU.GetBlock().IsGroupedDescendantsAtDepth()){for(var i=0;i<this._oo.length;i++){var _af7=_zU.GetDepth();var _apC=this.GetVisibleMember(i,_af7);if(this.IsSameLogicalMember(_apC,_zU)){if(!_apC.IsProxy()){_apC.SetTertiarySelection();_apC.SetCellStyle();}if(this._oz==CUIDataMatrix.iRowIndex){this._S.GetCellMap().SelectRow(_apC.GetMemberPos());}else{this._S.GetCellMap().SelectCol(_apC.GetMemberPos());}}}}};CUIAxis.prototype.TertiaryUnselectMember=function(_zU){_zU.SetMemberSelected(false);_zU.SetCellStyle();Utilities.DeleteFromArray(this._au,_zU.GetUniqueID());var _VW=_zU.GetParent();if(_VW&&!_VW.IsMemberSelected()&&!_zU.GetBlock().IsGroupedDescendantsAtDepth()){for(var i=0;i<this._oo.length;i++){var _af7=_zU.GetDepth();var _apC=this.GetVisibleMember(i,_af7);if(this.IsSameLogicalMember(_apC,_zU)){if(!_apC.IsProxy()){_apC.SetMemberSelected(false);_apC.SetCellStyle();}}}}};CUIAxis.prototype.TertiaryUnselectAll=function(){for(var i=0;i<this._au.length;i++){var oMem=this.GetMemberFromId(this._au[i]);this.TertiaryUnselectMember(oMem);}Utilities.DeleteAllFromArray(this._au);};CUIAxis.prototype.SelectMember=function(_zU,_Bm){_zU.EndHoverOver();this.selectMemberAndChildren(_zU,true);this._hb[_zU.GetUniqueID()]=_zU;this._ir[this._ir.length]=_zU.GetUniqueID();var _VW=_zU.GetParent();if(_VW&&!_VW.IsMemberSelected()&&!_zU.GetBlock().IsGroupedDescendantsAtDepth()){for(var i=0;i<this._oo.length;i++){var _apC=this.GetVisibleMember(i,_zU.GetDepth());if(this.IsSameLogicalMember(_apC,_zU)){if(!_apC.IsProxy()||!_apC.GetUIAxisMember().IsMemberSelected()){this.selectMemberAndChildren(_apC.GetUIAxisMember(),false);}this._nQ[_apC.GetDepth()].push(_apC.GetMemberPos());}}}this._az.AddNewSelection(_zU,_Bm);this._S.SetLastAxisSelected(this);this._S._hL=this;if(this.GetCrosstab()._nX){this.GetCrosstab()._nX=null;}};CUIAxis.prototype.selectMemberAndChildren=function(_zU,_Hj){for(var i=0;i<_zU.GetSiblingProxyCount()+1;i++){for(var j=_zU.GetDepth();j<this.GetDepth();j++){var oMem=this.GetMember(_zU.GetMemberPos()+i,j);if(oMem.IsChildProxy()){continue;}if(j>_zU.GetDepth()){oMem.SetSecondarySelection();}else{oMem.SetMemberSelected(true);}oMem.SetCellStyle();if(_Hj){this._gR=_zU.GetMemberPos();this._gz=_zU.GetDepth();}}if(this._oz==CUIDataMatrix.iRowIndex){this._S.GetCellMap().SelectRow(_zU.GetMemberPos()+i);}else{this._S.GetCellMap().SelectCol(_zU.GetMemberPos()+i);}}_zU.SetFocus();};CUIAxis.prototype.unselectMemberAndChildren=function(_zU,_Hj){for(var i=0;i<_zU.GetSiblingProxyCount()+1;i++){var _FU=0;if(this._j8&&this._j8[0]){_FU=this._j8[0].length;}for(var j=_zU.GetDepth();j<_FU;j++){var oMem=this.GetMember(_zU.GetMemberPos()+i,j);oMem.SetMemberSelected(false);oMem.SetCellStyle();}if(this._oz==CUIDataMatrix.iRowIndex){this._S.GetCellMap().UnselectRow(_zU.GetMemberPos()+i);}else{this._S.GetCellMap().UnselectCol(_zU.GetMemberPos()+i);}}};CUIAxis.prototype.HighlightBlock=function(_zU,_z7){for(var i=0;i<this._oo.length;i++){var oMem=this.GetVisibleMember(i,_zU.GetDepth());if(oMem.GetBlock()==_zU.GetBlock()){oMem.SetBlockHighlighted(_z7);oMem.SetCellStyle();}}};CUIAxis.prototype.HighlightBlockMembers=function(_zU){if(this._S.GetUIWorkSheet().AllowInteraction()){for(var i=0;i<this._oo.length;i++){var _af7=_zU.GetDepth();var oMem=this.GetVisibleMember(i,_af7);if(oMem.GetBlock()==_zU.GetBlock()){oMem._iV=true;oMem.SetCellStyle();}}}};CUIAxis.prototype.EndHighlightBlockMembers=function(_zU){if(this._S.GetUIWorkSheet().AllowInteraction()){for(var i=0;i<this._oo.length;i++){var _af7=_zU.GetDepth();var oMem=this.GetVisibleMember(i,_af7);if(oMem.GetBlock()==_zU.GetBlock()){oMem._iV=false;oMem.SetCellStyle();}}}};CUIAxis.prototype.SelectBlock=function(_zU,_No,_U7,_Wl){if(!_No){var _No=_zU.GetBlock();}var _aaK=false;if(this._S._n2){_aaK=_No.GetAxis().GetBlock(this._S._uH)?true:false;}var oMem=null;if(!_Wl){if(_No.IsEmptyBlock()){}else{for(var i=0;i<this._oo.length;i++){var _af7=_No.GetFirstNode().GetDepth();var oMem=this.GetVisibleMember(i,_af7);if(_zU){var _aax=_zU.GetAxisMember().IsDuplicateCalc();if(!_aax){_af7=_zU.GetDepth();oMem=this.GetVisibleMember(i,_af7);}}if(oMem&&oMem.GetBlock()==_No){if(!this._cV){this._cV=new Array();}oMem.SetMemberSelected(true);oMem.SetCellStyle();this._cV.push(oMem.GetUniqueID());}}}}this._dT=_No.GetId();this._az.SetUnit(ExpUserSelection.BlockUnit);this._az.SetType(ExpUserSelection.Uniary);this._az._cu=_No;this._S._hL=this;if(!_U7){if(!_aaK){this._S._jN.HandleSelectedAxisCntx(ExpEvent.kCUIWorksheet_ChangedAxisSel);}else{this._az.Notify(ExpEvent.kUserSelection_BlockChange);}}};CUIAxis.prototype.UnselectBlock=function(){for(var i=0;this._cV&&i<this._cV.length;i++){var _akP=this._bo[this._cV[i]];_akP.SetMemberSelected(false);_akP.SetCellStyle();}this._dT="";Utilities.DeleteAllFromArray(this._cV);this._cV=null;this._az.SetUnit(ExpUserSelection.MemberUnit);this._az._uI=true;this._S._hL=null;};CUIAxis.prototype.SequentialSelect=function(_zU){var _agB=_zU.GetMemberPos();if(this._gR==-1){this.SelectMember(_zU);}else{var _akr;var _aIe;var _0J=this._gR;var _VW=_zU.GetParent();if(_VW){var _73=this.GetLastSelection();if(_73.GetParent()!=_VW){var _awq=false;var _awX=_zU.GetBlock();var _aH8=this._eh.GetOpForBlock(_awX.GetId());if(_aH8.eType==CDLAxisOp.eTypeNest){_awq=true;}var _SW=_VW.GetFirstChild();while(_SW!=null&&!_awq){if(this.IsSameLogicalMember(_73,_SW)){_0J=_SW.GetMemberPos();this.UnselectMember(_73);break;}_SW=_SW.Next();}if(_73&&_0J==this._gR){this.SelectMember(_zU);return;}}}if(_agB>_0J){_akr=_0J;_aIe=_agB;}else{_akr=_agB;_aIe=_0J;}var _FU=_zU.GetDepth();for(var i=_akr;i<=_aIe;++i){var oMem=this.GetMember(i,_FU);if(!oMem.GetHtmlElement()){if(this.IsRowAxis()){this.GetCrosstab().CreateRowMemberCell(_FU,i);}else{this.GetCrosstab().CreateColMemberCell(i,_FU);}}}for(var i=_akr;i<=_aIe;++i){var oMem=this.GetMember(i,_FU);if(!oMem.IsProxy()&&oMem.GetHtmlElement()){this.SelectMember(oMem);}}}};CUIAxis.prototype.ReselectAllMembers=function(){var _aoi=new Object();for(id in this._hb){_aoi[id]=this._hb[id];}var _ai5=this._dT;var _as0=Utilities.CopyArray(this._au);this.UnselectAllMembers();for(id in _aoi){this.SelectMember(_aoi[id],true);}if(_ai5!=""){var _FK=this.GetDLAxis().GetBlock(_ai5);this.SelectBlock(null,_FK,true);}for(var i=0;i<_as0.length;i++){this.TertiarySelectMember(this.GetMemberFromId(_as0[i]));}};CUIAxis.prototype.UnselectAllMembers=function(){for(id in this._hb){this.UnselectMember(this._hb[id]);}Utilities.DeleteAllFromArray(this._nQ);for(var i=0;i<this.GetDepth();i++){this._nQ[i]=new Array();}this.TertiaryUnselectAll();Utilities.ClearObjectArray(this._hb);Utilities.DeleteAllFromArray(this._ir);this._gR=-1;this._gz=-1;if(this._dT!=""){this.UnselectBlock();}this._az._cu=null;};CUIAxis.prototype.UnselectMember=function(_zU,_Kf){var _aaQ=new Array();this.unselectMemberAndChildren(_zU,true);var _FU=_zU.GetDepth();if(this._nQ.length>0){for(var i=0;this._nQ[_FU]&&i<this._nQ[_FU].length;i++){var _aqn=this.GetMember(this._nQ[_FU][i],_FU);if(_aqn.GetMemberId()==_zU.GetMemberId()){this.unselectMemberAndChildren(_aqn,false);_aaQ.push(i);}}}for(var i=_aaQ.length-1;i>=0;i--){Utilities.DeleteNthFromArray(this._nQ[_FU],_aaQ[i]);}if(_Kf){for(var i=0;i<this._ir.length;i++){var _akP=this.GetMemberFromId(this._ir[i]);if(this.IsSameLogicalMember(_akP,_zU)){Utilities.DeleteNthFromArray(this._ir,i);break;}}for(var i in this._hb){if(this.IsSameLogicalMember(this._hb[i],_zU)){if(this._hb[i].IsMemberSelected()){this.unselectMemberAndChildren(this._hb[i],false);}delete this._hb[i];break;}}}else{Utilities.DeleteFromArray(this._ir,_zU.GetUniqueID());delete this._hb[_zU.GetUniqueID()];}this._az.RemoveSelection(_zU);var _4p=false;for(var i in this._hb){_4p=true;break;}if(!_4p){this._S.SetLastAxisSelected(null);}};CUIAxis.prototype.GetSelectedMembers=function(){return this._hb;};CUIAxis.prototype.HasNoItemsSelection=function(){var _av1=false;for(var i in this._hb){if(this._hb[i].IsNoItemsNode()){_av1=true;break;}}return _av1;};CUIAxis.prototype.CanHideSelectedMembers=function(){var _aDv=false;for(var i in this._hb){if(!this._hb[i].CanHide()){return false;}else{_aDv=true;}}return _aDv;};CUIAxis.prototype.CanDeleteSelectedMembers=function(){var _FK=null;var _afg=0;var _aC3=0;var _6f=false;var _afr=new Array();for(var i in this._hb){_FK=this._hb[i].GetBlock();if(_FK&&_FK.IsHAMC()){_afg=_FK._nx.length;_afr=_FK.GetCustomCalcIds();_aC3=_afr.length;}break;}var _axp=new Array();for(var i in this._hb){if(!this._hb[i].CanDelete()){return false;}else{if(_FK&&_FK.IsHAMC()){if(Utilities.IsInArray(_FK._nx,this._hb[i].GetMemberId())){_afg--;}if(Utilities.IsInArray(_afr,this._hb[i].GetMemberId())){_aC3--;_axp.push(this._hb[i].GetMemberId());}if(_afg==0){if(_aC3==0){return true;}else{_6f=false;}}else{_6f=true;}}else{_6f=true;}}}if(!_6f){for(var x=0;x<_afr.length;x++){if(!Utilities.IsInArray(_axp,_afr[x])){var _avR=_FK.oDataMgr._kX.GetCalculation(_afr[x]);if(_avR&&(!_avR.IsNumericConstant())){return true;}}}}return _6f;};CUIAxis.prototype.CanExcludeSelectedMembers=function(){var _aDv=false;var _aF2=this.GetSelectedMembers();for(var i in _aF2){if(!_aF2[i].CanExclude()){_aDv=false;break;}else{_aDv=true;}}var _Li=this._S.GetDataWorkSheet()._ak.GetCurrentDataMatrix();if(!_aDv||_Li.IsFullDataMode()){return _aDv;}var _FK=null;for(var i in _aF2){var oMem=_aF2[i].GetAxisMember();if(oMem){_FK=oMem.GetBlock();break;}}if(!_FK){_aDv=false;}else{var _af6=_FK.GetExcludedMemberIds();if(_af6){for(var i in _aF2){var oMem=_aF2[i].GetAxisMember();if(oMem&&Utilities.IsInArray(_af6,oMem.GetMemberId())){_aDv=false;break;}}}}return _aDv;};CUIAxis.prototype.CanHamcizeSelectedMembers=function(){var _aog=!this.HasCalcSelected();return _aog;};CUIAxis.prototype.CanCreateCalcUseSelectedMembers=function(){for(var i in this._hb){if(this._hb[i].IsDynamicCalc()){return false;}}return true;};CUIAxis.prototype.CleanBlockSelectors=function(){for(var i=0;i<this._qa.length;i++){var _anz=document.getElementById(this._qa[i]);_anz.axisMember=null;}Utilities.DeleteAllFromArray(this._qa);};CUIAxis.prototype.CleanAnnotations=function(_TO){for(var i=0;i<this._pa.length;i++){var _Vl=this._pa[i];if(_TO){if(_Vl._sq){_Vl._sq=null;_Vl.TNeighbor=null;}if(_Vl._lO){_Vl._lO=null;_Vl.LNeighbor=null;}else if(_Vl._dN){_Vl._dN=null;_Vl.LNeighbor=null;}}if(_Vl.dummyAnnoImg){_Vl.dummyAnnoImg._vd=null;_Vl.dummyAnnoImg=null;}}Utilities.DeleteAllFromArray(this._pa);if(_TO){Utilities.DeleteAllFromArray(this._dS);this._dS=new Array();}};CUIAxis.prototype.CleanSuppressionArr=function(){Utilities.DeleteAllFromArray(this._eA);};CUIAxis.prototype.GetNumberOfVisibleUnits=function(){return this._oo.length;};CUIAxis.prototype.GetLength=function(){if(!this._eh){return 0;}if(this._eh.GetXtabData()){return this._eh.GetXtabData().GetLength();}return 0;};CUIAxis.prototype.GetDepth=function(){if(!this._eh){return 0;}if(this._eh.GetXtabData()){return this._eh.GetXtabData().GetAxisDepth();}return 0;};function CUIChartAxis(_L3,_M4){this.base=CUIAbsAxis;this.base(_L3,_M4);};CUIChartAxis.prototype=new CUIAbsAxis;CUIChartAxis.superclass=CUIAbsAxis.prototype;CUIChartAxis.prototype.GetChart=function(){return this._S;};CUIChartAxis.prototype.GetResourceSuffix=function(){if(this._oz==CUIDataMatrix.iRowIndex){return 'ROWS';}else{return 'COLS';}};CUIChartAxis.prototype.Populate=function(){this.Clear();if(this._eh.GetChartData()==null){return;}for(var j=0;j<this.GetDepth();++j){for(var i=0;i<this.GetLength();++i){var a=new Array();a[0]=i;a[1]=j;var _zU=this._eh.GetChartData().GetAxisMemberCell(a);if(_zU){var _akV;var id=_zU.GetUniqueID();if(!this._bo[id]){_akV=new CUIAxisMember(this);_akV.SetAxisMember(_zU);_akV.SetMemberPos(i);this._bo[id]=_akV;this.AddMember(_akV,i,j);}}}}};CUIChartAxis.prototype.IsRowAxis=function(){return this._oz==CUIDataMatrix.iRowIndex;};CUIChartAxis.prototype.GetLength=function(){if(!this._eh){return 0;}if(this._eh.GetChartData()){return this._eh.GetChartData().GetLength();}return 0;};CUIChartAxis.prototype.GetDepth=function(){if(!this._eh){return 0;}if(this._eh.GetChartData()){return this._eh.GetChartData().GetAxisDepth();}return 0;};CUIAxisMember.eNotSelected=0;CUIAxisMember.eMemberSelected=1;CUIAxisMember.eParentMemberSelected=2;CUIAxisMember.eDataCellSelected=3;CUIAxisMember.kLabelTruncateLength=45;CUIAxisMember.kTRCorner=0;CUIAxisMember.kTLCorner=1;function CUIAxisMember(_Q1){this._qw=_Q1;this._b0=CUIAxisMember.eNotSelected;this._aA=null;this._f1=null;this._qH=-1;this._dC=0;this._mH=0;this._iV=false;this._nN='1px solid #787878';this._sw=null;this.bIsInnerTotal=false;this._oc='IDS_CROSSTAB_PROPERTY_VALUE';this._lX=false;};CUIAxisMember.prototype.GetUIAxisMember=function(){return this;};CUIAxisMember.prototype.Refresh=function(){if(this._aA){var _air=true;Dom.ClearRefs(this._aA,_air);}};CUIAxisMember.prototype.GetAxis=function(){return this._qw;};CUIAxisMember.prototype.IsSummaryOrNestedSummary=function(){var _IU=this.GetAxisMember();return(_IU&&_IU.IsSummaryOrNestedSummary());};CUIAxisMember.prototype.IsDynamicCalc=function(){var _IU=this.GetAxisMember();return(_IU&&_IU.IsDynamicCalc());};CUIAxisMember.prototype.IsCustomCalc=function(){var _IU=this.GetAxisMember();return(_IU&&_IU.IsCustomcCalc());};CUIAxisMember.prototype.IsMemberBasedCalc=function(){var _IU=this.GetAxisMember();return(_IU&&_IU.IsMemberBasedCalc());};CUIAxisMember.prototype.IsEditable=function(){var _IU=this.GetAxisMember();return(_IU&&_IU.IsEditable());};CUIAxisMember.prototype.IsSummaryMem=function(){var _IU=this.GetAxisMember();return(_IU&&_IU.IsSummaryMem());};CUIAxisMember.prototype.IsSummaryMemOrCalc=function(){var _IU=this.GetAxisMember();return(_IU&&_IU.IsSummaryMemOrCalc());};CUIAxisMember.prototype.GetChildProxyCount=function(){return this._dC;};CUIAxisMember.prototype.SetChildProxyCount=function(_EK){this._dC=_EK;};CUIAxisMember.prototype.GetSiblingProxyCount=function(){return this._mH;};CUIAxisMember.prototype.SetSiblingProxyCount=function(_C3){this._mH=_C3;};CUIAxisMember.prototype.GetLabel=function(){var _IU=this.GetAxisMember();return(_IU?_IU.GetLabel():"");};CUIAxisMember.prototype.GetDescription=function(){var _ape=this._cQ||"";if(!_ape){var _IU=this.GetAxisMember();_ape=(_IU?_IU.GetDescription():"");}if(!_ape&&this.IsNoItemsNode()){var _Co=this.GetAxis()._S._jN._m4.appobj.oResources;_ape=_Co.GetString('IDS_CROSSTAB_NO_ITEMS_TOOLTIP')||"";}return _ape;};CUIAxisMember.prototype.GetDefaultCalcLabel=function(){Debug.Assert(this.IsCalc());var _IU=this.GetAxisMember();return(_IU?_IU.GetDescription():"");};CUIAxisMember.prototype.GetPropertyCount=function(){var _IU=this.GetAxisMember();return(_IU?_IU.GetPropertyCount():0);};CUIAxisMember.prototype.DrawProperty=function(i){var _IU=this.GetAxisMember();var _aIT=_IU.GetPropertyLabel(i);var _Qs=String(_IU.GetPropertyValue(i));_z2=gResource.ReplaceParam(this._oc,1,_aIT);_BM=gResource.ReplaceParam(_z2,2,_Qs);var _afz=document.createElement('A');_afz.className="Property";_afz.iDropZoneType=CUIDropZone.kReplaceDrop;_afz.cellType=CUICrosstab.kMemberCellOther;_afz.ansType="Property";_afz._jX=false;_afz._iQ=this.GetUniqueID();_afz.appendChild(document.createTextNode(_BM));return _afz;};CUIAxisMember.prototype.DrawMemberText=function(_Vl,_Tq,_O3){var _IU=this.GetAxisMember();if(!_IU){return;}if(_IU.IsRemainder()){this.DrawRemainderText(_Tq);}else if(_IU.IsSubtotal()){this.DrawSubtotalText(_Tq);}else{var _ah3=this.GetLabel();var _aAn=(!this._qw._S._aF)&&(_ah3.length>CUIAxisMember.kLabelTruncateLength);if(_aAn){_BM=Utilities.GetTruncatedString(_ah3,CUIAxisMember.kLabelTruncateLength,gResource);}else{_BM=_ah3;}_3f=document.createTextNode(_BM);_O3.appendChild(_3f);_Tq.appendChild(_O3);this.AddMemberAnnotations(_Tq);var _azy=this.GetDescription();if(_azy){_Vl.title=_azy;if(this.CanDrillUpOrDown()){_O3.title='';}}if(_IU.IsInvalidCalc()){_Vl.title=gResource.ReplaceParam('IDS_CALC_INVALID_WARNING',1,_Vl.title);}}};CUIAxisMember.prototype.AddMemberAnnotations=function(){var _IU=this.GetAxisMember();if(_IU.IsExcludedSubtotal()){this._cQ=gResource.GetString('IDS_CROSSTAB_SUBTOTAL_EXCLUDED_TOOLTIP');this.GetAxis().AddToMemberAnnotationList(this);}else if(_IU.IsNotExcludedSubtotal()){this._cQ=gResource.GetString('IDS_CROSSTAB_SUBTOTAL_INCLUDED_TOOLTIP');this.GetAxis().AddToMemberAnnotationList(this);}};CUIAxisMember.prototype.DrawRemainderText=function(_Tq){var _IU=this.GetAxisMember();if(!_IU){return;}var _Co=gResource;Debug.Assert(_IU.IsRemainder());if(_IU.IsRemainder()){var _1E=_Tq.appendChild(document.createElement('A'));var _Nw=new Array();_1E.cellType=CUICrosstab.kMemberCellOther;var _aw8=false;var _asZ=false;var _FK=this.GetBlock();if(_FK.HasHiddenMembers()){_aw8=true;var _ams=this._qw.GetUIReportObj().GetUIWorkSheet()._m4.appobj;var _alq=_Co.ParseStringForParamOrder('IDS_CROSSTAB_REMAINDER_MORE_AND_HIDDEN',2);var _XK=_FK.oDataMgr._kX.GetSuppressionState();if(_XK!=ExpAPIXml.kNoSuppressionOnRowsOrColumns){_asZ=true;}}else{var _alq=_Co.ParseStringForParamOrder('IDS_CROSSTAB_REMAINDER_MORE',1);}for(var i=0;i<_alq.length;i++){var _aev=_alq[i];if(_aev){if(_aev.sBefore.length>0){_1E.appendChild(document.createTextNode(_aev.sBefore));}var _aqZ=_1E.appendChild(document.createElement('SPAN'));_aqZ.className="SpecialCalcText";_aqZ.onmouseover=Utilities.EventCallback(Dom.SetCSSClassName,["SpecialCalcTextHover"],null,true,false);_aqZ.onmouseout=Utilities.EventCallback(Dom.SetCSSClassName,["SpecialCalcText"],null,true,false);if(_aev.sElement==_Co.GetParameter(1)){_aqZ._vt=true;if(_asZ){_aqZ._et=true;_aqZ._vt=false;_aqZ.appendChild(document.createTextNode(_Co.GetString('IDS_CROSSTAB_HIDDEN_ONLY')));break;}else if(_aw8){_aqZ.appendChild(document.createTextNode(_Co.GetString('IDS_CROSSTAB_MORE')));}else{_aqZ.appendChild(document.createTextNode(_Co.GetString('IDS_CROSSTAB_MORE_ONLY')));}}else{_aqZ._et=true;_aqZ.appendChild(document.createTextNode(_Co.GetString('IDS_CROSSTAB_HIDDEN')));}if(_aev.sAfter.length>0){_1E.appendChild(document.createTextNode(_aev.sAfter));}}}}};CUIAxisMember.prototype.DrawSubtotalText=function(_Tq){var _IU=this.GetAxisMember();if(!_IU){return;}Debug.Assert(_IU.IsSubtotal());if(_IU.IsSubtotal()){var _amx=this._qw.IsVisibleItemCountReliable(this);if(!_amx){_Tq.appendChild(document.createTextNode(gResource.GetString('IDS_CROSSTAB_VISIBLE_SUBTOTAL_LABEL')));}else{var _XJ=_Tq.appendChild(document.createElement('A'));var _Nw=new Array();_XJ.cellType=CUICrosstab.kMemberCellOther;var _alq=gResource.ParseStringForParamOrder('IDS_CROSSTAB_SUBTOTAL_ITEMS',2);for(var i=0;i<_alq.length;i++){var _aev=_alq[i];if(_aev){if(_aev.sBefore.length>0){_XJ.appendChild(document.createTextNode(_aev.sBefore));}if(_aev.sElement==gResource.GetParameter(1)){_XJ.appendChild(document.createTextNode(this._qw.GetVisibleItemCount(this)));}else if(_aev.sElement==gResource.GetParameter(2)){var _aqZ=_XJ.appendChild(document.createElement('SPAN'));_aqZ.appendChild(document.createTextNode(gResource.GetString('IDS_CROSSTAB_SUBTOTAL_ITEMS_LINK')));_aqZ.className="SpecialCalcText";_aqZ.onmouseover=Utilities.EventCallback(Dom.SetCSSClassName,["SpecialCalcTextHover"],null,true,false);_aqZ.onmouseout=Utilities.EventCallback(Dom.SetCSSClassName,["SpecialCalcText"],null,true,false);_aqZ._pZ=true;}if(_aev.sAfter.length>0){_XJ.appendChild(document.createTextNode(_aev.sAfter));}}}}}};CUIAxisMember.prototype.GetAnnotation=function(){return this._cQ;};CUIAxisMember.prototype.GetUniqueID=function(){var _IU=this.GetAxisMember();return(_IU?_IU.GetUniqueID():null);};CUIAxisMember.prototype.GetMemberId=function(){var _IU=this.GetAxisMember();return(_IU?_IU.GetMemberId():null);};CUIAxisMember.prototype.GetSummaryLevel=function(){var _IU=this.GetAxisMember();return(_IU?_IU.GetSummaryLevel():0);};CUIAxisMember.prototype.IsCalc=function(){var _IU=this.GetAxisMember();return(_IU&&_IU.IsCalc());};CUIAxisMember.prototype.IsNoItemsNode=function(){var _IU=this.GetAxisMember();return(_IU&&_IU.IsNoItemsNode());};CUIAxisMember.prototype.CanDrillUpOrDown=function(){return(this.CanDrillUp()||this.CanDrillDown());};CUIAxisMember.prototype.isDrillable=function(){return(!this.IsCalc()&&!this.IsNoItemsNode());};CUIAxisMember.prototype.CanDrillUp=function(){var _IU=this.GetAxisMember();if(this.isDrillable()&&_IU){var _FK=_IU.GetBlock();return(this.IsSummaryMem()&&_FK.CanDrillUp());}return false;};CUIAxisMember.prototype.CanDoSecondaryDrillUp=function(){var _IU=this.GetAxisMember();if(this.isDrillable()&&_IU){var _FK=_IU.GetBlock();return(_FK.CanDrillUp()?!_IU.IsTopMember():false);}return false;};CUIAxisMember.prototype.CanDoSecondaryDrillDown=function(){return this.CanDrillDown();};CUIAxisMember.prototype.CanDrillDown=function(){if(this.isDrillable()&&!this.IsSummaryMem()){var _IU=this.GetAxisMember();if(_IU){var _FK=_IU.GetBlock();return(_FK&&_FK.CanDrillDown());}}return false;};CUIAxisMember.prototype.CanRenameSelectedDynamicCalc=function(){var _IU=this.GetAxisMember();if(_IU){return(!_IU.IsRemainder()&&!_IU.IsSubtotal());}return true;};CUIAxisMember.prototype.CanHide=function(){var _IU=this.GetAxisMember();return(_IU&&_IU.CanHide());};CUIAxisMember.prototype.CanExclude=function(){var _IU=this.GetAxisMember();return(_IU&&_IU.CanExclude());};CUIAxisMember.prototype.CanDelete=function(){var _IU=this.GetAxisMember();return(_IU&&_IU.CanDelete());};CUIAxisMember.prototype.CanUseAsDimFilter=function(){var _IU=this.GetAxisMember();return(_IU&&CanUseAsDimFilter());};CUIAxisMember.prototype.SetMemberSelected=function(_RM){if(_RM){this._b0=CUIAxisMember.eMemberSelected;}else{this._b0=CUIAxisMember.eNotSelected;}};CUIAxisMember.prototype.SetSecondarySelection=function(){this._b0=CUIAxisMember.eParentMemberSelected;};CUIAxisMember.prototype.SetTertiarySelection=function(){this._b0=CUIAxisMember.eDataCellSelected;};CUIAxisMember.prototype.IsMemberSelected=function(){return this._b0==CUIAxisMember.eMemberSelected;};CUIAxisMember.prototype.IsSelected=function(){return this._b0!=CUIAxisMember.eNotSelected;};CUIAxisMember.prototype.SetHtmlElement=function(_J6){this._aA=_J6;};CUIAxisMember.prototype.GetHtmlElement=function(){return this._aA;};CUIAxisMember.prototype.SetAxisMember=function(_zU){this._f1=_zU;};CUIAxisMember.prototype.GetAxisMember=function(){if(this._f1&&!this._f1.bNulledOut){return this._f1;}else{return null;}};CUIAxisMember.prototype.GetBlock=function(){var _IU=this.GetAxisMember();var _FK=(_IU?_IU.GetBlock():null);return(_FK||null);};CUIAxisMember.prototype.GetFirstChild=function(){var _IU=this.GetAxisMember();if(_IU){var _aur=_IU._dg;if(_aur){return this._qw.GetUIMember(_aur);}}return null;};CUIAxisMember.prototype.GetParent=function(){var _IU=this.GetAxisMember();if(_IU){var _aH9=_IU._qR;if(_aH9){return this._qw.GetUIMember(_aH9);}}return null;};CUIAxisMember.prototype.Next=function(){var _IU=this.GetAxisMember();return(_IU?this._qw.GetUIMember(_IU._b3):null);};CUIAxisMember.prototype.Previous=function(){var _IU=this.GetAxisMember();return(_IU?this._qw.GetUIMember(_IU._m7):null);};CUIAxisMember.prototype.IsLastHAMCBlockMember=function(){var _IU=this.GetAxisMember();return(_IU?((!_IU._b3)||(_IU._b3.GetBlock()!=this.GetBlock())):false);};CUIAxisMember.prototype.IsValidCalcOperand=function(){var _IU=this.GetAxisMember();if(!_IU){return false;}if(this.IsNoItemsNode()){return false;}return true;};CUIAxisMember.prototype.SetMemberPos=function(x){this._qH=x;};CUIAxisMember.prototype.GetMemberPos=function(){return this._qH;};CUIAxisMember.prototype.GetProxySpecificPos=function(){return this._qH;};CUIAxisMember.prototype.GetDepth=function(){var _IU=this.GetAxisMember();Debug.Assert(_IU);return(_IU?_IU.GetDepth():0);};CUIAxisMember.prototype.GetChildrenLength=function(){var _IU=this.GetAxisMember();Debug.Assert(_IU);return(_IU?_IU.GetChildrenLength():0);};CUIAxisMember.prototype.GetAllDescendantsLength=function(){var _IU=this.GetAxisMember();Debug.Assert(_IU);return(_IU?_IU.GetAllDescendantsLength(_IU,0):0);};CUIAxisMember.prototype.HoverOver=function(e){if(this._qw._S._xv.m_bDragging){return;}if(!this.GetAxisMember()){return;}this._iV=true;this.SetCellStyle();var _yW=Dom.GetEventTarget(e);if(this.CanDrillUpOrDown()){if(_yW&&_yW._jX){var _Pv=ExpAPIXml.kActionDrillDown;if(this.IsSummaryMem()){_Pv=ExpAPIXml.kActionDrillUp;}CUIManager.ShowDrillImage(_Pv,e.clientX,e.clientY);_yW.style.cursor="pointer";_yW.style.cursor="hand";if(this._qw._S._aF){this._qw._S._xv.HideBar();}}}else{CUIManager.HideDrillImage();}if(this._qw._S._aF){var _2s=e.clientX;while(_yW.tagName&&_yW.tagName.toLowerCase()!="td"){_yW=_yW.parentNode;}var _Qb=Dom.GetRelativeOffset(_yW,document.body);var _aEs=_Qb.iLeft;var _7G=_Qb.iLeft+_yW.offsetWidth;var _47=null;if(((_2s-_aEs)<5)||((_7G-_2s)<5)){var _Vl=_yW;if((_2s-_aEs)<5){if(this._qw.IsColAxis()){if(this._kG==this._qw._S._nj){return;}var _akU=this.Previous();if(_akU){_47=_akU.GetLastLeafDescendant();}}else{_47=this.GetParent()?this.GetParent():null;}}else{if(this._qw.IsColAxis()){_47=this.GetLastLeafDescendant();}else{_47=this;}}if(_47){this._qw._S._xv.ShowBar(_47,e);}}else{this._qw._S._xv.HideBar();}}};CUIAxisMember.prototype.GetLastLeafDescendant=function(){var _KE=this._qw.GetUIReportObj();var _Ir=this.GetMemberPos()+_KE._m1;var _80=this.GetSiblingProxyCount();var _ad9=null;if(_KE._nf[_Ir+_80]&&_KE._nf[_Ir+_80][_KE._m8-1]){_ad9=_KE._nf[_Ir+_80][_KE._m8-1].axisMember;}return _ad9;};CUIAxisMember.prototype.EndHoverOver=function(){if(!this.GetAxisMember()){return;}this._iV=false;this.SetCellStyle();if(this.CanDrillUpOrDown()){CUIManager.HideDrillImage();var _MY=Dom.GetElementsByTagName(this._aA,"A");for(var i=0;i<_MY.length;i++){if(_MY[i]._jX){_MY[i].style.cursor="default";}}}};CUIAxisMember.prototype.SetFocus=function(){Dom.SetFocus(Dom.GetElementsByTagName(this._aA,"A")[0]);};CUIAxisMember.prototype.IsProxy=function(){return false;};CUIAxisMember.prototype.IsSiblingProxy=function(){return false;};CUIAxisMember.prototype.IsChildProxy=function(){return false;};CUIAxisMember.prototype.DrillUp=function(){var _IU=this.GetAxisMember();if(_IU){_IU.DrillUp();}else{Debug.Assert(false);}};CUIAxisMember.prototype.DrillDown=function(){var _IU=this.GetAxisMember();if(_IU){_IU.DrillDown();}else{Debug.Assert(false);}};CUIAxisMember.prototype.ReplaceLevelWithMember=function(_F8,_Hb,_J3,_R1,_yL){if(!this.GetBlock()){Debug.Assert(false);return;}this.GetBlock().DoReplace(_F8,_Hb,_J3,_R1,_yL);};CUIAxisMember.prototype.SetCellStyle=function(){var _IU=this.GetAxisMember();if((!_IU)||(!this._aA)){return;}var _au1=this._aA.className;var _Re=_au1.indexOf("Block");var _2R=null;if(_Re>-1){_2R=_au1.substring(_Re);}var _1y=this.GetParent();while(_1y&&_1y.GetParent()){_1y=_1y.GetParent();}var _E3='';if(_IU.IsSummaryOrNestedSummary()){this.bIsInnerTotal=(_1y&&(!(_1y.IsSummaryOrNestedSummary())))?true:false;_E3=this.IsCalc()?"cl ":"";if(this.bIsInnerTotal){_E3+="il MemberCellTotal";}else{_E3+="ol MemberCellTotal";}if(this._iV){_E3+="Hover";}}else if(_IU.IsSubtotal()){if(this._iV){_E3="sl MemberCellSubtotalHover";}else{_E3="sl MemberCellSubtotal";}}else if(_IU.IsExcludedSubtotal()){if(this._iV){_E3="xl ExcludeSubtotalHover";}else{_E3="xl ExcludeSubtotal";}}else if(_IU.IsNotExcludedSubtotal()){if(this._iV){_E3="nl IncludeSubtotalHover";}else{_E3="nl IncludeSubtotal";}}else if(_IU.IsRemainder()){_E3="hl MemberCell";if(this._iV){_E3+="Hover";}}else if(_IU.IsCalc()){_E3="cl MemberCell";if(this._iV){_E3+="Hover";}}else{if(this._iV){_E3="ml MemberCellHover";}else{_E3="ml MemberCell";}}if(this._b0==CUIAxisMember.eMemberSelected){_E3+=" PrimarySelection";}else if(this._b0==CUIAxisMember.eParentMemberSelected){_E3+=" SecondarySelection";}else if(this._b0==CUIAxisMember.eDataCellSelected){_E3+=" TertiarySelection";}this._aA.className=_E3;if(_2R){var _avK=_2R.indexOf("HL");var _azl,_acD;if(_avK>-1){_azl=_2R;var re=/HL/g;_acD=_2R.replace(re,'');}else{_acD=_2R;var re=/Edge/g;_azl=_2R.replace(re,'EdgeHL');}if(this._sh){_E3+=" "+_azl;this.SetSharedBorderStyle(this._aA,true);}else{_E3+=" "+_acD;this.SetSharedBorderStyle(this._aA,false);}}if(_IU._tg){_E3+=" NoDataModeDummyMember";}this._aA.className=_E3;var _MY=Dom.GetElementsByTagName(this._aA,'A');if(_MY){for(var x=0;x<_MY.length;x++){if(_MY[x].ansType!="Property"){if(this._iV&&(this.CanDrillUpOrDown())){_MY[x].style.textDecoration='underline';}else{_MY[x].style.textDecoration='none';}if(_IU.IsInvalidCalc()){if(this._b0==CUIAxisMember.eMemberSelected){_MY[x].className="inValidOperandSelected";}else{_MY[x].className="inValidOperand";}}}else{if(this._b0==CUIAxisMember.eMemberSelected){_MY[x].className='Property_selected';}else{_MY[x].className='Property';}}}}};CUIAxisMember.prototype.SetIndent=function(){if(this._qw.IsRowAxis()){var _alS=this._qw.GetUIReportObj()._la;var _anh=this._sw!=null?this._sw:this.GetIndentWidth();COTStyle.SetPaddingLeft(this.GetHtmlElement(),_alS+_anh);COTStyle.AddCSSClassToEle(this.GetHtmlElement(),"SecondClass");}};CUIAxisMember.prototype.SetBlockSelectorPadding=function(){if(this._lX){if(this._qw.IsRowAxis()){var _Zt=this._qw.GetUIReportObj()._cz;COTStyle.SetPaddingTop(this.GetHtmlElement(),_Zt+CUICrosstab.kiBlockSelectorStaticDimension);COTStyle.AddCSSClassToEle(this.GetHtmlElement(),"SecondClass");}else{var _alS=this._qw.GetUIReportObj()._la;COTStyle.SetPaddingLeft(this.GetHtmlElement(),_alS+CUICrosstab.kiBlockSelectorStaticDimension);COTStyle.AddCSSClassToEle(this.GetHtmlElement(),"SecondClass");}}};CUIAxisMember.prototype.GetIndentWidth=function(){var _IU=this.GetAxisMember();if(this.GetBlock()&&this.GetBlock().IsHierarchyEnabled()){var _anh=0;var _agR=_IU.GetBlock().GetMinSumLevel();var _aqh=this.GetSummaryLevel();if(!_IU.IsCalc()&&_aqh){_anh=(_aqh-_agR)*CUICrosstab.kiIndentWidth;}this._sw=_anh;}else if(_IU&&(_IU.IsRemainder()||(_IU.IsSubtotal()&&!_IU.GetBlock().IsHAMC()))){this._sw=CUICrosstab.kiIndentWidth;}else{this._sw=0;}return this._sw;};CUIAxisMember.prototype.SetRightBorder=function(_Vl,x,_Su){var _KE=this._qw.GetUIReportObj();if(_Su&&x==_KE._m1-1){COTStyle.AddCSSClassToEle(_Vl,"BlockRightEdge");_Vl._lO=true;}else if(!_Su&&x==_KE._t7+_KE._m1-1){var _aoS=this.GetHtmlElement();COTStyle.AddCSSClassToEle(_aoS,"BlockRightEdge");_aoS._lO=true;}};CUIAxisMember.prototype.SetRowAxisBlockBorder=function(_Vl,x,y){var _KE=this._qw.GetUIReportObj();var _Su=true;if(x==0){COTStyle.AddCSSClassToEle(_Vl,"BlockLeftEdge");}this.SetRightBorder(_Vl,x,_Su);if(x>0){var _aH6=_KE._nf[x-1][y].axisMember.GetBlock();if(_aH6!=this.GetBlock()){var _ayc=_KE._nf[x-1][y].axisMember.GetHtmlElement();COTStyle.AddCSSClassToEle(_ayc,"BlockRightEdge");_ayc._lO=true;if(_ayc._sq){this._qw._pa[this._qw._pa.length]=_ayc;}Dom.SetObjRef(_Vl,_ayc,"LNeighbor");_Vl._dN=true;}}if(y==_KE._m8){COTStyle.AddCSSClassToEle(_Vl,"BlockTopEdge");_Vl._sq=true;if(_Vl._lO){this._qw._pa[this._qw._pa.length]=_Vl;}}if(y>_KE._m8){if(_KE._nf[x][y-1]){var _alF=_KE._nf[x][y-1].axisMember;var _aDe=_alF.GetHtmlElement();var _apR=_alF.GetBlock();if(this.GetBlock()==_apR&&(this.GetBlock().IsGroupedDescendantsAtDepth()||this.GetBlock().IsOuterNestedBlock())){if(this.GetChildProxyCount()>_alF.GetChildProxyCount()){for(var i=1;i<=this.GetChildProxyCount();i++){_aDe=_KE._nf[x+i][y-1].axisMember.GetHtmlElement();COTStyle.AddCSSClassToEle(_aDe,"BlockBottomEdge");}}}else if(_apR!=this.GetBlock()){COTStyle.AddCSSClassToEle(_aDe,"BlockBottomEdge");if(this.GetChildProxyCount()>0){for(var i=1;i<=this.GetChildProxyCount();i++){_aDe=_KE._nf[x+i][y-1].axisMember.GetHtmlElement();COTStyle.AddCSSClassToEle(_aDe,"BlockBottomEdge");}}_Vl._sq=true;if(_Vl._lO){this._qw._pa[this._qw._pa.length]=_Vl;}Dom.SetObjRef(_Vl,_aDe,'TNeighbor');}}}if(this._f1._un){this._qw._eA[this._qw._eA.length]=_Vl;}this.SetBottomBorder(_Vl,y,_Su);};CUIAxisMember.prototype.SetBottomBorder=function(_Vl,y,_Su){var _KE=this._qw.GetUIReportObj();if(_Su&&y==_KE._og+_KE._m8-1){COTStyle.AddCSSClassToEle(_Vl,"BlockBottomEdge");_Vl._dU=true;}else if(!_Su&&y==_KE._m8-1){COTStyle.AddCSSClassToEle(_Vl,"BlockBottomEdge");_Vl._dU=true;}};CUIAxisMember.prototype.SetColAxisBlockBorder=function(_Vl,x,y){var _KE=this._qw.GetUIReportObj();var _Su=false;if(y==0){COTStyle.AddCSSClassToEle(_Vl,"BlockTopEdge");_Vl._sq=true;}this.SetBottomBorder(_Vl,y,_Su);if(y>0){var _akx=_KE._nf[x][y-1].axisMember.GetBlock();if(_akx!=this.GetBlock()){var _alF=_KE._nf[x][y-1].axisMember.GetHtmlElement();COTStyle.AddCSSClassToEle(_alF,"BlockBottomEdge");_alF._dU=true;_Vl._sq=true;if(_Vl._dN){this._qw._pa[this._qw._pa.length]=_Vl;}Dom.SetObjRef(_Vl,_alF,'TNeighbor');if(_alF._dN){this._qw._pa[this._qw._pa.length]=_alF;}}}if(x==_KE._m1){COTStyle.AddCSSClassToEle(_Vl,"BlockLeftEdge");_Vl._dN=true;if(_Vl._sq){this._qw._pa[this._qw._pa.length]=_Vl;}}if(x>_KE._m1){if(_KE._nf[x-1]&&_KE._nf[x-1][y]){var _axA=_KE._nf[x-1][y].axisMember;var _ard=_axA.GetHtmlElement();var _aH6=_KE._nf[x-1][y].axisMember.GetBlock();if(this.GetBlock()==_aH6&&(this.GetBlock().IsGroupedDescendantsAtDepth()||this.GetBlock().IsOuterNestedBlock())){if(this.GetChildProxyCount()>_axA.GetChildProxyCount()){for(var i=1;i<=this.GetChildProxyCount();i++){_ard=_KE._nf[x-1][y+i].axisMember.GetHtmlElement();COTStyle.AddCSSClassToEle(_ard,"BlockRightEdge");}}}else if(_aH6!=this.GetBlock()){COTStyle.AddCSSClassToEle(_ard,"BlockRightEdge");if(this.GetChildProxyCount()>0){for(var i=1;i<=this.GetChildProxyCount();i++){var _ard=_KE._nf[x-1][y+i].axisMember.GetHtmlElement();COTStyle.AddCSSClassToEle(_ard,"BlockRightEdge");}}_Vl._dN=true;if(_Vl._sq){this._qw._pa[this._qw._pa.length]=_Vl;}Dom.SetObjRef(_Vl,_ard,'LNeighbor');}}}this.SetRightBorder(_Vl,x,_Su);if(this._f1._un){this._qw._eA[this._qw._eA.length]=_Vl;}};CUIAxisMember.prototype.SetSharedBorderStyle=function(el,_TK){if(el.LNeighbor){if(_TK){var re=/BlockRightEdge/g;if(el.LNeighbor.className.indexOf("BlockRightEdgeHL")<0){el.LNeighbor.className=el.LNeighbor.className.replace(re,"BlockRightEdgeHL");}}else{var re=/BlockRightEdgeHL/g;if(el.LNeighbor.className.indexOf("BlockRightEdgeHL")>-1){el.LNeighbor.className=el.LNeighbor.className.replace(re,"BlockRightEdge");}}}if(el.TNeighbor){if(_TK){var re=/BlockBottomEdge/g;if(el.TNeighbor.className.indexOf("BlockBottomEdgeHL")<0){el.TNeighbor.className=el.TNeighbor.className.replace(re,'BlockBottomEdgeHL');}}else{var re=/BlockBottomEdgeHL/g;if(el.TNeighbor.className.indexOf("BlockBottomEdgeHL")>-1){el.TNeighbor.className=el.TNeighbor.className.replace(re,'BlockBottomEdge');}}}};function ActiveDZ(_Jf,_B7){this.iCol=_Jf;this.iRow=_B7;};CUIAxisMember.SafeDoHighlightBlockMembers=function(axisMember){/*@if(!@bering_debug)@*/try{/*@end@*/if(axisMember){axisMember.GetAxis().HighlightBlockMembers(axisMember);}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIAxisMember.SafeDoEndHighlightBlockMembers=function(axisMember){/*@if(!@bering_debug)@*/try{/*@end@*/if(axisMember){axisMember.GetAxis().EndHighlightBlockMembers(axisMember);}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIAxisMember.SafeDoHighlightBlock=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(this._vd.axisMember){this._vd.axisMember.GetAxis().HighlightBlock(this._vd.axisMember,true);}/*@if(!@bering_debug)@*/}catch(excep){_f.HandleException(excep);}/*@end@*/};CUIAxisMember.prototype.SetBlockHighlighted=function(_TK){this._sh=_TK;};CUIAxisMember.SafeDoSetNormalBlock=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(this._vd.axisMember){this._vd.axisMember.GetAxis().HighlightBlock(this._vd.axisMember,false);}/*@if(!@bering_debug)@*/}catch(excep){_f.HandleException(excep);}/*@end@*/};CUIAxisMember.prototype.GetSuppressionID=function(){return this._f1._un;};CUIAxisMemberProxy.eSiblingProxy=0;CUIAxisMemberProxy.eChildProxy=1;function CUIAxisMemberProxy(_zC,_De,_Pf){this._xH=_zC;this._qL=_De;this._g8=_Pf;};CUIAxisMemberProxy.prototype.GetUIAxisMember=function(){return this._xH;};CUIAxisMemberProxy.prototype.Refresh=function(){this._xH.Refresh();};CUIAxisMemberProxy.prototype.GetAxis=function(){return this._xH.GetAxis();};CUIAxisMemberProxy.prototype.CanHide=function(){return this._xH.CanHide();};CUIAxisMemberProxy.prototype.CanDelete=function(){return this._xH.CanDelete();};CUIAxisMemberProxy.prototype.CanExclude=function(){return this._xH.CanExclude();};CUIAxisMemberProxy.prototype.IsSummaryMemOrCalc=function(){return this._xH.IsSummaryMemOrCalc();};CUIAxisMemberProxy.prototype.IsSummaryMem=function(){return this._xH.IsSummaryMem();};CUIAxisMemberProxy.prototype.IsSummaryOrNestedSummary=function(){return this._xH.IsSummaryOrNestedSummary();};CUIAxisMemberProxy.prototype.IsDynamicCalc=function(){return this._xH.IsDynamicCalc();};CUIAxisMemberProxy.prototype.IsMemberBasedCalc=function(){return this._xH.IsMemberBasedCalc();};CUIAxisMemberProxy.prototype.GetChildProxyCount=function(){return this._xH.GetChildProxyCount();};CUIAxisMemberProxy.prototype.SetChildProxyCount=function(_EK){this._xH.SetChildProxyCount(_EK);};CUIAxisMemberProxy.prototype.GetSiblingProxyCount=function(){return this._xH.GetSiblingProxyCount();};CUIAxisMemberProxy.prototype.SetSiblingProxyCount=function(_C3){this._xH.SetSiblingProxyCount(_C3);};CUIAxisMemberProxy.prototype.GetLabel=function(){return this._xH.GetAxisMember().GetLabel();};CUIAxisMemberProxy.prototype.GetPropertyCount=function(){return this._f1.GetPropertyCount();};CUIAxisMemberProxy.prototype.GetUniqueID=function(){return this._xH.GetUniqueID();};CUIAxisMemberProxy.prototype.GetSummaryLevel=function(){return this._xH.GetSummaryLevel();};CUIAxisMemberProxy.prototype.IsCalc=function(){return this._xH.IsCalc();};CUIAxisMemberProxy.prototype.IsNoItemsNode=function(){return this._xH.IsNoItemsNode();};CUIAxisMemberProxy.prototype.CanDrillUpOrDown=function(){return this._xH.CanDrillUpOrDown();};CUIAxisMemberProxy.prototype.isDrillable=function(){return this._xH.isDrillable();};CUIAxisMemberProxy.prototype.CanDrillUp=function(){return this._xH.CanDrillUp();};CUIAxisMemberProxy.prototype.CanDoSecondaryDrillUp=function(){return this._xH.CanDoSecondaryDrillUp();};CUIAxisMemberProxy.prototype.CanDoSecondaryDrillDown=function(){return this._xH.CanDoSecondaryDrillDown();};CUIAxisMemberProxy.prototype.CanDrillDown=function(){return this._xH.CanDrillDown();};CUIAxisMemberProxy.prototype.GetMemberId=function(){return this._xH.GetMemberId();};CUIAxisMemberProxy.prototype.SetMemberSelected=function(_RM){return this._xH.SetMemberSelected(_RM);};CUIAxisMemberProxy.prototype.SetSecondarySelection=function(){return this._xH.SetSecondarySelection();};CUIAxisMemberProxy.prototype.SetTertiarySelection=function(){return this._xH.SetTertiarySelection();};CUIAxisMemberProxy.prototype.IsMemberSelected=function(){return this._xH.IsMemberSelected();};CUIAxisMemberProxy.prototype.SetFocus=function(){return this._xH.SetFocus();};CUIAxisMemberProxy.prototype.IsSelected=function(){return this._xH.IsSelected();};CUIAxisMemberProxy.prototype.SetHtmlElement=function(_J6){this._xH.SetHtmlElement(_J6);};CUIAxisMemberProxy.prototype.GetHtmlElement=function(){return this._xH.GetHtmlElement();};CUIAxisMemberProxy.prototype.SetAxisMember=function(_zU){this._xH.SetAxisMember(_zU);};CUIAxisMemberProxy.prototype.GetAxisMember=function(){return this._xH.GetAxisMember();};CUIAxisMemberProxy.prototype.GetFirstChild=function(){return this._xH.GetFirstChild();};CUIAxisMemberProxy.prototype.GetParent=function(){return this._xH.GetParent();};CUIAxisMemberProxy.prototype.Next=function(){return this._xH.Next();};CUIAxisMemberProxy.prototype.Previous=function(){return this._xH.Previous();};CUIAxisMemberProxy.prototype.SetMemberPos=function(x){this._xH.SetMemberPos(x);};CUIAxisMemberProxy.prototype.GetMemberPos=function(){return this._xH.GetMemberPos();};CUIAxisMemberProxy.prototype.GetProxySpecificPos=function(){return this._g8;};CUIAxisMemberProxy.prototype.GetDepth=function(){return this._xH.GetDepth();};CUIAxisMemberProxy.prototype.HoverOver=function(){this._xH.HoverOver();};CUIAxisMemberProxy.prototype.EndHoverOver=function(){this._xH.EndHoverOver();};CUIAxisMemberProxy.prototype.ShowDZRow=function(_B7){this._xH.ShowDZRow(_B7);};CUIAxisMemberProxy.prototype.ShowDZCol=function(_Jf){this._xH.ShowDZCol(_Jf);};CUIAxisMemberProxy.prototype.ShowAllDZs=function(){this._xH.ShowAllDZs();};CUIAxisMemberProxy.prototype.HideAllDZs=function(){this._xH.HideAllDZs();};CUIAxisMemberProxy.prototype.GetBlock=function(){return this._xH.GetBlock();};CUIAxisMemberProxy.prototype.GetChildrenLength=function(){return this._xH.GetChildrenLength();};CUIAxisMemberProxy.prototype.IsProxy=function(){return true;};CUIAxisMemberProxy.prototype.IsSiblingProxy=function(){return this._qL==CUIAxisMemberProxy.eSiblingProxy;};CUIAxisMemberProxy.prototype.IsChildProxy=function(){return this._qL==CUIAxisMemberProxy.eChildProxy;};CUIAxisMemberProxy.prototype.DrillUp=function(){this._f1.DrillUp();};CUIAxisMemberProxy.prototype.DrillDown=function(){this._xH.DrillDown();};CUIAxisMemberProxy.prototype.ReplaceLevelWithMember=function(_F8,_Hb,_R1){this._xH.ReplaceLevelWithMember(_F8,_Hb,_R1);};CUIAxisMemberProxy.prototype.SetCellStyle=function(){this._xH.SetCellStyle();};CUIAxisMemberProxy.prototype.SetBlockHighlighted=function(_TK){this._xH.SetBlockHighlighted(_TK);};CUIAxisMemberProxy.prototype.SetColAxisBlockBorder=function(_Vl,x,y){this._xH.SetColAxisBlockBorder(_Vl,x,y);};CUIAxisMemberProxy.prototype.SetRowAxisBlockBorder=function(_Vl,x,y){this._xH.SetRowAxisBlockBorder(_Vl,x,y);};function CUICellMap(_G0,_Fh){this._r5=new Array();this._w5=_G0;this._dO=_Fh;this._fX=null;this._jl=null;this._w5.GetDataWorkSheet()._ak.Subscribe(this,ExpEvent.kCDLCrosstab_Create);this._w5.GetDataWorkSheet()._ak.Subscribe(this,ExpEvent.kCDLDataManager_DataMatrixCreate);this._eU=new Object();this._mk=document.createElement('TD');};CUICellMap.prototype.Refresh=function(){Utilities.DeleteAllFromArray(this._r5);Utilities.ClearObjectArray(this._eU);};CUICellMap.prototype.HasData=function(){if(this._jl&&this._jl.IsComplete()){return true;}return false;};CUICellMap.prototype.GetCell=function(x,y,_I5){if(this._r5[x]&&this._r5[x][y]){return this._r5[x][y];}else{var _FT;/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oGetCell.StartTimer(true);}/*@end@*/var _Pg=this._fX.GetCell(y,x);var _arw=false;if(_Pg._uJ!=ExpAPIXml.kStatusOK){_arw=true;}_FT=_Pg._jU;var _aHH=_o.is_ie5_5up;if(_aHH){var _9I=this.GetCellInnerHTML();var _Vl=document.createElement(_9I);_Vl.bRowSel=false;_Vl.bColSel=false;_Vl.bDragOver=false;_Vl.bCalc=false;_Vl.bRemainder=false;_Vl.bExclSubtotal=false;_Vl.bInclSubtotal=false;_Vl.bSubtotalItems=false;_Vl.bIsInnerTotal=false;_Vl.bIsTotal=false;_Vl.bDrillable=false;_Vl.bDrillUp=false;_Vl.bDependOnParentMember=_arw;_Vl.status=_Pg._uJ;_Vl.x=x;_Vl.y=y;if(this._dO._aF){if(Utilities.bCharBasedTruncation){_Vl.value=_FT;if((_FT!="")&&_I5&&(_FT.length>_I5)){_Vl.title=_FT;_FT=Utilities.GetTruncatedString(_FT,_I5-3,this._dO._sp);}}else{_Vl.title=_FT;}}_Vl.appendChild(document.createTextNode(_FT));this.AddCell(_Vl,x,y);/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oGetCell.StopTimer();}/*@end@*/return _Vl;}/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oGetCell.StopTimer();g_oCloneNode.StartTimer(true);}/*@end@*/var _Vl=this._mk.cloneNode(false);/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oCloneNode.StopTimer();g_oSetProps.StartTimer(true);}/*@end@*/if(this._dO._aF){if(Utilities.bCharBasedTruncation){_Vl.value=_FT;if((_FT!="")&&_I5&&(_FT.length>_I5)){_Vl.title=_FT;_FT=Utilities.GetTruncatedString(_FT,_I5-3,this._dO._sp);}}else{_Vl.title=_FT;}}_Vl.bRowSel=false;_Vl.bColSel=false;_Vl.bDragOver=false;_Vl.bCalc=false;_Vl.bRemainder=false;_Vl.bExclSubtotal=false;_Vl.bInclSubtotal=false;_Vl.bSubtotalItems=false;_Vl.bIsInnerTotal=false;_Vl.bIsTotal=false;_Vl.bDrillable=false;_Vl.bDrillUp=false;_Vl.cellType=CUICrosstab.kDataCell;_Vl.x=x;_Vl.y=y;_Vl.status=_Pg._uJ;_Vl.bDependOnParentMember=_arw;/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oSetProps.StopTimer();g_oAppendTextNode.StartTimer(true);}/*@end@*/if(!_Vl.bDependOnParentMember){_Vl.appendChild(document.createTextNode(_FT));}/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oAppendTextNode.StopTimer();}/*@end@*/this.AddCell(_Vl,x,y);return _Vl;}};CUICellMap.prototype.AddCell=function(_Aq,x,y){if(!this._r5[x]){this._r5[x]=new Array();}this._r5[x][y]=_Aq;};CUICellMap.prototype.GetCentralMeasureLabel=function(){var _BM="";if(this._jl){var _aG1=this._jl.GetDefMeasurePresentationType();switch(_aG1){case ExpAPIXml.kDefMeaActivePretType:case ExpAPIXml.kDefMeaSecondaryActivePretType:case ExpAPIXml.kDefMeaInactivePretType:_BM=this._jl.GetCurrentMeasureLabel();break;case ExpAPIXml.kDefMeaNonePretType:break;case ExpAPIXml.kDefMeaSecondaryNonePretType:case ExpAPIXml.kDefMeaTemplatePretType:_BM=this._dO._sp.GetString('IDS_CROSSTAB_BASIC_MEASURE_TEMPLATE');break;}}return _BM;};CUICellMap.prototype.GetCentralMeasurePresentationType=function(){return this._jl.GetDefMeasurePresentationType();};CUICellMap.prototype.CentralMeasureExists=function(){if(!this._jl||!this._jl.GetCurrentMeasure()){return false;}return true;};CUICellMap.prototype.GetNumCols=function(){return this._r5.length;};CUICellMap.prototype.GetNumOfVisibleCols=function(){return Math.min(this._r5.length,this._dO._bz.GetNumberOfVisibleUnits());};CUICellMap.prototype.GetNumRows=function(){for(var i=0;i<this.GetNumCols();++i){if(this._r5[i]){return this._r5[i].length;}}return 0;};CUICellMap.prototype.GetNumOfVisibleRows=function(){for(var i=0;i<this.GetNumCols();++i){if(this._r5[i]){return Math.min(this._r5[i].length,this._dO._ax.GetNumberOfVisibleUnits());}}return 0;};CUICellMap.prototype.SelectRow=function(_B7){var _aGe=this._dO._nj;for(var i=_aGe;i<this.GetNumOfVisibleCols()+_aGe;++i){if(this._r5[i]&&this._r5[i][_B7]){var _Pg=this._r5[i][_B7];if(_Pg&&_Pg.cellType!=CUICrosstab.kDataCellTemplate){_Pg.bRowSel=true;this.SetCellStyle(_Pg);}}}};CUICellMap.prototype.SelectCol=function(_Jf){var _36=this._dO._rz;for(var i=_36;i<this.GetNumOfVisibleRows()+_36;++i){if(this._r5[_Jf]&&this._r5[_Jf][i]){var _Pg=this._r5[_Jf][i];if(_Pg&&_Pg.cellType!=CUICrosstab.kDataCellTemplate){_Pg.bColSel=true;this.SetCellStyle(_Pg);}}}};CUICellMap.prototype.UnselectRow=function(_B7){var _aGe=this._dO._nj;for(var i=_aGe;i<this.GetNumOfVisibleCols()+_aGe;++i){if(this._r5[i]&&this._r5[i][_B7]){var _Pg=this._r5[i][_B7];_Pg.bRowSel=false;this.SetCellStyle(_Pg);}}};CUICellMap.prototype.UnselectCol=function(_Jf){var _36=this._dO._rz;for(var i=_36;i<this.GetNumOfVisibleRows()+_36;++i){if(this._r5[_Jf]&&this._r5[_Jf][i]){var _Pg=this._r5[_Jf][i];_Pg.bColSel=false;this.SetCellStyle(_Pg);}}};CUICellMap.prototype.UnselectAllCells=function(){var _36=this._dO._rz;var _aGe=this._dO._nj;for(var i=_aGe;i<this.GetNumOfVisibleCols()+_aGe;i++){for(var j=_36;j<this.GetNumOfVisibleRows()+_36;j++){if(this._r5[i]&&this._r5[i][j]){_Pg=this._r5[i][j];_Pg.bColSel=false;_Pg.bRowSel=false;this.SetCellStyle(_Pg);}}}};CUICellMap.prototype.SelectAllCells=function(){var _36=this._dO._rz;var _aGe=this._dO._nj;for(var i=_aGe;i<this.GetNumOfVisibleCols()+_aGe;i++){for(var j=_36;j<this.GetNumOfVisibleRows()+_36;j++){if(this._r5[i]&&this._r5[i][j]){_Pg=this._r5[i][j];if(_Pg.cellType!=CUICrosstab.kDataCellTemplate){_Pg.bColSel=true;this.SetCellStyle(_Pg);}}}}};CUICellMap.prototype.ReselectSelectAllCells=function(){this.UnselectAllCells();this.SelectAllCells();};CUICellMap.prototype.HighlightDropZone=function(){if(this._dO._nG){var _Pg=this._r5[0][0];_Pg.bDragOver=true;this.SetCellStyle(_Pg);return;}var _aGe=this._dO._nj;var _36=this._dO._rz;for(var i=_aGe;i<this.GetNumOfVisibleCols()+_aGe;i++){for(var j=_36;j<this.GetNumOfVisibleRows()+_36;j++){if(this._r5[i]&&this._r5[i][j]){var _Pg=this._r5[i][j];if(!_Pg.bDragOver){_Pg.bDragOver=true;this.SetCellStyle(_Pg);}}}}};CUICellMap.prototype.HideDropZone=function(){if(this._dO._nG){var _Pg=this._r5[0][0];_Pg.bDragOver=false;this.SetCellStyle(_Pg);return;}var _aGe=this._dO._nj;var _36=this._dO._rz;for(var i=_aGe;i<this.GetNumOfVisibleCols()+_aGe;i++){for(var j=_36;j<this.GetNumOfVisibleRows()+_36;j++){if(this._r5[i]&&this._r5[i][j]){var _Pg=this._r5[i][j];_Pg.bDragOver=false;this.SetCellStyle(_Pg);}}}};CUICellMap.prototype.HoverOver=function(_yW,e){if(_yW.bDrillable){COTStyle.AddCSSClassToEle(_yW,"DataCellHover");_yW.bHover=true;var _Pv=ExpAPIXml.kActionDrillDown;if(_yW.bDrillUp){_Pv=ExpAPIXml.kActionDrillUp;}CUIManager.ShowDrillImage(_Pv,e.clientX,e.clientY);}if(this._dO._aF){this.ResizeingHoverOver(_yW,e);}};CUICellMap.prototype.ResizeingHoverOver=function(_yW,e){if(this._dO._xv.m_bDragging){return;}if(_yW.x==this._dO._nj){return;}var _aFJ=this._dO._bz.GetMember(_yW.x,this._dO._m8-1);if(_aFJ){var _agF=_aFJ.GetHtmlElement();var _2s=e.clientX;var _Qb=Dom.GetRelativeOffset(_agF,document.body);var _aEs=_Qb.iLeft;var _7G=_Qb.iLeft+_agF.offsetWidth;if(((_2s-_aEs)<5)||((_7G-_2s)<5)){var _Vl=_agF;if((_2s-_aEs)<5){var _akU=_aFJ.Previous();if(_akU){this._dO._xv.ShowBar(_akU,e);}}else{this._dO._xv.ShowBar(_aFJ,e);}}else{this._dO._xv.HideBar();}}};CUICellMap.prototype.EndHoverOver=function(_yW,e){this.SetCellStyle(_yW);_yW.bHover=false;if(_yW.bDrillable){CUIManager.HideDrillImage();}};CUICellMap.prototype.SetCellStyle=function(_Pg){var _E3="";if(_Pg.cellType==CUICrosstab.kDataCellTemplate){_E3="DataCellTemplate";}else if(_Pg.cellType==CUICrosstab.kNoDataModeCellTemplate){_E3="NoDataModeCellTemplate";}else if(_Pg.status!=ExpAPIXml.kStatusOK){_E3="mv DataCellInvalid";}else{var _aq3=_Pg.bCalc?"c2 ":"";_E3=_aq3;if(_Pg.bIsTotal){if(_Pg.bIsInnerTotal){_E3+="iv ";}else{_E3+="ov ";}_E3+="DataCell";}else{if(_Pg.bRemainder){_E3+="hv ";}if(_Pg.bSubtotalItems){_E3+="sv ";}if(_Pg.bInclSubtotal){_E3+="nv ";}if(_Pg.bExclSubtotal){_E3+="xv ";}if(_E3==""){_E3="mv ";}_E3+="DataCell";}}if(_Pg.bRowSel&&_Pg.bColSel){_E3+=" PrimarySelection";}else if(_Pg.bRowSel||_Pg.bColSel){_E3+=" SecondarySelection";}if(_Pg.bDrillable&&_Pg.bRowSel&&_Pg.bColSel){_E3+=" DrillableDataCell";}if(_Pg.bDragOver){_E3+=" DragOver";}_Pg.className=_E3;};CUICellMap.prototype.Notify=function(event){if(event==ExpEvent.kCDLCrosstab_Create){this._fX=this._w5.GetDataWorkSheet()._ak.GetCurrentCrosstab();}if(event==ExpEvent.kCDLDataManager_DataMatrixCreate){this._jl=this._w5.GetDataWorkSheet()._ak.GetCurrentDataMatrix();}};CUICellMap.prototype.GetCellInnerHTML=function(){var _5P='<TD cellType="4"></TD>';return _5P;};CUICellMap.prototype.CreateNoCellValueTemplate=function(){var _Vl=document.createElement('TD');_Vl.cellType=CUICrosstab.kNoDataModeCellTemplate;var _BC=Utilities.GenerateCallback(this._jl.ModifyDataModeProperty,[ExpAPIXml.kAttrFullDataMode],this._jl);var _acp=gResource.GetString("IDS_CROSSTAB_GET_DATA_FUNCTION");var _3f=COTInputElementFactory.CreateLink(_BC,_acp,false,'noDataModeFuncLink');_Vl.appendChild(_3f);this.AddCell(_Vl,0,0);return _Vl;};function CUIAbsBlockPropSet(_KS){this._jC=_KS;this._gn=new Array();this._eE=null;};CUIAbsBlockPropSet.prototype.Unload=function(){for(var i=0;i<this._gn.length;i++){for(var j=0;this._gn[i]&&j<this._gn[i].length;j++){this._gn[i][j].Unload();}}this._jC.oUIMgr.dataManager.GetCurrentDataMatrix().RemoveProxy(this.oProxyBlock);Utilities.RemoveAllChildObjects(this);};CUIAbsBlockPropSet.prototype.ClearChanges=function(){this._jC.oUIMgr.dataManager.GetCurrentDataMatrix().RemoveProxy(this.oProxyBlock);this.oProxyBlock=this._jC.oUIMgr.dataManager.GetCurrentDataMatrix().GetBlockProxy(this.oOriginalBlock);for(var i=0;i<this._gn.length;i++){for(var j=0;this._gn[i]&&j<this._gn[i].length;j++){this._gn[i][j].Unload();}}Utilities.DeleteAllFromArray(this._gn);this._eE=null;this._up=null;this.Init();};CUIAbsBlockPropSet.prototype.ClearSelections=function(){for(var i=0;i<this._gn.length;i++){for(var j=0;this._gn[i]&&j<this._gn[i].length;j++){if(this._gn[i][j].bSelected){this._gn[i][j].bHover=false;}this._gn[i][j].bSelected=false;this._gn[i][j].SetStyle();}}};CUIAbsBlockPropSet.prototype.GetConfirmMsgByChangeType=function(){return CUIBlockPropertiesPane.aConfirmMsg[CUIBlockPropertiesPane.kPropertyOnly];};CUIAbsBlockPropSet.prototype.CommitChanges=function(){CDLBlockTransaction.Commit(this.oProxyBlock,this.oOriginalBlock);};CUIAbsBlockPropSet.prototype.OnUpdateProperty=function(_BY){if(_BY){for(var i=0;i<this._gn.length;i++){for(var j=0;this._gn[i]&&j<this._gn[i].length;j++){if(this._gn[i][j].UpdatePropertyFromBlock){this._gn[i][j].UpdatePropertyFromBlock(this.oProxyBlock,false);}}}}var _aat=this.HasUncommittedChanges();this._jC.OnUpdateProperty(_aat);};CUIAbsBlockPropSet.prototype.Init=function(_K9){this._gb=new Array();if(_K9){this.oOriginalBlock=_K9;}this.oProxyBlock=this._jC.oUIMgr.dataManager.GetCurrentDataMatrix().GetBlockProxy(this.oOriginalBlock);};CUIAbsBlockPropSet.prototype.Draw=function(_EP){this._mP=new Array();for(var i=0;i<this._gn.length;i++){if(this._gn[i]){this.sParentId=_EP.id;var _FW=_EP.appendChild(document.createElement("TR"));this._mP[i]=_FW;var _abL=_FW.appendChild(document.createElement("TD"));_abL.appendChild(document.createTextNode(this._jC.oRes.GetString(this._gb[i])));_abL.className="BlockPropertyLineLabel BlockPropertyCell";COTStyle.SetWidth(_abL,100-CUIAbsBlockPropSet.kPropertyCellWidth,'%');this.drawProperties(_FW,i);}}if(this._mP[0]){var _44=Dom.GetElementsByTagName(this._mP[0],"TD");for(var i=0;i<_44.length;i++){_44[i].style.paddingTop="6px";}}};CUIAbsBlockPropSet.prototype.drawProperties=function(_FW,i){if(this._gn[i].length==0){return;}if(this._gn[i].length==1){var _ID=_FW.appendChild(document.createElement("TD"));_ID.className="BlockPropertyCell";this._gn[i][0].Draw(_ID);_ID.appendChild(document.createTextNode(" "));return;}var _ID=_FW.appendChild(document.createElement("TD"));_ID.className="BlockPropertyCell";var _aHj=new Array();for(var j=0;j<this._gn[i].length;j++){_aHj.push("param"+j);}var _avb=this._jC.oRes.ReplaceParamList('IDS_BLOCKPROP_PROP_LIST',_aHj);var _alq=this._jC.oRes.ParseStringForOrder(_avb,_aHj);var _5Z=0;for(var _aJl=0;_aJl<_alq.length;_aJl++){if(_alq[_aJl]){if(_alq[_aJl].sBefore){var _An=_ID.appendChild(document.createElement('SPAN'));_An.appendChild(document.createTextNode(_alq[_aJl].sBefore));_An.className="prop_div";}if(_5Z>0){_ID.appendChild(document.createTextNode(" "));}this._gn[i][_5Z].Draw(_ID);if(_alq[_aJl].sAfter){var _An=_ID.appendChild(document.createElement('SPAN'));_An.appendChild(document.createTextNode(_alq[_aJl].sAfter));_An.className="prop_div";}_5Z++;}}};CUIAbsBlockPropSet.kPropertyCellWidth=80;CUIAbsBlockPropSet.prototype.GetWidthForPropertyValues=function(){return Math.floor(this._jC.GetInternalWidth()*CUIAbsBlockPropSet.kPropertyCellWidth/100);};CUIAbsBlockPropSet.SafeDoUpdateCurrentProperty=function(_Ke,_Ja,_OT){/*@if(!@bering_debug)@*/try{/*@end@*/var _aDS=FindApp(_Ke).uiManager.oBlockPropsPane.GetCurrentPropSet();Debug.Assert(_aDS);if(_aDS){_aDS.UpdateCurrentProperty(_Ja,_OT);}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIAbsBlockPropSet.prototype.UpdateCurrentProperty=function(_Ja,_OT){if(this._eE&&this._eE.UpdateProperty&&_Ja!=null){this._eE.UpdateProperty(_Ja,_OT,true);}else if(this._eE&&this._eE.UpdatePropertyFromBlock){this._eE.UpdatePropertyFromBlock(this.oProxyBlock,true);}};CUIAbsBlockPropSet.prototype.HandleStateChange=function(_Oq){var _EP=document.getElementById(this.sParentId);if(_EP){var _aG0=Dom.GetElementsByTagName(_EP,"INPUT");for(var i=0;i<_aG0.length;i++){_aG0[i].disabled=_Oq;}}};CUIAbsBlockPropSet.prototype.HasUncommittedChanges=function(){var _aat=false;for(var i=0;i<this._gn.length;i++){for(var j=0;this._gn[i]&&j<this._gn[i].length;j++){if(this._gn[i][j].bChanged){_aat=true;break;}}}return _aat;};CUIAbsBlockPropSet.prototype.SetCurrentProp=function(_Bn){this._eE=_Bn;};CUIAbsBlockPropSet.prototype.PreSelectProp=function(_UO,_Kb,_CO){for(var i=0;i<this._gn.length;i++){for(var j=0;this._gn[i]&&j<this._gn[i].length;j++){if(this._gn[i][j]instanceof _UO){this._gn[i][j].bSelected=true;this._gn[i][j].SetStyle();if(_Kb){this._gn[i][j].UpdateProperty(_Kb);}if(_CO&&this._gn[i][j].oArrowImg){Dom.FireEvent(this._gn[i][j].oArrowImg,"onclick");}}}}};CUIAbsBlockPropSet.prototype.getContextLabels=function(){var _as2=this._jC.oUIMgr.dataManager.GetCurrentWSFilterSet();var _Bu=new Array();if(this.oProxyBlock&&this.oProxyBlock.IsLocked()){_Tu=this.oProxyBlock.GetLockContextBlockIds();var _JE=this._jC.oUIMgr.dataManager._kX;for(var i=0;i<_Tu.length;i++){var _FK=_JE.getBlock(_Tu[i]);var _ahr=_FK.GetContextLabel();if(_ahr){_Bu.push(_ahr);}}}else{var _zZ=_as2.GetDimFilters();for(var i=0;i<_zZ.length;i++){var _ahr=_zZ[i].GetBlock().GetContextLabel();if(_ahr){_Bu.push(_ahr);}}}return _Bu;};CUIBlockPropSet.eLockLine=1;CUIBlockPropSet.eDisplayLine=0;CUIBlockPropSet.eFilterLine=2;CUIBlockPropSet.eContextLine=3;CUIBlockPropSet.eSortLine=4;function CUIBlockPropSet(_KS){this.base=CUIAbsBlockPropSet;this.base(_KS);};CUIBlockPropSet.prototype=new CUIAbsBlockPropSet;CUIBlockPropSet.superclass=CUIAbsBlockPropSet.prototype;CUIBlockPropSet.prototype.Init=function(_K9){CUIBlockPropSet.superclass.Init.call(this,_K9);this._gb[CUIBlockPropSet.eLockLine]='';this._gb[CUIBlockPropSet.eDisplayLine]="IDS_BLOCK_PROPERTY_PANE_DISPLAY";this._gb[CUIBlockPropSet.eFilterLine]="IDS_BLOCK_PROPERTY_PANE_FILTER";this._gb[CUIBlockPropSet.eContextLine]="IDS_BLOCK_PROPERTY_PANE_CONTEXT";this._gb[CUIBlockPropSet.eSortLine]="IDS_BLOCK_PROPERTY_PANE_SORT";for(var i=0;i<5;i++){var _As=null;switch(i){case CUIBlockPropSet.eLockLine:if(COTValidation.BlockTypeToFeatureRules[this.oOriginalBlock.GetType()]['lock']||COTValidation.BlockTypeToFeatureRules[this.oOriginalBlock.GetType()]['measureattribute']||COTValidation.BlockTypeToFeatureRules[this.oOriginalBlock.GetType()]['topbottom']){this._gn[i]=new Array();_As=new CUILockProperty(this,this._gn[i].length);this._gn[i].push(_As);_As.Init();}break;case CUIBlockPropSet.eDisplayLine:this._gn[i]=new Array();if(COTValidation.BlockTypeToFeatureRules[this.oOriginalBlock.GetType()][ExpAPIXml.kEleAxisOpExprBlockSize]){_As=new CUIVisibleItemProperty(this,this._gn[i].length);this._gn[i].push(_As);_As.Init();}if(COTValidation.BlockTypeToFeatureRules[this.oOriginalBlock.GetType()]['hide']){_As=new CUIHiddenItemProperty(this,this._gn[i].length);this._gn[i].push(_As);_As.Init();}if(this.oOriginalBlock.CanApplyAutoSubtotals()){_As=new CUIAutoSummaryProperty(this,this._gn[i].length);this._gn[i].push(_As);_As.Init();}if(this.oOriginalBlock.IsInsideSuppressedAxis()){_As=new CUIMoreUnavailableProperty(this,this._gn[i].length);this._gn[i].push(_As);_As.Init();}if(COTValidation.BlockTypeToFeatureRules[this.oOriginalBlock.GetType()]['showattributes']){_As=new CUIAttributeProperty(this,this._gn[i].length);this._gn[i].push(_As);_As.Init();}if(this._gn[i].length==0){delete this._gn[i];}break;case CUIBlockPropSet.eFilterLine:if(COTValidation.BlockTypeToFeatureRules[this.oOriginalBlock.GetType()]['exclude']){this._gn[i]=new Array();_As=new CUITopBottomProperty(this,this._gn[i].length);this._gn[i].push(_As);_As.Init();_As=new CUIUserDefFltProperty(this,this._gn[i].length);this._gn[i].push(_As);_As.Init();_As=new CUIExcludedItemsProperty(this,this._gn[i].length);this._gn[i].push(_As);_As.Init();}break;case CUIBlockPropSet.eContextLine:this._gn[i]=new Array();var _Bu=this.getContextLabels();if(_Bu.length==0){_As=new CUIContextProperty(this,this._gn[i].length);this._gn[i].push(_As);_As.Init(this._jC.oRes.GetString('IDS_BLOCKPROP_CONTEXT_NONE'));}else{for(var j=0;j<_Bu.length;j++){if(_Bu[j]&&_Bu[j]instanceof Array){_As=new CUICompositContextProperty(this,this._gn[i].length);}else{_As=new CUIContextProperty(this,this._gn[i].length);}this._gn[i].push(_As);_As.Init(_Bu[j]);}}break;case CUIBlockPropSet.eSortLine:this._gn[i]=new Array();_As=new CUISortProperty(this,this._gn[i].length);this._gn[i].push(_As);_As.Init();break;}}};CUIBlockPropSet.prototype.Draw=function(_EP){this._mP=new Array();for(var i=0;i<this._gn.length;i++){if(this._gn[i]){this.sParentId=_EP.id;var _FW=_EP.appendChild(document.createElement("TR"));this._mP[i]=_FW;var _abL=_FW.appendChild(document.createElement("TD"));_abL.appendChild(document.createTextNode(this._jC.oRes.GetString(this._gb[i])));if(i==CUIBlockPropSet.eLockLine){_abL.className="BlockPropertyCell";_abL.colSpan=2;for(var j=0;j<this._gn[i].length;j++){this._gn[i][j].Draw(_abL);}}else{_abL.className="BlockPropertyLineLabel BlockPropertyCell";COTStyle.SetWidth(_abL,100-CUIAbsBlockPropSet.kPropertyCellWidth,'%');this.drawProperties(_FW,i);}}}if(this.oProxyBlock&&this.oProxyBlock.IsLocked()){var _Ss=true;this.ToggleLockRelatedProps(_Ss);}if(this._mP[0]){var _44=Dom.GetElementsByTagName(this._mP[0],"TD");for(var i=0;i<_44.length;i++){_44[i].style.paddingTop="6px";}}};CUIBlockPropSet.prototype.ToggleLockRelatedProps=function(_Ss){if(this._mP){if(_o.is_ie5_5up){this._mP[CUIBlockPropSet.eFilterLine].disabled=_Ss;this._mP[CUIBlockPropSet.eSortLine].disabled=_Ss;this._mP[CUIBlockPropSet.eContextLine].disabled=_Ss;}else{sModifiedCSSStr=_Ss?"disabledDIV_NS":"";this._mP[CUIBlockPropSet.eFilterLine].className=sModifiedCSSStr;this._mP[CUIBlockPropSet.eSortLine].className=sModifiedCSSStr;this._mP[CUIBlockPropSet.eContextLine].className=sModifiedCSSStr;}}};CUIBlockPropSet.prototype.HasUncommittedChanges=function(){var _aat=false;this._cP=true;this._up=false;this._mK=false;this._nw=false;for(var i=0;i<this._gn.length;i++){for(var j=0;this._gn[i]&&j<this._gn[i].length;j++){if(this._gn[i][j].bChanged){_aat=true;if(!(this._gn[i][j]instanceof CUIUserDefFltProperty)){this._cP=false;}}else{var _ano=this._jC.oUIMgr.oDialogMgr._jg;if(_ano&&_ano._r3){if((_ano instanceof CUIUserDefFilterDlg||_ano instanceof CUICombineFilterDlg)&&this._gn[i][j]instanceof CUIUserDefFltProperty){this._up=_ano.HasBeenChanged();}else if(_ano instanceof CUITopBottomDlg&&this._gn[i][j]instanceof CUITopBottomProperty){this._mK=true;}else if(_ano instanceof CUISortDlg&&this._gn[i][j]instanceof CUISortProperty){this._nw=true;}}}}}return(_aat||this._up||(_aat&&this._mK)||(_aat&&this._nw));};CUIBlockPropSet.prototype.GetConfirmMsgByChangeType=function(){var _1B=CUIBlockPropertiesPane.kPropertyOnly;if(this._up&&this._cP){_1B=CUIBlockPropertiesPane.kFltDlgOnly;}else if(this._up){_1B=CUIBlockPropertiesPane.kPropertyAndFltDlg;}else if(this._mK){_1B=CUIBlockPropertiesPane.kPropertyAndTBDlg;}else if(this._nw){_1B=CUIBlockPropertiesPane.kPropertyAndSortDlg;}return CUIBlockPropertiesPane.aConfirmMsg[_1B];};function CUINoSelPropSet(_KS){this.base=CUIAbsBlockPropSet;this.base(_KS);};CUINoSelPropSet.prototype=new CUIAbsBlockPropSet;CUINoSelPropSet.superclass=CUIAbsBlockPropSet.prototype;CUINoSelPropSet.eMeasureLine=0;CUINoSelPropSet.prototype.Init=function(){var _amH=this._jC.oUIMgr.GetCurrentWorkSheet();if(_amH!=this.oUIWS){this.oUIWS=this._jC.oUIMgr.GetCurrentWorkSheet();}var _ag6=this.oUIWS.GetUIAxesContainer();var _afq=this._jC.oUIMgr.dataManager.GetCurrentDataMatrix().GetAxisCount();this._gb=new Array();this._gb[CUINoSelPropSet.eMeasureLine]="IDS_BLOCK_PROPERTY_PANE_DEF_MEASURE";for(var i=1;i<_afq+1;i++){var _ady=_ag6.GetUIAxis(i-1).GetResourceSuffix();this._gb[i]=this._jC.oRes.GetString('IDS_BLOCKPROP_'+_ady);}this._gb.push("IDS_BLOCK_PROPERTY_PANE_CONTEXT");CUINoSelPropSet.eContextLine=this._gb.length-1;this._gb.push("IDS_BLOCK_PROPERTY_PANE_REPORT_OPTIONS");CUINoSelPropSet.eReportLine=this._gb.length-1;var _N5=this.oUIWS.oContextBar;var _As=null;for(var i=0;i<3+_afq;i++){switch(i){case CUINoSelPropSet.eMeasureLine:this._gn[i]=new Array();_As=new CUIMeasureProperty(this,this._gn[i].length);this._gn[i].push(_As);_As.Init();_As=new CUIShowValuesAsProperty(this,this._gn[i].length);this._gn[i].push(_As);_As.Init();break;case CUINoSelPropSet.eContextLine:this._gn[i]=new Array();var _Bu=this.getContextLabels();if(_Bu.length==0){_As=new CUIContextProperty(this,this._gn[i].length);this._gn[i].push(_As);_As.Init(this._jC.oRes.GetString('IDS_BLOCKPROP_CONTEXT_NONE'));}else{for(var j=0;j<_Bu.length;j++){if(_Bu[j]&&_Bu[j]instanceof Array){_As=new CUICompositContextProperty(this,this._gn[i].length);}else{_As=new CUIContextProperty(this,this._gn[i].length);}this._gn[i].push(_As);_As.Init(_Bu[j]);}}break;case CUINoSelPropSet.eReportLine:this._gn[i]=new Array();_As=new CUIReportOptionsProperty(this,this._gn[i].length);this._gn[i].push(_As);_As.Init(this._jC.oUIMgr.dataManager.GetAnalysis());break;default:this._gn[i]=new Array();var _awP=_N5.GetAxisSet(i-1);var _aDN=_awP.GetItemCount();for(var j=0;j<_aDN;j++){if(_awP.GetItem(j)instanceof CUIAxisComboItem){var _I3=_awP.GetItem(j).GetSimpleBlockArray();for(var _aqL=0;_aqL<_I3.length;_aqL++){var oProp=new CUIAxisProperty(this,this._gn[i].length);this._gn[i].push(oProp);oProp.Init(_I3[_aqL].GetId());if(Utilities.bSingleMemExpandEnabled){if(_I3[_aqL].HasSingleMemberExpandedSet()){var _3N=_I3[_aqL].GetAllExpandedSets();for(var _0C=0;_0C<_3N.length;_0C++){var _0s=new CUIAxisProperty(this,this._gn[i].length);this._gn[i].push(_0s);_0s.Init(_3N[_0C].GetId());}}}}}else{var oProp=new CUIAxisProperty(this,this._gn[i].length);this._gn[i].push(oProp);var _FK=_awP.GetItem(j).GetBlock();oProp.Init(_FK.GetId());if(Utilities.bSingleMemExpandEnabled){if(_FK.HasSingleMemberExpandedSet()){var _3N=_FK.GetAllExpandedSets();for(var _0C=0;_0C<_3N.length;_0C++){var _0s=new CUIAxisProperty(this,this._gn[i].length);this._gn[i].push(_0s);_0s.Init(_3N[_0C].GetId());}}}}}if(_aDN==0){var oProp=new CUIAxisProperty(this,this._gn[i].length);this._gn[i].push(oProp);oProp.Init();}break;}}this.sCurrentMeasureId=this._jC.oUIMgr.dataManager.GetCurrentDataMatrix().GetCurrentMeasureId();this.sCurrentDispProp=this._jC.oUIMgr.dataManager.GetCurrentDataMatrix().GetDisplayProperty();};CUINoSelPropSet.prototype.HasCurrentMeasureChanged=function(_SK){return _SK!=this.sCurrentMeasureId;};CUINoSelPropSet.prototype.HasShowValuesAsChanged=function(_Bl){return _Bl!=this.sCurrentDispProp;};CUINoSelPropSet.prototype.ClearChanges=function(){for(var i=0;i<this._gn.length;i++){for(var j=0;this._gn[i]&&j<this._gn[i].length;j++){this._gn[i][j].Unload();}}Utilities.DeleteAllFromArray(this._gn);this._eE=null;this.Init();};CUINoSelPropSet.prototype.CommitChanges=function(){var _AE=new Array();var _avF=this._gn[CUINoSelPropSet.eMeasureLine][0].GetValue();if(_avF!=this.sCurrentMeasureId){var _Le=true;_AE.push(this._jC.oUIMgr.dataManager.GetCurrentWorkSheet().AddMeasure(_avF,_Le));}var _avO=this._gn[CUINoSelPropSet.eMeasureLine][1].GetValue();if(_avO!=this.sCurrentDispProp){var _Le=true;_AE.push(this._jC.oUIMgr.dataManager.GetCurrentDataMatrix().SetDisplayProperty(_avO,null,null,null,null,_Le));}var _ZA=this._gn[CUINoSelPropSet.eReportLine][0];if(_ZA.bChanged&&!_ZA.CheckForDispNameOnlyChanges()){_AE.push(this._jC.oUIMgr.dataManager._kX.Modify(this._gn[CUINoSelPropSet.eReportLine][0].GetValue(),true));}if(this.oUIWS._my.isViewsChartNameChanged()){_AE.push(this.oUIWS._my.ModifyViewsChartName(true));}if(this.oUIWS._my.isViewsXtabNameChanged()){_AE.push(this.oUIWS._my.ModifyViewsXtabName(true));}var _aBj=this._jC.oUIMgr.dataManager.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this._jC.oUIMgr.dataManager.GetCurrentWorkSheet(),true);};CUINoSelPropSet.prototype.OnUpdateProperty=function(){var _aat=false;for(var i=0;i<this._gn[CUINoSelPropSet.eMeasureLine].length;i++){if(this._gn[CUINoSelPropSet.eMeasureLine][i].bChanged){_aat=true;break;}}var _aGc=this._gn[CUINoSelPropSet.eReportLine][0].UpdatePropertyFromDialog();if(_aGc){_aat=true;}this._jC.OnUpdateProperty(_aat);};CUINoSelPropSet.prototype.GetConfirmMsgByChangeType=function(){var _aGc=this._gn[CUINoSelPropSet.eReportLine][0].bChanged;var _1B=_aGc?CUIBlockPropertiesPane.kNoSelPropertyAndRepOptDlg:CUIBlockPropertiesPane.kNoSelPropertyOnly;return CUIBlockPropertiesPane.aConfirmMsg[_1B];};function CUIBlockPropertiesPane(_Hk){this.oUIMgr=_Hk;this.oRes=_Hk.appobj.oResources;this.bExpanded=false;this.oSelection=null;this._xw=null;this.oWS=_Hk._jf;this._aq=new Object();this._e6=new Array();this._e6[ExpEvent.kCUIBlockPropertiesPane_ToggleDisplay]=new Array();};CUIBlockPropertiesPane.kiExpandedHeight=200;CUIBlockPropertiesPane.kNoBlockSel=1;CUIBlockPropertiesPane.kPropertyOnly=1;CUIBlockPropertiesPane.kFltDlgOnly=2;CUIBlockPropertiesPane.kPropertyAndFltDlg=3;CUIBlockPropertiesPane.kNoSelPropertyOnly=4;CUIBlockPropertiesPane.kNoSelPropertyAndRepOptDlg=5;CUIBlockPropertiesPane.kPropertyAndTBDlg=6;CUIBlockPropertiesPane.kPropertyAndSortDlg=7;CUIBlockPropertiesPane.aConfirmMsg=new Object();CUIBlockPropertiesPane.aConfirmMsg[CUIBlockPropertiesPane.kPropertyOnly]='IDS_BLOCK_PROPERTY_PANE_COMMIT_CHANGES';CUIBlockPropertiesPane.aConfirmMsg[CUIBlockPropertiesPane.kFltDlgOnly]='IDS_FLT_DLG_ONLY_COMMIT_CHANGES';CUIBlockPropertiesPane.aConfirmMsg[CUIBlockPropertiesPane.kPropertyAndFltDlg]='IDS_BLOCK_PROPERTY_PANE_AND_FLT_DLG_COMMIT_CHANGES';CUIBlockPropertiesPane.aConfirmMsg[CUIBlockPropertiesPane.kPropertyAndTBDlg]='IDS_BLOCK_PROPERTY_PANE_AND_TOPBOTTOM_DLG_COMMIT_CHANGES';CUIBlockPropertiesPane.aConfirmMsg[CUIBlockPropertiesPane.kPropertyAndSortDlg]='IDS_BLOCK_PROPERTY_PANE_AND_SORT_DLG_COMMIT_CHANGES';CUIBlockPropertiesPane.aConfirmMsg[CUIBlockPropertiesPane.kNoSelPropertyOnly]='IDS_ANALYSIS_PROPERTY_PANE_COMMIT_CHANGES';CUIBlockPropertiesPane.aConfirmMsg[CUIBlockPropertiesPane.kNoSelPropertyAndRepOptDlg]='IDS_ANALYSIS_PROPERTY_PANE_AND_REP_DLG_COMMIT_CHANGES';CUIBlockPropertiesPane.prototype.IsVisible=function(){return this.bExpanded;};CUIBlockPropertiesPane.prototype.Init=function(_EP){this._r1=_EP;this.DrawHeading();this.oWS.Subscribe(this,ExpEvent.kCUIWorksheet_ChangedBlockSel);this.oWS.Subscribe(this,ExpEvent.kCUIWorksheet_Busy);this.oWS.Subscribe(this,ExpEvent.kCUIWorksheet_Free);this.oUIMgr.Subscribe(this,ExpEvent.kCUIManager_Unload);};CUIBlockPropertiesPane.prototype.Hide=function(){if(this._p2){this._p2.style.visibility="hidden";}};CUIBlockPropertiesPane.prototype.Show=function(){if(this._p2){this._p2.style.visibility="visible";}this.Draw();};CUIBlockPropertiesPane.prototype.Draw=function(_Ae){if(this._ra){this.bExpanded=this._xw;this._ra=false;this._xw=null;}this.DrawHeading();this.DrawProperties();this.DrawButtons();if(_Ae){this.updateButtons();}var _az6=document.getElementById(this.sContainerId);if(this.bExpanded){if(_az6){var _aGM=CUIBlockPropertiesPane.kiExpandedHeight-this.GetHeaderHeight()-this.GetButtonsHeight();COTStyle.SetHeight(_az6,_aGM);}this._p2.style.top=this.getExpandedTop()+"px";}else{if(_az6){COTStyle.SetHeight(_az6,0);}this._p2.style.top=this.getCollapsedTop()+"px";}};CUIBlockPropertiesPane.prototype.DrawHeading=function(){if(!this._p2){this._p2=document.createElement('DIV');this._p2.style.position="absolute";this._p2.className="BlockProperties";this._p2.onmousedown=CUIBlockPropertiesPane.SafeHandleMouseDown;Dom.SetObjRef(this._p2,this,'oPane');var _51=this.oWS._my.GetAnalysisName();this.oToggleBar=new CUIToggleBar(_51);this.oToggleBar.Init(this._p2,this,CUIBlockPropertiesPane.SafeToggleDisplay);this._r1.appendChild(this._p2);}else{var _ayv="";if(this.oSelection&&this.oSelection.GetLabel()){var _ayv=this.oSelection.GetLabelWithDescription();var _3x=this.oSelection.GetLabel();if(this.oSelection.IsLocked()){var _Rz=this.oRes.ReplaceParam('IDS_CONTEXTBAR_LOCKED_BLOCK',1,_3x);this.oToggleBar.InsertImgBeforeHeader('icon_hold.gif',_Rz,null);}else{this.oToggleBar.RemoveImgBeforeHeader();}}else{_ayv=this.oWS._my.GetAnalysisName();if(this.oUIMgr.dataManager.GetAnalysis()&&this.oUIMgr.dataManager.GetAnalysis().GetTitle()){_ayv=this.oRes.ReplaceParam('IDS_BLOCK_PROPERTIES_TITLE_NO_SEL',1,_ayv);_ayv=this.oRes.ReplaceParam(_ayv,2,this.oUIMgr.dataManager.GetAnalysis().GetTitle());}this.oToggleBar.RemoveImgBeforeHeader();}this.oToggleBar.Update(_ayv,this.bExpanded);}};CUIBlockPropertiesPane.prototype.GetInternalWidth=function(){return this._nq-CUIManager.kiScrollbarWidth;};CUIBlockPropertiesPane.prototype.DrawProperties=function(){if(!this.sContainerId&&this.bExpanded){var _az6=this._p2.appendChild(document.createElement('DIV'));this.sContainerId="blockPropContainer"+Utilities.GenerateId();_az6.id=this.sContainerId;_az6.className="BlockPropertiesContainer";var _F4=COTStyle.GetWidth(this._p2)-COTStyle.GetHorizontalBordersWidth(_az6);COTStyle.SetWidth(_az6,_F4,'px');var _aE1=document.createElement('table');_az6.appendChild(_aE1);this.sPropertyTableId="blockpropTable"+Utilities.GenerateId();_aE1.id=this.sPropertyTableId;_aE1.cellSpacing=0;var _avJ=COTStyle.GetWidthFromOffset(_az6);COTStyle.SetWidth(_aE1,_avJ-CUIManager.kiScrollbarWidth);var _F0=document.createElement('tbody');this.sTBodyId="infoTBody"+Utilities.GenerateId();_F0.id=this.sTBodyId;_aE1.appendChild(_F0);}if(this.bExpanded){var _RK=document.getElementById(this.sTBodyId);Dom.RemoveAllChildren(_RK);var _3O="";if(this.oSelection){_3O=this.oSelection.GetId();}if(this.oSelection&&!this._aq[this.oSelection.GetId()]){this._aq[_3O]=new CUIBlockPropSet(this);this._aq[_3O].Init(this.oSelection);}else if(!this.oSelection){_3O=CUIBlockPropertiesPane.kNoBlockSel;if(!this._aq[_3O]){this._aq[_3O]=new CUINoSelPropSet(this);this._aq[_3O].Init();}}this._aq[_3O].Draw(_RK);}else{var _RK=document.getElementById(this.sTBodyId);Dom.RemoveAllChildren(_RK);}};CUIBlockPropertiesPane.prototype.DrawButtons=function(){if(!this.sButtonTableId&&this.bExpanded){var _acd=this._p2.appendChild(document.createElement('TABLE'));_acd.className='blockproppanebutton';var _6T=_acd.appendChild(document.createElement('TBODY'));var _YO=_6T.appendChild(document.createElement('TR'));this.sButtonTableId=Utilities.GenerateId();_acd.id=this.sButtonTableId;var _aID=this.oRes.GetString('IDS_BUTTON_OK');var _aIq=COTInputElementFactory.CreateButton('PropOKButton',_aID,CUIBlockPropertiesPane.SafeDoOK,false);this.sOKButtonId=Utilities.GenerateId();_aIq.id=this.sOKButtonId;var _3K=_YO.appendChild(document.createElement('TD'));_3K.appendChild(_aIq);Dom.SetObjRef(_aIq,this,'oPane');var _aut=this.oRes.GetString('IDS_BUTTON_CANCEL');var _Zv=COTInputElementFactory.CreateButton('PropCancelButton',_aut,CUIBlockPropertiesPane.SafeDoCancel,false,true);this.sCancelButtonId=Utilities.GenerateId();_Zv.id=this.sCancelButtonId;_3K.appendChild(_Zv);Dom.SetObjRef(_Zv,this,'oPane');var _axY=this.oRes.GetString('IDS_BUTTON_APPLY');var _H1=COTInputElementFactory.CreateButton('PropApplyButton',_axY,CUIBlockPropertiesPane.SafeDoApply,false,true);_3K.appendChild(_H1);Dom.SetObjRef(_H1,this,'oPane');this.sApplyButtonId=Utilities.GenerateId();_H1.id=this.sApplyButtonId;COTInputElementFactory.DisableInput(_H1);}var _acd=document.getElementById(this.sButtonTableId);if(_acd&&this.bExpanded){_acd.style.display="block";}else if(_acd){_acd.style.display="none";}};CUIBlockPropertiesPane.prototype.updateButtons=function(_Ly,_Oq){var _ami=document.getElementById(this.sApplyButtonId);if(_ami){if(_Ly){COTInputElementFactory.EnableInput(_ami);}else{COTInputElementFactory.DisableInput(_ami);}}var _ajY=document.getElementById(this.sOKButtonId);if(_ajY){if(_Oq){COTInputElementFactory.DisableInput(_ajY);}else{COTInputElementFactory.EnableInput(_ajY);}}var _arG=document.getElementById(this.sCancelButtonId);if(_arG){if(_Oq){COTInputElementFactory.DisableInput(_arG);}else{COTInputElementFactory.EnableInput(_arG);}}};CUIBlockPropertiesPane.prototype.OnUpdateProperty=function(_Ly){this.updateButtons(_Ly);};CUIBlockPropertiesPane.prototype.GetCurrentPropSet=function(){if(!this.oSelection){return this._aq[CUIBlockPropertiesPane.kNoBlockSel];}return this._aq[this.oSelection.GetId()];};CUIBlockPropertiesPane.SafeHandleMouseDown=function(){/*@if(!@bering_debug)@*/try{/*@end@*/if(this.oPane.GetCurrentPropSet()){this.oPane.GetCurrentPropSet().ClearSelections();}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIBlockPropertiesPane.SafeDoOK=function(){/*@if(!@bering_debug)@*/try{/*@end@*/if(this.oPane.oSelection){this.oPane.oWS.SetLastBlockSelectionId(this.oPane.oSelection.GetId());}var _ami=document.getElementById(this.oPane.sApplyButtonId);if(_ami){if(!_ami.disabled){this.oPane.GetCurrentPropSet().CommitChanges();}}var _asS=true;this.oPane.ToggleDisplay(_asS);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIBlockPropertiesPane.SafeDoApply=function(){/*@if(!@bering_debug)@*/try{/*@end@*/if(this.oPane.oSelection){this.oPane.oWS.SetLastBlockSelectionId(this.oPane.oSelection.GetId());}this.oPane.GetCurrentPropSet().CommitChanges();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIBlockPropertiesPane.SafeDoCancel=function(){/*@if(!@bering_debug)@*/try{/*@end@*/this.oPane.GetCurrentPropSet().ClearChanges();var _asS=true;this.oPane.ToggleDisplay(_asS);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIBlockPropertiesPane.prototype.GetHeaderHeight=function(){return COTStyle.GetDisplayOffsetHeight(this.oToggleBar._cT);};CUIBlockPropertiesPane.prototype.GetButtonsHeight=function(){var _9P=document.getElementById(this.sButtonTableId);if(_9P){return COTStyle.GetDisplayOffsetHeight(_9P);}return 0;};CUIBlockPropertiesPane.prototype.SetWidth=function(_F4){this._nq=_F4;COTStyle.SetWidth(this._p2,_F4);var _zr=document.getElementById(this.sPropertyTableId);if(_zr){COTStyle.SetWidth(_zr,_F4-CUIManager.kiScrollbarWidth);}};CUIBlockPropertiesPane.prototype.SetLeft=function(_P6){this._p2.style.left=_P6+'px';};CUIBlockPropertiesPane.prototype.getCollapsedTop=function(){return parseInt(this._vq-this.GetHeaderHeight());};CUIBlockPropertiesPane.prototype.getExpandedTop=function(){return parseInt(this._vq-CUIBlockPropertiesPane.kiExpandedHeight);};CUIBlockPropertiesPane.prototype.GetTop=function(){if(!this.bExpanded){return this.getCollapsedTop();}else{return this.getExpandedTop();}};CUIBlockPropertiesPane.prototype.HandleResize=function(_Dg){this._vq=_Dg;if(!this.bExpanded){this._p2.style.top=this.getCollapsedTop()+"px";}else{this._p2.style.top=this.getExpandedTop()+"px";}if(this.sContainerId){var _az6=document.getElementById(this.sContainerId);var _F4=COTStyle.GetWidth(this._p2)-COTStyle.GetHorizontalBordersWidth(_az6);COTStyle.SetWidth(_az6,_F4,'px');}this.DrawProperties();};CUIBlockPropertiesPane.SafeToggleDisplay=function(){/*@if(!@bering_debug)@*/try{/*@end@*/this.oOwner.ToggleDisplay();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIBlockPropertiesPane.SafeShowPane=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/FindApp(_Ke).uiManager.oBlockPropsPane.ShowPane();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIBlockPropertiesPane.prototype.ShowPane=function(){if(this.oUIMgr.oDialogMgr.IsModalessDialogDisplayed()){this.oUIMgr.oDialogMgr.HideCurrentDialog();}if(!this.bExpanded){if(this.oWS.AllowInteraction()){this.bExpanded=!this.bExpanded;this.Draw();this.Notify(ExpEvent.kCUIBlockPropertiesPane_ToggleDisplay);}}};CUIBlockPropertiesPane.prototype.IsToggleDisabled=function(){if(!this.oWS.AllowInteraction()){return true;}return false;};CUIBlockPropertiesPane.SafeDoClearChanges=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/var _aH0=FindApp(_Ke).uiManager.oBlockPropsPane;_aH0.GetCurrentPropSet().ClearChanges();var _Hy=FindApp(_Ke).uiManager.oDialogMgr;_aH0.Draw();_Hy.HideCurrentDialog();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIBlockPropertiesPane.prototype.ShowConfirmDialog=function(){var _Oo=this.GetCurrentPropSet();var _Ke=this.oUIMgr.appobj.appname;var _aAS=Utilities.GenerateCallback(CUIBlockPropertiesPane.SafeDoClearChanges,[_Ke]);var _anu=Utilities.GenerateCallback(CUIDialogMgr.SafeHideCurrentDialog,[_Ke]);var _aAo=Utilities.GenerateCallbackUnion([Utilities.SafeDoRemoveHoldingProcedure,_anu]);CUIDialogMgr._q5.SetCallBackFuntion(_aAS,_aAo);var _aHG=_Oo.GetConfirmMsgByChangeType();CUIDialogMgr._q5.Display(_aHG,'',CUIConfirmDlg._hw);};CUIBlockPropertiesPane.prototype.ConfirmLossOfChanges=function(){if(!this._w7&&this.GetCurrentPropSet()&&this.GetCurrentPropSet().HasUncommittedChanges()){this.ShowConfirmDialog();return Utilities.eStateHold;}else{return Utilities.eStateContinue;}};CUIBlockPropertiesPane.prototype.DoContinueDraw=function(){this.bExpanded=!this.bExpanded;this.Draw();this.Notify(ExpEvent.kCUIBlockPropertiesPane_ToggleDisplay);};CUIBlockPropertiesPane.SafeDoContinueDraw=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/var _aH0=FindApp(_Ke).uiManager.oBlockPropsPane;_aH0.DoContinueDraw();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIBlockPropertiesPane.prototype.ToggleDisplay=function(_C5){var _Ke=this.oUIMgr.appobj.appname;if(!this.bExpanded){if(this.oWS.AllowInteraction()){this.bExpanded=!this.bExpanded;this.Draw();this.Notify(ExpEvent.kCUIBlockPropertiesPane_ToggleDisplay);}}else{var _amW=Utilities.eStateContinue;if(!_C5){_amW=this.ConfirmLossOfChanges();}if(_amW==Utilities.eStateContinue){this.DoContinueDraw();}else if(_amW==Utilities.eStateHold){Utilities.SetProcedureToHold(CUIBlockPropertiesPane.SafeDoContinueDraw,new Array(_Ke));this.oUIMgr.oDialogMgr.Subscribe(this,ExpEvent.kCUIDialogMgr_HideModalDialog);}}};CUIBlockPropertiesPane.prototype.DoTempHide=function(){if(this._xw==null){this._xw=this.bExpanded;if(this.bExpanded){this.bExpanded=!this.bExpanded;this.Draw();this._ra=true;}}};CUIBlockPropertiesPane.prototype.DoEndTempHide=function(){if(this._xw==true){this.bExpanded=this._xw;if(!this._w7){this.Draw();}}this._xw=null;this._ra=false;if(this.GetCurrentPropSet()){var _BY=true;this.GetCurrentPropSet().OnUpdateProperty(_BY);}};CUIBlockPropertiesPane.prototype.HandleChangedBLKSelection=function(){if(!this._w7){if(this.GetCurrentPropSet()){this.GetCurrentPropSet().ClearChanges();}this.oSelection=this.oWS.GetSelectedBlock();var _Ae=true;this.Draw(_Ae);}};CUIBlockPropertiesPane.SafeHandleChangedBLKSelection=function(_Ke){/*@if(!@bering_debug)@*/try{/*@end@*/var _aH0=FindApp(_Ke).uiManager.oBlockPropsPane;_aH0.HandleChangedBLKSelection();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIBlockPropertiesPane.prototype.Notify=function(_Dy){var _Ke=this.oUIMgr.appobj.appname;if(_Dy==ExpEvent.kCUIWorksheet_ChangedBlockSel){if(this._w7){for(var i in this._aq){this._aq[i].Unload();}Utilities.ClearObjectArray(this._aq);this._w7=false;}this.HandleChangedBLKSelection();}else if(_Dy==ExpEvent.kCUIWorksheet_Free){var _JE=this.oUIMgr.dataManager.GetAnalysis();if(!_JE||!_JE._v6){for(var i in this._aq){this._aq[i].Unload();}Utilities.ClearObjectArray(this._aq);this._w7=false;}this.oSelection=this.oWS.GetSelectedBlock();var _Ae=true;this.Draw(_Ae);}else if(_Dy==ExpEvent.kCUIWorksheet_Busy){this._w7=true;this.updateButtons(false,true);if(this.GetCurrentPropSet()){this.GetCurrentPropSet().HandleStateChange(true);}}else if(_Dy==ExpEvent.kCUIDialogMgr_HideModalDialog){Utilities.ExecuteHoldingProcedure();this.oUIMgr.oDialogMgr.UnSubscribe(this,ExpEvent.kCUIDialogMgr_HideModalDialog);}if(this._e6[_Dy]){for(var i=0;i<this._e6[_Dy].length;i++){this._e6[_Dy][i].Notify(_Dy);}}if(_Dy==ExpEvent.kCUIManager_Unload){this.Unload();}};CUIBlockPropertiesPane.prototype.Subscribe=function(obj,event){if(this._e6[event]){this._e6[event].push(obj);}};CUIBlockPropertiesPane.prototype.Unload=function(){this.oToggleBar.Unload();for(var i in this._aq){this._aq[i].Unload();}Dom.RemoveObject(this._p2);Utilities.RemoveAllChildObjects(this);};CUIBlockPropertiesPane.prototype.GetSortDlg=function(){if(!this.oSortDlg){var _H8=true;this.oSortDlg=new CUISortDlg(_H8);this.oSortDlg.Init(this.oUIMgr.oDialogMgr);}return this.oSortDlg;};CUIBlockPropertiesPane.prototype.GetTopBottomDlg=function(){if(!this.oTopBottomDlg){var _H8=true;this.oTopBottomDlg=new CUITopBottomDlg(_H8);this.oTopBottomDlg.Init(this.oUIMgr.oDialogMgr);}return this.oTopBottomDlg;};CUIBlockPropertiesPane.prototype.GetUserDefFilterDlg=function(){if(!this.oUserDefFLTDlg){this.oUserDefFLTDlg=new CUIUserDefFilterDlg(true);this.oUserDefFLTDlg.Init(this.oUIMgr.oDialogMgr);this.oUserDefFLTDlg.InitFLTRuleOptions();this.oUserDefFLTDlg.SubscribeWSEvent();}return this.oUserDefFLTDlg;};CUIBlockPropertiesPane.prototype.GetCombineFilterDlg=function(){if(!this.oCombineFLTDlg){this.oCombineFLTDlg=new CUICombineFilterDlg(true);this.oCombineFLTDlg.Init(this.oUIMgr.oDialogMgr);this.oCombineFLTDlg.SubscribeWSEvent();}return this.oCombineFLTDlg;};CUIBlockPropertiesPane.prototype.GetAutoSummaryDlg=function(){if(!this._ws){this._ws=new CUIAutoSubtotalsDlg(true);this._ws.Init(this.oUIMgr.oDialogMgr,this.oWS);}return this._ws;};CUIBlockPropertiesPane.prototype.OnHide=function(){this.ToggleDisplay(true);};CUIBlockPropertiesPane.prototype.IsActive=function(){var _TD=this._ra?this._xw:this.bExpanded;if(!_TD){return false;}var _akk=true;var _ajd=this.oUIMgr.oDialogMgr._jg;if(_ajd){var _awB=false;if(_ajd.IsInSaveMode){_awB=_ajd.IsInSaveMode();}if(_awB){var opener=this;if(_ajd.GetRootOpener){opener=_ajd.GetRootOpener();}if(opener!=this){_akk=false;}}else{_akk=false;}}return _akk;};CUIAbsBlockProperty.eReadOnly=0;CUIAbsBlockProperty.eEditable=1;CUIAbsBlockProperty.kArrowHeight=12;CUIAbsBlockProperty.kArrowWidth=11;function CUIAbsBlockProperty(_Oo,_Dl){this._G=_Oo;this._l3=_Dl;this._jU=null;this._p8=null;this._mr=CUIAbsBlockProperty.eEditable;this.bChanged=false;this.bHover=false;this.bSelected=false;this._uu='prop_div';this._fi='prop_dropdown_arrow';this._wt='ComboBoxArrow.gif';this._mb=null;this._eN=null;};CUIAbsBlockProperty.prototype.Init=function(){this._sp=this._G._jC.oRes;this._J=document.createElement('DIV');this._gC=this._G._jC.oUIMgr.appobj.appname;this._J.className=this._uu;};CUIAbsBlockProperty.prototype.SetValue=function(_UN){this._jU=_UN;};CUIAbsBlockProperty.prototype.GetValue=function(){return this._jU;};CUIAbsBlockProperty.prototype.SetLabel=function(_BM,_QI){this._p8=_BM;if(_QI){this._eN=_QI;}};CUIAbsBlockProperty.prototype.GetLabel=function(){return this._p8;};CUIAbsBlockProperty.prototype.SetReadOnly=function(){this._mr=CUIAbsBlockProperty.eReadOnly;};CUIAbsBlockProperty.prototype.Draw=function(_ID){Dom.RemoveAllChildren(this._J);this._hI=null;if(this._mb){this._hI=COTInputElementFactory.CreateImage(this._mb,12,12);this._hI.style.paddingRight='5px';this._J.appendChild(this._hI);if(this._mr==CUIAbsBlockProperty.eReadOnly){this._hI.style.display="none";}else{this._hI.style.display="inline";}}if(_ID){_ID.appendChild(this._J);}this._s1=document.createElement('SPAN');this._s1.appendChild(document.createTextNode(this._p8));this._J.appendChild(this._s1);if(this._eN){this._s1.title=this._eN;}this.DrawDropDownArrow(this._J);if(this._mr==CUIAbsBlockProperty.eEditable){this.oArrowImg.style.display="inline";}else{this.oArrowImg.style.display="none";}Dom.SetObjRef(this._J,this,'oProp');this._J.onmouseover=CUIAbsBlockProperty.SafeHandleMouseOver;this._J.onmouseout=CUIAbsBlockProperty.SafeHandleMouseOut;this._J.onclick=Utilities.EventCallback(this.GeneralHandleClick,[],this,false,true);var _Zy=COTStyle.GetDisplayOffsetWidth(this._J);if(_Zy>this._G.GetWidthForPropertyValues()){var _alq=this._sp.ParseStringForParamOrder('IDS_TRUNCATED_STRING',1);var _X4=0;for(var i=0;i<_alq.length;i++){if(_alq[i]){if(_alq[i].sBefore!=""){var _acc=document.createElement("SPAN");_acc.appendChild(document.createTextNode(_alq[i].sBefore));this._J.insertBefore(_acc,this._s1);_X4+=COTStyle.GetDisplayOffsetWidth(_acc);}if(_alq[i].sAfter!=""){var _acc=document.createElement("SPAN");_acc.appendChild(document.createTextNode(_alq[i].sAfter));this._J.insertBefore(_acc,this.oArrowImg);_X4+=COTStyle.GetDisplayOffsetWidth(_acc);}}}COTStyle.SetWidth(this._s1,this._G.GetWidthForPropertyValues()-CUIAbsBlockProperty.kArrowWidth-CUIManager.kiScrollbarWidth-_X4);}};CUIAbsBlockProperty.prototype.RedrawLabel=function(_U5,_BY){if(!this._s1){return;}if(this._mb){if(this._hI){Dom.RemoveObject(this._hI);this._hI=null;}this._hI=COTInputElementFactory.CreateImage(this._mb,12,12);this._hI.style.paddingRight='5px';this._J.insertBefore(this._hI,this._s1);if(this._mr==CUIAbsBlockProperty.eReadOnly){this._hI.style.display="none";}else{this._hI.style.display="inline";}}else if((!this._mb)&&this._hI){Dom.RemoveObject(this._hI);this._hI=null;}Dom.ReplaceText(this._s1,this._p8);if(this._eN){this._s1.title=this._eN;}this.bChanged=_U5;this.SetStyle();if(this._mr==CUIAbsBlockProperty.eEditable){this.oArrowImg.style.display="inline";}else{this.oArrowImg.style.display="none";}this._G.OnUpdateProperty(_BY);};CUIAbsBlockProperty.prototype.SetStyle=function(){if(!this._J){return;}this._J.className=this._uu;if(this.bChanged){this._J.className+=' prop_div_changed';}if(this.bHover){this._J.className+=' prop_div_hover';}if(this.bSelected){this._J.className+=' prop_div_selected';}if(this._mr==CUIAbsBlockProperty.eEditable){this._J.className+=" prop_div_editable";}var _aHM=Dom.GetElementsByTagName(this._J,"INPUT");if(_aHM&&_aHM[0]&&_aHM[0].type=="text"){if(this.bChanged){_aHM[0].className+=" integerTextBox_changed";}else{_aHM[0].className=_aHM[0].sBaseClassName;}}};CUIAbsBlockProperty.prototype.DrawDropDownArrow=function(_MU){var _azP=document.createElement('IMG');_azP.className=this._fi;_MU.appendChild(_azP);_azP.src=Utilities.IMG_PATH+this._wt;Dom.SetObjRef(_azP,this,'oProp');_azP.onclick=Utilities.EventCallback(this.GeneralHandleClick,[],this,false,true);COTStyle.SetSize(_azP,CUIAbsBlockProperty.kArrowWidth,CUIAbsBlockProperty.kArrowHeight);this.oArrowImg=_azP;return _azP;};CUIAbsBlockProperty.prototype.GeneralHandleClick=function(e){var _KS=this._G._jC;if(_KS&&_KS.oUIMgr._jf.AllowInteraction()){var _Qb=Dom.GetRelativeOffset(this._s1,document.body);var _apr=Dom.GetRelativeOffset(this.oArrowImg,document.body);var x=_apr.iLeft+COTStyle.GetDisplayOffsetWidth(this.oArrowImg);var y=_Qb.iTop+COTStyle.GetDisplayOffsetHeight(this._s1);this.bSelected=true;this.SetStyle();if(this.HandleClick){this.HandleClick(e,x,y);}}};CUIAbsBlockProperty.SafeHandleMouseOver=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(this.oProp._mr==CUIAbsBlockProperty.eEditable){this.oProp.bHover=true;this.oProp.SetStyle();}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIAbsBlockProperty.SafeHandleMouseOut=function(){/*@if(!@bering_debug)@*/try{/*@end@*/this.oProp.bHover=false;if(this.oProp._mr==CUIAbsBlockProperty.eEditable){this.oProp.SetStyle();}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIAbsBlockProperty.prototype.Unload=function(){Dom.RemoveObject(this._J);Utilities.RemoveAllChildObjects(this);};CUIAbsBlockProperty.prototype.OnSelect=function(){this.bSelected=true;this.SetStyle();};CUIAbsBlockProperty.prototype.OnUnSelect=function(){this.bSelected=false;this.SetStyle();};function CUILockProperty(_Oo,_PQ){this.base=CUIAbsBlockProperty;this.base(_Oo,_PQ);this._uu="lock_prop_div";};CUILockProperty.prototype=new CUIAbsBlockProperty;CUILockProperty.superclass=CUIAbsBlockProperty.prototype;CUILockProperty.prototype.Draw=function(_ID){Dom.RemoveAllChildren(this._J);if(this._mr==CUIAbsBlockProperty.eReadOnly){this._J.disabled=true;}else{this._J.disabled=false;}if(_ID){_ID.appendChild(this._J);}this._oE=this._J.appendChild(document.createElement('DIV'));var _0k=this._G.oProxyBlock.IsLocked();if(_0k){var _asx=this._oE.appendChild(document.createElement('IMG'));_asx.src=Utilities.IMG_PATH+"icon_hold.gif";_asx.style.verticalAlign="middle";}this._s1=document.createElement('SPAN');this._oE.appendChild(this._s1);this._s1.appendChild(document.createTextNode(this._p8));if(this._eN){this._s1.title=this._eN;}Dom.SetObjRef(this._J,this,'oProp');this._J.onmouseover=CUIAbsBlockProperty.SafeHandleMouseOver;this._J.onmouseout=CUIAbsBlockProperty.SafeHandleMouseOut;this.DrawDropDownArrow(this._oE);if(this._mr==CUIAbsBlockProperty.eEditable){this.oArrowImg.style.display="inline";}else{this.oArrowImg.style.display="none";}this._J.onclick=Utilities.EventCallback(this.GeneralHandleClick,[],this,false,true);var _aez=this._J.appendChild(document.createElement('IMG'));_aez.src=Utilities.IMG_PATH+"resize_area.gif";if(_o.is_ie5_5up){COTStyle.SetWidth(_aez,100,'%');}else{COTStyle.SetWidth(_aez,93,'%');}COTStyle.SetHeight(_aez,3);_aez.style.verticalAlign="middle";this.SetStyle();};CUILockProperty.prototype.SetStyle=function(){if(!this._oE){return;}this._oE.className=this._uu;if(this.bChanged){this._oE.className+=' prop_div_changed';}if(this.bHover){this._oE.className+=' prop_div_hover';}if(this.bSelected){this._oE.className+=' prop_div_selected';}if(this._mr==CUIAbsBlockProperty.eEditable){this._oE.className+=" prop_div_editable";}};CUILockProperty.prototype.Init=function(){CUILockProperty.superclass.Init.call(this);this._uu='prop_div_middel_valign';if(this._G.oOriginalBlock.IsLockable()){this._mr=CUIAbsBlockProperty.eEditable;}else{this._mr=CUIAbsBlockProperty.eReadOnly;}this._wC=this._sp.GetString('IDS_LOCK_PROP');this.SetValue(this._G.oOriginalBlock.IsLocked());this.SetLabel(this._wC);};CUILockProperty.SafeHandleClick=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/this.oProp.UpdateProperty();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUILockProperty.prototype.HandleClick=function(e,x,y){if(this._mr==CUIAbsBlockProperty.eEditable){this.ShowDropDown(e,x,y);}};CUILockProperty.prototype.ShowDropDown=function(e,x,y){var _Kk=new CUIContextMenu(this._gC,0,this);_Kk.SetUnloadOnHide(true);this._G.SetCurrentProp(this);var _Jj=CUIAbsBlockPropSet.SafeDoUpdateCurrentProperty;var _AG=new Array(this._gC,ExpAPIXml.kEleAxisOpExprIsLocked,false);var _BM=this._sp.GetString('OTH_BLOCKPROP_DEFINITION_UNPINNED');var _PM=new ContextItem("",_BM,_Jj,false,_AG,_Kk);_PM.SetRadioState(!this._G.oProxyBlock.IsLocked());var _AG=new Array(this._gC,ExpAPIXml.kEleAxisOpExprIsLocked,true);_BM=this._sp.GetString('OTH_BLOCKPROP_DEFINITION_PINNED');var _PM=new ContextItem("icon_hold.gif",_BM,_Jj,false,_AG,_Kk);_PM.SetRadioState(this._G.oProxyBlock.IsLocked());_Kk.SetChildrenComplete();_Kk.display(e,true,x,y);};CUILockProperty.prototype.UpdateProperty=function(_z2,_H6){this.SetValue(_H6);this._G.oProxyBlock._hF=_H6;this.bSelected=true;this.bChanged=!CDLBlockTransaction.IsLockPropEqual(this._G.oProxyBlock,this._G.oOriginalBlock);this.Draw(null);this._G.OnUpdateProperty(true);var _aEc=_H6;this._G.ToggleLockRelatedProps(_aEc);};CUIVisibleItemProperty.kDefault='default';CUIVisibleItemProperty.kOptNum1='5';CUIVisibleItemProperty.kOptNum2='10';CUIVisibleItemProperty.kOptNum3='15';CUIVisibleItemProperty.kOptNum4='20';CUIVisibleItemProperty.kCustomize='customize';function CUIVisibleItemProperty(_Oo,_PQ){this.base=CUIAbsBlockProperty;this.base(_Oo,_PQ);};CUIVisibleItemProperty.prototype=new CUIAbsBlockProperty;CUIVisibleItemProperty.superclass=CUIAbsBlockProperty.prototype;CUIVisibleItemProperty.prototype.Init=function(){CUIVisibleItemProperty.superclass.Init.call(this);this._vy=new Array(CUIVisibleItemProperty.kDefault,CUIVisibleItemProperty.kOptNum1,CUIVisibleItemProperty.kOptNum2,CUIVisibleItemProperty.kOptNum3,CUIVisibleItemProperty.kOptNum4,CUIVisibleItemProperty.kCustomize);this._uv=new Object();this._uv[CUIVisibleItemProperty.kDefault]=this._sp.GetString('OTH_CROSSTAB_MENU_BLOCK_SIZE_DEFAULT');this._uv[CUIVisibleItemProperty.kOptNum1]=this._sp.GetString('OTH_CROSSTAB_MENU_BLOCK_SIZE_5');this._uv[CUIVisibleItemProperty.kOptNum2]=this._sp.GetString('OTH_CROSSTAB_MENU_BLOCK_SIZE_10');this._uv[CUIVisibleItemProperty.kOptNum3]=this._sp.GetString('OTH_CROSSTAB_MENU_BLOCK_SIZE_15');this._uv[CUIVisibleItemProperty.kOptNum4]=this._sp.GetString('OTH_CROSSTAB_MENU_BLOCK_SIZE_20');this._uv[CUIVisibleItemProperty.kCustomize]=this._sp.GetString('OTH_CROSSTAB_MENU_BLOCK_SIZE_CUSTOMIZE');this._wC=this._sp.GetString('IDS_VISIBLE_ITEM_PROP_PREFIX');this._vj=!(this._G.oOriginalBlock.GetBlockSize()==this._G.oOriginalBlock._yf);var _Rz;if(!this._vj){this._wC=this._sp.ReplaceParam('IDS_VISIBLE_ITEM_PROP_PREFIX',1,this._uv[CUIVisibleItemProperty.kDefault]);_Rz=this._wC;}else{var re=this._sp.GetParameterForReplace(1);_Rz=this._wC.replace(re,this._G.oOriginalBlock.GetBlockSize());}this.SetValue(this._G.oOriginalBlock.GetBlockSize());this.SetLabel(this._wC,_Rz);};CUIVisibleItemProperty.prototype.Draw=function(_ID,_U5){CUIVisibleItemProperty.superclass.Draw.call(this,_ID,_U5);var re=this._sp.GetParameterForReplace(1);if(this._dk){Dom.RemoveObject(this._dk);this._dk=null;}if(this._vj){var _FT=this._G.oProxyBlock.GetBlockSize();this._dk=COTInputElementFactory.CreateIntegerTextBox(this,2,_FT,false,false,1,ExpAPIXml.maxBlockSize,true);COTInputElementFactory.InsertTextBoxIntoLabelSpan(this._s1,this._dk,this._wC,re);}};CUIVisibleItemProperty.prototype.HandleClick=function(e,x,y){if(this._mr==CUIAbsBlockProperty.eEditable&&Dom.GetEventTarget(e)!=this._dk){this.ShowDropDown(e,x,y);}};CUIVisibleItemProperty.prototype.UpdateProperty=function(_UN,_zg){this._wC=this._sp.GetString('IDS_VISIBLE_ITEM_PROP_PREFIX');var re=this._sp.GetParameterForReplace(1);var _FT;if(_UN==CUIVisibleItemProperty.kDefault){_FT=String(this._G.oOriginalBlock._yf);this._G.oProxyBlock._b8=_FT;this._wC=this._sp.ReplaceParam('IDS_VISIBLE_ITEM_PROP_PREFIX',1,_zg);this.SetLabel(this._wC,this._wC);this.RedrawLabel(!CDLBlockTransaction.IsBlockSizeEqual(this._G.oProxyBlock,this._G.oOriginalBlock));if(this._dk){Dom.RemoveObject(this._dk);this._dk=null;}this._vj=false;}else{var _arT=(_UN==CUIVisibleItemProperty.kCustomize);var _atN=(parseInt(this._G.oProxyBlock._b8,10)==this._G.oOriginalBlock._yf);_FT=_arT?(_atN?'':this._G.oProxyBlock._b8):_UN;if(!this._dk){this._dk=COTInputElementFactory.CreateIntegerTextBox(this,2,_FT,false,false,1,ExpAPIXml.maxBlockSize,true);COTInputElementFactory.InsertTextBoxIntoLabelSpan(this._s1,this._dk,this._wC,re);this._vj=true;}else{COTInputElementFactory.SetNewTextBoxValue(this._dk,_FT);}if(_arT){this._dk.focus();}this._da=this._wC.replace(re,_zg);this._s1.title=this._da;this._G.oProxyBlock._b8=this._dk.value;this.bChanged=(!CDLBlockTransaction.IsBlockSizeEqual(this._G.oProxyBlock,this._G.oOriginalBlock));this.SetStyle();this._G.OnUpdateProperty();if(this._G.oProxyBlock._b8==''){this._G.oProxyBlock._b8=String(this._G.oOriginalBlock._yf);}}this.SetValue(_FT);};CUIVisibleItemProperty.prototype.OnTextBoxMaxExceeded=function(id,_Mu){var _BM=this._sp.ReplaceParam('IDS_VISIBLE_ITEM_PROP_MAX_REACHED',1,ExpAPIXml.maxBlockSize);CUIDialogMgr.DisplayMessageBox(CUIMessageBox.kInformation,_BM);};CUIVisibleItemProperty.prototype.OnTextBoxValueChange=function(id,_FT){var _Xn=this._sp.GetString('IDS_VISIBLE_ITEM_PROP_PREFIX');var re=this._sp.GetParameterForReplace(1);if(_FT==''){if(parseInt(this._G.oProxyBlock._b8,10)!=this._G.oOriginalBlock._yf){_FT=this._G.oProxyBlock._b8;}else{this.UpdateProperty(CUIVisibleItemProperty.kDefault,this._uv[CUIVisibleItemProperty.kDefault]);return;}}if((parseInt(_FT,10))<=ExpAPIXml.maxBlockSize){this._G.oProxyBlock._b8=_FT;this.bChanged=!CDLBlockTransaction.IsBlockSizeEqual(this._G.oProxyBlock,this._G.oOriginalBlock);this.SetStyle();this._G.OnUpdateProperty();this.SetValue(_FT);}else{this._dk.value=this._G.oProxyBlock._b8;this._dk.sLastValue=this._G.oProxyBlock._b8;_FT=this._G.oProxyBlock._b8;}this._da=_Xn.replace(re,_FT);this._s1.title=this._da;};CUIVisibleItemProperty.prototype.ShowDropDown=function(e,x,y){var _Kk=new CUIContextMenu(this._gC,0,this);_Kk.SetUnloadOnHide(true);this._G.SetCurrentProp(this);var _awT=false;var _axh=false;for(var i=0;i<this._vy.length;i++){var _Ng=false;if((i==0)&&(this.GetValue()==this._G.oOriginalBlock._yf)){_Ng=true;_awT=true;}else if((!_awT)&&(this.GetValue()==this._vy[i])){_Ng=true;_awT=true;}var _BM=this._uv[this._vy[i]];var _Jj=CUIAbsBlockPropSet.SafeDoUpdateCurrentProperty;var _AG=new Array(this._gC,this._vy[i],this._uv[this._vy[i]]);if(parseInt(this._vy[i],10)>ExpAPIXml.maxBlockSize){continue;}if(parseInt(this._vy[i],10)==ExpAPIXml.maxBlockSize){_BM=this._sp.ReplaceParam('OTH_CROSSTAB_MENU_BLOCK_SIZE_MAX',1,ExpAPIXml.maxBlockSize);_axh=true;}if(this._vy[i]==CUIVisibleItemProperty.kCustomize){if(!_axh){var _asX=this._sp.ReplaceParam('OTH_CROSSTAB_MENU_BLOCK_SIZE_MAX',1,ExpAPIXml.maxBlockSize);var _alx=new Array(this._gC,ExpAPIXml.maxBlockSize,ExpAPIXml.maxBlockSize);var _PM=new ContextItem("",_asX,_Jj,false,_alx,_Kk);_Ng=(this.GetValue()==ExpAPIXml.maxBlockSize);_PM.SetRadioState(_Ng);if(_Ng){_awT=true;}}_Ng=false;if(!_awT){_Ng=true;}}var _PM=new ContextItem("",_BM,_Jj,false,_AG,_Kk);_PM.SetRadioState(_Ng);}_Kk.SetChildrenComplete();_Kk.display(e,true,x,y);};CUIVisibleItemProperty.prototype.Unload=function(){if(this._dk){this._dk.oOwner=null;}CUIVisibleItemProperty.superclass.Unload.call(this);};CUIHiddenItemProperty.kHideAll='hideall';CUIHiddenItemProperty.kMaxItemsToShow=16;function CUIHiddenItemProperty(_Oo,_PQ){this.base=CUIAbsBlockProperty;this.base(_Oo,_PQ);};CUIHiddenItemProperty.prototype=new CUIAbsBlockProperty;CUIHiddenItemProperty.superclass=CUIAbsBlockProperty.prototype;CUIHiddenItemProperty.prototype.EditableChecking=function(){if(this._dI.length==0){this._mr=CUIAbsBlockProperty.eReadOnly;}else{this._mr=CUIAbsBlockProperty.eEditable;}};CUIHiddenItemProperty.prototype.Init=function(){CUIVisibleItemProperty.superclass.Init.call(this);this._vy=new Array();this._uv=new Array();var _aA4=this._G.oOriginalBlock.GetHiddenMemberIds();this._dI=new Array();if(this._G.oOriginalBlock.HasHiddenMembers()){var _RJ=this._G._jC.oUIMgr._qi._ob;for(var i=0;i<_aA4.length;i++){this._dI[i]=_aA4[i];this._vy[i]=_aA4[i];this._uv[i]=_RJ.GetDataLabel(_aA4[i]);}_KG=String(_aA4.length);this._wC=this._sp.ReplaceParam('IDS_HIDDEN_ITEM_POSTFIX',1,_KG);}else{this._wC=this._sp.GetString('IDS_BLOCKPROP_HIDDEN_ITEM_NONE');}this.SetValue(this._dI?this._dI.length:0);this.SetLabel(this._wC,this._wC);this.EditableChecking();};CUIHiddenItemProperty.prototype.HandleClick=function(e,x,y){if(this._mr==CUIAbsBlockProperty.eEditable){if(this._vy.length>0){this.ShowDropDown(e,x,y);}}};CUIHiddenItemProperty.prototype.UpdateProperty=function(_UN,_zg){if(_UN==CUIHiddenItemProperty.kHideAll){if(this._dI.length==0){this._dI=Utilities.CopyArray(this._vy);}else{Utilities.DeleteAllFromArray(this._dI);}}else if(Utilities.IsInArray(this._dI,_UN)){Utilities.DeleteFromArray(this._dI,_UN);}else{this._dI.push(_UN);}this._G.oProxyBlock._wM=this._dI;this.SetValue(this._dI.length);if(this._dI.length==0){this._wC=this._sp.GetString('IDS_BLOCKPROP_HIDDEN_ITEM_NONE');}else{_KG=String(this._dI.length);this._wC=this._sp.ReplaceParam('IDS_HIDDEN_ITEM_POSTFIX',1,_KG);}this.SetLabel(this._wC,this._wC);this.RedrawLabel(!CDLBlockTransaction.AreHiddenMembersEqual(this._G.oProxyBlock,this._G.oOriginalBlock));};CUIHiddenItemProperty.prototype.ShowDropDown=function(e,x,y){var _Kk=new CUIContextMenu(this._gC,0,this);_Kk.SetUnloadOnHide(true);this._G.SetCurrentProp(this);var _Jj=CUIAbsBlockPropSet.SafeDoUpdateCurrentProperty;var _BM=this._sp.GetString('OTH_BLOCKPROP_HIDDEN_ITEM_UNHIDE_ALL');var _AG=new Array(this._gC,CUIHiddenItemProperty.kHideAll,_BM);var _PM=new ContextItem("",_BM,_Jj,false,_AG,_Kk);_PM.SetChecked(this._dI.length==0);var _aIC=new ContextSeparator(_Kk);for(var i=0;i<this._vy.length;i++){_BM=this._sp.ReplaceParam('OTH_BLOCKPROP_HIDDEN_ITEM_UNHIDE',1,this._uv[i]);_AG=new Array(this._gC,this._vy[i],this._uv[i]);var _PM=new ContextItem("",_BM,_Jj,false,_AG,_Kk);var _Ng=!(Utilities.IsInArray(this._dI,this._vy[i]));_PM.SetChecked(_Ng);}if(this._G.oOriginalBlock.GetHiddenMemberIds().length>CUIHiddenItemProperty.kMaxItemsToShow){_BM=this._sp.GetString('OTH_BLOCKPROP_HIDDEN_ITEM_MORE');var _PM=new ContextItem("",_BM,Utilities.DoNothing,true,_AG,_Kk);}_Kk.SetChildrenComplete();_Kk.display(e,true,x,y);};CUIViewProperty.kHierView='hierview';CUIViewProperty.kFlatView='flatview';function CUIViewProperty(_Oo,_PQ){this.base=CUIAbsBlockProperty;this.base(_Oo,_PQ);};CUIViewProperty.prototype=new CUIAbsBlockProperty;CUIViewProperty.superclass=CUIAbsBlockProperty.prototype;CUIViewProperty.prototype.Init=function(){CUIViewProperty.superclass.Init.call(this);this._vy=new Array(CUIViewProperty.kFlatView,CUIViewProperty.kHierView);this._uv=new Array(this._sp.GetString('OTH_CROSSTAB_MENU_VIEWS_NO_HIERARCHY'),this._sp.GetString('OTH_CROSSTAB_MENU_VIEWS_HIERARCHY'));this._wC=this._G.oOriginalBlock.IsHierarchyEnabled()?this._sp.GetString('IDS_BLOCKPROP_VIEW_HIER'):this._sp.GetString('IDS_BLOCKPROP_VIEW_FLAT');this.SetValue(this._G.oOriginalBlock.IsHierarchyEnabled()?CUIViewProperty.kHierView:CUIViewProperty.kFlatView);this.SetLabel(this._wC,this._wC);this._mr=CUIAbsBlockProperty.eEditable;if(!this._G.oOriginalBlock.CanHierarchize()){this._mr=CUIAbsBlockProperty.eReadOnly;}};CUIViewProperty.prototype.HandleClick=function(e,x,y){if(this._mr==CUIAbsBlockProperty.eEditable){this.ShowDropDown(e,x,y);}};CUIViewProperty.prototype.UpdateProperty=function(_UN,_zg){if(_UN==CUIViewProperty.kHierView&&this._G.oProxyBlock.IsExplicitSort()){CUIDialogMgr._U.SetCallBackFuntion(Utilities.ExecuteHoldingProcedure);CUIDialogMgr._U.Display('IDS_VIEW_HIER_SORT_WARNING','',CUIConfirmDlg._hw);var _Ro=new Array(this,_UN,_zg);Utilities.SetProcedureToHold(CUIViewProperty.SafeDoContinueUpdateProperty,_Ro);return;}else{this.DoContinueUpdateProperty(_UN,_zg);}};CUIViewProperty.SafeDoConfirm=function(){/*@if(!@bering_debug)@*/try{/*@end@*/Utilities.ExecuteHoldingProcedure();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIViewProperty.SafeDoContinueUpdateProperty=function(_Vw,_UN,_zg){/*@if(!@bering_debug)@*/try{/*@end@*/_Vw.DoContinueUpdateProperty(_UN,_zg);CUIDialogMgr.SafeHideCurrentDialog(_Vw._gC);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIViewProperty.prototype.DoContinueUpdateProperty=function(_UN,_zg){if(_UN==CUIViewProperty.kHierView){this._G.oProxyBlock.bHierarchyEnabled=true;}else{this._G.oProxyBlock.bHierarchyEnabled=false;}this.SetValue(_UN);this.SetLabel(_zg,_zg);var _U5=!CDLBlockTransaction.IsViewPropEqual(this._G.oProxyBlock,this._G.oOriginalBlock);var _BY=true;this.RedrawLabel(_U5,_BY);};CUIViewProperty.prototype.UpdatePropertyFromBlock=function(_FK,_BY){this._wC=_FK.IsHierarchyEnabled()?this._sp.GetString('IDS_BLOCKPROP_VIEW_HIER'):this._sp.GetString('IDS_BLOCKPROP_VIEW_FLAT');this.SetValue(_FK.IsHierarchyEnabled()?CUIViewProperty.kHierView:CUIViewProperty.kFlatView);this.SetLabel(this._wC,this._wC);this._mr=CUIAbsBlockProperty.eEditable;if(!this._G.oProxyBlock.CanHierarchize()){this._mr=CUIAbsBlockProperty.eReadOnly;}var _U5=!CDLBlockTransaction.IsViewPropEqual(this._G.oProxyBlock,this._G.oOriginalBlock);var _BY=false;this.RedrawLabel(_U5,_BY);};CUIViewProperty.prototype.ShowDropDown=function(e,x,y){var _Kk=new CUIContextMenu(this._gC,0,this);_Kk.SetUnloadOnHide(true);this._G.SetCurrentProp(this);for(var i=0;i<this._vy.length;i++){var _Ng=this._vy[i]==this.GetValue();var _BM=this._uv[i];var _Jj=CUIAbsBlockPropSet.SafeDoUpdateCurrentProperty;var _AG=new Array(this._gC,this._vy[i],this._uv[i]);var _PM=new ContextItem("",_BM,_Jj,false,_AG,_Kk);_PM.SetRadioState(_Ng);}_Kk.SetChildrenComplete();_Kk.display(e,true,x,y);};CUIViewProperty.prototype.Unload=function(){CUIViewProperty.superclass.Unload.call(this);};CUIAutoSummaryProperty.kShowVisible=1;CUIAutoSummaryProperty.kCalcItems=2;CUIAutoSummaryProperty.kVisibleSubtotal=3;CUIAutoSummaryProperty.kOther=4;CUIAutoSummaryProperty.kIncluded=5;CUIAutoSummaryProperty.kExcluded=6;CUIAutoSummaryProperty.kTotal=7;function CUIAutoSummaryProperty(_Oo,_PQ,_Dv,_Cu){this.base=CUIAbsBlockProperty;this.base(_Oo,_PQ);this._dF=_Dv;this._l2=_Cu;};CUIAutoSummaryProperty.prototype=new CUIAbsBlockProperty;CUIAutoSummaryProperty.superclass=CUIAbsBlockProperty.prototype;CUIAutoSummaryProperty.prototype.EditableChecking=function(){if(this._G.oProxyBlock.CanApplyAutoSubtotals()){this._mr=CUIAbsBlockProperty.eEditable;}else{this._mr=CUIAbsBlockProperty.eReadOnly;}};CUIAutoSummaryProperty.prototype.Init=function(){CUIAutoSummaryProperty.superclass.Init.call(this);this._vy=new Array();this._uv=new Array();this._xQ=new Object();var _K5=new Array();if(this._G.oProxyBlock.CanApplyShowSubtotalsOnly()){this._xQ[CUIAutoSummaryProperty.kShowVisible]=this._G.oProxyBlock.IsVisibleEnabled();if(this._xQ[CUIAutoSummaryProperty.kShowVisible]){_K5.push(this._sp.GetString('IDS_BLOCKPROP_AUTOSUMMARY_VISIBLE_ITEMS_DESC'));}}if(this._G.oProxyBlock.CanApplyUserDefCalculation()){this._xQ[CUIAutoSummaryProperty.kCalcItems]=true;if(this._xQ[CUIAutoSummaryProperty.kCalcItems]){_K5.push(this._sp.GetString('IDS_BLOCKPROP_AUTOSUMMARY_CALC_ITEMS'));}}if(this._G.oProxyBlock.CanApplySubtotalVisibleItems()){this._xQ[CUIAutoSummaryProperty.kVisibleSubtotal]=this._G.oProxyBlock.IsSubTotalEnabled();if(this._xQ[CUIAutoSummaryProperty.kVisibleSubtotal]){_K5.push(this._sp.GetString('IDS_BLOCKPROP_AUTOSUMMARY_SUBTOTAL_VISIBLE_ITEMS'));}}if(this._G.oProxyBlock.CanApplyRemainder()){this._xQ[CUIAutoSummaryProperty.kOther]=this._G.oProxyBlock.IsRemainderEnabled();if(this._xQ[CUIAutoSummaryProperty.kOther]){_K5.push(this._sp.GetString('IDS_BLOCKPROP_AUTOSUMMARY_OTHER'));}}if(this._G.oProxyBlock.CanApplyFilterSubtotals()){this._xQ[CUIAutoSummaryProperty.kIncluded]=this._G.oProxyBlock.IsPassedFilterAggregateEnabled();if(this._xQ[CUIAutoSummaryProperty.kIncluded]){_K5.push(this._sp.GetString('IDS_BLOCKPROP_AUTOSUMMARY_NOTEXCLUDED'));}this._xQ[CUIAutoSummaryProperty.kExcluded]=this._G.oProxyBlock.IsFilterAggregateEnabled();if(this._xQ[CUIAutoSummaryProperty.kExcluded]){_K5.push(this._sp.GetString('IDS_BLOCKPROP_AUTOSUMMARY_EXCLUDED'));}}if(this._G.oProxyBlock.CanApplySummary()){this._xQ[CUIAutoSummaryProperty.kTotal]=this._G.oProxyBlock.ShowSummary();if(this._xQ[CUIAutoSummaryProperty.kTotal]){_K5.push(this._sp.GetString('IDS_BLOCKPROP_AUTOSUMMARY_TOTAL'));}}this.PopulateFullLabel(_K5);this._wt="edit_property.gif";this.SetLabel(this._wC,this._wC);this.EditableChecking();};CUIAutoSummaryProperty.prototype.PopulateFullLabel=function(_K5){if(_K5.length==0){this._wC=this._sp.GetString('IDS_BLOCKPROP_AUTOSUMMARY_NONE');}else if(_K5.length==1){this._wC=this._sp.ReplaceParam('IDS_BLOCKPROP_AUTOSUMMARY',1,_K5[0]);return;}else{var _aHB=this._sp.ReplaceParamList('IDS_BLOCKPROP_VALUE_LIST',_K5);this._wC=this._sp.ReplaceParam('IDS_BLOCKPROP_AUTOSUMMARY',1,_aHB);}};CUIAutoSummaryProperty.prototype.HandleClick=function(e,x,y){if(this._mr==CUIAbsBlockProperty.eEditable){this._G.SetCurrentProp(this);var _FK=this._G.oProxyBlock;_FK._hu=new Object();Utilities.CopyObjArray(this._xQ,_FK._hu);var _ano=this._G._jC.GetAutoSummaryDlg();_ano.SetHostObj(_FK);_ano.Display();}};CUIAutoSummaryProperty.prototype.UpdatePropertyFromBlock=function(_FK,_BY){var _K5=new Array();for(var i in this._xQ){if(this._G.oProxyBlock._hu){this._xQ[i]=this._G.oProxyBlock._hu[i];}var _Ic;switch(parseInt(i,10)){case CUIAutoSummaryProperty.kShowVisible:_Ic=this._sp.GetString('IDS_BLOCKPROP_AUTOSUMMARY_VISIBLE_ITEMS_DESC');this._G.oProxyBlock.bVisibleEnabled=this._xQ[i];break;case CUIAutoSummaryProperty.kCalcItems:_Ic=this._sp.GetString('IDS_BLOCKPROP_AUTOSUMMARY_CALC_ITEMS');break;case CUIAutoSummaryProperty.kVisibleSubtotal:_Ic=this._sp.GetString('IDS_BLOCKPROP_AUTOSUMMARY_SUBTOTAL_VISIBLE_ITEMS');this._G.oProxyBlock.bSubTotalEnabled=this._xQ[i];break;case CUIAutoSummaryProperty.kOther:_Ic=this._sp.GetString('IDS_BLOCKPROP_AUTOSUMMARY_OTHER');this._G.oProxyBlock.bRemainderEnabled=this._xQ[i];break;case CUIAutoSummaryProperty.kIncluded:_Ic=this._sp.GetString('IDS_BLOCKPROP_AUTOSUMMARY_NOTEXCLUDED');this._G.oProxyBlock.bPassedFilterAggEnabled=this._xQ[i];break;case CUIAutoSummaryProperty.kTotal:_Ic=this._sp.GetString('IDS_BLOCKPROP_AUTOSUMMARY_TOTAL');this._G.oProxyBlock._fZ=this._xQ[i];break;case CUIAutoSummaryProperty.kExcluded:_Ic=this._sp.GetString('IDS_BLOCKPROP_AUTOSUMMARY_EXCLUDED');this._G.oProxyBlock.bFilterAggEnabled=this._xQ[i];break;default:break;}if(this._xQ[i]){_K5.push(_Ic);}}this.PopulateFullLabel(_K5);this.SetLabel(this._wC,this._wC);this.EditableChecking();var _U5=!CDLBlockTransaction.IsAutoSummaryEqual(this._G.oProxyBlock,this._G.oOriginalBlock);this.RedrawLabel(_U5,_BY);if(this._G.oProxyBlock._hu){Utilities.ClearObjectArray(this._G.oProxyBlock._hu);this._G.oProxyBlock._hu=null;}};CUIAutoSummaryProperty.prototype.Unload=function(){CUIAutoSummaryProperty.superclass.Unload.call(this);};CUIAttributeProperty.kShowAll='showall';function CUIAttributeProperty(_Oo,_PQ){this.base=CUIAbsBlockProperty;this.base(_Oo,_PQ);};CUIAttributeProperty.prototype=new CUIAbsBlockProperty;CUIAttributeProperty.superclass=CUIAbsBlockProperty.prototype;CUIAttributeProperty.prototype.Init=function(){CUIAttributeProperty.superclass.Init.call(this);this._vy=new Array();this._uv=new Array();this._ev=this._G.oOriginalBlock.GetAllDistinctProps();var _ZR=new Object();if(this._ev.IsAllPropsRetrieved()){_ZR=this._ev.GetExistProps();}else{this._uQ=true;}this._gq=new Object();var _Og=new Array();this._uv=new Array();if(Utilities.IsObjectEmpty(_ZR)&&(!this._uQ)){this._vy.push(ContextItem.kNoneValue);this._uv.push(this._sp.GetString('IDS_BLOCKPROP_ATTRIBUTE_NONE_DROP_DOWN_ITEM'));}else{var oProp=null;for(var i in _ZR){oProp=_ZR[i];if(Utilities.IsInArray(this._G.oOriginalBlock._qS,i)){this._gq[oProp.GetId()]=true;_Og.push(oProp.GetBreadCrumbText());}else{this._gq[oProp.GetId()]=false;}this._vy.push(oProp.GetId());this._uv.push(oProp.GetBreadCrumbText());}}this._mr=CUIAbsBlockProperty.eEditable;this.PopulateFullLabel(_Og);this.SetValue(this._gq);this.SetLabel(this._wC,this._wC);};CUIAttributeProperty.prototype.PopulateFullLabel=function(_Og){if(_Og.length==0){this._wC=this._sp.GetString('IDS_BLOCKPROP_ATTRIBUTE_NONE');}else{var _76=this._sp.ReplaceParamList('IDS_BLOCKPROP_VALUE_LIST',_Og);this._wC=this._sp.ReplaceParam('IDS_BLOCKPROP_ATTRIBUTE',1,_76);}};CUIAttributeProperty.prototype.HandleClick=function(e,x,y){if(this._mr==CUIAbsBlockProperty.eEditable){if(this._vy.length>0||this._uQ){this.ShowDropDown(e,x,y);}}};CUIAttributeProperty.prototype.UpdateProperty=function(_UN,_zg){this._gq[_UN]=(!this._gq[_UN]);if(this._gq[_UN]){this._G.oProxyBlock._qS.push(_UN);}else{Utilities.DeleteFromArray(this._G.oProxyBlock._qS,_UN);}var _Og=new Array();for(var i in this._gq){var _PQ=Utilities.GetObjIndex(this._vy,i);var _Ic=this._uv[_PQ];if(this._gq[i]){_Og.push(_Ic);}}this.PopulateFullLabel(_Og);this.SetLabel(this._wC,this._wC);this.RedrawLabel(!CDLBlockTransaction.IsDisplayAttributesEqual(this._G.oProxyBlock,this._G.oOriginalBlock));};CUIAttributeProperty.prototype.FetchPropertiesOnFly=function(){var _RJ=this._G._jC.oUIMgr._qi._ob;_RJ.FetchProperties(this._ev.GetIncompletePropOwner());_RJ.Subscribe(this._ev,ExpEvent.kCDLMetadata_Merge_Properties);this._ev.Subscribe(this,ExpEvent.kCOTPropsLoadingMgr_Merge_Complete);};CUIAttributeProperty.prototype.ShowDropDown=function(e,x,y){var _Kk=new CUIContextMenu(this._gC,0,this);_Kk.SetUnloadOnHide(true);this._G.SetCurrentProp(this);if(this._uQ){var _PM=new ContextItem("icon_loading.gif",this._sp.GetString('IDS_CONTEXTBAR_LOADING'),null,true,null,_Kk);this._kt=_Kk;this.oLastEvent=Dom.CloneMouseEvent(e);this.oLastXPos=x;this.oLastYPos=y;this.FetchPropertiesOnFly();}else{var _Jj=CUIAbsBlockPropSet.SafeDoUpdateCurrentProperty;for(var i=0;i<this._vy.length;i++){var _BM=this._uv[i];var _AG=new Array(this._gC,this._vy[i],_BM);var _PM=new ContextItem("",_BM,_Jj,(this._vy[i]==ContextItem.kNoneValue),_AG,_Kk);var _Ng=this._gq[this._vy[i]];_PM.SetChecked(_Ng);}_Kk.SetChildrenComplete();}_Kk.display(e,true,x,y);};CUIAttributeProperty.prototype.UpdateAttributeLoadingMenu=function(){this._uQ=false;var _Kk=this._kt;if(_Kk&&_Kk.IsVisible()){_Kk.Clear();var _ZR=this._ev.GetExistProps();if(Utilities.IsObjectEmpty(_ZR)){this._vy.push(ContextItem.kNoneValue);var _asb=this._sp.GetString('IDS_BLOCKPROP_ATTRIBUTE_NONE_DROP_DOWN_ITEM');this._uv.push(_asb);var _aqf=new ContextItem("",_asb,null,true,null,_Kk);}else{var oProp=null;var _Jj=CUIAbsBlockPropSet.SafeDoUpdateCurrentProperty;for(var i in _ZR){oProp=_ZR[i];this._vy.push(oProp.GetId());var _BM=oProp.GetBreadCrumbText();this._uv.push(_BM);var _AG=new Array(this._gC,this._vy[i],this._uv[i]);var _PM=new ContextItem("",_BM,_Jj,false,_AG,_Kk);}_Kk.SetChildrenComplete();}_Kk.display(this.oLastEvent,true,this.oLastXPos,this.oLastYPos);}this._kt=null;this.oLastEvent=null;this.oLastXPos=null;this.oLastYPos=null;};CUIAttributeProperty.prototype.Unload=function(){CUIAttributeProperty.superclass.Unload.call(this);};CUIAttributeProperty.prototype.Notify=function(_Dy){if(_Dy==ExpEvent.kCOTPropsLoadingMgr_Merge_Complete){var _RJ=this._G._jC.oUIMgr._qi._ob;this.UpdateAttributeLoadingMenu();_RJ.UnSubscribe(this._ev,ExpEvent.kCDLMetadata_Merge_Properties);this._ev.UnSubscribe(this,ExpEvent.kCOTPropsLoadingMgr_Merge_Complete);}};function CUIMoreUnavailableProperty(_Oo,_PQ){this.base=CUIAbsBlockProperty;this.base(_Oo,_PQ);};CUIMoreUnavailableProperty.prototype=new CUIAbsBlockProperty;CUIMoreUnavailableProperty.superclass=CUIAbsBlockProperty.prototype;CUIMoreUnavailableProperty.prototype.Init=function(){CUIMoreUnavailableProperty.superclass.Init.call(this);this._wC=this._sp.GetString('IDS_BLOCKPROP_PROP_MORE_UNAVAILABLE');this.SetLabel(this._wC,this._wC);this.SetReadOnly();};CUIAttributeProperty.prototype.Unload=function(){CUIMoreUnavailableProperty.superclass.Unload.call(this);};CUITopBottomProperty.kNoTopBottom=0;CUITopBottomProperty.kTop=1;CUITopBottomProperty.kBottom=2;CUITopBottomProperty.kCustom=3;CUITopBottomProperty.kIntOption1=5;CUITopBottomProperty.kIntOption2=10;CUITopBottomProperty.kIntOption3=20;CUITopBottomProperty.kPercentOption1=5;CUITopBottomProperty.kPercentOption2=10;CUITopBottomProperty.kPercentOption3=20;CUITopBottomProperty.kPercentOption4=25;CUITopBottomProperty.kDefaultSize=10;function CUITopBottomProperty(_Oo,_Dl){this.base=CUIAbsBlockProperty;this.base(_Oo,_Dl);};CUITopBottomProperty.prototype=new CUIAbsBlockProperty;CUITopBottomProperty.superclass=CUIAbsBlockProperty.prototype;CUITopBottomProperty.prototype.Init=function(){CUITopBottomProperty.superclass.Init.call(this);var _BM="";if(this._G.oProxyBlock.HasTopBottomRule()){_BM=this._G.oProxyBlock.GetSubset().GetLabel();this._mb="top_bottom_12.gif";}else{_BM=this._sp.GetString('IDS_BLOCKPROP_TOPBOTTOM_RULE_NONE');this._mb=null;}this.SetLabel(_BM,_BM);this._vy=new Array(CUITopBottomProperty.kNoTopBottom,CUITopBottomProperty.kTop,CUITopBottomProperty.kBottom,CUITopBottomProperty.kCustom);this._uv=new Array();this._uv[CUITopBottomProperty.kNoTopBottom]=this._sp.GetString('OTH_BLOCKPROP_TOPBOTTOM_MENU_NO');this._uv[CUITopBottomProperty.kTop]=this._sp.GetString('OTH_BLOCKPROP_TOPBOTTOM_MENU_TOP');this._uv[CUITopBottomProperty.kBottom]=this._sp.GetString('OTH_BLOCKPROP_TOPBOTTOM_MENU_BOTTOM');this._uv[CUITopBottomProperty.kCustom]=this._sp.GetString('OTH_BLOCKPROP_TOPBOTTOM_MENU_CUSTOM');this._jv=new Array(CUITopBottomProperty.kIntOption1,CUITopBottomProperty.kIntOption2,CUITopBottomProperty.kIntOption3);this._ru=new Array(CUITopBottomProperty.kPercentOption1,CUITopBottomProperty.kPercentOption2,CUITopBottomProperty.kPercentOption3,CUITopBottomProperty.kPercentOption4);this.setValueFromBlock(this._G.oProxyBlock);};CUITopBottomProperty.prototype.setValueFromBlock=function(_FK){if(!_FK.HasTopBottomRule()){this.SetValue(CUITopBottomProperty.kNoTopBottom);}else if((!_FK.GetSubset().IsDefaultSortMember())||(!_FK.GetSubset().IsDefaultSortMeasure())){this.SetValue(CUITopBottomProperty.kCustom);}else if(_FK.GetSubset()._aK==ExpAPIXml.kEleAxisOpExprSorttypeTop){this.SetValue(CUITopBottomProperty.kTop);}else{this.SetValue(CUITopBottomProperty.kBottom);}this._mr=CUIAbsBlockProperty.eEditable;if(_FK.IsLocked()){this._mr=CUIAbsBlockProperty.eReadOnly;}};CUITopBottomProperty.prototype.UpdateProperty=function(_UN,_zg){if(_zg==this.sTextBoxArrowId){this._G.oProxyBlock.GetSubset()._uj=_UN;}else if(_zg==this.sTopArrowId){if(_UN==CUITopBottomProperty.kNoTopBottom){if(this._G.oProxyBlock._mF){this._G.oProxyBlock._mF.DeleteTopBottom();}this._mb=null;;}else if(_UN==CUITopBottomProperty.kTop){this._mb="top_bottom_12.gif";if(!this._G.oProxyBlock.GetSubset()){this._G.oProxyBlock._mF=new CDLFilterExpr(this._G.oProxyBlock.oAxis._rk._he);this._G.oProxyBlock._mF._qs=new Array(DefaultConstants.kDefScope);}if(this._G.oProxyBlock.GetSubset()._uj==null){this._G.oProxyBlock.GetSubset()._uj=CUITopBottomProperty.kDefaultSize;}this._G.oProxyBlock.GetSubset()._aK=ExpAPIXml.kEleAxisOpExprSorttypeTop;if(this._G.oProxyBlock.GetSubset()._sf==null){this._G.oProxyBlock.GetSubset()._sf=ExpAPIXml.eSubsetTypeInteger;}this.updateMeasure();}else if(_UN==CUITopBottomProperty.kBottom){this._mb="top_bottom_12.gif";if(!this._G.oProxyBlock.GetSubset()){this._G.oProxyBlock._mF=new CDLFilterExpr(this._G.oProxyBlock.oAxis._rk._he);this._G.oProxyBlock._mF._qs=new Array(DefaultConstants.kDefScope);}if(this._G.oProxyBlock.GetSubset()._uj==null){this._G.oProxyBlock.GetSubset()._uj=CUITopBottomProperty.kDefaultSize;}this._G.oProxyBlock.GetSubset()._aK=ExpAPIXml.kEleAxisOpExprSorttypeBottom;if(this._G.oProxyBlock.GetSubset()._sf==null){this._G.oProxyBlock.GetSubset()._sf=ExpAPIXml.eSubsetTypeInteger;}this.updateMeasure();}}this.setValueFromBlock(this._G.oProxyBlock);var _U5=!CDLBlockTransaction.IsSubsetEqual(this._G.oProxyBlock,this._G.oOriginalBlock);this.bChanged=_U5;this.Draw(null,_U5);};CUITopBottomProperty.prototype.updateMeasure=function(){var _Li=this._G._jC.oUIMgr.dataManager.GetCurrentDataMatrix();var _Tc=this._G._jC.oUIMgr.dataManager.metadata;if(!_Li.GetCurrentMeasure()&&this._G.oProxyBlock.GetSubset()._sA==null){var _Hf=true;var _aho=_Li.GetAllMeasuresAndMeasureCalcs(_Hf);var _BM="";for(var _aqb in _aho){this._G.oProxyBlock.GetSubset()._sA=_aqb;break;}if(this._G.oProxyBlock.GetSubset()._sA==null){for(var i in _Tc._yb){this._G.oProxyBlock.GetSubset()._sA=i;break;}}}else{this._G.oProxyBlock.GetSubset()._sA=DefaultConstants.kDefMeasure;}};CUITopBottomProperty.prototype.UpdatePropertyFromBlock=function(_FK,_BY){this.setValueFromBlock(_FK);var _U5=!CDLBlockTransaction.IsSubsetEqual(this._G.oProxyBlock,this._G.oOriginalBlock);this.bChanged=_U5;if(this._G.oProxyBlock.HasTopBottomRule()){this._mb="top_bottom_12.gif";}else{this._mb=null;}this.Draw(null,_U5);};CUITopBottomProperty.prototype.Draw=function(_ID,_U5){Dom.RemoveAllChildren(this._J);if(_ID){_ID.appendChild(this._J);}var _avT="";var _8f=this._G.oProxyBlock.GetSubset();if(this._jU==CUITopBottomProperty.kNoTopBottom||_8f._aK==null){var _BM=this._sp.GetString('IDS_BLOCKPROP_TOPBOTTOM_RULE_NONE');this.SetLabel(_BM,_BM);CUITopBottomProperty.superclass.Draw.call(this);var _QX=Dom.GetElementsByTagName(this._J,"IMG");Debug.Assert(_QX[0]);if(_QX[0]){this.sTopArrowId=Utilities.GenerateId();_QX[0].id=this.sTopArrowId;}}else{if(this._mb){this._hI=COTInputElementFactory.CreateImage(this._mb,12,12);this._hI.style.paddingRight='5px';this._hI.style.paddingTop='1px';this._J.appendChild(this._hI);if(this._mr==CUIAbsBlockProperty.eReadOnly){this._hI.style.display="none";}else{this._hI.style.display="inline";}}var _BM=this._G.oProxyBlock.GetSubset().GetLabel();this.SetLabel(_BM,_BM);this._J.title=_BM;var _Xo="";var _YE=0;var _4k="";if(_8f._sf==ExpAPIXml.eSubsetTypePercentage){_4k="_PERCENT";}else if(_8f._sf==ExpAPIXml.eSubsetTypeSum){_4k="_SUM";}if((!_8f.IsDefaultSortMeasure())&&(!_8f.IsDefaultSortMember())){if(_8f._aK==ExpAPIXml.kEleAxisOpExprSorttypeTop){_Xo='IDS_BLOCKPROP_TOPBOTTOM_RULE_TOP'+_4k+'_MEMBER_MEASURE';}else{_Xo='IDS_BLOCKPROP_TOPBOTTOM_RULE_BOTTOM'+_4k+'_MEMBER_MEASURE';}_YE=5;}else if(!_8f.IsDefaultSortMeasure()){if(_8f._aK==ExpAPIXml.kEleAxisOpExprSorttypeTop){_Xo='IDS_BLOCKPROP_TOPBOTTOM_RULE_TOP'+_4k+'_MEASURE';}else{_Xo='IDS_BLOCKPROP_TOPBOTTOM_RULE_BOTTOM'+_4k+'_MEASURE';}_YE=4;}else if(!_8f.IsDefaultSortMember()){if(_8f._aK==ExpAPIXml.kEleAxisOpExprSorttypeTop){_Xo='IDS_BLOCKPROP_TOPBOTTOM_RULE_TOP'+_4k+'_MEMBER';}else{_Xo='IDS_BLOCKPROP_TOPBOTTOM_RULE_BOTTOM'+_4k+'_MEMBER';}_YE=5;}else{if(_8f._aK==ExpAPIXml.kEleAxisOpExprSorttypeTop){_Xo='IDS_BLOCKPROP_TOPBOTTOM_RULE_TOP'+_4k;}else{_Xo='IDS_BLOCKPROP_TOPBOTTOM_RULE_BOTTOM'+_4k;}_YE=3;}if(_8f._sf==ExpAPIXml.eSubsetTypeSum){_YE=6;}var _alq=this._sp.ParseStringForParamOrder(_Xo,_YE);var _RJ=this._G._jC.oUIMgr.dataManager.metadata;for(var i=0;i<_alq.length;i++){if(_alq[i]){if(_alq[i].sBefore){this._s1=document.createElement('SPAN');this._J.appendChild(this._s1);this._s1.appendChild(document.createTextNode(_alq[i].sBefore));}switch(_alq[i].sElement){case this._sp.GetParameter(1):var _apk=this.DrawDropDownArrow(this._J);this.sTopArrowId=Utilities.GenerateId();_apk.id=this.sTopArrowId;if(this._mr==CUIAbsBlockProperty.eReadOnly){this.oArrowImg.style.display="none";}else{this.oArrowImg.style.display="inline";}break;case this._sp.GetParameter(2):var _FT=this._G.oProxyBlock.GetSubset().GetSortSizeAsString();if(this._mr==CUIAbsBlockProperty.eReadOnly){this._J.appendChild(document.createTextNode(_FT));}else{if(_8f._sf==ExpAPIXml.eSubsetTypeInteger){var _Ll=COTInputElementFactory.CreateIntegerTextBox(this,3,_FT,false,false,1,null,true);}else if(_8f._sf==ExpAPIXml.eSubsetTypePercentage){var _Ll=COTInputElementFactory.CreateFloatTextBox(this,3,_FT,false,false,0,100,true);}else{var _Ll=COTInputElementFactory.CreateFloatTextBox(this,7,_FT,false,false,null,null,true);}this._J.appendChild(_Ll);}break;case this._sp.GetParameter(3):var _apF=this.DrawDropDownArrow(this._J);this.sTextBoxArrowId=Utilities.GenerateId();_apF.id=this.sTextBoxArrowId;if(this._mr==CUIAbsBlockProperty.eReadOnly){_apF.style.display="none";}else{_apF.style.display="inline";}break;case this._sp.GetParameter(4):var _azC=_RJ.GetDataLabel(_8f._sA);if((!_azC)||_azC==""){_azC=_8f._lR._kX.GetCalculation(_8f._sA).GetLabel();}var _ay8=document.createElement('SPAN');_ay8.appendChild(document.createTextNode(_azC));this._J.appendChild(_ay8);break;case this._sp.GetParameter(5):var _Zi=CDLBlock.GetTupleMembersLabel(null,null,_8f._lR.GetCurrentDataMatrix(),_8f._qs);var _ay8=document.createElement('SPAN');_ay8.appendChild(document.createTextNode(_Zi));this._J.appendChild(_ay8);break;case this._sp.GetParameter(6):var _ay8=document.createElement('SPAN');this._J.appendChild(document.createTextNode('\u2211'));this._J.appendChild(_ay8);break;}if(_alq[i].sAfter){this._s1=document.createElement('SPAN');this._J.appendChild(this._s1);this._s1.appendChild(document.createTextNode(_alq[i].sAfter));}}}Dom.SetObjRef(this._J,this,'oProp');this._J.onmouseover=CUIAbsBlockProperty.SafeHandleMouseOver;this._J.onmouseout=CUIAbsBlockProperty.SafeHandleMouseOut;this._J.onclick=Utilities.EventCallback(this.GeneralHandleClick,[],this,false,true);}this._G.OnUpdateProperty();this.SetStyle();};CUITopBottomProperty.prototype.OnTextBoxValueChange=function(id,_FT){this._G.oProxyBlock.GetSubset()._uj=parseInt(_FT);if(this._G.oProxyBlock.GetSubset()._sf==ExpAPIXml.eSubsetTypeSubsVar){this._G.oProxyBlock.GetSubset()._sf=ExpAPIXml.eSubsetTypeInteger;}var _U5=!CDLBlockTransaction.IsSubsetEqual(this._G.oProxyBlock,this._G.oOriginalBlock);this.bChanged=_U5;this._G.OnUpdateProperty();this.SetStyle();};CUITopBottomProperty.prototype.HandleClick=function(e,x,y){if(this._mr==CUIAbsBlockProperty.eEditable){this.ShowDropDown(e,x,y);}};CUITopBottomProperty.prototype.ShowDropDown=function(e,x,y){var _yW=Dom.GetEventTarget(e);if(_yW&&_yW.id==this.sTopArrowId||this._jU==CUITopBottomProperty.kNoTopBottom){var _aCk=false;if(!this._df){_aCk=true;this._df=new CUIContextMenu(this._gC,0,this);}this._G.SetCurrentProp(this);var _awT=false;for(var i=0;i<this._vy.length;i++){var _Ng=false;var _Ss=false;if((!_awT)&&(this.GetValue()==this._vy[i])){_Ng=true;_awT=true;}if(_aCk){var _BM=this._uv[this._vy[i]];var _Jj=CUIAbsBlockPropSet.SafeDoUpdateCurrentProperty;var _PM=new ContextItem("",_BM,_Jj,_Ss,null,this._df);}var _AG=new Array(this._gC,this._vy[i],this.sTopArrowId);if(this._vy[i]==CUITopBottomProperty.kCustom){this._df.items[i].SetItemAction(CUITopBottomProperty.SafeDoShowTopBottomDlg);_AG=new Array(this);}this._df.items[i].SetParameterArr(_AG);this._df.items[i].SetRadioState(_Ng);if(this._df.items[i]._ny==this._sp.GetString('OTH_BLOCKPROP_TOPBOTTOM_MENU_TOP')||this._df.items[i]._ny==this._sp.GetString('OTH_BLOCKPROP_TOPBOTTOM_MENU_BOTTOM')){this._df.items[i].SetEnabled(this._G.oProxyBlock.oAxis._rk.GetCurrentMeasure());}}this._df.SetChildrenComplete();this._df.display(e,true,x,y);}else if(_yW.id==this.sTextBoxArrowId){if(!this._il){this._il=new CUIContextMenu(this._gC,0,this);}this._il.Clear();this._G.SetCurrentProp(this);var _awT=false;var _KW=this._jv;if(this._G.oProxyBlock.GetSubset()._sf==ExpAPIXml.eSubsetTypePercentage){_KW=this._ru;}for(var i=0;i<_KW.length;i++){var _Ng=false;var _Ss=false;if((!_awT)&&(this._G.oProxyBlock.GetSubset()._uj==_KW[i])){_Ng=true;_awT=true;}var _BM=new String(_KW[i]);if(_KW==this._ru){_BM=this._sp.ReplaceParam('OTH_BLOCKPROP_TOPBOTTOM_RULE_PERCENTAGE_DROPDOWN',1,_KW[i]);}var _Jj=CUIAbsBlockPropSet.SafeDoUpdateCurrentProperty;var _AG=new Array(this._gC,_KW[i],this.sTextBoxArrowId);var _PM=new ContextItem("",_BM,_Jj,_Ss,_AG,this._il);_PM.SetRadioState(_Ng);}var _BM=this._sp.GetString('OTH_BLOCKPROP_TOPBOTTOM_MENU_CUSTOM');var _AG=new Array(this);var _PM=new ContextItem("",_BM,CUITopBottomProperty.SafeDoShowTopBottomDlg,_Ss,_AG,this._il);if(!_awT){_PM.SetRadioState(true);}this._il.SetChildrenComplete();this._il.display(e,true,x,y);}};CUITopBottomProperty.prototype.SetStyle=function(){this._J.className=this._uu;if(this.bChanged){this._J.className+=' prop_div_changed';}if(this.bHover){this._J.className+=' prop_div_hover';}if(this.bSelected){this._J.className+=' prop_div_selected';}if(this._mr==CUIAbsBlockProperty.eEditable&&this._jU==CUITopBottomProperty.kNoTopBottom){this._J.className+=" prop_div_editable";}var _aHM=Dom.GetElementsByTagName(this._J,"INPUT");if(_aHM&&_aHM[0]){if(this.bChanged){_aHM[0].className+=" integerTextBox_changed";}else{_aHM[0].className=_aHM[0].sBaseClassName;}}};CUITopBottomProperty.SafeDoShowTopBottomDlg=function(_As){/*@if(!@bering_debug)@*/try{/*@end@*/_As.ShowTopBottomDlg();/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUITopBottomProperty.prototype.ShowTopBottomDlg=function(){var _X9=this._G._jC.GetTopBottomDlg();_X9.Display();_X9.SetHostObj(this._G.oProxyBlock);};CUITopBottomProperty.prototype.Unload=function(){if(this._df){this._df.Unload();}if(this._il){this._il.Unload();}var _ano=this._G._jC.oUIMgr.oDialogMgr._jg;if(_ano&&(_ano instanceof CUITopBottomDlg)&&(_ano==this._G._jC.oTopBottomDlg)){this._G._jC.oUIMgr.oDialogMgr.HideCurrentModalessDialog(true);}CUITopBottomProperty.superclass.Unload.call(this);};function CUIUserDefFltProperty(_Oo,_Dl){this.base=CUIAbsBlockProperty;this.base(_Oo,_Dl);};CUIUserDefFltProperty.prototype=new CUIAbsBlockProperty;CUIUserDefFltProperty.superclass=CUIAbsBlockProperty.prototype;CUIUserDefFltProperty.prototype.Init=function(){CUIUserDefFltProperty.superclass.Init.call(this);var _BM="";if(this._G.oProxyBlock.GetUserDefFLT()){_BM=this._G.oProxyBlock.GetUserDefFLT().GetLabel();this.SetLabel();this._mb="filter_12.gif";}else{_BM=this._sp.GetString('IDS_BLOCKPROP_EXPRESSION_RULE_NONE');this._mb=null;}this.SetLabel(_BM,_BM);this._wt="edit_property.gif";this.EditableChecking();};CUIUserDefFltProperty.prototype.Unload=function(){var _ano=this._G._jC.oUIMgr.oDialogMgr._jg;if(_ano&&(_ano.GetRootOpener)&&(_ano.GetRootOpener()==this._G._jC)){if(_ano instanceof CUIUserDefFilterDlg||_ano instanceof CUICombineFilterDlg){this._G._jC.oUIMgr.oDialogMgr.HideCurrentModalessDialog(true);}}CUIUserDefFltProperty.superclass.Unload.call(this);};CUIUserDefFltProperty.prototype.EditableChecking=function(){if(this._G.oProxyBlock.IsLocked()){this._mr=CUIAbsBlockProperty.eReadOnly;}else{this._mr=CUIAbsBlockProperty.eEditable;}};CUIUserDefFltProperty.prototype.HandleClick=function(){if(this._mr==CUIAbsBlockProperty.eEditable){this._G.SetCurrentProp(this);var _FK=this._G.oProxyBlock;var _Gd=_FK.GetUserDefFLT()?_FK.GetUserDefFLT().Clone():null;if(_Gd&&_Gd._lW&&_Gd._lW==ExpAPIXml.kEleCombineFilterExpr){_ano=this._G._jC.GetCombineFilterDlg();}else{_ano=this._G._jC.GetUserDefFilterDlg();}_ano.SetHostObj(_FK);_ano.SetInitFilterExpr(_Gd);_ano.Create();_ano.Display();}};CUIUserDefFltProperty.prototype.UpdatePropertyFromBlock=function(){var _BM="";if(this._G.oProxyBlock.GetUserDefFLT()){_BM=this._G.oProxyBlock.GetUserDefFLT().GetLabel();this._mb="filter_12.gif";}else{_BM=this._sp.GetString('IDS_BLOCKPROP_EXPRESSION_RULE_NONE');this._mb=null;}this.SetLabel(_BM,_BM);var _U5=!CDLBlockTransaction.IsUserDefFilterEqual(this._G.oProxyBlock,this._G.oOriginalBlock);this.EditableChecking();this.RedrawLabel(_U5);};CUIExcludedItemsProperty.kIncludeAll='includeall';function CUIExcludedItemsProperty(_Oo,_Dl){this.base=CUIAbsBlockProperty;this.base(_Oo,_Dl);};CUIExcludedItemsProperty.prototype=new CUIAbsBlockProperty;CUIExcludedItemsProperty.superclass=CUIAbsBlockProperty.prototype;CUIExcludedItemsProperty.prototype.Init=function(){CUIExcludedItemsProperty.superclass.Init.call(this);this._vy=new Array();this._uv=new Array();this._wC=this._sp.GetString('IDS_BLOCKPROP_EXCLUDED_ITEMS_NONE');var _af6=this._G.oOriginalBlock.GetExcludedMemberIds();this._f6=new Array();if(this._G.oOriginalBlock.HasExcludedMembers()){this._wC='IDS_BLOCKPROP_EXCLUDED_ITEMS';var _KG=_af6.length;var _RJ=this._G._jC.oUIMgr._qi._ob;for(var i=0;i<_af6.length;i++){this._f6[i]=_af6[i];this._vy[i]=_af6[i];this._uv[i]=_RJ.GetDataLabel(_af6[i]);}this._wC=this._sp.ReplaceParam(this._wC,1,String(_KG));this._mb="excluded_items_12.gif";}else{this._mb=null;}this.SetValue(this._f6?this._f6.length:0);this.SetLabel(this._wC,this._wC);this.EditableChecking();};CUIExcludedItemsProperty.prototype.EditableChecking=function(){if((this._f6.length==0)||(this._G.oProxyBlock.IsLocked())){this._mr=CUIAbsBlockProperty.eReadOnly;}else{this._mr=CUIAbsBlockProperty.eEditable;}};CUIExcludedItemsProperty.prototype.UpdatePropertyFromBlock=function(){this.EditableChecking();this.RedrawLabel(!CDLBlockTransaction.AreExcludedMembersEqual(this._G.oProxyBlock,this._G.oOriginalBlock));};CUIExcludedItemsProperty.prototype.HandleClick=function(e,x,y){if(this._mr==CUIAbsBlockProperty.eEditable){if(this._vy.length>0){this.ShowDropDown(e,x,y);}}};CUIExcludedItemsProperty.prototype.UpdateProperty=function(_UN,_zg){if(_UN==CUIExcludedItemsProperty.kIncludeAll){if(this._f6.length==0){this._f6=Utilities.CopyArray(this._vy);}else{Utilities.DeleteAllFromArray(this._f6);}}else if(Utilities.IsInArray(this._f6,_UN)){Utilities.DeleteFromArray(this._f6,_UN);}else{this._f6.push(_UN);}this._G.oProxyBlock._kL=this._f6;this.SetValue(this._f6.length);if(this._f6.length==0){this._wC=this._sp.GetString('IDS_BLOCKPROP_EXCLUDED_ITEMS_NONE');this._mb=null;}else{this._wC='IDS_BLOCKPROP_EXCLUDED_ITEMS';var _KG=(this._f6.length==0)?this._sp.GetString('IDS_BLOCKPROP_EXCLUDED_NONE'):this._f6.length;this._wC=this._sp.ReplaceParam(this._wC,1,_KG);this._mb="excluded_items_12.gif";}this.SetLabel(this._wC,this._wC);this.RedrawLabel(!CDLBlockTransaction.AreExcludedMembersEqual(this._G.oProxyBlock,this._G.oOriginalBlock));};CUIExcludedItemsProperty.prototype.ShowDropDown=function(e,x,y){var _Kk=new CUIContextMenu(this._gC,0,this);this._G._eE=this;var _Jj=CUIAbsBlockPropSet.SafeDoUpdateCurrentProperty;var _BM=this._sp.GetString('OTH_BLOCKPROP_INCLUDE_ALL');var _AG=new Array(this._gC,CUIExcludedItemsProperty.kIncludeAll,_BM);var _PM=new ContextItem("",_BM,_Jj,false,_AG,_Kk);_PM.SetChecked(this._f6.length==0);var _aIC=new ContextSeparator(_Kk);var _asn='OTH_BLOCKPROP_INCLUDE';for(var i=0;i<this._vy.length;i++){_BM=this._sp.ReplaceParam(_asn,1,this._uv[i]);_AG=new Array(this._gC,this._vy[i],this._uv[i]);var _PM=new ContextItem("",_BM,_Jj,false,_AG,_Kk);var _Ng=!(Utilities.IsInArray(this._f6,this._vy[i]));_PM.SetChecked(_Ng);}_Kk.SetChildrenComplete();_Kk.display(e,true,x,y);this._df=_Kk;};CUIExcludedItemsProperty.prototype.Unload=function(){if(this._df){this._df.Unload();}CUIExcludedItemsProperty.superclass.Unload.call(this);};function CUIContextProperty(_Oo,_Dl){this.base=CUIAbsBlockProperty;this.base(_Oo,_Dl);this._mr=CUIAbsBlockProperty.eReadOnly;};CUIContextProperty.prototype=new CUIAbsBlockProperty;CUIContextProperty.superclass=CUIAbsBlockProperty.prototype;CUIContextProperty.prototype.Init=function(_BM){CUIContextProperty.superclass.Init.call(this);this.SetLabel(_BM,_BM);};function CUICompositContextProperty(_Oo,_Dl){this.base=CUIContextProperty;this.base(_Oo,_Dl);this._bS=new Array();};CUICompositContextProperty.prototype=new CUIContextProperty;CUICompositContextProperty.superclass=CUIContextProperty.prototype;CUICompositContextProperty.prototype.Init=function(_zc){CUICompositContextProperty.superclass.Init.call(this);if(_zc){var _alE="";Utilities.DeleteAllFromArray(this._bS);for(var i=0;i<_zc.length;i++){var _aee=_zc[i];_alE+=_aee[0];var _PK=new CUIContextProperty(this._G,this._l3);_PK.Init(_aee[0]);_PK.SetLabel(_aee[0],_aee[1]);this._bS.push(_PK);}this.SetLabel(_BM,_BM);}};CUICompositContextProperty.prototype.Draw=function(_ID){if(!this._bS||this._bS.length==0){CUICompositContextProperty.superclass.Draw.call(_ID);}else{for(var i=0;i<this._bS.length;i++){this._bS[i].Draw(_ID);}}};CUICompositContextProperty.prototype.RedrawLabel=function(_U5,_BY){if(!this._bS||this._bS.length==0){CUICompositContextProperty.superclass.Draw.call(_U5,_BY);}else{for(var i=0;i<this._bS.length;i++){this._bS[i].RedrawLabel(_U5,_BY);}}};function CUISortProperty(_Oo,_Dl){this.base=CUIAbsBlockProperty;this.base(_Oo,_Dl);};CUISortProperty.prototype=new CUIAbsBlockProperty;CUISortProperty.superclass=CUIAbsBlockProperty.prototype;CUISortProperty.prototype.Init=function(){CUISortProperty.superclass.Init.call(this);var _BM="";if(this._G.oProxyBlock.IsExplicitSort()){_BM=this._G.oProxyBlock.GetSortLabel();this._mb=this._G.oProxyBlock.IsAscending()?"summary_sort_ascending_12.gif":"summary_sort_descending_12.gif";}else{_BM=this._sp.GetString('IDS_BLOCKPROP_SORT_NONE');this._mb=null;}this.SetLabel(_BM,_BM);this.setValueFromBlock(this._G.oProxyBlock);};CUISortProperty.prototype.setValueFromBlock=function(_FK){if(_FK.IsHierarchyEnabled()){_FK._fR=null;_FK._qs=new Array();_FK._k2=null;_FK._cc=false;_FK._mm=ExpAPIXml.kEleAxisOpExprSorttypeDefault;}this._mr=CUIAbsBlockProperty.eEditable;if(!_FK.CanSort()){this._mr=CUIAbsBlockProperty.eReadOnly;}};CUISortProperty.SafeDoUpdate=function(_Ke,_FK,_RC,_BI){/*@if(!@bering_debug)@*/try{/*@end@*/var _aDS=FindApp(_Ke).uiManager.oBlockPropsPane.GetCurrentPropSet();Debug.Assert(_aDS);if(_aDS&&_aDS._eE){_aDS._eE.UpdateProperty(_RC,_BI);}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUISortProperty.prototype.UpdateProperty=function(_RC,_BI){if(_RC==ExpAPIXml.kEleAxisOpExprSorttypeDefault){this._G.oProxyBlock._mm=ExpAPIXml.kEleAxisOpExprSorttypeDefault;this._G.oProxyBlock._qs=new Array();this._G.oProxyBlock._k2=null;this._G.oProxyBlock._cc=false;this._G.oProxyBlock._fR=null;this._mb=null;}else if(_RC==ExpAPIXml.kEleAxisOpExprSorttypeBottom){this._G.oProxyBlock._mm=ExpAPIXml.kEleAxisOpExprSorttypeBottom;this._mb="summary_sort_ascending_12.gif";}else if(_RC==ExpAPIXml.kEleAxisOpExprSorttypeTop){this._G.oProxyBlock._mm=ExpAPIXml.kEleAxisOpExprSorttypeTop;this._mb="summary_sort_descending_12.gif";}if(!this._G.oProxyBlock._k2){this._G.oProxyBlock._k2=DefaultConstants.kDefMeasure;}if(this._G.oProxyBlock._qs.length==0){this._G.oProxyBlock._qs.push(DefaultConstants.kDefScope);}this._G.oProxyBlock._cc=_BI?true:false;this.setValueFromBlock(this._G.oProxyBlock);var _BM="";if(this._G.oProxyBlock.IsExplicitSort()){_BM=this._G.oProxyBlock.GetSortLabel();}else{_BM=this._sp.GetString('IDS_BLOCKPROP_SORT_NONE');}this.SetLabel(_BM,_BM);var _U5=!CDLBlockTransaction.IsSortEqual(this._G.oProxyBlock,this._G.oOriginalBlock);var _BY=this._G.oProxyBlock.IsHAMC()?true:false;this.RedrawLabel(_U5,_BY);};CUISortProperty.prototype.UpdatePropertyFromBlock=function(_FK,_BY){this.setValueFromBlock(_FK);var _BM="";if(this._G.oProxyBlock.IsExplicitSort()){_BM=this._G.oProxyBlock.GetSortLabel();this._mb=this._G.oProxyBlock.IsAscending()?"summary_sort_ascending_12.gif":"summary_sort_descending_12.gif";}else{_BM=this._sp.GetString('IDS_BLOCKPROP_SORT_NONE');this._mb=null;}this.SetLabel(_BM,_BM);var _U5=!CDLBlockTransaction.IsSortEqual(this._G.oProxyBlock,this._G.oOriginalBlock);_BY=this._G.oProxyBlock.IsHAMC()&&_BY?true:false;this.RedrawLabel(_U5,_BY);};CUISortProperty.prototype.HandleClick=function(e,x,y){if(this._mr==CUIAbsBlockProperty.eEditable){this.ShowDropDown(e,x,y);}};CUISortProperty.prototype.ShowDropDown=function(e,x,y){var _Kk=new CUIContextMenu(this._gC,0,this);this._G.SetCurrentProp(this);CUIWorkSheet.AttachBlockSortItems(this._gC,this._sp,_Kk);var _Lz=true;CUIWorkSheet.UpdateSortItems(_Kk,this._gC,this._G.oProxyBlock,_Lz);_Kk.SetChildrenComplete();_Kk.display(e,true,x,y);this._df=_Kk;};CUISortProperty.SafeDoShowSortDlg=function(_Ke,_Ru){/*@if(!@bering_debug)@*/try{/*@end@*/var _aDS=FindApp(_Ke).uiManager.oBlockPropsPane.GetCurrentPropSet();Debug.Assert(_aDS);if(_aDS&&_aDS._eE){_aDS._eE.ShowSortDlg(_Ru);}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUISortProperty.prototype.ShowSortDlg=function(_Ru){var _ajw=this._G._jC.GetSortDlg();_ajw.Draw();_ajw.Display();_ajw.SetHostObj(this._G.oProxyBlock);if(_Ru){_ajw.SetSortTypeRadio(_Ru);}};CUISortProperty.prototype.Unload=function(){if(this._df){this._df.Unload();}var _ano=this._G._jC.oUIMgr.oDialogMgr._jg;if(_ano&&(_ano instanceof CUISortDlg)&&(_ano==this._G._jC.oSortDlg)){this._G._jC.oUIMgr.oDialogMgr.HideCurrentModalessDialog(true);}CUISortProperty.superclass.Unload.call(this);};function CUIMeasureProperty(_Oo,_Dl){this.base=CUIAbsBlockProperty;this.base(_Oo,_Dl);};CUIMeasureProperty.prototype=new CUIAbsBlockProperty;CUIMeasureProperty.superclass=CUIAbsBlockProperty.prototype;CUIMeasureProperty.prototype.Init=function(){CUIMeasureProperty.superclass.Init.call(this);var _Li=this._G._jC.oUIMgr.dataManager.GetCurrentDataMatrix();if(!_Li.GetCurrentMeasure()){var _BM=this._sp.GetString('IDS_APPPROP_DEFAULT_MEASURE_NONE');this.SetValue(null);}else{var _0L=_Li.GetCurrentMeasureId();var _BM=_Li._he.metadata.GetMeasure(_0L).GetExplicitLabel();this.SetValue(_0L);}this.SetLabel(_BM,_BM);};CUIMeasureProperty.prototype.HandleClick=function(e,x,y){if(this._mr==CUIAbsBlockProperty.eEditable){this.ShowDropDown(e,x,y);}};CUIMeasureProperty.prototype.ShowDropDown=function(e,x,y){var _Kk=new CUIContextMenu(this._gC,0,this);_Kk.SetUnloadOnHide(true);this._G.SetCurrentProp(this);var _RJ=this._G._jC.oUIMgr.dataManager.metadata;var _Li=this._G._jC.oUIMgr.dataManager.GetCurrentDataMatrix();var _0h=_Li.GetCurrentMeasureId();var _Oi=0;for(var i in _RJ._yb){var _Ng=(i==this.GetValue());var _BM=_RJ._yb[i].GetExplicitLabel();var _Jj=CUIAbsBlockPropSet.SafeDoUpdateCurrentProperty;var _AG=new Array(this._gC,i,_BM);var _PM=new ContextItem("",_BM,_Jj,false,_AG,_Kk);_PM.SetRadioState(_Ng);_Oi++;}_Kk.SetChildrenComplete();_Kk.display(e,true,x,y);this._df=_Kk;};CUIMeasureProperty.prototype.UpdateProperty=function(_UN,_zg){this.SetLabel(_zg,_zg);this.SetValue(_UN);this.RedrawLabel(this._G.HasCurrentMeasureChanged(_UN));};function CUIShowValuesAsProperty(_Oo,_Dl){this.base=CUIAbsBlockProperty;this.base(_Oo,_Dl);};CUIShowValuesAsProperty.prototype=new CUIAbsBlockProperty;CUIShowValuesAsProperty.superclass=CUIAbsBlockProperty.prototype;CUIShowValuesAsProperty.prototype.Init=function(){CUIShowValuesAsProperty.superclass.Init.call(this);this._vy=new Array(ExpAPIXml.kDefDisplayDsp,ExpAPIXml.kPcntRowTotalDsp,ExpAPIXml.kPcntRowSubTotalDsp,ExpAPIXml.kPcntColTotalDsp,ExpAPIXml.kPcntColSubTotalDsp,ExpAPIXml.kPcntOfTotalDsp);this._uv=new Array(this._sp.GetString('IDS_BLOCKPROP_SHOWVALUES_VALUES'),this._sp.GetString('IDS_BLOCKPROP_SHOWVALUES_ROWS'),this._sp.GetString('IDS_BLOCKPROP_SHOWVALUES_EACH_ROW'),this._sp.GetString('IDS_BLOCKPROP_SHOWVALUES_COLS'),this._sp.GetString('IDS_BLOCKPROP_SHOWVALUES_EACH_COL'),this._sp.GetString('IDS_BLOCKPROP_SHOWVALUES_OVERALL'));this._dy=new Array(this._sp.GetString('OTH_BLOCKPROP_SHOWVALUES_VALUES_MENU'),this._sp.GetString('OTH_BLOCKPROP_SHOWVALUES_ROWS_MENU'),this._sp.GetString('OTH_BLOCKPROP_SHOWVALUES_EACH_ROW_MENU'),this._sp.GetString('OTH_BLOCKPROP_SHOWVALUES_COLS_MENU'),this._sp.GetString('OTH_BLOCKPROP_SHOWVALUES_EACH_COL_MENU'),this._sp.GetString('OTH_BLOCKPROP_SHOWVALUES_OVERALL_MENU'));var _Li=this._G._jC.oUIMgr.dataManager.GetCurrentDataMatrix();var _aIH=_Li.GetDisplayProperty();this.SetValue(_aIH);var _PQ=Utilities.GetObjIndex(this._vy,_aIH);this.SetLabel(this._uv[_PQ],this._uv[_PQ]);this.EditableChecking();};CUIShowValuesAsProperty.prototype.EditableChecking=function(){var _Li=this._G._jC.oUIMgr.dataManager.GetCurrentDataMatrix();if(_Li.CanChangeValueDspSetting()){this._mr=CUIAbsBlockProperty.eEditable;}else{this._mr=CUIAbsBlockProperty.eReadOnly;}};CUIShowValuesAsProperty.prototype.HandleClick=function(e,x,y){if(this._mr==CUIAbsBlockProperty.eEditable){this.ShowDropDown(e,x,y);}};CUIShowValuesAsProperty.prototype.ShowDropDown=function(e,x,y){var _Kk=new CUIContextMenu(this._gC,0,this);_Kk.SetUnloadOnHide(true);this._G.SetCurrentProp(this);var _Li=this._G._jC.oUIMgr.dataManager.GetCurrentDataMatrix();for(var i=0;i<this._vy.length;i++){var _Ng=this._vy[i]==this.GetValue();var _BM=this._dy[i];var _Jj=CUIAbsBlockPropSet.SafeDoUpdateCurrentProperty;var _AG=new Array(this._gC,this._vy[i],this._uv[i]);var _PM=new ContextItem("",_BM,_Jj,false,_AG,_Kk);_PM.SetRadioState(_Ng);_PM.SetEnabled(_Li._d4[this._vy[i]]);}_Kk.SetChildrenComplete();_Kk.display(e,true,x,y);};CUIShowValuesAsProperty.prototype.UpdateProperty=function(_UN,_zg){this.SetLabel(_zg,_zg);this.SetValue(_UN);this.RedrawLabel(this._G.HasCurrentMeasureChanged(_UN));};function CUIAxisProperty(_Oo,_Dl,_BZ){this.base=CUIAbsBlockProperty;this.base(_Oo,_Dl);this._mr=CUIAbsBlockProperty.eReadOnly;this.iAxisIdx=_BZ;};CUIAxisProperty.prototype=new CUIAbsBlockProperty;CUIAxisProperty.superclass=CUIAbsBlockProperty.prototype;CUIAxisProperty.prototype.Init=function(_L7){CUIAxisProperty.superclass.Init.call(this);var _Li=this._G._jC.oUIMgr.dataManager.GetCurrentDataMatrix();this.sBlockId=_L7;if(this.sBlockId!=null){var _BM=_Li.GetBlock(this.sBlockId).GetLabel();var _Rz=_Li.GetBlock(this.sBlockId).GetLabelWithDescription();this.SetLabel(_BM,_Rz);this._mr=CUIAbsBlockProperty.eEditable;}else{this.SetLabel(this._sp.GetString('IDS_BLOCKPROP_AXIS_PROP_NOTHING'),this._sp.GetString('IDS_BLOCKPROP_AXIS_PROP_NOTHING'));this._mr=CUIAbsBlockProperty.eReadOnly;}};CUIAxisProperty.prototype.Draw=function(_ID){Dom.RemoveAllChildren(this._J);if(_ID){_ID.appendChild(this._J);}this._s1=document.createElement('SPAN');this._s1.className=Dom.GetStyleByBrowser("BlockPropertiesText");this._J.appendChild(this._s1);var _afP=document.createElement('TABLE');_afP.className='prop_block_table';var _9Z=_afP.appendChild(document.createElement('TBODY'));this._s1.appendChild(_afP);var _ayA=_9Z.appendChild(document.createElement('TR'));var _aHF=_ayA.appendChild(document.createElement('TD'));_aHF.style.whiteSpace='pre';var _ach=new Array();var _76="";if(this.sBlockId!=null){var _Li=this._G._jC.oUIMgr.dataManager.GetCurrentDataMatrix();_ach=_Li.GetBlock(this.sBlockId).GetFilterSortLabels();if(_ach.length>1){_76=_Co.ReplaceParamList('IDS_BLOCK_PROPERTIES_TITLE_TOKEN_DESC',_ach);}else if(_ach.length==1){_76=_ach[0];}}if(this.sBlockId==null||_ach.length==0){var _ajm=_aHF.appendChild(document.createElement("SPAN"));_ajm.appendChild(document.createTextNode(this._p8));this._wO=_ajm;}else{var _aoH=this._sp.ParseStringForParamOrder('IDS_BLOCK_PROPERTIES_TITLE_W_SELECTION_DESC',2);for(var i=0;i<_aoH.length;i++){if(_aoH[i]){if(_aoH[i].sBefore!=""){var _ax0=document.createElement("SPAN");_ax0.appendChild(document.createTextNode(_aoH[i].sBefore));_aHF.appendChild(_ax0);}switch(_aoH[i].sElement){case this._sp.GetParameter(1):var _abL=document.createElement("SPAN");_abL.appendChild(document.createTextNode(this._p8));_aHF.appendChild(_abL);this._wO=_abL;break;case this._sp.GetParameter(2):var _aFG=document.createElement("SPAN");_aFG.appendChild(document.createTextNode(_76));_aHF.appendChild(_aFG);this._xJ=_aFG;break;}if(_aoH[i].sAfter!=""){var _Xb=document.createElement("SPAN");_Xb.appendChild(document.createTextNode(_aoH[i].sAfter));_aHF.appendChild(_Xb);}}}}if(this._eN){this._J.title=this._eN;}Dom.SetObjRef(this._J,this,'oProp');if(this._mr==CUIAbsBlockProperty.eEditable){this._J.onmouseover=CUIAbsBlockProperty.SafeHandleMouseOver;this._J.onmouseout=CUIAbsBlockProperty.SafeHandleMouseOut;this._J.onclick=CUIAxisProperty.SafeHandleClick;}var _Zy=COTStyle.GetDisplayOffsetWidth(this._J);if(_Zy>this._G.GetWidthForPropertyValues()){var _alq=this._sp.ParseStringForParamOrder('IDS_TRUNCATED_STRING',1);var _X4=0;for(var i=0;i<_alq.length;i++){if(_alq[i]){if(_alq[i].sBefore!=""){var _acc=document.createElement("SPAN");_acc.appendChild(document.createTextNode(_alq[i].sBefore));this._J.insertBefore(_acc,this._J.firstChild);_X4+=COTStyle.GetDisplayOffsetWidth(_acc);}if(_alq[i].sAfter!=""){var _acc=document.createElement("SPAN");_acc.appendChild(document.createTextNode(_alq[i].sAfter));this._J.appendChild(_acc);_X4+=COTStyle.GetDisplayOffsetWidth(_acc);}}}COTStyle.SetWidth(this._s1,this._G.GetWidthForPropertyValues()-CUIManager.kiScrollbarWidth-_X4);}this.SetStyle();};CUIAxisProperty.prototype.SetStyle=function(){CUIAxisProperty.superclass.SetStyle.call(this);if(this._mr==CUIAbsBlockProperty.eEditable){if(this._wO){this._wO.className="prop_div_link";}}};CUIAxisProperty.SafeHandleClick=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/this.oProp.bSelected=true;this.oProp.SetStyle();this.oProp.HandleClick(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIAxisProperty.prototype.HandleClick=function(){if(this.sBlockId!=null){this._G.oUIWS.ApplyBlockSelection(this.sBlockId);}};function CUIReportOptionsProperty(_Oo,_Dl){this.base=CUIAbsBlockProperty;this.base(_Oo,_Dl);};CUIReportOptionsProperty.prototype=new CUIAbsBlockProperty;CUIReportOptionsProperty.superclass=CUIAbsBlockProperty.prototype;CUIReportOptionsProperty.prototype.Init=function(_JE){CUIReportOptionsProperty.superclass.Init.call(this);this.oAnalysis=_JE;this.UpdateProperty(_JE);this._wt="edit_property.gif";};CUIReportOptionsProperty.prototype.Unload=function(){if(this.oReportOptionsDlg){if(this.oReportOptionsDlg._r3){var _Hy=this.oReportOptionsDlg.oDialogMgr;_Hy.HideCurrentDialog(true);}this.oReportOptionsDlg.Unload();}};CUIReportOptionsProperty.prototype.UpdatePropertyFromDialog=function(){var _U5=false;if(this.oReportOptionsDlg){var _JE=this.oReportOptionsDlg.GetNewAnalysisObj();if(_JE){_U5=this.CheckForChanges(_JE)||this.CheckForDispNameOnlyChanges();this.UpdateProperty(_JE,_U5);this.RedrawLabel(_U5);}else{_JE=this.oReportOptionsDlg.GetHostAnalysisObj();if(_JE._v6){this.UpdateProperty(_JE,_U5);this.RedrawLabel(_U5);}}}this.bChanged=_U5;return _U5;};CUIReportOptionsProperty.prototype.GetValue=function(){if(!this.oReportOptionsDlg||!this.oReportOptionsDlg.GetNewAnalysisObj()){return this.oAnalysis;}else{return this.oReportOptionsDlg.GetNewAnalysisObj();}};CUIReportOptionsProperty.prototype.UpdateProperty=function(_JE,_U5){var _BM="";if(_JE.GetTitle()){_BM+=_JE.GetTitle();}else{_BM+=this._sp.GetString('IDS_BLOCK_PROPERTY_PANE_NO_TITLE');}_BM+=this._sp.GetString('IDS_BLOCKPROP_PROP_VALUE_SEPARATOR');if(_JE.GetSubtitle()){_BM+=_JE.GetSubtitle();}else{_BM+=this._sp.GetString('IDS_BLOCK_PROPERTY_PANE_NO_SUBTITLE');}if(_JE.DisplayFilters()){_BM+=this._sp.GetString('IDS_BLOCKPROP_PROP_VALUE_SEPARATOR');if(_JE.DisplayFiltersAtEnd()){_BM+=this._sp.GetString('IDS_BLOCK_PROPERTY_PANE_FILTERS_END');}else{_BM+=this._sp.GetString('IDS_BLOCK_PROPERTY_PANE_FILTERS_BEG');}}if(_JE.DisplayAll()){_BM+=this._sp.GetString('IDS_BLOCKPROP_PROP_VALUE_SEPARATOR');_BM+=this._sp.GetString('IDS_BLOCK_PROPERTY_PANE_SHOW_ALL');}_BM+=this._sp.GetString('IDS_BLOCKPROP_PROP_VALUE_SEPARATOR');var _awb='IDS_BLOCK_PROPERTY_PANE_PAGE_BREAKS';var _amd="";if(_JE.DisplayOutermostGroups()){_amd=this._sp.GetString('IDS_REPORT_OPTIONS_DLG_GROUPS_ON_ROWS');}if(_JE.DisplaySections()){if(_amd!=""){_amd+=this._sp.GetString('IDS_BLOCKPROP_PROP_VALUE_SEPARATOR');}_amd+=_JE.GetDisplaySectionItemLabel();}if(_JE.DisplaySetsOnRows()){if(_amd!=""){_amd+=this._sp.GetString('IDS_BLOCKPROP_PROP_VALUE_SEPARATOR');}_amd+=this._sp.GetString('IDS_REPORT_OPTIONS_DLG_SETS_ON_ROWS');}if(_amd==""){var _amd=this._sp.GetString('IDS_BLOCK_PROPERTY_PANE_NO_PAGE_BREAKS');}_BM+=this._sp.ReplaceParam(_awb,1,_amd);_BM+=this._sp.GetString('IDS_BLOCKPROP_PROP_VALUE_SEPARATOR');if(_JE.IsPortraitOrientation()){_BM+=this._sp.GetString('IDS_REPORT_OPTIONS_DLG_PORTRAIT');}else{_BM+=this._sp.GetString('IDS_REPORT_OPTIONS_DLG_LANDSCAPE');}if(_JE.GetPaperSize()==ExpAPIXml.kDefaultPaper){_BM+=this._sp.GetString('IDS_BLOCKPROP_PROP_VALUE_SEPARATOR');_BM+=this._sp.GetString('IDS_BLOCK_PROPERTY_PANE_DEFAULT_PAPER');}else if(this.oAnalysis._mn){var _azf=_JE.GetPaperSizeName(_JE.GetPaperSize());if(!_azf){_azf=this._sp.GetString('IDS_BLOCK_PROPERTY_PANE_DEFAULT_PAPER');}_BM+=this._sp.GetString('IDS_BLOCKPROP_PROP_VALUE_SEPARATOR');_BM+=_azf;}if(!this._G._jC.oUIMgr.appobj._cl){_BM+=this._sp.GetString('IDS_BLOCKPROP_PROP_VALUE_SEPARATOR');if(_JE.GetReportTemplate()&&_JE.GetUseReportTemplate()){_BM+=this._sp.GetString('IDS_BLOCK_PROPERTY_PANE_REPORT_TEMPLATE');}else{_BM+=this._sp.GetString('IDS_BLOCK_PROPERTY_PANE_NO_REPORT_TEMPLATE');}}var _Rz=_BM;_Rz+=this._sp.GetString('IDS_BLOCKPROP_PROP_VALUE_SEPARATOR');var _adC=(_JE.GetOutputPurpose()==ExpAPIXml.kPrintPurpose)?'IDS_BLOCK_PROPERTY_PANE_ANALYSIS_OUTPUT_PURPOSE':'IDS_BLOCK_PROPERTY_PANE_INTERACTIVE_OUTPUT_PURPOSE';_Rz+=this._sp.GetString(_adC);this.SetLabel(_BM,_Rz);};CUIReportOptionsProperty.prototype.CheckForChanges=function(_CK){if(_CK.GetTitle()!=this.oAnalysis.GetTitle()){return true;}if(_CK.GetSubtitle()!=this.oAnalysis.GetSubtitle()){return true;}if(_CK.GetReportTemplate()!=this.oAnalysis.GetReportTemplate()){return true;}if(_CK.GetUseReportTemplate()!=this.oAnalysis.GetUseReportTemplate()){return true;}if(_CK.GetPaperSize()!=this.oAnalysis.GetPaperSize()){return true;}if(_CK.GetPaperOrientation()!=this.oAnalysis.GetPaperOrientation()){return true;}if(_CK.DisplayFilters()!=this.oAnalysis.DisplayFilters()){return true;}if(_CK.DisplayFiltersAtEnd()!=this.oAnalysis.DisplayFiltersAtEnd()){return true;}if(_CK.DisplayAll()!=this.oAnalysis.DisplayAll()){return true;}if(_CK.DisplayOutermostGroups()!=this.oAnalysis.DisplayOutermostGroups()){return true;}if(_CK.DisplaySections()!=this.oAnalysis.DisplaySections()){return true;}if(_CK.GetDisplaySectionItem()!=this.oAnalysis.GetDisplaySectionItem()){if(_CK.DisplaySections()){return true;}return false;}if(_CK.DisplaySetsOnRows()!=this.oAnalysis.DisplaySetsOnRows()){return true;}if(_CK.GetOutputPurpose()!=this.oAnalysis.GetOutputPurpose()){return true;}if(_CK.GetDisplayBreadcrumb()!=this.oAnalysis.GetDisplayBreadcrumb()){return true;}if(_CK.DisplayDataUpdatedOn()!=this.oAnalysis.DisplayDataUpdatedOn()){return true;}return false;};CUIReportOptionsProperty.prototype.CheckForDispNameOnlyChanges=function(){if(this._G.oUIWS._my.isViewsXtabNameChanged()){return true;}if(this._G.oUIWS._my.isViewsChartNameChanged()){return true;}return false;};CUIReportOptionsProperty.prototype.RedrawLabel=function(_U5,_BY){Dom.ReplaceText(this._s1,this._p8);if(this._eN){this._s1.title=this._eN;}this.bChanged=_U5;this.SetStyle();if(this._mr==CUIAbsBlockProperty.eEditable){this.oArrowImg.style.display="inline";}else{this.oArrowImg.style.display="none";}};CUIReportOptionsProperty.prototype.HandleClick=function(){var _JE=this.oAnalysis;if(this.oReportOptionsDlg&&this.oReportOptionsDlg.GetNewAnalysisObj()){if(this._G._jC._w7){this._G._jC._w7=false;}_JE=this.oReportOptionsDlg.GetNewAnalysisObj();}if(!this.oReportOptionsDlg){this.oReportOptionsDlg=new CUIReportOptionsDlg(true);var _Sb=true;this.oReportOptionsDlg.Init(this._G._jC.oUIMgr.oDialogMgr,_Sb);}this.oReportOptionsDlg.SetHostObj(_JE);this.oReportOptionsDlg.Display();};function COTRect(_P6,_TM,_Kl,_Uz){this.m_iLeft=_P6;this.m_iTop=_TM;this.m_iRight=_Kl;this.m_iBottom=_Uz;};COTRect.prototype.GetWidth=function(){return(this.m_iRight-this.m_iLeft);};COTRect.prototype.GetHeight=function(){return(this.m_iBottom-this.m_iTop);};COTRect.prototype.IsPtInRect=function(_Qb){if((_Qb.iLeft>=this.m_iLeft)&&(_Qb.iLeft<=this.m_iRight)&&(_Qb.iTop>=this.m_iTop)&&(_Qb.iTop<=this.m_iBottom))return true;else{return false;}};function COTPosition(_P6,_TM){this.iLeft=_P6;this.iTop=_TM;};function CUIPane(){};CUIPane.prototype.Init=function(){this.m_aoListeners=new Array();this.m_aoChildren=new Array();this.m_oFocus=null;this.m_Rect=null;this.m_oParent=null;this.m_oParentPane=null;this.m_oDom=null;this.m_bInitialized=false;};CUIPane.prototype.CreatePaneFromGDO=function(_L5){this.Init();this.m_oDom=_L5;return true;};CUIPane.prototype.CreatePane=function(_VW,_F4,_T6,_E3,_Rn){Debug.Assert(_VW);this.Init();this.m_oParentPane=_VW;this.m_oDom=document.createElement("DIV");_VW.AppendChild(this);this.m_oDom.className=_E3;this.m_oDom.style.top="0px";this.m_oDom.style.left="0px";this.m_oDom.style.position="absolute";var sU="px";if(_Rn){sU=_Rn;}if(_F4!=null){COTStyle.SetWidth(this.m_oDom,_F4,sU);}if(_T6!=null){COTStyle.SetHeight(this.m_oDom,_T6,sU);}this.m_bVisible=true;return true;};CUIPane.prototype.Create=function(_VW,_F4,_T6,_E3,_Km){this.Init();this.m_oParent=_VW;if(!_VW){this.m_oParent=document.body;}var _82=document.createElement("DIV");if(!_82){return false;}this.m_oDom=_82;this.m_oParent.appendChild(this.m_oDom);this.m_oDom.id="div"+Utilities.GenerateId();this.m_oDom.style.position="absolute";if(!_Km){_Km="px";}if(_F4!=null){COTStyle.SetWidth(this.m_oDom,_F4,_Km);}if(_T6!=null){COTStyle.SetHeight(this.m_oDom,_T6,_Km);}this.m_bVisible=true;this.m_oDom.className=_E3;return true;};CUIPane.prototype.OnResize=function(_Ls,_Nf,_P6,_TM){if(!this.m_hResize||!this.m_hResize()){if(this.m_Rect==null){this.m_Rect=new COTRect(this.m_oDom.offsetLeft,this.m_oDom.offsetTop,this.m_oDom.offsetLeft+this.m_oDom.offsetWidth,this.m_oDom.offsetTop+this.m_oDom.offsetHeight);}if(_P6>=0){this.m_Rect.m_iLeft=_P6;this.m_oDom.style.left=_P6+"px";}if(_TM>=0){this.m_Rect.m_iTop=_TM;this.m_oDom.style.top=_TM+"px";}this.m_Rect.m_iRight=this.m_Rect.m_iLeft+_Ls;this.m_Rect.m_iBottom=this.m_Rect.m_iTop+_Nf;COTStyle.SetWidth(this.m_oDom,_Ls);COTStyle.SetHeight(this.m_oDom,_Nf);}for(var i=0;i<this.m_aoListeners.length;i++){if(this.m_aoListeners[i]){if(this.m_aoListeners[i].Callback){this.m_aoListeners[i].Callback("Pane_Resized",this);}else if(this.m_aoListeners[i].OnResize){this.m_aoListeners[i].OnResize();}}}return true;};CUIPane.prototype.SetPosition=function(_P6,_TM,_Rn){this.m_oDom.style.left=_P6+_Rn;this.m_oDom.style.top=_TM+_Rn;};CUIPane.prototype.SetTopPosition=function(_TM,_Rn){this.m_oDom.style.top=_TM+_Rn;};CUIPane.prototype.SetLeftPosition=function(_P6,_Rn){this.m_oDom.style.left=_P6+_Rn;};CUIPane.prototype.OnShow=function(){};CUIPane.prototype.GetDom=function(){return this.m_oDom;};CUIPane.prototype.AddChild=function(_SW){for(var i=0;i<this.m_aoChildren.length;i++){if(this.m_aoChildren[i]==_SW)return i;}i=this.m_aoChildren.length;this.m_aoChildren[this.m_aoChildren.length]=_SW;return i;};CUIPane.prototype.GetChild=function(id){return this.m_aoChildren[id];};CUIPane.prototype.RemoveChild=function(id){if(this.m_aoChildren[id]){this.m_aoChildren[id]=null;this.m_oDom.removeChild(this.m_aoChildren[id].GetDom());return true;}return false;};CUIPane.prototype.RemoveThisChild=function(_GI){for(var i=0;i<this.m_aoChildren.length;i++){if(this.m_aoChildren[i]==_GI){_GI.Unload();this.m_aoChildren[i]=null;}}};CUIPane.prototype.SetDom=function(_Qu){if(!this.m_bInitialized){this.Init();}if(_Qu){this.m_oDom=_Qu;}Dom.SetObjRef(this.m_oDom,this,'parentPane');};CUIPane.prototype.Destroy=function(){Debug.Assert(false,'call unload');};CUIPane.prototype.SetHandlers=function(_ER){this.m_hResize=_ER[0];};CUIPane.prototype.AddListener=function(_Lq){this.m_aoListeners[this.m_aoListeners.length]=_Lq;return true;};CUIPane.prototype.RemoveListener=function(_E5){for(var i=0;i<this.m_aoListeners.length;i++){if(this.m_aoListeners[i]==_E5)this.m_aoListeners[i]=null;}};CUIPane.prototype.Unload=function(){if(this.m_oDom){this.m_oDom.parentPane=null;if(this.m_oParent){this.m_oParent.removeChild(this.m_oDom);}Dom.RemoveObject(this.m_oDom);}Utilities.DeleteAllFromArray(this.m_aoChildren);Utilities.DeleteAllFromArray(this.m_aoListeners);this.m_oDom=null;this.m_oParent=null;Utilities.RemoveAllChildObjects(this);};CUIPane.prototype.OnCreate=function(){this.Init();this.m_bVisible=true;return true;};CUIPane.prototype.GetWidth=function(){if(this.m_Rect==null){this.m_Rect=new COTRect(this.m_oDom.offsetLeft,this.m_oDom.offsetTop,this.m_oDom.offsetLeft+this.m_oDom.offsetWidth,this.m_oDom.offsetTop+this.m_oDom.offsetHeight);}return this.m_Rect.GetWidth();};CUIPane.prototype.GetHeight=function(){if(this.m_Rect==null){this.m_Rect=new COTRect(this.m_oDom.offsetLeft,this.m_oDom.offsetTop,this.m_oDom.offsetLeft+this.m_oDom.offsetWidth,this.m_oDom.offsetTop+this.m_oDom.offsetHeight);}return this.m_Rect.GetHeight();};CUIPane.prototype.AppendChild=function(_GI){_GI.m_oParent=this.m_oDom;this.m_oDom.appendChild(_GI.GetDom());var i=this.m_aoChildren.length;this.m_aoChildren[i]=_GI;return i;};function CUIPaneSplitter(){this.iLastMove=0;this.iLastPos=0;this.bParentHasScrollbar=false;};CUIPaneSplitter.prototype=new CUIPane();CUIPaneSplitter.superclass=CUIPane.prototype;CUIPaneSplitter.kiStaticDimensionSize=4;CUIPaneSplitter.prototype.Unload=function(){if(window.oPaneSplitter){window.oPaneSplitter=null;}if(this.m_oParentPane.GetDom()){this.m_oParentPane.GetDom().oPaneSplitter=null;}CUIPaneSplitter.superclass.Unload.call(this);};CUIPaneSplitter.prototype.SetParentHasScrollbar=function(_P7){this.bParentHasScrollbar=_P7;};CUIPaneSplitter.prototype.SafeOnMouseDown=function(e){try{if(!e)var e=window.event;this.oPaneSplitter.OnMouseDown(e);}catch(e){_f.HandleException(e);}};CUIPaneSplitter.prototype.OnMouseDown=function(e){Dom.CancelEvent(e);CUIManager.CallCurrentMouseDown(e);if(this.m_oDom.setCapture){this.m_oDom.setCapture();}else{this.normalWindowMouseUpHandler=window.onmouseup;this.normalWindowMouseMoveHandler=window.onmousemove;Dom.SetObjRef(window,this,'oPaneSplitter');window.captureEvents(Event.MouseUp);window.onmouseup=this.SafeOnMouseUp;window.captureEvents(Event.MouseMove);window.onmousemove=this.SafeOnMouseMove;}this.iLastMove=0;Dom.SetObjRef(this.m_oParentPane.GetDom(),this,'oPaneSplitter');this.normalMouseMoveHandler=this.m_oParentPane.GetDom().onmousemove;this.normalMouseUpHandler=this.m_oParentPane.GetDom().onmouseup;this.m_oParentPane.GetDom().onmousemove=this.SafeOnMouseMove;this.m_oParentPane.GetDom().onmouseup=this.SafeOnMouseUp;this.m_iInitialX=e.clientX;this.m_iLastX=e.clientX;this.m_iInitialY=e.clientY;this.m_iLastY=e.clientY;this.m_MovingLine.style.visibility="visible";this.m_MovingLine.style.top=this.m_oDom.offsetTop+"px";this.m_MovingLine.style.left=this.m_oDom.offsetLeft+"px";COTStyle.SetWidth(this.m_MovingLine,this.m_oDom.offsetWidth);COTStyle.SetHeight(this.m_MovingLine,this.m_oDom.offsetHeight);};CUIPaneSplitter.prototype.SafeOnMouseMove=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e)var e=window.event;this.oPaneSplitter.OnMouseMove(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIPaneSplitter.prototype.SafeOnMouseUp=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e)var e=window.event;this.oPaneSplitter.OnMouseUp(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIPaneSplitter.prototype.OnMouseUp=function(event){Dom.CancelEvent(event);if(this.m_oDom.releaseCapture){this.m_oDom.releaseCapture();}else{window.releaseEvents(Event.MouseUp);window.onmouseup=this.normalWindowMouseUpHandler;window.releaseEvents(Event.MouseMove);window.onmousemove=this.normalWindowMouseMoveHandler;}this.m_MovingLine.style.visibility="hidden";this.m_oParentPane.m_oDom.onmousemove=this.normalMouseMoveHandler;this.m_oParentPane.m_oDom.onmouseup=this.normalMouseUpHandler;this.setNewPos(event);};CUIPaneSplitter.prototype.Hide=function(){this.m_oDom.style.display="none";};CUIPaneSplitter.prototype.CreatePaneSplitter=function(_JT,_E3,_F4,_T6,_J1,_Rn,sCustomImg){if(!this.CreatePane(_JT,_F4,_T6,_E3,"px")){Debug.Assert(false,"CUIPaneSplitter::CreatePaneSplitter--failed");return false;}if(this.bVertical){this.m_oDom.style.left=_J1+_Rn;}else{this.m_oDom.style.top=_J1+_Rn;}this.m_oDom.id="divSplitter"+Utilities.GenerateId();Dom.SetObjRef(this.m_oDom,this,"oPaneSplitter");this.m_MovingLine=this.m_oDom.cloneNode(true);_JT.GetDom().appendChild(this.m_MovingLine);this.m_oDom.onmousedown=this.SafeOnMouseDown;this.setStyle();if(sCustomImg){this.elImg=this.m_oDom.appendChild(document.createElement('IMG'));this.elImg.src=Utilities.IMG_PATH+sCustomImg;COTStyle.SetSize(this.elImg,_F4,_T6);this.m_oDom.style.border="none";}return true;};function CUIHorizPaneSplitter(){this.base=CUIPaneSplitter;this.base();this.bVertical=false;};CUIHorizPaneSplitter.prototype=new CUIPaneSplitter;CUIHorizPaneSplitter.superclass=CUIPaneSplitter.prototype;CUIHorizPaneSplitter.prototype.OnCreate=function(_JT,_E5,_Ig,_Rn,sCustomImg){this.m_oListener=_E5;return this.CreatePaneSplitter(_JT,"clsSplitterHoriz",_JT.GetDom().offsetWidth,CUIPaneSplitter.kiStaticDimensionSize,_Ig,_Rn,sCustomImg);};CUIHorizPaneSplitter.prototype.setStyle=function(){this.m_MovingLine.className="clsSplitterMoverHoriz";};CUIHorizPaneSplitter.prototype.SetTop=function(_TM){this.m_oDom.style.top=_TM+'px';this.iLastMove=this.iLastMove+(_TM-this.iLastPos);};CUIHorizPaneSplitter.prototype.SetLeft=function(_P6){this.m_oDom.style.left=_P6+"px";};CUIHorizPaneSplitter.prototype.OnMouseMove=function(e){Dom.CancelEvent(e);var y=this.m_iLastY-e.clientY;if(Math.abs(y)>3){this.m_iLastY=e.clientY;this.m_MovingLine.style.top=this.m_MovingLine.offsetTop-y+"px";}};CUIHorizPaneSplitter.prototype.setNewPos=function(event){var y=event.clientY-this.m_iInitialY;var _UT=this.m_oDom.offsetTop+y;var _aCj=this.m_oParentPane.GetDom().offsetTop;var _aha=0;if(this.bParentHasScrollbar){_aha=this.m_oParentPane.GetDom().scrollTop;}if(y!=0&&_UT>0&&(_UT-CUIPaneSplitter.kiStaticDimensionSize-_aha)<Dom.GetWindowHeight()){var _ajE=COTStyle.GetHeightFromOffset(this.m_oParentPane.GetDom());var _arB=0;_arB=_arB-_aha;if((_UT+_arB)<_ajE){this.iLastPos=this.m_oDom.offsetHeight;this.m_oDom.style.top=this.m_oDom.offsetHeight-y+"px";this.iLastMove=y;this.m_oListener.Notify(ExpEvent.kCUIPaneSplitter_Move);if(this.m_oListener.OnSplitterMove){this.m_oListener.OnSplitterMove(this);}}}};CUIHorizPaneSplitter.prototype.SetWidth=function(_F4){COTStyle.SetWidth(this.m_oDom,_F4);COTStyle.SetWidth(this.m_MovingLine,_F4);if(this.elImg){COTStyle.SetWidth(this.elImg,_F4);}};function CUIVertPaneSplitter(){this.base=CUIPaneSplitter;this.base();this.bVertical=true;};CUIVertPaneSplitter.prototype=new CUIPaneSplitter;CUIVertPaneSplitter.superclass=CUIPaneSplitter.prototype;CUIVertPaneSplitter.prototype.OnCreate=function(_JT,_E5,_CX,_Rn,sCustomImg){this.m_oListener=_E5;return this.CreatePaneSplitter(_JT,"clsSplitterVert",CUIPaneSplitter.kiStaticDimensionSize,_JT.GetDom().offsetHeight,_CX,_Rn,sCustomImg);};CUIVertPaneSplitter.prototype.setStyle=function(){this.m_MovingLine.className="clsSplitterMoverVert";};CUIVertPaneSplitter.prototype.SetLeft=function(_P6){this.m_oDom.style.left=_P6+'px';this.iLastMove=this.iLastMove+(_P6-this.iLastPos);this.m_oDom.style.display="block";};CUIVertPaneSplitter.prototype.OnMouseMove=function(e){Dom.CancelEvent(e);var x=this.m_iLastX-e.clientX;if(Math.abs(x)>3){this.m_iLastX=e.clientX;this.m_MovingLine.style.left=this.m_MovingLine.offsetLeft-x+"px";}};CUIVertPaneSplitter.prototype.setNewPos=function(event){var x=event.clientX-this.m_iInitialX;var _UT=this.m_oDom.offsetLeft+x;var _aDq=this.m_oParentPane.GetDom().offsetLeft;var _9x=0;if(this.bParentHasScrollbar){_9x=this.m_oParentPane.GetDom().scrollLeft;}if(x!=0&&_UT>0&&(_UT-CUIPaneSplitter.kiStaticDimensionSize)<Dom.GetWindowWidth()){var _aDV=COTStyle.GetWidthFromOffset(this.m_oParentPane.GetDom());var _arB=0;_arB=0-_9x;if((_UT+_arB)<_aDV){this.iLastPos=this.m_oDom.offsetLeft;this.m_oDom.style.left=this.m_oDom.offsetLeft+x+"px";this.iLastMove=x;this.m_oListener.Notify(ExpEvent.kCUIPaneSplitter_Move);if(this.m_oListener.OnSplitterMove){this.m_oListener.OnSplitterMove(this);}}}};CUIVertPaneSplitter.prototype.SetTop=function(_TM){this.m_oDom.style.top=_TM+'px';};CUIVertPaneSplitter.prototype.SetHeight=function(_T6){COTStyle.SetHeight(this.m_oDom,_T6);COTStyle.SetHeight(this.m_MovingLine,_T6);if(this.elImg){COTStyle.SetHeight(this.elImg,_T6);}};function CUIVertResizingBar(){this.base=CUIVertPaneSplitter;this.base();window.lastActiveResizeBar=null;};CUIVertResizingBar.prototype=new CUIVertPaneSplitter;CUIVertResizingBar.superclass=CUIVertPaneSplitter.prototype;CUIVertResizingBar.prototype.CreateResizingBar=function(_zX,_E3,sCustomImg){if(!this.CreateBar(_zX,_E3)){Debug.Assert(false,"CUIPaneSplitter::CreatePaneSplitter--failed");return false;}this.m_oDom.id="divSplitter"+Utilities.GenerateId();Dom.SetObjRef(this.m_oDom,this,"oResizeBar");_zX.appendChild(this.m_oDom);this.m_oDom._ec=this;this.m_oDom.onmousedown=CUIVertResizingBar.SafeOnMouseDown;this.m_oDom.onmousemove=CUIVertResizingBar.SafeOnMouseMove;this.m_oDom.onmouseup=CUIVertResizingBar.SafeOnMouseUp;this.m_oDom.onmouseover=function(){};this.m_oDom.onmouseover=Dom.CancelEvent;if(sCustomImg){this.m_MovingLine=this.m_oDom.appendChild(document.createElement('IMG'));this.m_MovingLine.src=Utilities.IMG_PATH+sCustomImg;COTStyle.SetSize(this.m_MovingLine,1,1);}return true;};CUIVertResizingBar.prototype.CreateBar=function(_zX,_E3){Debug.Assert(_zX);this.m_oTargetEle=_zX;this.m_oDom=document.createElement("DIV");this.m_oDom.className=_E3;return true;};CUIVertResizingBar.prototype.OnCreate=function(_Tf,_E5,_VW){this.m_oListener=_E5;return this.CreateResizingBar(_VW,"clsVertResizeBar",_Tf);};CUIVertResizingBar.prototype.HideBar=function(){this.m_oDom.style.display='none';this.m_MovingLine.style.display='none';};CUIVertResizingBar.prototype.ShowBar=function(_ON,e){var _Vl=_ON.GetHtmlElement();var _2s=e.clientX;var _Qb=Dom.GetRelativeOffset(_Vl,document.body);var _aEs=_Qb.iLeft;var _7G=_Qb.iLeft+_Vl.offsetWidth;var _afE=_Qb.iTop;if(((_2s-_aEs)<10)||((_7G-_2s)<10)){this.m_oDom.style.display='block';if(_o.is_ie5_5up){this.m_oDom.style.left=((_2s-_aEs)<12?(_Vl.offsetLeft-5):(_Vl.offsetLeft+_Vl.offsetWidth-5))+'px';}else{this.m_oDom.style.left=((_2s-_aEs)<12?(_Vl.offsetLeft):(_Vl.offsetLeft+_Vl.offsetWidth))+'px';}this.m_oDom.style.top='0px';COTStyle.SetHeight(this.m_oDom,this.m_oTargetEle.offsetHeight-4);}this._mU=_ON;};CUIVertResizingBar.SafeOnMouseDown=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}var _arL=Dom.GetEventTarget(e)._ec;if(_arL){window.lastActiveResizeBar=_arL;_arL.OnMouseDown(e);_arL.m_bDragging=true;}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIVertResizingBar.prototype.OnMouseDown=function(e){Dom.CancelEvent(e);CUIManager.CallCurrentMouseDown(e);if(this.m_oDom.setCapture){this.m_oDom.setCapture(true);}else{Dom.SetObjRef(this.m_oTargetEle,this,'oResizeBar');var _arL=window.lastActiveResizeBar;if(!_arL)return;window.captureEvents(Event.MouseUp|Event.MouseMove);window.onmouseup=function(e){_arL.OnMouseUp(e);};window.onmousemove=function(e){_arL.OnMouseMove(e);};}this.iLastMove=0;Dom.SetObjRef(this.m_oTargetEle,this,'oResizeBar');this.m_iInitialX=e.clientX;this.m_iLastX=e.clientX;this.m_iInitialY=e.clientY;this.m_iLastY=e.clientY;this.m_MovingLine.style.display="block";COTStyle.SetWidth(this.m_MovingLine,1,'px');COTStyle.SetHeight(this.m_MovingLine,this.m_oDom.offsetHeight);};CUIVertResizingBar.SafeOnMouseMove=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e)var e=window.event;var _arL=window.lastActiveResizeBar;if(!_arL)return;_arL.OnMouseMove(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIVertResizingBar.prototype.OnMouseMove=function(e){if(!this.m_bDragging){return;}Dom.CancelEvent(e);var x=this.m_iLastX-e.clientX;if(Math.abs(x)>3){this.m_iLastX=e.clientX;this.m_oDom.style.left=this.m_oDom.offsetLeft-x+"px";}};CUIVertResizingBar.SafeOnMouseUp=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}if(!Dom.IsLeftButton(e))return;var _arL=window.lastActiveResizeBar;if(!_arL)return;_arL.OnMouseUp(e);_arL.m_bDragging=false;window.lastActiveResizeBar=null;/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIVertResizingBar.prototype.OnMouseUp=function(event){Dom.CancelEvent(event);if(this.m_oDom.releaseCapture){this.m_oDom.releaseCapture();}else{window.releaseEvents(Event.MouseUp);window.releaseEvents(Event.MouseMove);}this.HideBar();if(this.m_bDragging){this.SetNewWidth(this._mU.GetHtmlElement(),event);this.m_bDragging=false;}};CUIVertResizingBar.prototype.SetNewWidth=function(_Vl,event){if(this.m_iInitialX!==null){_Vl._lU=event.clientX-this.m_iInitialX;if(_Vl._lU!=0){this.m_oListener.SetCurrentResizeTrigger(_Vl);this.m_oListener.Notify(ExpEvent.kCUICrosstab_ColResize);}}this.m_iInitialX=null;this.m_iLastX=null;this._mU=null;};CUIVertResizingBar.prototype.Clear=function(){Dom.RemoveObject(this.m_oDom);this.m_oDom=null;this.m_MovingLine=null;this.m_oListener=null;};function CUIVertChartSlider(){this.base=CUIVertPaneSplitter;this.base();};CUIVertChartSlider.prototype=new CUIVertPaneSplitter;CUIVertChartSlider.superclass=CUIVertPaneSplitter.prototype;CUIVertChartSlider.ikPaddingFromLineToBarBorder=9;CUIVertChartSlider.prototype.CreateSlider=function(_zX,_E3,sCustomImg,_QC,_IB,_PN,_DT,_OK,_TM){Debug.Assert(_zX);this.m_oTargetEle=_zX;this.iCurYMeaValue=_PN;this.iTotalHeight=_OK-_DT;this.iMinValue=_QC;this.iMaxValue=_IB;this.iMovingUnitValue=(_IB-_QC)/this.iTotalHeight;if(!this.CreateBar(this.iCurYMeaValue,_DT,_OK,_TM)){Debug.Assert(false,"CUIPaneSplitter::CreatePaneSplitter--failed");return false;}this.m_oDom.id="verticalSlider"+Utilities.GenerateId();Dom.SetObjRef(this.m_oDom,this,"oSlider");this.m_oDom.onmousedown=this.SafeOnMouseDown;this.m_oDom.onmousemove=this.SafeOnMouseMove;this.m_oDom.onmouseup=this.SafeOnMouseUp;this.m_oDom.onmouseover=Dom.CancelEvent;if(sCustomImg){this.m_MovingLine=this.m_oDom.appendChild(document.createElement('IMG'));this.m_MovingLine.src=Utilities.IMG_PATH+sCustomImg;this.m_MovingLine.className="clsVertChartSliderRuler";this.m_MovingLine.alt=this.iCurYMeaValue;this.m_MovingLine.title=this.iCurYMeaValue;}return true;};CUIVertChartSlider.prototype.CreateBar=function(iCurYMeaValue,_DT,_OK,_TM){this.m_oDom=document.createElement("DIV");this.m_oTargetEle.appendChild(this.m_oDom);this.m_oDom.className="clsChartSliderMovingBar";this.iInitYPos=_OK-((this.iCurYMeaValue-this.iMinValue)/this.iMovingUnitValue);this.m_oDom.style.top=this.iInitYPos-CUIVertChartSlider.ikPaddingFromLineToBarBorder+'px';COTStyle.SetSize(this.m_oDom,400,20);var _arc=COTInputElementFactory.CreateImage('sliderhandlevertical.gif',15,10);_arc.className="clsVertChartSliderHandler";this.m_oDom.appendChild(_arc);var _ap0=Math.round((this.iMaxValue-this.iMinValue)*0.05);this._uF=this.iMinValue-_ap0;this.iOrigPointYPos=_TM+(_OK+(_ap0/this.iMovingUnitValue))-9;this.iMapTop=_TM;this.iMinYPos=_TM;this.m_oCoordsDiv=document.createElement("DIV");this.m_oCoordsDiv.className="sliderCoordinatesToolTip";this.m_oCoordsDiv.style.left=0+'px';this.m_oTargetEle.appendChild(this.m_oCoordsDiv);this.m_oCoordsDiv.style.display='none';return true;};CUIVertChartSlider.prototype.OnCreate=function(_Tf,_E5,_VW,_QC,_IB,_PN,_DT,_OK,_SU){this.m_oListener=_E5;return this.CreateSlider(_VW,"clsChartSlider",_Tf,_QC,_IB,_PN,_DT,_OK,_SU);};CUIVertChartSlider.prototype.SetHandlerInitLeftPos=function(_P6){this.m_oDom.style.left=_P6+"px";};CUIVertChartSlider.prototype.HideBar=function(){this.m_oDom.style.display='none';this.m_MovingLine.style.display='none';};CUIVertChartSlider.prototype.ShowBar=function(_ON,e){};CUIVertChartSlider.prototype.SafeOnMouseDown=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}this.oSlider.OnMouseDown(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIVertChartSlider.prototype.OnMouseDown=function(e){Dom.CancelEvent(e);CUIManager.CallCurrentMouseDown(e);this.m_bDragging=true;if(this.m_oDom.setCapture){this.m_oDom.setCapture(true);}else{this.normalWindowMouseUpHandler=window.onmouseup;this.normalWindowMouseMoveHandler=window.onmousemove;window.captureEvents(Event.MouseUp);window.onmouseup=this.SafeOnMouseUp;window.captureEvents(Event.MouseMove);window.onmousemove=this.SafeOnMouseMove;}this.m_iInitialX=e.clientX;this.m_iLastX=e.clientX;this.m_iInitialY=e.clientY;this.m_iLastY=e.clientY;};CUIVertChartSlider.prototype.SafeOnMouseMove=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e)var e=window.event;this.oSlider.OnMouseMove(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIVertChartSlider.prototype.OnMouseMove=function(e){Dom.CancelEvent(e);var y=this.m_iLastY-e.clientY;if(Math.abs(y)>1&&this.m_bDragging){var _af4=this.m_oDom.offsetTop-y;if((this.iMapTop+_af4)>this.iOrigPointYPos||((this.iMapTop+_af4)<this.iMinYPos)){return;}this.m_iLastY=e.clientY;this.m_oDom.style.top=_af4+"px";this.m_oCoordsDiv.style.top=this.m_iLastY-90+'px';var _1l=Math.abs(this.iOrigPointYPos-(this.m_oDom.offsetTop+this.iMapTop));var _DB=this._uF+(_1l*this.iMovingUnitValue);this.m_oCoordsDiv.innerHTML=this.m_oListener.yMeasureLabel+" = "+Math.round(_DB);this.m_oCoordsDiv.style.display='block';}};CUIVertChartSlider.prototype.SafeOnMouseUp=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}this.oSlider.OnMouseUp(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIVertChartSlider.prototype.OnMouseUp=function(event){Dom.CancelEvent(event);if(this.m_oDom.releaseCapture){this.m_oDom.releaseCapture();}else{window.releaseEvents(Event.MouseUp);window.onmouseup=this.normalWindowMouseUpHandler;window.releaseEvents(Event.MouseMove);window.onmousemove=this.normalWindowMouseMoveHandler;}if(this.m_bDragging){this.SetNewPosition(event);this.m_bDragging=false;}this.m_oCoordsDiv.style.display='none';};CUIVertChartSlider.prototype.GetZeroYPosition=function(){return this.iOrigPointYPos-this.iMapTop;};CUIVertChartSlider.prototype.SetNewPosition=function(event){var _1l=Math.abs(this.iOrigPointYPos-(this.m_oDom.offsetTop+this.iMapTop));var _DB=this._uF+Math.round(_1l*this.iMovingUnitValue);this.m_MovingLine.alt=_DB;this.m_MovingLine.title=_DB;this.m_oListener.CreateVSegments(_DB);};CUIVertChartSlider.prototype.Clear=function(){Dom.RemoveObject(this.m_oDom);this.m_oDom=null;this.m_MovingLine=null;this.m_oListener=null;};function CUIHorizChartSlider(){this.base=CUIVertPaneSplitter;this.base();};CUIHorizChartSlider.prototype=new CUIHorizPaneSplitter;CUIHorizChartSlider.superclass=CUIHorizPaneSplitter.prototype;CUIHorizChartSlider.ikPaddingFromLineToBarBorder=9;CUIHorizChartSlider.prototype.CreateSlider=function(_zX,_E3,sCustomImg,_QC,_IB,_A6,_PL,_St,_P6){Debug.Assert(_zX);this.m_oTargetEle=_zX;this.iCurXMeaValue=_A6;this.iTotalWidth=_St-_PL;this.iMinValue=_QC;this.iMaxValue=_IB;this.iMovingUnitValue=(_IB-_QC)/this.iTotalWidth;if(!this.CreateBar(_PL,_St,_P6)){Debug.Assert(false,"CUIPaneSplitter::CreatePaneSplitter--failed");return false;}this.m_oDom.id="verticalSlider"+Utilities.GenerateId();Dom.SetObjRef(this.m_oDom,this,"oSlider");this.m_oDom.onmousedown=this.SafeOnMouseDown;this.m_oDom.onmousemove=this.SafeOnMouseMove;this.m_oDom.onmouseup=this.SafeOnMouseUp;this.m_oDom.onmouseover=Dom.CancelEvent;if(sCustomImg){this.m_MovingLine=this.m_oDom.appendChild(document.createElement('IMG'));this.m_MovingLine.src=Utilities.IMG_PATH+sCustomImg;this.m_MovingLine.className="clsHorizChartSliderRuler";this.m_MovingLine.style.top=0+"px";this.m_MovingLine.style.left=CUIHorizChartSlider.ikPaddingFromLineToBarBorder+"px";this.m_MovingLine.alt=this.iCurXMeaValue;this.m_MovingLine.title=this.iCurXMeaValue;}return true;};CUIHorizChartSlider.prototype.CreateBar=function(_PL,_St,_P6){this.m_oDom=document.createElement("DIV");this.iInitXPos=_PL+((this.iCurXMeaValue-this.iMinValue)/this.iMovingUnitValue);this.m_oDom.style.top=0+"px";this.m_oDom.style.left=this.iInitXPos-10+"px";COTStyle.SetSize(this.m_oDom,20,325);this.m_oTargetEle.appendChild(this.m_oDom);this.m_oDom.className="clsChartSliderMovingBar";var _arc=COTInputElementFactory.CreateImage('sliderhandlehorizontal.gif',10,16);_arc.className="clsHorizChartSliderHandler";_arc.style.top=287+"px";_arc.style.left=4+"px";_arc.id=Utilities.GenerateId();this._hk=_arc.id;var _ap0=Math.round((this.iMaxValue-this.iMinValue)*0.05);this._uF=this.iMinValue-_ap0;this.iOrigPointXPos=_P6-10+(_PL-_ap0/this.iMovingUnitValue);this.iMapLeft=_P6;this.iMaxXPos=this.iOrigPointXPos+this.iTotalWidth+_PL;this.m_oDom.appendChild(_arc);this.m_oCoordsDiv=document.createElement("DIV");this.m_oCoordsDiv.className="sliderCoordinatesToolTip";this.m_oCoordsDiv.style.top=292+'px';this.m_oTargetEle.appendChild(this.m_oCoordsDiv);this.m_oCoordsDiv.style.display='none';return true;};CUIHorizChartSlider.prototype.OnCreate=function(_Tf,_E5,_VW,_QC,_IB,_A6,_PL,_St,_P6){this.m_oListener=_E5;return this.CreateSlider(_VW,"clsChartSlider",_Tf,_QC,_IB,_A6,_PL,_St,_P6);};CUIHorizChartSlider.prototype.HideBar=function(){this.m_oDom.style.display='none';this.m_MovingLine.style.display='none';};CUIVertChartSlider.prototype.ShowBar=function(_ON,e){};CUIHorizChartSlider.prototype.SafeOnMouseDown=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}this.oSlider.OnMouseDown(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIHorizChartSlider.prototype.OnMouseDown=function(e){Dom.CancelEvent(e);CUIManager.CallCurrentMouseDown(e);this.m_bDragging=true;if(this.m_oDom.setCapture){this.m_oDom.setCapture(true);}else{this.normalWindowMouseUpHandler=window.onmouseup;this.normalWindowMouseMoveHandler=window.onmousemove;window.captureEvents(Event.MouseUp);window.onmouseup=this.SafeOnMouseUp;window.captureEvents(Event.MouseMove);window.onmousemove=this.SafeOnMouseMove;}this.m_iInitialX=e.clientX;this.m_iLastX=e.clientX;this.m_iInitialY=e.clientY;this.m_iLastY=e.clientY;};CUIHorizChartSlider.prototype.SafeOnMouseMove=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e)var e=window.event;this.oSlider.OnMouseMove(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIHorizChartSlider.prototype.OnMouseMove=function(e){Dom.CancelEvent(e);var x=this.m_iLastX-e.clientX;if(Math.abs(x)>1&&this.m_bDragging){var _avp=this.m_oDom.offsetLeft-x;if((this.iMapLeft+_avp)<this.iOrigPointXPos||((this.iMapLeft+_avp)>this.iMaxXPos)){return;}this.m_iLastX=e.clientX;this.m_oDom.style.left=_avp+"px";this.m_oCoordsDiv.style.left=this.m_iLastX-this.iMapLeft+10+'px';var _axR=Math.abs((this.m_oDom.offsetLeft+this.iMapLeft)-this.iOrigPointXPos);var _DB=this._uF+(_axR*this.iMovingUnitValue);this.m_oCoordsDiv.style.display='block';this.m_oCoordsDiv.innerHTML=this.m_oListener.xMeasureLabel+" = "+Math.round(_DB);}};CUIHorizChartSlider.prototype.SafeOnMouseUp=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}this.oSlider.OnMouseUp(e);window.lastActiveResizeBar=null;/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIHorizChartSlider.prototype.OnMouseUp=function(event){Dom.CancelEvent(event);if(this.m_oDom.releaseCapture){this.m_oDom.releaseCapture();}else{window.releaseEvents(Event.MouseUp);window.onmouseup=this.normalWindowMouseUpHandler;window.releaseEvents(Event.MouseMove);window.onmousemove=this.normalWindowMouseMoveHandler;}if(this.m_bDragging){this.SetNewPosition(event);this.m_bDragging=false;}this.m_oCoordsDiv.style.display='none';};CUIHorizChartSlider.prototype.SetNewPosition=function(event){var _axR=Math.abs((this.m_oDom.offsetLeft+this.iMapLeft)-this.iOrigPointXPos);var _DB=this._uF+Math.round(_axR*this.iMovingUnitValue);this.m_MovingLine.alt=_DB;this.m_MovingLine.title=_DB;this.m_MovingLine.className="clsHorizChartSliderRuler";this.m_oListener.CreateHSegments(_DB);};CUIHorizChartSlider.prototype.Clear=function(){Dom.RemoveObject(this.m_oDom);this.m_oDom=null;this.m_MovingLine=null;this.m_oListener=null;};CUIHorizChartSlider.prototype.GetZeroXPosition=function(){return this.iOrigPointXPos-this.iMapLeft;};CUIHorizChartSlider.prototype.SetHandlerInitTopPos=function(_TM){var _YH=document.getElementById(this._hk);_YH.style.top=_TM+"px";};function CUIScrollbar(){};CUIScrollbar.prototype.OnCreate=function(_F4,_T6,_D3,_zF,_Fx,_Kq,oPane,_DX,_Cv,_JN){this.m_iWidth=_F4;this.m_iHeight=_T6;this.m_iTotalUnits=Math.max(1,_D3);this.m_iVisibleUnits=_zF;this.m_iFirstVisibleUnit=_Fx;this.m_oParentControl=_Kq;this.m_oPane=oPane;this.m_oDiv=oPane.GetDom();this.m_oDiv.bIsScrollControlElement=true;this.m_bVisible=_DX;this.m_bVertical=_Cv;this.m_iStartPos=_JN-2;this.m_iMinScrollBoxLength=5;var _aAT=Utilities.GenerateId();this.m_oDiv.id="scrollbar"+_aAT;Dom.SetWindowGlobalObject(this.m_oDiv.id,this);Dom.SetObjRef(this.m_oDiv,this,'scrollbar');this.m_oDiv.onmousedown=this.SafeHandleMouseDown;this.m_oDiv.onmouseup=this.SafeHandleMouseUp;this.m_oDiv.onmouseout=this.SafeHandleMouseOut;this.m_oDiv.onmouseover=this.SafeHandleMouseOver;this.m_oDiv.onmousemove=this.SafeHandleMouseMove;this.m_iFirstPageDelay=300;this.m_iRepeatPageDelay=0;this.setArrowLength();this.setScrollTrackLength();this.createScrollComponents();};CUIScrollbar.prototype.Unload=function(){this.OnClose();};CUIScrollbar.prototype.OnClose=function(){if(this.m_oPane){this.m_oPane.Unload();this.m_oStartArrow.Unload();this.m_oEndArrow.Unload();this.m_oScrollBox.Unload();Dom.SetWindowGlobalObject(this.m_oDiv.id,null);this.m_oDiv.scrollbar=null;Dom.RemoveObject(this.m_oDiv);}Utilities.RemoveAllChildObjects(this);window.lastActiveScrollbar=null;};CUIScrollbar.prototype.GetFirstVisibleIndex=function(){return this.m_iFirstVisibleUnit;};CUIScrollbar.prototype.SetFirstVisibleIndex=function(_Fx){this.m_iFirstVisibleUnit=_Fx;};CUIScrollbar.prototype.GetVisibleUnits=function(){return this.m_iVisibleUnits;};CUIScrollbar.prototype.GetTotalUnits=function(){return this.m_iTotalUnits;};CUIScrollbar.prototype.CreateScrollBox=function(){if(this.m_bVertical){var _QY=this.m_iWidth;}else{var _QY=this.m_iHeight;}if(this.m_oScrollBox){this.m_oDiv.removeChild(this.m_oScrollBox.m_oDom);}this.m_oScrollBox=new CUIScrollBox();this.m_oScrollBox.OnCreate(this,this.m_bVisible,_QY);this.m_oScrollBox.SetLength(this.GetScrollBoxLength());this.m_oScrollBox.SetScrollPos(this.GetStartTrackLength(),this.GetMaxEndPosition());this.m_oScrollBox.Show(this.m_bVisible);return true;};CUIScrollbar.prototype.Show=function(_DX){this.m_bVisible=_DX;if(this.m_bVisible){this.m_oDiv.style.visibility="visible";}else{this.m_oDiv.style.visibility="hidden";}this.m_oEndArrow.Show(this.m_bVisible);this.m_oStartArrow.Show(this.m_bVisible);this.m_oScrollBox.Show(this.m_bVisible);return true;};CUIScrollbar.prototype.IsVisible=function(_DX){return this.m_bVisible;};CUIScrollbar.prototype.Resize=function(_Hh){if(this.m_bVertical){this.m_iHeight=_Hh;}else{this.m_iWidth=_Hh;}this.setScrollTrackLength();this.updateVisualComponents();return true;};CUIScrollbar.prototype.UpdateScrollPosition=function(_Fx){if((_Fx<0)||(_Fx>(this.m_iTotalUnits-1))){return false;}this.m_iFirstVisibleUnit=_Fx;this.setComponentsPosition();return true;};CUIScrollbar.prototype.OnStartArrowDown=function(){if(this.m_iFirstVisibleUnit<=0)return;this.m_iFirstVisibleUnit--;this.m_oEndArrow.UpdateImage();if(this.m_bVertical){this.OnNotifyUpArrowDown(this.m_iFirstVisibleUnit);}else{this.OnNotifyLeftArrowDown(this.m_iFirstVisibleUnit);}};CUIScrollbar.prototype.OnEndArrowDown=function(){if(this.m_iFirstVisibleUnit>=this.m_iTotalUnits-this.m_iVisibleUnits)return;this.m_iFirstVisibleUnit++;this.m_oStartArrow.UpdateImage();if(this.m_bVertical){this.OnNotifyDownArrowDown(this.m_iFirstVisibleUnit);}else{this.OnNotifyRightArrowDown(this.m_iFirstVisibleUnit);}};CUIScrollbar.prototype.OnStartTrackDown=function(){var _ahy=Math.max(this.m_iVisibleUnits,1);this.m_iFirstVisibleUnit=Math.max(0,this.m_iFirstVisibleUnit-_ahy);if(this.m_bVertical){this.OnNotifyUpTrackDown(this.m_iFirstVisibleUnit);}else{this.OnNotifyLeftTrackDown(this.m_iFirstVisibleUnit);}};CUIScrollbar.prototype.OnEndTrackDown=function(){var _ahy=Math.max(this.m_iVisibleUnits,1);this.m_iFirstVisibleUnit=Math.min(this.m_iTotalUnits-_ahy,this.m_iFirstVisibleUnit+_ahy);if(this.m_bVertical){this.OnNotifyDownTrackDown(this.m_iFirstVisibleUnit);}else{this.OnNotifyRightTrackDown(this.m_iFirstVisibleUnit);}};CUIScrollbar.prototype.OnScrollBoxRelease=function(){if(this.m_bVertical){this.OnNotifyVScrollBoxReleased(this.m_iFirstVisibleUnit);}else{this.OnNotifyHScrollBoxReleased(this.m_iFirstVisibleUnit);}};CUIScrollbar.prototype.GetStartTrackLength=function(){if(this.m_iFirstVisibleUnit+this.m_iVisibleUnits>this.m_iTotalUnits){var _On=this.m_iScrollTrackLength-this.GetScrollBoxLength();}else{var _On=Math.min(Math.floor(this.m_iScrollTrackLength*this.m_iFirstVisibleUnit/this.m_iTotalUnits),(this.m_iScrollTrackLength-this.m_iMinScrollBoxLength));}return Math.max(_On,0);};CUIScrollbar.prototype.GetScrollBoxLength=function(){var i=0;if(this.m_iVisibleUnits>this.m_iTotalUnits){return Math.max(this.m_iMinScrollBoxLength,this.m_iScrollTrackLength);}else{return Math.max(this.m_iMinScrollBoxLength,Math.floor(this.m_iScrollTrackLength*this.m_iVisibleUnits/this.m_iTotalUnits));}};CUIScrollbar.prototype.GetEndTrackLength=function(){return Math.max(0,this.m_iScrollTrackLength-this.GetScrollBoxLength()-this.GetStartTrackLength());};CUIScrollbar.prototype.GetMaxEndPosition=function(){var _Yx=this.m_iArrowLength;if(this.m_oParentControl.HasBothScrollbars()){_Yx=2*this.m_iArrowLength;}if(this.m_bVertical){return Math.max(this.m_iHeight-_Yx,0);}else{return Math.max(this.m_iWidth-_Yx,0);}};CUIScrollbar.prototype.setComponentsPosition=function(){var _Rk=this.GetMaxEndPosition();this.setArrowPos(true,_Rk);this.m_oScrollBox.SetScrollPos(this.GetStartTrackLength(),_Rk);this.setArrowPos(false,_Rk);};CUIScrollbar.prototype.setScrollBoxDimension=function(){this.m_oScrollBox.SetLength(this.GetScrollBoxLength());};CUIScrollbar.prototype.setScrollTrackLength=function(){if(this.m_bVertical){this.m_iScrollTrackLength=this.GetMaxEndPosition()-this.m_iStartPos-this.m_iArrowLength;}else{this.m_iScrollTrackLength=this.GetMaxEndPosition()-this.m_iStartPos-this.m_iArrowLength;}};CUIScrollbar.prototype.setArrowLength=function(){if(this.m_bVertical){this.m_iArrowLength=this.m_iWidth;}else{this.m_iArrowLength=this.m_iHeight;}};CUIScrollbar.prototype.updateVisualComponents=function(){this.setScrollBoxDimension();this.setComponentsPosition();this.Show(this.m_bVisible);};CUIScrollbar.prototype.notifyParent=function(){if(this.m_bScrollDirection){this.OnStartTrackDown();}else{this.OnEndTrackDown();}};CUIScrollbar.RepeatPageScroll=function(){/*@if(!@bering_debug)@*/try{/*@end@*/if(window.lastActiveScrollbar){window.lastActiveScrollbar.RepeatPageScroll();}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIScrollbar.prototype.RepeatPageScroll=function(){try{if(!this.continueScrolling()){this.m_bScrollTimeoutStarted=false;}else{this.notifyParent();if(window.lastActiveScrollbar){var _6z=CUIScrollbar.RepeatPageScroll;setTimeout(_6z,this.m_iRepeatPageDelay);}this.m_bScrollTimeoutStarted=true;}}catch(e){_f.HandleException(e);}};CUIScrollbar.prototype.continueScrolling=function(){if(!this.m_bScrolling)return false;if(this.m_bScrollDirection){return(this.m_iMousePosition<=this.m_iArrowLength+this.GetStartTrackLength());}else{return(this.m_iMousePosition>=this.m_iArrowLength+this.GetStartTrackLength()+this.GetScrollBoxLength());}};CUIScrollbar.prototype.SafeHandleMouseMove=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e)var e=window.event;var _aFQ=window.lastActiveScrollbar;if(!_aFQ||(_aFQ.m_oDiv&&_aFQ.m_oDiv.id!=Dom.GetEventTarget(e).id)){return;}_aFQ.HandleMouseMove(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIScrollbar.prototype.HandleMouseMove=function(e){if(this.m_bVertical){if((Dom.GetOffsetX(e)<0)||(Dom.GetOffsetX(e)>this.m_iArrowLength)){this.m_bScrolling=false;return;}if((Dom.GetOffsetY(e)<this.m_iArrowLength)||(Dom.GetOffsetY(e)>(this.m_iHeight-this.m_iArrowLength))){this.m_bScrolling=false;return;}}else{if((Dom.GetOffsetY(e)<0)||(Dom.GetOffsetY(e)>this.m_iArrowLength)){this.m_bScrolling=false;return;}if((Dom.GetOffsetX(e)<this.m_iArrowLength)||(Dom.GetOffsetX(e)>(this.m_iWidth-this.m_iArrowLength))){this.m_bScrolling=false;return;}}if(this.m_bVertical){this.m_iMousePosition=Dom.GetOffsetY(e);}else{this.m_iMousePosition=Dom.GetOffsetX(e);}var _aad=this.m_oParentControl.m_oApp.browserInfo.is_netscape;if(this.m_bScrolling&&(!this.m_bScrollTimeoutStarted)){this.RepeatPageScroll();}else if(_aad&&!this.m_bScrolling){if(this.m_bButtonHeldDown)this.m_bScrolling=true;if(this.m_bVertical){this.OnNotifyVMouseOver();}else{this.OnNotifyHMouseOver();}}};CUIScrollbar.SafeDisableBodyTextSelection=function(_yW){if(!_yW.bTextSelectionDisabled){if(_o.is_ie5_5up){_yW.onselectstart=function(){return false;};}else if(_o.is_firefox){_yW.style.MozUserSelect="none";}else{_yW.onmousedown=function(){return false;};}_yW.style.cursor="default";_yW.bTextSelectionDisabled=true;}};CUIScrollbar.prototype.SafeHandleMouseDown=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e)var e=window.event;if(!Dom.IsLeftButton(e)||!Dom.GetEventTarget(e)||Dom.GetEventTarget(e).id=="")return;var _aFQ=Dom.GetWindowGlobalObject(Dom.GetEventTarget(e).id);if(_aFQ&&_aFQ instanceof CUIScrollbar){window.lastActiveScrollbar=_aFQ;_aFQ.HandleMouseDown(e);}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/try{}catch(e){_f.HandleException(e);}};CUIScrollbar.prototype.HandleMouseDown=function(e){CUIScrollbar.SafeDisableBodyTextSelection(this.m_oDiv);if(this.m_bVertical){this.m_iMousePosition=Dom.GetOffsetY(e);var _asm=parseInt(this.m_oStartArrow.m_oDomImage.style.top);var _Xj=parseInt(this.m_oEndArrow.m_oDomImage.style.top)+parseInt(this.m_oEndArrow.m_oDomImage.style.height);if((this.m_iMousePosition<_asm)||(this.m_iMousePosition>_Xj)){return;}this.m_bScrollDirection=(Dom.GetOffsetY(e)-this.m_iStartPos<=this.GetStartTrackLength()+this.m_iArrowLength);}else{this.m_iMousePosition=Dom.GetOffsetX(e);var _avx=parseInt(this.m_oStartArrow.m_oDomImage.style.left);var _acr=parseInt(this.m_oEndArrow.m_oDomImage.style.left)+parseInt(this.m_oEndArrow.m_oDomImage.style.width);if((this.m_iMousePosition<_avx)||(this.m_iMousePosition>_acr)){return;}this.m_bScrollDirection=(Dom.GetOffsetX(e)-this.m_iStartPos<=this.GetStartTrackLength()+this.m_iArrowLength);}this.m_bButtonHeldDown=true;this.m_bScrolling=true;CUIManager.CallCurrentMouseDown(e);if(this.m_oDiv.setCapture){this.m_oDiv.setCapture();}else{window.captureEvents(Event.MouseMove);window.onmousemove=this.SafeHandleMouseMove;window.captureEvents(Event.MouseUp);window.onmouseup=this.SafeHandleMouseUp;}this.notifyParent();if(window.lastActiveScrollbar){var _6z=CUIScrollbar.RepeatPageScroll;setTimeout(_6z,this.m_iFirstPageDelay);}this.m_bScrollTimeoutStarted=true;Dom.CancelBubble(e);};CUIScrollbar.prototype.SafeHandleMouseUp=function(e){if(window.lastActiveScrollBox&&window.lastActiveScrollBox.m_bDrag){CUIScrollBox.SafeHandleMouseUp(e);return;}if(window.lastActiveScrollArrow&&window.lastActiveScrollArrow.m_bButtonHeldDown){CUIScrollArrow.SafeHandleMouseUp(e);return;}try{if(!e)var e=window.event;if(!Dom.IsLeftButton(e))return;var _aFQ=window.lastActiveScrollbar;if(!_aFQ)return;else{_aFQ.HandleMouseUp(e);}}catch(e){_f.HandleException(e);}};CUIScrollbar.prototype.HandleMouseUp=function(e){if(this.m_bScrolling)this.m_bScrolling=false;if(this.m_oDiv&&this.m_oDiv.releaseCapture)this.m_oDiv.releaseCapture();else{window.releaseEvents(Event.MouseMove);window.onmousemove=null;window.releaseEvents(Event.MouseUp);window.onmouseup=null;}this.m_bButtonHeldDown=false;Dom.CancelBubble(e);};CUIScrollbar.prototype.SafeHandleMouseOut=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e)var e=window.event;var _aFQ=Dom.GetEventTarget(e).scrollbar;if(!_aFQ)return;_aFQ.m_bScrolling=false;Dom.CancelBubble(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIScrollbar.prototype.SafeHandleMouseOver=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e)var e=window.event;var _aFQ=Dom.GetEventTarget(e).scrollbar;if(!_aFQ)return;else{_aFQ.HandleMouseOver(e);}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIScrollbar.prototype.HandleMouseOver=function(e){if(this.m_bButtonHeldDown)this.m_bScrolling=true;Dom.CancelBubble(e);if(this.m_bVertical){this.OnNotifyVMouseOver();}else{this.OnNotifyHMouseOver();}};CUIScrollbar.prototype.OnScrollBoxDrag=function(_Tt){var _aD3=_Tt-this.m_iInitialScrollBoxDragPosition;this.m_iFirstVisibleUnit=Math.round(this.m_iTotalUnits*_aD3/this.m_iScrollTrackLength)+this.m_iDragInitialFirstVisibleUnit;if(_aD3<this.m_iMaxStartDrag)this.m_iFirstVisibleUnit=0;if(_aD3>this.m_iMaxEndDrag)this.m_iFirstVisibleUnit=this.m_iTotalUnits-this.m_iVisibleUnits;this.setComponentsPosition();if(this.m_bVertical){this.OnNotifyVScrollBoxDrag(this.m_iFirstVisibleUnit);}else{this.OnNotifyHScrollBoxDrag(this.m_iFirstVisibleUnit);}};CUIScrollbar.prototype.OnStartScrollBoxDrag=function(_SB){this.m_iInitialScrollBoxDragPosition=_SB;this.m_iDragInitialFirstVisibleUnit=this.m_iFirstVisibleUnit;this.m_iMaxStartDrag=(-1)*this.GetStartTrackLength();this.m_iMaxEndDrag=this.GetEndTrackLength();};CUIScrollbar.prototype.SetUnits=function(_zF,_Fx,_D3){if(_zF||(_zF==0))this.m_iVisibleUnits=_zF;if(_Fx||(_Fx==0))this.m_iFirstVisibleUnit=_Fx;if(_D3)this.m_iTotalUnits=_D3;return true;};CUIScrollbar.prototype.removeDomObject=function(_TT){var _VW=_TT.parentElement;if(_VW){var c=_VW.removeChild(_TT);if(c){c=null;}}_TT=null;};CUIScrollbar.prototype.AddListener=function(_E5){this.m_oListener=_E5;};function CUIHorizScrollbar(){this.m_sStartArrowImagePath=Utilities.IMG_PATH+"scrollLeftArrow.gif";this.m_sStartArrowPushedImagePath=Utilities.IMG_PATH+"scrollLeftArrowPushed.gif";this.m_sEndArrowImagePath=Utilities.IMG_PATH+"scrollRightArrow.gif";this.m_sEndArrowPushedImagePath=Utilities.IMG_PATH+"scrollRightArrowPushed.gif";};CUIHorizScrollbar.prototype=new CUIScrollbar();CUIHorizScrollbar.prototype.createScrollComponents=function(){this.m_oDiv.className="scrollbarStyle";this.m_oStartArrow=new CUIScrollArrow(this.m_sStartArrowImagePath,this.m_sStartArrowPushedImagePath,this.m_iArrowLength,this.m_iHeight);this.m_oStartArrow.OnCreate(this.m_bVisible,this,true,false,true);this.m_oDiv.appendChild(this.m_oStartArrow.GetDomImage());this.CreateScrollBox();this.m_oEndArrow=new CUIScrollArrow(this.m_sEndArrowImagePath,this.m_sEndArrowPushedImagePath,this.m_iArrowLength,this.m_iHeight);this.m_oEndArrow.OnCreate(this.m_bVisible,this,false,false,true);this.m_oDiv.appendChild(this.m_oEndArrow.GetDomImage());this.updateVisualComponents();return true;};CUIHorizScrollbar.prototype.CreateSplitter=function(){this.m_oSplitter=document.createElement("DIV");this.m_oSplitter.className="v_scroll_bar_splitter";return this.m_oSplitter;};CUIHorizScrollbar.prototype.SetStartPosition=function(_UT){this.m_iStartPos=Math.min(_UT-2,this.GetMaxEndPosition());this.m_oScrollBox.m_iLeft=Math.min(this.m_iStartPos+this.m_iArrowLength,this.GetMaxEndPosition());};CUIHorizScrollbar.prototype.SetWidth=function(_Ls){this.m_iWidth=_Ls;this.m_iStartPos=Math.min(this.m_iStartPos,this.GetMaxEndPosition());};CUIHorizScrollbar.prototype.OnResize=function(){return this.Resize(this.m_oPane.GetWidth());};CUIHorizScrollbar.prototype.OnNotifyLeftArrowDown=function(_Fx){this.notify(_Fx);};CUIHorizScrollbar.prototype.OnNotifyRightArrowDown=function(_Fx){this.notify(_Fx);};CUIHorizScrollbar.prototype.OnNotifyLeftTrackDown=function(_Fx){this.notify(_Fx);};CUIHorizScrollbar.prototype.OnNotifyRightTrackDown=function(_Fx){this.notify(_Fx);};CUIHorizScrollbar.prototype.OnNotifyHScrollBoxReleased=function(_Fx){this.notify(_Fx);};CUIHorizScrollbar.prototype.notify=function(_Fx){if(this.m_oListener&&this.m_oListener.Notify){this.m_oListener.Notify(ExpEvent.kCUIScrollControl_HScroll);}else if(this.m_oListener&&this.m_oListener.OnHScrollTo){this.m_oListener.OnHScrollTo(_Fx);}else{this.UpdateScrollPosition(_Fx);}};CUIHorizScrollbar.prototype.OnNotifyHMouseOver=function(){};CUIHorizScrollbar.prototype.OnNotifyHScrollBoxDrag=function(_Fx){};CUIHorizScrollbar.prototype.setArrowPos=function(_TP,_Rk){if(_TP){var _P6=Math.min(this.m_iStartPos,_Rk);this.m_oStartArrow.GetDomImage().style.left=_P6+"px";}else{this.m_oEndArrow.GetDomImage().style.left=_Rk+"px";}};function CUIVertScrollbar(){this.m_sStartArrowImagePath=Utilities.IMG_PATH+"scrollUpArrow.gif";this.m_sStartArrowPushedImagePath=Utilities.IMG_PATH+"scrollUpArrowPushed.gif";this.m_sEndArrowImagePath=Utilities.IMG_PATH+"scrollDownArrow.gif";this.m_sEndArrowPushedImagePath=Utilities.IMG_PATH+"scrollDownArrowPushed.gif";};CUIVertScrollbar.prototype=new CUIScrollbar();CUIVertScrollbar.prototype.createScrollComponents=function(){this.m_oDiv.className="scrollbarStyle";this.m_oStartArrow=new CUIScrollArrow(this.m_sStartArrowImagePath,this.m_sStartArrowPushedImagePath,this.m_iWidth,this.m_iArrowLength);this.m_oStartArrow.OnCreate(this.m_bVisible,this,true,true,true);this.m_oDiv.appendChild(this.m_oStartArrow.GetDomImage());this.CreateScrollBox();this.m_oEndArrow=new CUIScrollArrow(this.m_sEndArrowImagePath,this.m_sEndArrowPushedImagePath,this.m_iWidth,this.m_iArrowLength);this.m_oEndArrow.OnCreate(this.m_bVisible,this,false,true,true);this.m_oDiv.appendChild(this.m_oEndArrow.GetDomImage());this.updateVisualComponents();return true;};CUIVertScrollbar.prototype.CreateSplitter=function(){this.m_oSplitter=document.createElement("DIV");this.m_oSplitter.className="h_scroll_bar_splitter";return this.m_oSplitter;};CUIVertScrollbar.prototype.SetStartPosition=function(_UT){this.m_iStartPos=Math.min(_UT-2,this.GetMaxEndPosition());this.m_oScrollBox.m_iTop=Math.min(this.m_iStartPos+this.m_iArrowLength,this.GetMaxEndPosition());};CUIVertScrollbar.prototype.OnResize=function(){return this.Resize(this.m_oPane.GetHeight());};CUIVertScrollbar.prototype.OnNotifyUpArrowDown=function(_Fx){this.notify(_Fx);};CUIVertScrollbar.prototype.OnNotifyDownArrowDown=function(_Fx){this.notify(_Fx);};CUIVertScrollbar.prototype.OnNotifyUpTrackDown=function(_Fx){this.notify(_Fx);};CUIVertScrollbar.prototype.OnNotifyDownTrackDown=function(_Fx){this.notify(_Fx);};CUIVertScrollbar.prototype.OnNotifyVScrollBoxReleased=function(_Fx){this.notify(_Fx);};CUIVertScrollbar.prototype.notify=function(_Fx){if(this.m_oListener&&this.m_oListener.Notify){this.m_oListener.Notify(ExpEvent.kCUIScrollControl_VScroll);}else if(this.m_oListener&&this.m_oListener.OnVScrollTo){this.m_oListener.OnVScrollTo(_Fx);}else{this.UpdateScrollPosition(_Fx);}};CUIVertScrollbar.prototype.OnNotifyVMouseOver=function(){};CUIVertScrollbar.prototype.OnNotifyVScrollBoxDrag=function(_Fx){};CUIVertScrollbar.prototype.setArrowPos=function(_TP,_Rk){if(_TP){var _TM=Math.min(this.m_iStartPos,_Rk);this.m_oStartArrow.GetDomImage().style.top=_TM+"px";}else{this.m_oEndArrow.GetDomImage().style.top=_Rk+"px";}};CUIVertScrollbar.prototype.SetHeight=function(_Nf){this.m_iHeight=_Nf;this.m_iStartPos=Math.min(this.GetMaxEndPosition(),this.m_iStartPos);};function CUIScrollControl(_Mg){this.m_oVScrollbar=null;this.m_oHScrollbar=null;this.m_bVVisible=false;this.m_bHVisible=false;this.m_oApp=_Mg;};CUIScrollControl.kBothVH=1;CUIScrollControl.kVertOnly=2;CUIScrollControl.kHoriOnly=3;CUIScrollControl.kNone=4;CUIScrollControl.prototype.OnVCreate=function(_yZ){this.ApplyCallingContext(_yZ);if(this.m_oVPane){var _F4=this.m_oVPane.GetWidth();var _T6=this.m_oVPane.GetHeight();var _D3=_yZ.m_iVInitialTotalUnits;var _zF=_yZ.m_iVInitialVisibleUnits;var _Fx=_yZ.m_iVInitialFirstVisibleUnit;var _Sn=_yZ.m_iVStartPos;this.createScrollbar(_F4,_T6,_D3,_zF,_Fx,true,_Sn);if(this.m_oVScrollbar==null){return false;}this.m_oVPane.AddListener(this.m_oVScrollbar);}this.m_oApp.uiManager.Subscribe(this,ExpEvent.kCUIManager_Unload);return true;};CUIScrollControl.prototype.OnHCreate=function(_yZ){this.ApplyCallingContext(_yZ);if(this.m_oHPane){var _F4=this.m_oHPane.GetWidth();var _T6=this.m_oHPane.GetHeight();var _D3=_yZ.m_iHInitialTotalUnits;var _zF=_yZ.m_iHInitialVisibleUnits;var _Fx=_yZ.m_iHInitialFirstVisibleUnit;var _Nd=_yZ.m_iHStartPos;this.createScrollbar(_F4,_T6,_D3,_zF,_Fx,false,_Nd);if(this.m_oHScrollbar==null){return false;}this.m_oHPane.AddListener(this.m_oHScrollbar);}this.m_oApp.uiManager.Subscribe(this,ExpEvent.kCUIManager_Unload);return true;};CUIScrollControl.prototype.Notify=function(_Dy){if(_Dy==ExpEvent.kCUIManager_Unload){this.Unload();}};CUIScrollControl.prototype.Unload=function(_Cv){if(this.m_oHScrollbar){this.m_oHScrollbar.Unload();}if(this.m_oVScrollbar){this.m_oVScrollbar.Unload();}Utilities.RemoveAllChildObjects(this);};CUIScrollControl.prototype.VUnload=function(){if(this.m_oVScrollbar){this.m_oVScrollbar.Unload();this.m_oVScrollbar=null;}};CUIScrollControl.prototype.HUnload=function(){if(this.m_oHScrollbar){this.m_oHScrollbar.Unload();this.m_oHScrollbar=null;}};CUIScrollControl.IsScrollEvent=function(e){if(Dom.GetEventTarget(e).bIsScrollControlElement)return true;else{return false;}};CUIScrollControl.prototype.HasBothScrollbars=function(){if(this.m_oHScrollbar&&this.m_oVScrollbar){return true;}return false;};CUIScrollControl.prototype.GetScrollCtrlCType=function(){if(this.HasBothScrollbars()){return CUIScrollControl.kBothVH;}else if(this.m_oHScrollbar){return CUIScrollControl.kHoriOnly;}else if(this.m_oVScrollbar){return CUIScrollControl.kVertOnly;}else{return CUIScrollControl.kNone;}};CUIScrollControl.prototype.OnClose=function(){if(this.m_oVScrollbar!=null){this.m_oVScrollbar.OnClose();this.m_oVScrollbar=null;}if(this.m_oHScrollbar!=null){this.m_oHScrollbar.OnClose();this.m_oHScrollbar=null;}return true;};CUIScrollControl.prototype.ApplyCallingContext=function(_yZ){this.m_oVPane=_yZ.m_oVPane;this.m_oHPane=_yZ.m_oHPane;this.m_bVVisible=_yZ.m_bVVisible;this.m_bHVisible=_yZ.m_bHVisible;};CUIScrollControl.prototype.createScrollbar=function(_F4,_T6,_D3,_zF,_Fx,_Cv,_JN){if(_Cv){this.m_oVScrollbar=new CUIVertScrollbar();return this.m_oVScrollbar.OnCreate(_F4,_T6,_D3,_zF,_Fx,this,this.m_oVPane,this.m_bVVisible,_Cv,_JN);}else{this.m_oHScrollbar=new CUIHorizScrollbar();return this.m_oHScrollbar.OnCreate(_F4,_T6,_D3,_zF,_Fx,this,this.m_oHPane,this.m_bHVisible,_Cv,_JN);}};CUIScrollControl.prototype.ShowV=function(_DX){if(this.m_oVScrollbar==null)return false;return this.m_oVScrollbar.Show(_DX);};CUIScrollControl.prototype.ShowH=function(_DX){if(this.m_oHScrollbar==null)return false;return this.m_oHScrollbar.Show(_DX);};CUIScrollControl.prototype.UpdateVScrollPosition=function(_Fx){if(this.m_oVScrollbar==null)return false;return this.m_oVScrollbar.UpdateScrollPosition(_Fx);};CUIScrollControl.prototype.UpdateHScrollPosition=function(_Fx){if(this.m_oHScrollbar==null)return false;return this.m_oHScrollbar.UpdateScrollPosition(_Fx);};CUIScrollControl.prototype.ResizeVScrollbar=function(_T6){if(!this.m_oVPane)return false;var _F4=this.m_oVPane.GetWidth();return this.m_oVPane.OnResize(_F4,_T6);};CUIScrollControl.prototype.ResizeHScrollbar=function(_F4){if(!this.m_oHPane){return false;}var _T6=this.m_oHPane.GetHeight();return this.m_oHPane.OnResize(_F4,_T6);};CUIScrollControl.prototype.SetVUnits=function(_zF,_Fx,_D3){return this.m_oVScrollbar.SetUnits(_zF,_Fx,_D3);};CUIScrollControl.prototype.SetHUnits=function(_zF,_Fx,_D3){return this.m_oHScrollbar.SetUnits(_zF,_Fx,_D3);};CUIScrollControl.prototype.AddListener=function(_E5){if(this.m_oVScrollbar){this.m_oVScrollbar.AddListener(_E5);}if(this.m_oHScrollbar){this.m_oHScrollbar.AddListener(_E5);}};CUIScrollControl.prototype.Subscribe=function(_E5,event){if(event==ExpEvent.kCUIScrollControl_VScroll&&this.m_oVScrollbar){this.m_oVScrollbar.AddListener(_E5);}else if(event==ExpEvent.kCUIScrollControl_HScroll&&this.m_oHScrollbar){this.m_oHScrollbar.AddListener(_E5);}};function gScrollControlOpen(_MU){if(this.m_oDummyParent)this.m_oDummyParent.OnClose();this.m_oDummyParent=new CDummyParent();this.m_oDummyParent.OnCreate(_MU);return null;};function gScrollControlClose(_MJ){if(this.m_oDummyParent)this.m_oDummyParent.OnClose();};function CUIScrollControlCallingContext(){this.m_oVPane=null;this.m_oHPane=null;this.m_iVWidth=0;this.m_iHWidth=0;this.m_iVHeight=0;this.m_iHHeight=0;this.m_bVVisible=false;this.m_bHVisible=false;this.m_iVInitialTotalUnits=0;this.m_iVInitialVisibleUnits=0;this.m_iVInitialFirstVisibleUnit=0;this.m_iHInitialTotalUnits=0;this.m_iHInitialVisibleUnits=0;this.m_iHInitialFirstVisibleUnit=0;this.m_iVStartPos=0;this.m_iHStartPos=0;};CUIScrollControlCallingContext.prototype.SetVAttributes=function(_Ip,_Ih,_A0,_Ra,_Tv,_Sn){this.m_oVPane=_Ip;this.m_bVVisible=_Ih;this.m_iVInitialTotalUnits=_A0;this.m_iVInitialVisibleUnits=_Ra;this.m_iVInitialFirstVisibleUnit=_Tv;this.m_iVStartPos=_Sn;};CUIScrollControlCallingContext.prototype.SetHAttributes=function(_Qe,_Du,_JW,_M9,_GO,_Nd){this.m_oHPane=_Qe;this.m_bHVisible=_Du;this.m_iHInitialTotalUnits=_JW;this.m_iHInitialVisibleUnits=_M9;this.m_iHInitialFirstVisibleUnit=_GO;this.m_iHStartPos=_Nd;};function CDummyParent(){this.m_oScrollControl=null;};CDummyParent.prototype.OnCreate=function(_MU){this.m_iVTotalUnits=100;this.m_iVVisibleUnits=25;this.m_iVFirstVisibleUnit=0;this.m_iHTotalUnits=60;this.m_iHVisibleUnits=10;this.m_iHFirstVisibleUnit=0;window.dummyParent=this;var _aAM=_MU;var _aGG=document.createElement('DIV');var _0D=document.createElement('DIV');_aGG.style.position="absolute";_0D.style.position="absolute";_0D.style.overflow="hidden";var _2A=new CUIPane();var _Zb=new CUIPane();_2A.SetDom(_aGG);_Zb.SetDom(_0D);var _aEV=parseInt(COTStyle.GetStyle(_MU,"width"));var _8L=parseInt(COTStyle.GetStyle(_MU,'height'));_2A.OnResize(16,200,_aEV,0);_Zb.OnResize(200,16,0,_8L);var _yZ=new CUIScrollControlCallingContext();_yZ.SetVAttributes(_2A,true,this.m_iVTotalUnits,this.m_iVVisibleUnits,this.m_iVFirstVisibleUnit);_yZ.SetHAttributes(_Zb,true,this.m_iHTotalUnits,this.m_iHVisibleUnits,this.m_iHFirstVisibleUnit);this.m_oScrollControl=new CUIScrollControl();if(!this.m_oScrollControl.OnCreate(_yZ))throw new COTException("Could not create scroll control");this.m_oScrollControl.AddListener(this);};CDummyParent.prototype.OnClose=function(){this.m_oScrollControl.OnClose();};CDummyParent.prototype.OnVScrollTo=function(_Q2){this.m_iVFirstVisibleUnit=_Q2;this.m_oScrollControl.UpdateVScrollPosition(_Q2);};CDummyParent.prototype.OnHScrollTo=function(_Q2){this.m_iHFirstVisibleUnit=_Q2;this.m_oScrollControl.UpdateHScrollPosition(_Q2);};function CUIScrollArrow(_LK,_DW,_F4,_T6,_EC){this.m_sImagePath=_LK;this.m_sPushedImagePath=_DW;if(!_EC||_EC==''){_EC=this.m_sImagePath;}this.m_sDisabledImagePath=_EC;this.m_iWidth=_F4;this.m_iHeight=_T6;this.m_bVisible=false;this.kScrollTimerInterval=420;this.m_bButtonHeldDown=false;this.m_bImagePushed=false;this.m_iFirstDelay=300;this.m_iRepeatDelay=20;this.sPressedStyle=null;this.sHoverOverStyle=null;};CUIScrollArrow.prototype.OnCreate=function(_DX,_VW,_Ps,_Cv,_SX,_yx){this.m_oParent=_VW;this.m_bStartArrow=_Ps;this.m_bVertical=_Cv;this.m_oDomImage=document.createElement('IMG');this.UpdateImage();this.m_oDomImage.bIsScrollControlElement=true;COTStyle.SetWidth(this.m_oDomImage,this.m_iWidth);COTStyle.SetHeight(this.m_oDomImage,this.m_iHeight);if(_SX){this.m_oDomImage.style.position="absolute";this.m_oDomImage.style.top="0px";this.m_oDomImage.style.left="0px";if(!this.m_bVertical&&(!this.m_bStartArrow)){this.m_oDomImage.style.left=(_VW.m_iWidth-this.m_iWidth)+"px";}else if((!this.m_bVertical)&&this.m_bStartArrow){this.m_oDomImage.style.left=_VW.m_iStartPos+"px";}else if(this.m_bVertical&&(!this.m_bStartArrow)){this.m_oDomImage.style.top=(_VW.m_iHeight-this.m_iHeight)+"px";}else if(this.m_bVertical&&this.m_bStartArrow){this.m_oDomImage.style.top=_VW.m_iStartPos+"px";}}this.sDefaultStyle="scrollArrowStyle";if(_yx!=null){this.sDefaultStyle=_yx;}this.SetStyle();this.Show(_DX);var _akc=Utilities.GenerateId();this.m_oDomImage.id="scrollArrow"+_akc;Dom.SetWindowGlobalObject(this.m_oDomImage.id,this);this.m_oDomImage.scrollparent=this.m_oParent;this.m_oDomImage.onmousedown=CUIScrollArrow.SafeHandleMouseDown;this.m_oDomImage.onmouseup=CUIScrollArrow.SafeHandleMouseUp;this.m_oDomImage.onmouseout=CUIScrollArrow.SafeHandleMouseOut;this.m_oDomImage.onmouseover=CUIScrollArrow.SafeHandleMouseOver;return true;};CUIScrollArrow.prototype.Unload=function(){Dom.SetWindowGlobalObject(this.m_oDomImage.id,null);window.lastActiveScrollArrow=null;Dom.RemoveObject(this.m_oDomImage);this.m_oDomImage.scrollparent=null;Utilities.RemoveAllChildObjects(this);};CUIScrollArrow.prototype.SetHoverOverStyle=function(_Ec){this.sHoverOverStyle=_Ec;};CUIScrollArrow.prototype.SetPressedStyle=function(_S2){this.sPressedStyle=_S2;};CUIScrollArrow.prototype.SetDisabledStyle=function(_Fi){this.sDisabledStyle=_Fi;};CUIScrollArrow.prototype.SetStyle=function(){this.m_oDomImage.className=this.sDefaultStyle;if(this.bDisabled&&this.sDisabledStyle!=null){this.m_oDomImage.className+=" "+this.sDisabledStyle;}else if(this.bHover&&this.sHoverOverStyle!=null){this.m_oDomImage.className+=" "+this.sHoverOverStyle;}else if(this.m_bButtonHeldDown&&this.sPressedStyle!=null){this.m_oDomImage.className+=" "+this.sPressedStyle;}};CUIScrollArrow.prototype.IsMoreToScroll=function(){if(this.m_bStartArrow){if(this.m_oParent.GetFirstVisibleIndex()==0){return false;}else{return true;}}else{if(this.m_oParent.GetVisibleUnits()>=this.m_oParent.GetTotalUnits()){return false;}var _Zh=this.m_oParent.GetFirstVisibleIndex()+this.m_oParent.GetVisibleUnits();if(_Zh==this.m_oParent.GetTotalUnits()){return false;}else{return true;}}};CUIScrollArrow.prototype.Show=function(_DX){this.m_bVisible=_DX;if(this.m_bVisible){this.m_oDomImage.style.visibility="visible";}else{this.m_oDomImage.style.visibility="hidden";}return true;};CUIScrollArrow.prototype.GetDomImage=function(){return this.m_oDomImage;};CUIScrollArrow.SafeHandleMouseDown=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e)var e=window.event;if(!Dom.IsLeftButton(e)||!Dom.GetEventTarget(e)||Dom.GetEventTarget(e).id==""){return;}var _adc=Dom.GetWindowGlobalObject(Dom.GetEventTarget(e).id);if(_adc&&_adc instanceof CUIScrollArrow){window.lastActiveScrollArrow=_adc;_adc.HandleMouseDown(e);}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIScrollArrow.prototype.HandleMouseDown=function(e){if(!window.lastActiveScrollbar){Debug.Assert(this.m_oParent);}this.m_bButtonHeldDown=true;this.setImageDown();this.SetStyle();CUIManager.CallCurrentMouseDown(e);if(this.m_oDomImage.setCapture){this.m_oDomImage.setCapture();}else{window.captureEvents(Event.MouseUp);window.onmouseup=function(e){CUIScrollArrow.SafeHandleMouseUp(e);};}this.notifyParent();if(window.lastActiveScrollArrow){this.oScrollTimer=setInterval(CUIScrollArrow.SafeNotifyParent,this.kScrollTimerInterval);}if(e){Dom.CancelEvent(e);}};CUIScrollArrow.SafeHandleMouseUp=function(e){if(window.lastActiveScrollBox&&window.lastActiveScrollBox.m_bDrag){CUIScrollBox.SafeHandleMouseUp(e);return;}/*@if(!@bering_debug)@*/try{/*@end@*/if(!e)var e=window.event;if(window.lastActiveScrollArrow){window.lastActiveScrollArrow.HandleMouseUp(e);}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIScrollArrow.prototype.HandleMouseUp=function(e){if(this.oScrollTimer){clearInterval(this.oScrollTimer);}if(this.m_bImagePushed){this.setImageUp();}if(this.m_oDomImage.releaseCapture){this.m_oDomImage.releaseCapture();}else{window.releaseEvents(Event.MouseUp);window.onmouseup=null;}window.lastActiveScrollArrow=null;this.m_bButtonHeldDown=false;this.SetStyle();if(e){Dom.CancelBubble(e);}};CUIScrollArrow.SafeHandleMouseOut=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e)var e=window.event;if(Dom.GetEventTarget(e).id==""){return;}var _adc=Dom.GetWindowGlobalObject(Dom.GetEventTarget(e).id);if(_adc&&_adc instanceof CUIScrollArrow){_adc.HandleMouseOut(e);}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIScrollArrow.prototype.HandleMouseOut=function(e){if(this.m_bImagePushed){this.setImageUp();}this.bHover=false;this.SetStyle();if(e){Dom.CancelBubble(e);}};CUIScrollArrow.SafeHandleMouseOver=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e)var e=window.event;if(Dom.GetEventTarget(e).id==""){return;}var _adc=Dom.GetWindowGlobalObject(Dom.GetEventTarget(e).id);if(_adc&&_adc instanceof CUIScrollArrow){_adc.HandleMouseOver(e);}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIScrollArrow.prototype.HandleMouseOver=function(e){this.bHover=true;this.SetStyle();if(this.m_bButtonHeldDown){this.setImageDown();this.SafeRepeatScroll();}};CUIScrollArrow.prototype.setImageDown=function(){this.m_bImagePushed=true;};CUIScrollArrow.prototype.setImageUp=function(){this.m_bImagePushed=false;};CUIScrollArrow.prototype.UpdateImage=function(){if(this.IsMoreToScroll()){this.m_oDomImage.src=this.m_sImagePath;this.bDisabled=false;}else{this.m_oDomImage.src=this.m_sDisabledImagePath;this.bDisabled=true;}this.SetStyle();};CUIScrollArrow.SafeNotifyParent=function(){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e)var e=window.event;if(window.lastActiveScrollArrow){window.lastActiveScrollArrow.notifyParent();}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIScrollArrow.prototype.notifyParent=function(){this.UpdateImage();if(this.m_bStartArrow){this.m_oParent.OnStartArrowDown();}else{this.m_oParent.OnEndArrowDown();}};CUIScrollArrow.prototype.SafeRepeatScroll=function(){try{if(this.m_bImagePushed){this.notifyParent();if(window.lastActiveScrollArrow){var _6z=CUIScrollbar.RepeatPageScroll;setTimeout(_6z,this.m_iRepeatDelay);}}}catch(e){_f.HandleException(e);}};function CUIScrollBox(){this.m_bDrag=false;};CUIScrollBox.prototype.OnCreate=function(_VW,_DX,_QY){this.m_oParent=_VW;this.m_bVisible=_DX;this.m_bVertical=this.m_oParent.m_bVertical;this.m_oDom=document.createElement('SPAN');this.m_oDom._d8=this;this.m_oDom.style.position='absolute';this.m_oDom.className=Dom.GetStyleByBrowser("scrollBoxOuterStyle");this.m_oDom.bIsScrollControlElement=true;if(this.m_bVertical){this.m_oDom.style.top=_VW.m_iArrowLength+_VW.m_iStartPos+"px";this.m_iTop=_VW.m_iArrowLength+_VW.m_iStartPos;this.m_oDom.style.left="0px";this.m_iLeft=0;}else{this.m_oDom.style.top='0px';this.m_iTop=0;this.m_oDom.style.left=_VW.m_iArrowLength+_VW.m_iStartPos+"px";this.m_iLeft=_VW.m_iArrowLength+_VW.m_iStartPos;}var _aCp=Utilities.GenerateId();this.m_oDom.id="scrollbar"+_aCp;Dom.SetWindowGlobalObject(this.m_oDom.id,this);this.m_oDom.scrollparent=this.m_oParent;this.m_oDom.onmousedown=CUIScrollBox.SafeHandleMouseDown;this.m_oDom.onmouseup=CUIScrollBox.SafeHandleMouseUp;this.m_oDom.onmousemove=CUIScrollBox.SafeHandleMouseMove;_VW.m_oDiv.appendChild(this.m_oDom);if(this.m_bVertical){var _aio=COTStyle.GetHorizontalBordersWidth(this.m_oDom);COTStyle.SetWidth(this.m_oDom,_QY-_aio);}else{var _aDL=COTStyle.GetVerticalBordersHeight(this.m_oDom);COTStyle.SetHeight(this.m_oDom,_QY-_aDL);}};CUIScrollBox.prototype.Unload=function(){Dom.SetWindowGlobalObject(this.m_oDom.id);this.m_oDom.scrollparent=null;Dom.RemoveObject(this.m_oDom);window.lastActiveScrollBox=null;Utilities.RemoveAllChildObjects(this);};CUIScrollBox.SafeHandleMouseDown=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e)var e=window.event;if(!Dom.IsLeftButton(e)||!Dom.GetEventTarget(e)||Dom.GetEventTarget(e).id=="")return;var _as3=Dom.GetEventTarget(e)._d8;if(_as3){window.lastActiveScrollBox=_as3;_as3.HandleMouseDown(e);}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIScrollBox.prototype.HandleMouseDown=function(e){if(this.m_bDrag==true){this.m_oParent.CreateScrollBox();}if(this.m_bVertical){this.m_oParent.OnStartScrollBoxDrag(e.screenY);}else{this.m_oParent.OnStartScrollBoxDrag(e.screenX);}this.m_bDrag=true;CUIScrollbar.SafeDisableBodyTextSelection(this.m_oParent.m_oParentControl.m_oApp.uiManager._jf._st);CUIManager.CallCurrentMouseDown(e);if(this.m_oDom.setCapture){this.m_oDom.setCapture();}else{var _as3=window.lastActiveScrollBox;window.captureEvents(Event.MouseUp|Event.MouseMove);window.onmouseup=function(e){_as3.HandleMouseUp(e);window.releaseEvents(Event.MouseUp|Event.MouseMove);};window.onmousemove=function(e){_as3.HandleMouseMove(e);};}Dom.CancelBubble(e);};CUIScrollBox.SafeHandleMouseUp=function(e){if(window.lastActiveScrollArrow&&window.lastActiveScrollArrow.m_bButtonHeldDown){CUIScrollArrow.SafeHandleMouseUp(e);return;}/*@if(!@bering_debug)@*/try{/*@end@*/if(!e)var e=window.event;if(!Dom.IsLeftButton(e))return;var _as3=window.lastActiveScrollBox;if(!_as3){return;}_as3.HandleMouseUp(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIScrollBox.prototype.HandleMouseUp=function(e){if(this.m_oParent.m_oParentControl._xv&&this.m_oParent.m_oParentControl._xv.m_bDragging){return;}if(!this.m_oDom){var _as3=window.lastActiveScrollBox;if(!_as3){_as3.m_oParent.CreateScrollBox();_as3.m_oParent.OnScrollBoxRelease();this.m_bDrag=false;Dom.CancelBubble(e);}return;}if(this.m_oDom.releaseCapture){this.m_oDom.releaseCapture();}else{window.releaseEvents(Event.MouseUp);window.onmouseup=null;window.releaseEvents(Event.MouseMove);window.onmousemove=null;this.m_oParent.CreateScrollBox();}window.lastActiveScrollBox=null;this.m_oParent.OnScrollBoxRelease();this.m_bDrag=false;Dom.CancelBubble(e);};CUIScrollBox.SafeHandleMouseMove=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e)var e=window.event;var _as3=window.lastActiveScrollBox;if(!_as3){return;}_as3.HandleMouseMove(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CUIScrollBox.prototype.HandleMouseMove=function(e){if(this.m_oParent.m_oParentControl._xv&&this.m_oParent.m_oParentControl._xv.m_bDragging){return;}if(this.m_bDrag){if(this.m_bVertical){this.m_oParent.OnScrollBoxDrag(e.screenY);}else{this.m_oParent.OnScrollBoxDrag(e.screenX);}}Dom.CancelBubble(e);};CUIScrollBox.prototype.SetScrollPos=function(_Pm,_Pa){if(this.m_bVertical){var _arf=Math.min(this.m_iTop+_Pm,_Pa);this.m_oDom.style.top=_arf+"px";}else{var _ao5=Math.min(this.m_iLeft+_Pm,_Pa);this.m_oDom.style.left=_ao5+"px";}};CUIScrollBox.prototype.SetLength=function(_On){if(!_On&&_On!=0){return;}if(this.m_bVertical){COTStyle.SetHeight(this.m_oDom,_On);}else{COTStyle.SetWidth(this.m_oDom,_On);}};CUIScrollBox.prototype.Show=function(_DX){this.m_bVisible=_DX;if(this.m_bVisible){this.m_oDom.style.visibility="visible";}else{this.m_oDom.style.visibility="hidden";}return true;};CUIScrollBox.prototype.GetDom=function(){return this.m_oDom;};function COTStyle(){COTStyle._w3=false;};COTStyle.SetBackCompat=function(_Hs){COTStyle._w3=_Hs;};COTStyle.GetStyle=function(el,_zS){var s="";if(document.defaultView){_zS=COTStyle.ConvertToCSSFormat(_zS);s=document.defaultView.getComputedStyle(el,"").getPropertyValue(_zS);}else if(el.currentStyle){s=el.currentStyle[_zS];}return s;};COTStyle.IsVisible=function(el){if(COTStyle.GetStyle(el,'visibility')=='visible'){return true;}else if(COTStyle.GetStyle(el,'visibility')=='hidden'){return false;}else if(!el.parentNode){return true;}else{return COTStyle.IsVisible(el.parentNode);}};COTStyle.GetNonComputedStyle=function(el,_zS){return el.style[_zS];};COTStyle.GetPosition=function(el,_BL){var _acq=COTStyle.GetStyle(el,_BL);var _Us=0;if(_acq!=''&&_acq!='auto'){_Us=parseInt(_acq);}return _Us;};COTStyle.ConvertToCSSFormat=function(_BL){var s=_BL;var c="";var _aHw="";for(var i=0;i<s.length;i++){if(s.IsCharAtUpperCase(i)){_aHw=s;s=s.substring(0,i);s+='-';c=_aHw.charAt(i).toLowerCase();s+=c;if(i+1<_aHw.length){s+=_aHw.substring(i+1,_aHw.length);}}}return s;};COTStyle.GetWidth=function(_RS){var _arM,_F4;_arM=new Number(parseInt(COTStyle.GetStyle(_RS,"width")));if(_arM.toString()=="NaN"){_F4=COTStyle.GetWidthFromOffset(_RS);COTStyle.SetWidth(_RS,_F4);}else{_F4=_arM.valueOf();if(COTStyle._w3){_F4-=COTStyle.GetHorizontalPaddingWidth(_RS);_F4-=COTStyle.GetHorizontalBordersWidth(_RS);}}return _F4;};COTStyle.GetHeight=function(_RS){var _0Q,_T6;_0Q=new Number(parseInt(COTStyle.GetStyle(_RS,"height")));if(_0Q.toString()=="NaN"){_T6=COTStyle.GetHeightFromOffset(_RS);COTStyle.SetHeight(_RS,_T6);}else{_T6=_0Q.valueOf();if(COTStyle._w3){_T6-=COTStyle.GetVerticalPaddingHeight(_RS);_T6-=COTStyle.GetVerticalBordersHeight(_RS);}}return _T6;};COTStyle.GetDisplayWidth=function(_RS){var _F4=COTStyle.GetWidth(_RS);_F4+=COTStyle.GetHorizontalPaddingWidth(_RS);_F4+=COTStyle.GetHorizontalBordersWidth(_RS);_F4+=COTStyle.GetHorizontalMarginsWidth(_RS);return _F4;};COTStyle.GetDisplayOffsetWidth=function(_RS){var _F4=_RS.offsetWidth;if(_o.is_ie5_5up&&_F4==0){var _akp=new String(_RS.currentStyle.width);if(_akp.indexOf('%')!=-1){_F4=_RS.offsetParent.offsetWidth*parseInt(_akp)*0.01;}}_F4+=COTStyle.GetHorizontalMarginsWidth(_RS);return _F4;};COTStyle.GetDisplayHeight=function(_RS){var _T6=COTStyle.GetHeight(_RS);_T6+=COTStyle.GetVerticalPaddingHeight(_RS);_T6+=COTStyle.GetVerticalBordersHeight(_RS);_T6+=COTStyle.GetVerticalMarginsHeight(_RS);return _T6;};COTStyle.GetDisplayOffsetHeight=function(_RS){var _T6=_RS.offsetHeight;if(_o.is_ie5_5up&&_T6==0){var _amQ=new String(_RS.currentStyle.height);if(_amQ.indexOf('%')!=-1){_T6=_RS.offsetParent.offsetHeight*parseInt(_amQ)*0.01;}}_T6+=COTStyle.GetVerticalMarginsHeight(_RS);return _T6;};COTStyle.SetWidth=function(_RS,_Aj,_Rn){if(!_Rn){var _Rn='px';}if(COTStyle._w3){if(_Rn=='%'&&_RS.parentElement&&(_RS.offsetParent!=null&&_RS.offsetParent.offsetWidth!=0)){_Aj+=COTStyle.GetHorizontalPaddingWidth(_RS)/_RS.offsetParent.offsetWidth*100;_Aj+=COTStyle.GetHorizontalBordersWidth(_RS)/_RS.offsetParent.offsetWidth*100;}else if(_Rn!='%'){_Aj+=COTStyle.GetHorizontalPaddingWidth(_RS);_Aj+=COTStyle.GetHorizontalBordersWidth(_RS);}}_Aj=Math.max(_Aj,0);var _F4=Math.ceil(_Aj);_RS.style.width=_F4+_Rn;};COTStyle.SetHeight=function(_RS,_Ug,_Rn){if(!_Rn){var _Rn="px";}if(COTStyle._w3){if(_Rn=='%'&&_RS.parentElement&&(_RS.offsetParent!=null&&_RS.offsetParent.offsetHeight!=0)){_Ug+=COTStyle.GetVerticalPaddingHeight(_RS)/_RS.offsetParent.offsetHeight*100;_Ug+=COTStyle.GetVerticalBordersHeight(_RS)/_RS.offsetParent.offsetHeight*100;}else if(_Rn!='%'){_Ug+=COTStyle.GetVerticalPaddingHeight(_RS);_Ug+=COTStyle.GetVerticalBordersHeight(_RS);}}_Ug=Math.max(_Ug,0);var _T6=Math.ceil(_Ug);_RS.style.height=_T6+_Rn;};COTStyle.SetSize=function(_RS,_F4,_T6){COTStyle.SetWidth(_RS,_F4);COTStyle.SetHeight(_RS,_T6);};COTStyle.SetTDOverflow=function(_RS,_KL){_RS.style.overflow=_KL;};COTStyle.GetHorizontalExtrasWidth=function(_RS){var _F4=COTStyle.GetHorizontalBordersWidth(_RS);_F4+=COTStyle.GetHorizontalPaddingWidth(_RS);_F4+=COTStyle.GetHorizontalMarginsWidth(_RS);return _F4;};COTStyle.GetVerticalExtrasHeight=function(_RS){var _T6=COTStyle.GetVerticalBordersHeight(_RS);_T6+=COTStyle.GetVerticalPaddingHeight(_RS);_T6+=COTStyle.GetVerticalMarginsHeight(_RS);return _T6;};COTStyle.GetHorizontalBordersWidth=function(_RS){var _aqT=COTStyle.GetBorderLeft(_RS);var _9b=COTStyle.GetBorderRight(_RS);return _aqT+_9b;};COTStyle.GetVerticalBordersHeight=function(_RS){var _awj=COTStyle.GetBorderTop(_RS);var _anw=COTStyle.GetBorderBottom(_RS);return _awj+_anw;};COTStyle.GetHorizontalPaddingWidth=function(_RS){var _asR,_92;var _aoz,_ajF;_asR=new Number(parseInt(COTStyle.GetStyle(_RS,"paddingLeft")));_92=new Number(parseInt(COTStyle.GetStyle(_RS,"paddingRight")));if(_asR.toString()=="NaN"){_aoz=0;}else{_aoz=_asR.valueOf();}if(_92.toString()=="NaN"){_ajF=0;}else{_ajF=_92.valueOf();}return _aoz+_ajF;};COTStyle.GetVerticalPaddingHeight=function(_RS){var _agC,_aDW;var _3D,_aoG;_agC=new Number(parseInt(COTStyle.GetStyle(_RS,"paddingTop")));_aDW=new Number(parseInt(COTStyle.GetStyle(_RS,"paddingBottom")));if(_agC.toString()=="NaN"){_3D=0;}else{_3D=_agC.valueOf();}if(_aDW.toString()=="NaN"){_aoG=0;}else{_aoG=_aDW.valueOf();}return _3D+_aoG;};COTStyle.AlertDimensions=function(_Gs){var _aef="ID: "+_Gs.id;_aef+="\r\n";_aef+="offsetWidth: "+_Gs.offsetWidth;_aef+="\r\n";_aef+="clientWidth: "+_Gs.clientWidth;_aef+="\r\n";_aef+="currentStyle.width: "+COTStyle.GetStyle(_Gs,"width");_aef+="\r\n";_aef+="currentStyle.pixelWidth: "+COTStyle.GetStyle(_Gs,"pixelWidth");_aef+="\r\n";_aef+="currentStyle.borderLeftWidth: "+COTStyle.GetStyle(_Gs,"borderLeftWidth");_aef+="\r\n";_aef+="currentStyle.borderRightWidth: "+COTStyle.GetStyle(_Gs,"borderRightWidth");_aef+="\r\n";_aef+="currentStyle.paddingLeft: "+COTStyle.GetStyle(_Gs,"paddingLeft");_aef+="\r\n";_aef+="currentStyle.paddingRight: "+COTStyle.GetStyle(_Gs,"paddingRight");_aef+="\r\n";_aef+="currentStyle.marginLeft: "+COTStyle.GetStyle(_Gs,"marginLeft");_aef+="\r\n";_aef+="currentStyle.marginRight "+COTStyle.GetStyle(_Gs,"marginRight");_aef+="\r\n";_aef+="offsetHeight: "+_Gs.offsetHeight;_aef+="\r\n";_aef+="clientHeight: "+_Gs.clientHeight;_aef+="\r\n";_aef+="currentStyle.height: "+COTStyle.GetStyle(_Gs,"height");_aef+="\r\n";_aef+="currentStyle.borderTopWidth: "+COTStyle.GetStyle(_Gs,"borderTopWidth");_aef+="\r\n";_aef+="currentStyle.borderBottomWidth: "+COTStyle.GetStyle(_Gs,"borderBottomWidth");_aef+="\r\n";_aef+="currentStyle.paddingTop: "+COTStyle.GetStyle(_Gs,"paddingTop");_aef+="\r\n";_aef+="currentStyle.paddingBottom: "+COTStyle.GetStyle(_Gs,"paddingBottom");_aef+="\r\n";_aef+="currentStyle.marginTop: "+COTStyle.GetStyle(_Gs,"marginTop");_aef+="\r\n";_aef+="currentStyle.marginBottom "+COTStyle.GetStyle(_Gs,"marginBottom");_aef+="\r\n";alert(_aef);};COTStyle.GetWidthFromOffset=function(_RS){var _F4=_RS.offsetWidth;if(_o.is_ie5_5up&&_F4==0){var _akp=new String(_RS.currentStyle.width);if(_akp.indexOf('%')!=-1){_F4=_RS.offsetParent.offsetWidth*parseInt(_akp)*0.01;}}_F4-=COTStyle.GetHorizontalPaddingWidth(_RS);_F4-=COTStyle.GetHorizontalBordersWidth(_RS);return _F4;};COTStyle.GetHeightFromOffset=function(_RS){var _T6=_RS.offsetHeight;if(_o.is_ie5_5up&&_T6==0){var _amQ=new String(_RS.currentStyle.height);if(_amQ.indexOf('%')!=-1){_T6=_RS.offsetParent.offsetHeight*parseInt(_amQ)*0.01;}}_T6-=COTStyle.GetVerticalPaddingHeight(_RS);_T6-=COTStyle.GetVerticalBordersHeight(_RS);return _T6;};COTStyle.SetPadding=function(_RS,_TM,_Uz,_P6,_Kl){COTStyle.SetPaddingTop(_RS,_TM);COTStyle.SetPaddingBottom(_RS,_Uz);COTStyle.SetPaddingLeft(_RS,_P6);COTStyle.SetPaddingRight(_RS,_Kl);};COTStyle.SetPaddingLeft=function(_RS,_LV){if(COTStyle._w3&&_RS.parentElement!=null){var _aif=COTStyle.GetWidth(_RS);_RS.style.paddingLeft=_LV+"px";COTStyle.SetWidth(_RS,_aif);return;}_RS.style.paddingLeft=_LV+"px";};COTStyle.SetPaddingRight=function(_RS,_LV){if(COTStyle._w3&&_RS.parentElement!=null){var _aif=COTStyle.GetWidth(_RS);_RS.style.paddingRight=_LV+"px";COTStyle.SetWidth(_RS,_aif);return;}_RS.style.paddingRight=_LV+"px";};COTStyle.SetPaddingBottom=function(_RS,_LV){if(COTStyle._w3&&_RS.parentElement!=null){var _awa=COTStyle.GetHeight(_RS);_RS.style.paddingBottom=_LV+"px";COTStyle.SetHeight(_RS,_awa);return;}_RS.style.paddingBottom=_LV+"px";};COTStyle.SetPaddingTop=function(_RS,_LV){if(COTStyle._w3&&_RS.parentElement!=null){var _awa=COTStyle.GetHeight(_RS);_RS.style.paddingTop=_LV+"px";COTStyle.SetHeight(_RS,_awa);return;}_RS.style.paddingTop=_LV+"px";};COTStyle.AdjustSize=function(_RS){COTStyle.AdjustHeight(_RS);COTStyle.AdjustWidth(_RS);};COTStyle.AdjustHeight=function(_RS){var _T6=COTStyle.GetHeight(_RS);if(_T6!=_aiC){var _aiC=COTStyle.GetHeightFromOffset(_RS);COTStyle.SetHeight(_RS,_aiC);}};COTStyle.AdjustWidth=function(_RS){var _F4=COTStyle.GetWidth(_RS);if(_F4!=_ahW){var _ahW=COTStyle.GetWidthFromOffset(_RS);COTStyle.SetWidth(_RS,_ahW);}};COTStyle.GetHorizontalMarginsWidth=function(_RS){var _aj6,_aBf;var _aaE,_arV;_aj6=new Number(parseInt(COTStyle.GetStyle(_RS,"marginLeft")));_aBf=new Number(parseInt(COTStyle.GetStyle(_RS,"marginRight")));if(_aj6.toString()=="NaN"){_aaE=0;}else{_aaE=_aj6.valueOf();}if(_aBf.toString()=="NaN"){_arV=0;}else{_arV=_aBf.valueOf();}return _aaE+_arV;};COTStyle.GetVerticalMarginsHeight=function(_RS){var _Yq,_agj;var _alY,_ZE;_Yq=new Number(parseInt(COTStyle.GetStyle(_RS,"marginTop")));_agj=new Number(parseInt(COTStyle.GetStyle(_RS,"marginBottom")));if(_Yq.toString()=="NaN"){_alY=0;}else{_alY=_Yq.valueOf();}if(_agj.toString()=="NaN"){_ZE=0;}else{_ZE=_agj.valueOf();}return _alY+_ZE;};COTStyle.SetMargins=function(_RS,_TM,_Uz,_P6,_Kl){COTStyle.SetMarginTop(_RS,_TM);COTStyle.SetMarginBottom(_RS,_Uz);COTStyle.SetMarginLeft(_RS,_P6);COTStyle.SetMarginRight(_RS,_Kl);};COTStyle.SetMarginLeft=function(_RS,_EL){_RS.style.marginLeft=_EL+"px";};COTStyle.SetMarginRight=function(_RS,_EL){_RS.style.marginRight=_EL+"px";};COTStyle.SetMarginTop=function(_RS,_EL){_RS.style.marginTop=_EL+"px";};COTStyle.SetMarginBottom=function(_RS,_EL){_RS.style.marginBottom=_EL+"px";};COTStyle.SetBorders=function(_RS,_TM,_Uz,_P6,_Kl){COTStyle.SetBorderTop(_RS,_TM);COTStyle.SetBorderBottom(_RS,_Uz);COTStyle.SetBorderLeft(_RS,_P6);COTStyle.SetBorderRight(_RS,_Kl);};COTStyle.SetBorderLeft=function(_RS,_EL){_RS.style.borderLeftWidth=_EL+"px";};COTStyle.SetBorderRight=function(_RS,_EL){_RS.style.borderRightWidth=_EL+"px";};COTStyle.SetBorderTop=function(_RS,_EL){_RS.style.borderTopWidth=_EL+"px";};COTStyle.SetBorderBottom=function(_RS,_EL){_RS.style.borderBottomWidth=_EL+"px";};COTStyle.SetEnabled=function(_RS){if(_RS.tagName=="INPUT"){_RS.disabled=false;}else{_RS.style.disabled=false;}};COTStyle.SetDisabled=function(_RS){if(_RS.tagName=="INPUT"){_RS.disabled=true;}else{_RS.style.disabled=true;}};COTStyle.GetMarginTop=function(_RS){var _Yq;var _alY;_Yq=new Number(parseInt(COTStyle.GetStyle(_RS,"marginTop")));if(_Yq.toString()=="NaN"){_alY=0;}else{_alY=_Yq.valueOf();}return _alY;};COTStyle.GetMarginBottom=function(_RS){var _agj;var _ZE;_agj=new Number(parseInt(COTStyle.GetStyle(_RS,"marginBottom")));if(_agj.toString()=="NaN"){_ZE=0;}else{_ZE=_agj.valueOf();}return _ZE;};COTStyle.GetPaddingLeft=function(_RS){var _agY;var _LV;_agY=new Number(parseInt(COTStyle.GetStyle(_RS,"paddingLeft")));if(_agY.toString()=="NaN"){_LV=0;_agY=new Number(parseInt(COTStyle.GetLeftValue(COTStyle.GetStyle(_RS,"padding"))));if(_agY.toString()!="NaN"){_LV=_agY.valueOf();}}else{_LV=_agY.valueOf();}return _LV;};COTStyle.GetPaddingRight=function(_RS){var _agY;var _LV;_agY=new Number(parseInt(COTStyle.GetStyle(_RS,"paddingRight")));if(_agY.toString()=="NaN"){_LV=0;_agY=new Number(parseInt(COTStyle.GetRightValue(COTStyle.GetStyle(_RS,"padding"))));if(_agY.toString()!="NaN"){_LV=_agY.valueOf();}}else{_LV=_agY.valueOf();}return _LV;};COTStyle.GetPaddingTop=function(_RS){var _agY;var _LV;_agY=new Number(parseInt(COTStyle.GetStyle(_RS,"paddingTop")));if(_agY.toString()=="NaN"){_LV=0;_agY=new Number(parseInt(COTStyle.GetTopValue(COTStyle.GetStyle(_RS,"padding"))));if(_agY.toString()!="NaN"){_LV=_agY.valueOf();}}else{_LV=_agY.valueOf();}return _LV;};COTStyle.GetPaddingBottom=function(_RS){var _agY;var _LV;_agY=new Number(parseInt(COTStyle.GetStyle(_RS,"paddingBottom")));if(_agY.toString()=="NaN"){_LV=0;_agY=new Number(parseInt(COTStyle.GetBottomValue(COTStyle.GetStyle(_RS,"padding"))));if(_agY.toString()!="NaN"){_LV=_agY.valueOf();}}else{_LV=_agY.valueOf();}return _LV;};COTStyle.GetTopValue=function(_Rm){var _6V=_Rm.indexOf(" ");if(_6V==-1){return _Rm;}else{return _Rm.substring(0,_6V);}};COTStyle.GetBottomValue=function(_Rm){var _6V=_Rm.indexOf(" ");if(_6V==-1){return _Rm;}else{var _aoN=_Rm.indexOf(" ",_6V+1);if(_aoN==-1){return _Rm.substring(0,_6V);}else{var _6U=_Rm.indexOf(" ",_aoN+1);if(_6U==-1){return _Rm.substring(_aoN+1,_Rm.length);}else{return _Rm.substring(_6U+1,_Rm.length);}}}};COTStyle.GetLeftValue=function(_Rm){var _6V=_Rm.indexOf(" ");if(_6V==-1){return _Rm;}else{var _aoN=_Rm.indexOf(" ",_6V+1);if(_aoN==-1){return _Rm.substring(0,_6V);}else{return _Rm.substring(_6V+1,_aoN);}}};COTStyle.GetRightValue=function(_Rm){var _6V=_Rm.indexOf(" ");if(_6V==-1){return _Rm;}else{var _aoN=_Rm.indexOf(" ",_6V+1);if(_aoN==-1){return _Rm.substring(0,_6V);}else{var _6U=_Rm.indexOf(" ",_aoN+1);if(_6U==-1){return _Rm.substring(_6V+1,_aoN);}else{return _Rm.substring(_aoN,_6U);}}}};COTStyle.GetBorderLeft=function(_RS){var _atl;var _af9;_atl=new Number(parseInt(COTStyle.GetStyle(_RS,"borderLeftWidth")));if(_atl.toString()=="NaN"){_af9=0;var _aBq=COTStyle.GetLeftValue(COTStyle.GetStyle(_RS,"borderWidth"));_atl=new Number(parseInt(_aBq));if(_atl.toString()!="NaN"){_af9=_atl.valueOf();}else{var _axe=COTStyle.GetStyle(_RS,"borderLeftStyle");if(_aBq=="medium"&&_axe!="none"){_af9=4;}}}else{_af9=_atl.valueOf();}return _af9;};COTStyle.GetBorderRight=function(_RS){var _atl;var _af9;_atl=new Number(parseInt(COTStyle.GetStyle(_RS,"borderRightWidth")));if(_atl.toString()=="NaN"){_af9=0;var _aBq=COTStyle.GetRightValue(COTStyle.GetStyle(_RS,"borderWidth"));_atl=new Number(parseInt(_aBq));if(_atl.toString()!="NaN"){_af9=_atl.valueOf();}else{var _axe=COTStyle.GetStyle(_RS,"borderRightStyle");if(_aBq=="medium"&&_axe!="none"){_af9=4;}}}else{_af9=_atl.valueOf();}return _af9;};COTStyle.GetBorderTop=function(_RS){var _atl;var _af9;_atl=new Number(parseInt(COTStyle.GetStyle(_RS,"borderTopWidth")));if(_atl.toString()=="NaN"){_af9=0;var _aBq=COTStyle.GetTopValue(COTStyle.GetStyle(_RS,"borderWidth"));_atl=new Number(parseInt(_aBq));if(_atl.toString()!="NaN"){_af9=_atl.valueOf();}else{var _axe=COTStyle.GetStyle(_RS,"borderTopStyle");if(_aBq=="medium"&&_axe!="none"){_af9=4;}}}else{_af9=_atl.valueOf();}return _af9;};COTStyle.GetBorderBottom=function(_RS){var _atl;var _af9;_atl=new Number(parseInt(COTStyle.GetStyle(_RS,"borderBottomWidth")));if(_atl.toString()=="NaN"){_af9=0;var _aBq=COTStyle.GetBottomValue(COTStyle.GetStyle(_RS,"borderWidth"));_atl=new Number(parseInt(_aBq));if(_atl.toString()!="NaN"){_af9=_atl.valueOf();}else{var _axe=COTStyle.GetStyle(_RS,"borderBottomStyle");if(_aBq=="medium"&&_axe!="none"){_af9=4;}}}else{_af9=_atl.valueOf();}return _af9;};COTStyle.AddCSSClassToEle=function(_yW,_SN){if(_yW.className.indexOf(_SN)==-1){_yW.className=_yW.className+" "+_SN;}};function CUIArrowOnlyScrollControl(_Mg){this.base=CUIScrollControl;this.base(_Mg);this._b4=new Array();this._b4[ExpEvent.kCUIArrowOnlyScrollControl_Scroll]=new Array();this.oStartDirArrow=null;this.oEndDirArrow=null;this.oJumpStartArrow=null;this.oJumpEndArrow=null;};CUIArrowOnlyScrollControl.prototype=new CUIScrollControl;CUIArrowOnlyScrollControl.superclass=CUIScrollControl.prototype;CUIArrowOnlyScrollControl.prototype.OnCreate=function(_C1,_Cv,_DX){this.bVertical=_Cv;this.applyCallingContext(_C1);this.setImgPaths();if(this.elStartDirArrow){this.oStartDirArrow=new CUIScrollArrow(this.sStartArrowImg,this.sStartArrowPushedImg,this.iArrowWidth,this.iArrowHeight,this.sStartArrowDisabledImg);this.oStartDirArrow.OnCreate(true,this,true,_Cv,false,'scroll_arrow_button');this.elStartDirArrow.appendChild(this.oStartDirArrow.GetDomImage());var _9F=COTStyle.GetVerticalExtrasHeight(this.oStartDirArrow.m_oDomImage);COTStyle.SetHeight(this.oStartDirArrow.m_oDomImage,this.iArrowHeight-_9F);_9F=COTStyle.GetHorizontalExtrasWidth(this.oStartDirArrow.m_oDomImage);COTStyle.SetWidth(this.oStartDirArrow.m_oDomImage,this.iArrowWidth-_9F);this.oStartDirArrow.SetHoverOverStyle('button_hover');this.oStartDirArrow.SetPressedStyle('button_pressed');this.oStartDirArrow.SetDisabledStyle('button_disabled');}if(this.elEndDirArrow){this.oEndDirArrow=new CUIScrollArrow(this.sEndArrowImg,this.sEndArrowPushedImg,this.iArrowWidth,this.iArrowHeight,this.sEndArrowDisabledImg);this.oEndDirArrow.OnCreate(true,this,false,_Cv,false,'scroll_arrow_button');this.elEndDirArrow.appendChild(this.oEndDirArrow.GetDomImage());var _9F=COTStyle.GetVerticalExtrasHeight(this.oEndDirArrow.m_oDomImage);COTStyle.SetHeight(this.oEndDirArrow.m_oDomImage,this.iArrowHeight-_9F);_9F=COTStyle.GetHorizontalExtrasWidth(this.oEndDirArrow.m_oDomImage);COTStyle.SetWidth(this.oEndDirArrow.m_oDomImage,this.iArrowWidth-_9F);this.oEndDirArrow.SetHoverOverStyle('button_hover');this.oEndDirArrow.SetPressedStyle('button_pressed');this.oEndDirArrow.SetDisabledStyle('button_disabled');}if(this.elJumpStartArrow){this.oJumpStartArrow=new CUIJumpArrow(this.sJumpStartArrowImg,this.sJumpStartArrowImg,this.iArrowWidth,this.iArrowHeight,this.sJumpStartArrowDisabledImg);this.oJumpStartArrow.OnCreate(true,this,true,_Cv);this.elJumpStartArrow.appendChild(this.oJumpStartArrow.GetDomImage());}if(this.elJumpEndArrow){this.oJumpEndArrow=new CUIJumpArrow(this.sJumpEndArrowImg,this.sJumpEndArrowImg,this.iArrowWidth,this.iArrowHeight,this.sJumpEndArrowDisabledImg);this.oJumpEndArrow.OnCreate(true,this,false,_Cv);this.elJumpEndArrow.appendChild(this.oJumpEndArrow.GetDomImage());}this.m_oApp.uiManager.Subscribe(this,ExpEvent.kCUIManager_Unload);};CUIArrowOnlyScrollControl.prototype.ShowIfNeeded=function(){var _DX=false;if(this.oStartDirArrow&&this.oStartDirArrow.m_oDomImage&&this.oEndDirArrow&&this.oEndDirArrow.m_oDomImage){var _afl=(this._qQ>0);var _aAR=(this._qQ+this._tu<this._fI);_DX=_afl||_aAR;if(_DX){this.oStartDirArrow.m_oDomImage.style.visibility="visible";this.oEndDirArrow.m_oDomImage.style.visibility="visible";}else{this.oStartDirArrow.m_oDomImage.style.visibility="hidden";this.oStartDirArrow.m_bButtonHeldDown=false;this.oStartDirArrow.m_bImagePushed=false;this.oEndDirArrow.m_oDomImage.style.visibility="hidden";this.oEndDirArrow.m_bButtonHeldDown=false;this.oEndDirArrow.m_bImagePushed=false;}}return _DX;};CUIArrowOnlyScrollControl.prototype.GetArrowWidth=function(){return this.iArrowWidth;};CUIArrowOnlyScrollControl.prototype.Subscribe=function(obj,_Dy){if(_Dy==ExpEvent.kCUIArrowOnlyScrollControl_Scroll){this._b4[_Dy].push(obj);}};CUIArrowOnlyScrollControl.prototype.Notify=function(_Dy){if(this._b4[_Dy]){for(var i=0;i<this._b4[_Dy].length;i++){this._b4[_Dy][i].Notify(_Dy);}}if(_Dy==ExpEvent.kCUIManager_Unload){this.Unload();}};CUIArrowOnlyScrollControl.prototype.Unload=function(){if(this.oJumpEndArrow){this.oJumpEndArrow.Unload();this.oJumpEndArrow=null;}if(this.oJumpStartArrow){this.oJumpStartArrow.Unload();this.oJumpStartArrow=null;}if(this.oEndDirArrow){this.oEndDirArrow.Unload();this.oEndDirArrow=null;}if(this.oStartDirArrow){this.oStartDirArrow.Unload();this.oStartDirArrow=null;}Utilities.RemoveAllChildObjects(this);};CUIArrowOnlyScrollControl.prototype.applyCallingContext=function(_yZ){this._qQ=_yZ.iFirstVisibleUnit;this._fI=_yZ.iTotalUnits;this._tu=_yZ.iVisibleUnits;this.elJumpStartArrow=_yZ.elJumpStartArrow;this.elStartDirArrow=_yZ.elStartDirArrow;this.elEndDirArrow=_yZ.elEndDirArrow;this.elJumpEndArrow=_yZ.elJumpEndArrow;this.iArrowWidth=_yZ.iArrowWidth;this.iArrowHeight=_yZ.iArrowHeight;};CUIArrowOnlyScrollControl.prototype.setImgPaths=function(){var _LK=Utilities.IMG_PATH;this.sStartArrowImg=_LK;this.sStartArrowPushedImg=_LK;this.sStartArrowDisabledImg=_LK;this.sEndArrowImg=_LK;this.sEndArrowPushedImg=_LK;this.sEndArrowDisabledImg=_LK;this.sJumpEndArrowImg=_LK;this.sJumpEndArrowPushedImg=_LK;this.sJumpEndArrowDisabledImg=_LK;this.sJumpStartArrowImg=_LK;this.sJumpStartArrowPushedImg=_LK;this.sJumpStartArrowDisabledImg=_LK;if(this.bVertical){this.sStartArrowImg+='upone.gif';this.sStartArrowPushedImg+='upone.gif';this.sStartArrowDisabledImg+='upone_d.gif';this.sEndArrowImg+='downone.gif';this.sEndArrowPushedImg+='downone.gif';this.sEndArrowDisabledImg+='downone_d.gif';this.sJumpStartArrowImg+='upall.gif';this.sJumpStartArrowPushedImg+='upall.gif';this.sJumpStartArrowDisabledImg+='upall_d.gif';this.sJumpEndArrowImg+='downall.gif';this.sJumpEndArrowImg+='downnall.gif';this.sJumpEndArrowDisabledImg+='downall_d.gif';}else{this.sStartArrowImg+='context_scroll_left.gif';this.sStartArrowPushedImg+='context_scroll_left.gif';this.sStartArrowDisabledImg+='context_scroll_left_dis.gif';this.sEndArrowImg+='context_scroll_right.gif';this.sEndArrowPushedImg+='context_scroll_right.gif';this.sEndArrowDisabledImg+='context_scroll_right_dis.gif';this.sJumpStartArrowImg+='farleft.gif';this.sJumpStartArrowPushedImg+='farleft.gif';this.sJumpStartArrowDisabledImg+='farleft_dis.gif';this.sJumpEndArrowImg+='farright.gif';this.sJumpEndArrowPushedImg+='farright.gif';this.sJumpEndArrowDisabledImg+='farright_dis.gif';}};CUIArrowOnlyScrollControl.prototype.OnStartArrowDown=function(){if(this._qQ<=0)return;this._qQ--;this.UpdateAllArrows();this.Notify(ExpEvent.kCUIArrowOnlyScrollControl_Scroll);};CUIArrowOnlyScrollControl.prototype.OnEndArrowDown=function(){if(this._qQ>=this._fI-this._tu)return;this._qQ++;this.UpdateAllArrows();this.Notify(ExpEvent.kCUIArrowOnlyScrollControl_Scroll);};CUIArrowOnlyScrollControl.prototype.OnScrollToEnd=function(){this._qQ=Math.max(0,this._fI-this._tu);this.UpdateAllArrows();this.Notify(ExpEvent.kCUIArrowOnlyScrollControl_Scroll);};CUIArrowOnlyScrollControl.prototype.OnScrollToStart=function(){this._qQ=0;this.UpdateAllArrows();this.Notify(ExpEvent.kCUIArrowOnlyScrollControl_Scroll);};CUIArrowOnlyScrollControl.prototype.UpdateAllArrows=function(){if(this.oJumpStartArrow){this.oJumpStartArrow.UpdateImage();}if(this.oStartDirArrow){this.oStartDirArrow.UpdateImage();}if(this.oEndDirArrow){this.oEndDirArrow.UpdateImage();}if(this.oJumpEndArrow){this.oJumpEndArrow.UpdateImage();}};CUIArrowOnlyScrollControl.prototype.GetStartArrowEle=function(){return this.oStartDirArrow.m_oDomImage;};CUIArrowOnlyScrollControl.prototype.GetEndArrowEle=function(){return this.oEndDirArrow.m_oDomImage;};CUIArrowOnlyScrollControl.prototype.IsScrollArrow=function(el){if(el==this.GetStartArrowEle()||el==this.GetEndArrowEle()){return true;}else{return false;}};CUIArrowOnlyScrollControl.prototype.GetFirstVisibleIndex=function(){return this._qQ;};CUIArrowOnlyScrollControl.prototype.GetVisibleUnits=function(){return this._tu;};CUIArrowOnlyScrollControl.prototype.GetTotalUnits=function(){return this._fI;};CUIArrowOnlyScrollControl.prototype.SetUnits=function(_yT,_OP,_Sj){if(_yT!=null){_yT=Math.max(_yT,0);this._qQ=_yT;}if(_OP!=null){_OP=Math.max(_OP,1);this._tu=_OP;}if(_Sj!=null){_Sj=Math.max(_Sj,1);this._fI=_Sj;}this.UpdateAllArrows();};function CUIArrowOnlyCallingContext(){this.iArrowWidth=10;this.iArrowHeight=20;};CUIArrowOnlyCallingContext.prototype.SetUnitAttributes=function(_z4,_HZ,_UC){this.iTotalUnits=_z4;this.iVisibleUnits=_HZ;this.iFirstVisibleUnit=_UC;};CUIArrowOnlyCallingContext.prototype.SetArrowAttributes=function(_M1,_Dn,_zh,_S7,_Au,_AF){this.elJumpStartArrow=_M1;this.elStartDirArrow=_Dn;this.elEndDirArrow=_zh;this.elJumpEndArrow=_S7;if(_Au!=null){this.iArrowWidth=_Au;}if(_AF!=null){this.iArrowHeight=_AF;}};function CUIJumpArrow(_LK,_DW,_F4,_T6,_EC){this.base=CUIScrollArrow;this.base(_LK,_DW,_F4,_T6,_EC);};CUIJumpArrow.prototype=new CUIScrollArrow;CUIJumpArrow.prototype.HandleMouseDown=function(e){this.m_bButtonHeldDown=true;this.setImageDown();if(this.m_oDomImage.setCapture){this.m_oDomImage.setCapture();}else{window.captureEvents(Event.MouseUp);window.onmouseup=this.HandleMouseUp;}this.notifyParent();if(e){Dom.CancelEvent(e);}};CUIJumpArrow.prototype.notifyParent=function(){if(this.m_bStartArrow){this.m_oParent.OnScrollToStart();}else{this.m_oParent.OnScrollToEnd();}};function CDLBlockTransaction(_AT){this.oDataMgr=_AT;};CDLBlockTransaction.CreateChildrenOfActionArray=function(_TZ,_FK){var _VI=new Array();if(_TZ.bSubTotalEnabled!=_FK.bSubTotalEnabled){_VI.push(_FK.getSetPropertyAction("subtotal",_TZ.bSubTotalEnabled));}if(_TZ._fZ!=_FK._fZ){_VI.push(_FK.getSetPropertyAction("summary",_TZ._fZ));}if(_TZ.bRemainderEnabled!=_FK.bRemainderEnabled){_VI.push(_FK.getSetPropertyAction("remainder",_TZ.bRemainderEnabled));}if(_TZ.bVisibleEnabled!=_FK.bVisibleEnabled){_VI.push(_FK.getSetPropertyAction("visible",_TZ.bVisibleEnabled));}if(_TZ.bFilterAggEnabled!=_FK.bFilterAggEnabled){_VI.push(_FK.getSetPropertyAction("filteraggregate",_TZ.bFilterAggEnabled));}if(_TZ.bPassedFilterAggEnabled!=_FK.bPassedFilterAggEnabled){_VI.push(_FK.getSetPropertyAction("passedfilteraggregate",_TZ.bPassedFilterAggEnabled));}if(_FK._hF&&_TZ._hF){var _aGR=(!CDLBlockTransaction.IsSortEqual(_TZ,_FK))||(!CDLBlockTransaction.IsSubsetEqual(_TZ,_FK))||(!CDLBlockTransaction.IsUserDefFilterEqual(_TZ,_FK))||(!Utilities.AreArrayContentsEqualIgnoreOrder(_TZ.GetExcludedMemberIds(),_FK.GetExcludedMemberIds()));if(_aGR){_VI.push(_FK.getSetPropertyAction("lock",false));CDLBlockTransaction.CreateLockRelatedPropActionArray(_TZ,_FK,_VI);_VI.push(_FK.getSetPropertyAction("lock",true));}}else if(_FK._hF&&(!_TZ._hF)){_VI.push(_FK.getSetPropertyAction("lock",false));CDLBlockTransaction.CreateLockRelatedPropActionArray(_TZ,_FK,_VI);}else if((!_FK._hF)&&_TZ._hF){CDLBlockTransaction.CreateLockRelatedPropActionArray(_TZ,_FK,_VI);_VI.push(_FK.getSetPropertyAction("lock",true));}else{CDLBlockTransaction.CreateLockRelatedPropActionArray(_TZ,_FK,_VI);}if(_TZ._d0!=_FK._d0){_VI.push(_FK.SetProperty(ExpAPIXml.kEleAnnotation,_TZ._d0,true));}if(_TZ.GetBlockSize()!=_FK.GetBlockSize()){_VI.push(_FK.SetProperty(ExpAPIXml.kEleAxisOpExprBlockSize,_TZ.GetBlockSize(),true));}if(!Utilities.AreArrayContentsEqualIgnoreOrder(_TZ._wM,_FK._wM)){var _aqY=Utilities.CopyArray(_FK._wM);_VI=CDLBlockTransaction.SyncAppendMemberList(_TZ._wM,_aqY,_FK,_VI);}if(!Utilities.AreArrayContentsEqualIgnoreOrder(_TZ._qS,_FK._qS)){_VI=CDLBlockTransaction.SyncPropertyValueDisplay(_TZ,_FK,_VI);}return _VI;};CDLBlockTransaction.CreateLockRelatedPropActionArray=function(_TZ,_FK,_VI){CDLBlockTransaction.SyncSortProperties(_TZ,_FK,_VI);if(!CDLBlockTransaction.IsSubsetEqual(_TZ,_FK)){_VI.push(_FK.SetProperty(ExpAPIXml.kEleSubset,_TZ.GetSubset(),true));}if(!CDLBlockTransaction.IsUserDefFilterEqual(_TZ,_FK)){_VI.push(_FK.SetProperty(ExpAPIXml.kEleUserDefFilter,_TZ.GetUserDefFLT(),true));}if(!Utilities.AreArrayContentsEqualIgnoreOrder(_TZ._kL,_FK._kL)){var _aqY=Utilities.CopyArray(_FK._kL);_VI=CDLBlockTransaction.SyncAppendMemberList(_TZ._kL,_aqY,_FK,_VI);}};CDLBlockTransaction.CreateHamcActionArray=function(_TZ,_FK){var _VI=new Array();if(_TZ.bFilterAggEnabled!=_FK.bFilterAggEnabled){_VI.push(_FK.getSetPropertyAction("filteraggregate",_TZ.bFilterAggEnabled));}if(_TZ.bPassedFilterAggEnabled!=_FK.bPassedFilterAggEnabled){_VI.push(_FK.getSetPropertyAction("passedfilteraggregate",_TZ.bPassedFilterAggEnabled));}if(_TZ.bVisibleEnabled!=_FK.bVisibleEnabled){_VI.push(_FK.getSetPropertyAction("visible",_TZ.bVisibleEnabled));}if(_FK._hF&&_TZ._hF){var _aGR=(!CDLBlockTransaction.IsSortEqual(_TZ,_FK))||(!CDLBlockTransaction.IsSubsetEqual(_TZ,_FK))||(!CDLBlockTransaction.IsUserDefFilterEqual(_TZ,_FK))||(!Utilities.AreArrayContentsEqualIgnoreOrder(_TZ.GetExcludedMemberIds(),_FK.GetExcludedMemberIds()));if(_aGR){_VI.push(_FK.getSetPropertyAction("lock",false));CDLBlockTransaction.CreateLockRelatedPropActionArray(_TZ,_FK,_VI);_VI.push(_FK.getSetPropertyAction("lock",true));}}else if(_FK._hF&&(!_TZ._hF)){_VI.push(_FK.getSetPropertyAction("lock",false));CDLBlockTransaction.CreateLockRelatedPropActionArray(_TZ,_FK,_VI);}else if((!_FK._hF)&&_TZ._hF){CDLBlockTransaction.CreateLockRelatedPropActionArray(_TZ,_FK,_VI);_VI.push(_FK.getSetPropertyAction("lock",true));}else{CDLBlockTransaction.CreateLockRelatedPropActionArray(_TZ,_FK,_VI);}if(_FK.bHierarchyEnabled){if(_TZ.bHierarchyEnabled!=_FK.bHierarchyEnabled){_VI.push(_FK.getSetPropertyAction("hierarchy",_TZ.bHierarchyEnabled));}if(_TZ._fZ!=_FK._fZ){_VI.push(_FK.getSetPropertyAction("summary",_TZ._fZ));}}else{if(_TZ._fZ!=_FK._fZ){_VI.push(_FK.getSetPropertyAction("summary",_TZ._fZ));}if(_TZ.bHierarchyEnabled!=_FK.bHierarchyEnabled){_VI.push(_FK.getSetPropertyAction("hierarchy",_TZ.bHierarchyEnabled));}}if(!Utilities.AreArrayContentsEqualIgnoreOrder(_TZ._qS,_FK._qS)){_VI=CDLBlockTransaction.SyncPropertyValueDisplay(_TZ,_FK,_VI);}return _VI;};CDLBlockTransaction.Commit=function(_TZ,_FK){if(_TZ.IsHAMC()){var _VI=CDLBlockTransaction.CreateHamcActionArray(_TZ,_FK);}else{var _VI=CDLBlockTransaction.CreateChildrenOfActionArray(_TZ,_FK);}if(_VI.length>0){_FK.oAxis._rk.SendDMActionArray(_VI);}};CDLBlockTransaction.IsSortEqual=function(_TZ,_FK){if(_TZ._mm==_FK._mm&&Utilities.AreArrayContentsEqualIgnoreOrder(_TZ._qs,_FK._qs)&&_TZ._k2==_FK._k2&&_TZ._fR==_FK._fR&&_TZ._cc==_FK._cc){return true;}else{return false;}};CDLBlockTransaction.SyncSortProperties=function(_TZ,_FK,_VI){_VI.push(_FK.SetProperty(ExpAPIXml.kEleAxisOpExprSorttype,ExpAPIXml.kEleAxisOpExprSorttypeDefault,true));if(_TZ._mm!=ExpAPIXml.kEleAxisOpExprSorttypeDefault){_VI.push(_FK.SetProperty(ExpAPIXml.kEleAxisOpExprSorttype,_TZ._mm,true));}if(_TZ._qs.length>0){_VI.push(_FK.SetSortMembers(_TZ._qs,true));}if(_TZ._k2){_VI.push(_FK.SetProperty(ExpAPIXml.kEleAxisOpExprSortMeasure,_TZ._k2,true));}if(_TZ._fR){_VI.push(_FK.SetProperty(ExpAPIXml.kEleAxisOpExprSortProperty,_TZ._fR,true));}if(_TZ._cc){_VI.push(_FK.SetProperty(ExpAPIXml.kEleAxisOpExprSortLabel,_TZ._cc,true));}};CDLBlockTransaction.IsBlockSizeEqual=function(_TZ,_FK){if(_TZ.GetBlockSize()==_FK.GetBlockSize()){return true;}else{return false;}};CDLBlockTransaction.IsViewPropEqual=function(_TZ,_FK){return _TZ.bHierarchyEnabled==_FK.bHierarchyEnabled;};CDLBlockTransaction.AreHiddenMembersEqual=function(_TZ,_FK){if(Utilities.AreArrayContentsEqualIgnoreOrder(_TZ.GetHiddenMemberIds(),_FK.GetHiddenMemberIds())){return true;}return false;};CDLBlockTransaction.AreExcludedMembersEqual=function(_TZ,_FK){if(Utilities.AreArrayContentsEqualIgnoreOrder(_TZ.GetExcludedMemberIds(),_FK.GetExcludedMemberIds())){return true;}return false;};CDLBlockTransaction.IsAutoSummaryEqual=function(_TZ,_FK){if(_TZ.bSubTotalEnabled==_FK.bSubTotalEnabled&&_TZ._fZ==_FK._fZ&&_TZ.bRemainderEnabled==_FK.bRemainderEnabled&&_TZ.bFilterAggEnabled==_FK.bFilterAggEnabled&&_TZ.bPassedFilterAggEnabled==_FK.bPassedFilterAggEnabled&&_TZ.bVisibleEnabled==_FK.bVisibleEnabled){return true;}return false;};CDLBlockTransaction.IsSubsetEqual=function(_TZ,_FK){if(_TZ.GetSubset()&&_FK.GetSubset()){return this.isSubsetFilterExprEqual(_TZ.GetSubset(),_FK.GetSubset());}else if(_TZ.GetSubset()||_FK.GetSubset()){if(_TZ.GetSubset()&&_TZ.GetSubset()._uj==null){return true;}if(_FK.GetSubset()&&_FK.GetSubset()._uj==null){return true;}return false;}else{return true;}};CDLBlockTransaction.IsUserDefFilterEqual=function(_TZ,_FK){if(_TZ.GetUserDefFLT()&&_FK.GetUserDefFLT()){return CDLBlockTransaction.IsUserDefFLTExprEqual(_TZ.GetUserDefFLT(),_FK.GetUserDefFLT());}else if(_TZ.GetUserDefFLT()||_FK.GetUserDefFLT()){return false;}else{return true;}};CDLBlockTransaction.IsUserDefFLTExprEqual=function(_za,_IK){var _31=true;var _aqJ=_c.LoadString(_za._ni.GetAsXML(_za._ni,'',_IK._lR.GetCurrentDataMatrix()),false);var _YQ=Dom.GetImmediateChildByName(_aqJ,CDLMathMLOperands.Apply);var _98=_c.LoadString(_IK._ni.GetAsXML(_IK._ni,'',_IK._lR.GetCurrentDataMatrix()));var _5w=Dom.GetImmediateChildByName(_98,CDLMathMLOperands.Apply);if(_YQ.childNodes.length!=_5w.childNodes.length){return false;}else if(_YQ.childNodes.length==_5w.childNodes.length==0){return true;}else if(!((_za._nt&&_IK._nt)||((!_za._nt)&&(!_IK._nt)))){return false;}var _aJA=Dom.GetTreeWalker(_YQ);var _3R=Dom.GetTreeWalker(_5w);while(!_aJA.AtEnd()){if(_3R.AtEnd()){_31=false;break;}var _aHq=_aJA.GetElement();var _1R=_3R.GetElement();if(_aHq.nodeName!=_1R.nodeName){_31=false;break;}if(_aHq.nodeName!=CDLMathMLOperands.Apply){if(Dom.GetNodeText(_aHq)!=Dom.GetNodeText(_1R)){_31=false;break;}}_aJA.MoveToNext();_3R.MoveToNext();}if((_31)&&(!_3R.AtEnd())){_31=false;}return _31;};CDLBlockTransaction.isSubsetFilterExprEqual=function(_za,_IK){if(_za._uj==_IK._uj&&_za._aK==_IK._aK&&_za._sA==_IK._sA&&Utilities.AreArrayContentsEqual(_za._qs,_IK._qs)&&_za._sf==_IK._sf){return true;}return false;};CDLBlockTransaction.IsDisplayAttributesEqual=function(_TZ,_FK){return Utilities.AreArrayContentsEqualIgnoreOrder(_TZ._qS,_FK._qS);};CDLBlockTransaction.SyncPropertyValueDisplay=function(_TZ,_FK,_VI){var _KZ=Utilities.CopyArray(_FK._qS);for(var i=0;i<_TZ._qS.length;i++){if(!Utilities.DeleteFromArray(_KZ,_TZ._qS[i])){_VI.push(_FK.ShowPropertyValue(_TZ._qS[i],true));}}for(var i=0;i<_KZ.length;i++){_VI.push(_FK.DisablePropertyDisplay(_KZ[i],true));}return _VI;};CDLBlockTransaction.SyncAppendMemberList=function(_HD,_KZ,_FK,_VI){var _ay0=new Array();for(var i=0;i<_KZ.length;i++){if(!Utilities.DeleteFromArray(_HD,_KZ[i])){_ay0.push(_KZ[i]);}}_VI.push(_FK.AppendMembers(_ay0,true));return _VI;};CDLBlockTransaction.IsLockPropEqual=function(_TZ,_FK){return _TZ._hF==_FK._hF;};CDLDataManager.ObjectTypeMap=new Object();CDLDataManager.CategorizedObjectMap=new Object();function CDLDataManager(_N0,_GJ,_Un,_LP){this._fH=false;this.appobj=_N0;this.commManager=_GJ;this._xt=_LP;this._ea=_Un;this._an="";this.realSavedAnalysisName="";this._kX=null;this._wn=new Object();this._iF=new Object();this._pv=new Object();this._k5=new Object();this._kE=new Object();this._dE=new CDLCMFolder(this);this._fz=new Object();this.oFilterSetArray=new Object();this.oBlockTransaction=new CDLBlockTransaction(this);this._od=false;this._yd=false;CDLDataManager.CategorizedObjectMap[ExpAPIXml.kEleWorksheet]=this._wn;CDLDataManager.CategorizedObjectMap[ExpAPIXml.kEleDataMatrix]=this._iF;CDLDataManager.CategorizedObjectMap[ExpAPIXml.kEleCrosstab]=this._pv;CDLDataManager.CategorizedObjectMap[ExpAPIXml.kEleChart]=this._fz;CDLDataManager.CategorizedObjectMap[ExpAPIXml.kEleFilterSet]=this.oFilterSetArray;this.metadata=null;this._vw=null;this._xb=null;this._pe=null;this._e6=new Array();this._e6[ExpEvent.kCDLDataManager_DataMatrixCreate]=new Array();this._e6[ExpEvent.kCDLDataManager_CurrentWSFSChange]=new Array();this._e6[ExpEvent.kCDLDataManager_ChartRefresh]=new Array();this._e6[ExpEvent.kCDLDataManager_AnalysisCreate]=new Array();this._e6[ExpEvent.kCDLCrosstab_Create]=new Array();this._e6[ExpEvent.kCDLCustomSet_Deleted]=new Array();this._e6[ExpEvent.kCDLWorksheet_SaveSuccess]=new Array();this._e6[ExpEvent.kCDLWorksheet_SaveContinue]=new Array();this._e6[ExpEvent.kCDLWorksheet_SaveUpdateContinue]=new Array();this._e6[ExpEvent.kCDLWorksheet_SaveForEditSuccess]=new Array();this._e6[ExpEvent.kCDLWorksheet_LoadSuccess]=new Array();this._e6[ExpEvent.kCDLWorksheet_NewSuccess]=new Array();this._e6[ExpEvent.kCDLDataManager_UpdateViews]=new Array();this._e6[ExpEvent.kCDLDataManager_MissingDataCreate]=new Array();this._e6[ExpEvent.kCDLDataManager_MissingDataDelete]=new Array();this._e6[ExpEvent.kCDLDataManager_UpdateTree]=new Array();this._e6[ExpEvent.kCDLDataManager_CapabilitiesUpdated]=new Array();this._uJ=new CDLStatus();this._mw=new Object();this._eQ=new Object();this.appobj._bf.datamanager=this;this._aF=null;this._bp=null;this._eF=null;this._i4=new CDLDescriptiveStats(this.GetCurrentWorkSheet());this.descriptiveStatsInserted=false;this.descriptiveStatsType=null;};CDLDataManager.kMetadataReleaseToken='dometadatareplace';CDLDataManager.prototype.IsDescriptiveStatisticsEnabled=function(){return this._od;};CDLDataManager.prototype.SetDescriptiveStatisticsEnabled=function(_KN){this._od=_KN;};CDLDataManager.prototype.IsMultiRootMembersMetadataFixEnabled=function(){return this._yd;};CDLDataManager.prototype.SetMultiRootMembersMetadataFixEnabled=function(_KN){this._yd=_KN;};CDLDataManager.prototype.SetObjToStale=function(_B5,_Rq){this._eQ[_B5]=_Rq;};CDLDataManager.prototype.CreateConfiguration=function(){this._eF=new CDLConfiguration(this);};CDLDataManager.prototype.GetConfigProperty=function(_LW){var _aBl=null;if(this._eF){_aBl=this._eF.GetProperty(_LW);}return _aBl;};CDLDataManager.prototype.CheckConfiguration=function(_VQ){var _2j=Dom.GetElementsByTagName(_VQ,'bus:biBusHeader');if(_2j.length==1){var _amA=Dom.GetImmediateChildByNameNoNS(_2j[0],'userPreferenceVars');var _TC=_amA.selectNodes(ExpAPIXml.kEleItem);for(var i=0;i<_TC.length;i++){var _2H=_TC[i];var _aDY=Dom.GetImmediateChildByNameNoNS(_2H,ExpAPIXml.kEleName);var _aJP=Dom.GetNodeText(_aDY);switch(_aJP){case CDLConfiguration.K_sLineageURL:var _anE=Dom.GetImmediateChildByNameNoNS(_2H,ExpAPIXml.kEleValue);this._eF.SetProperty(_aJP,Dom.GetNodeText(_anE));break;case CDLConfiguration.K_sGlossaryURL:var _anE=Dom.GetImmediateChildByNameNoNS(_2H,ExpAPIXml.kEleValue);this._eF.SetProperty(_aJP,Dom.GetNodeText(_anE));break;}}}};CDLDataManager.prototype.CreateUserCapabilityProfile=function(){this._bp=new CDLCapability(this);return this._bp;};CDLDataManager.prototype.CheckGlobalUserCapability=function(_VQ){var _2j=Dom.GetElementsByTagName(_VQ,'bus:biBusHeader');if(_2j.length==1){_R5=this.GetUserProfiles();var _alK=Dom.GetImmediateChildByNameNoNS(_2j[0],'userCapabilityCache');var _BW=Dom.GetImmediateChildByNameNoNS(_alK,'userCapabilities');var _abH=_BW.selectSingleNode("item[text()='"+CDLCapability.K_sCanIndexSearch+"']");if(_abH){_R5.SetCapabilities(CDLCapability.K_sCanIndexSearch,true);}var _ayi=_BW.selectSingleNode("item[text()='"+CDLCapability.K_sCanUseReportStudio+"']");if(_ayi){_R5.SetCapabilities(CDLCapability.K_sCanUseReportStudio,true);}this.CheckForReportOutputPermissions(_BW,_R5);}};CDLDataManager.prototype.CheckForReportOutputPermissions=function(_BW,_R5){var _azA=false;var _al2=_BW.selectSingleNode("item[text()='"+CDLCapability.K_sCanGenerateXMLOutput+"']");if(_al2){_R5.SetCapabilities(CDLCapability.K_sCanGenerateXMLOutput,true);}var _8H=_BW.selectSingleNode("item[text()='"+CDLCapability.K_sCanGenerateCSVOutput+"']");if(_8H){_R5.SetCapabilities(CDLCapability.K_sCanGenerateCSVOutput,true);}var _aqC=_BW.selectSingleNode("item[text()='"+CDLCapability.K_sCanGenerateExcelOutput+"']");if(_aqC){_R5.SetCapabilities(CDLCapability.K_sCanGenerateExcelOutput,true);}var _aEi=_BW.selectSingleNode("item[text()='"+CDLCapability.K_sCanGeneratePDFOutput+"']");if(_aEi){_R5.SetCapabilities(CDLCapability.K_sCanGeneratePDFOutput,true);}_azA=_al2||_8H||_aqC||_aEi;if(_azA){this.Notify(ExpEvent.kCDLDataManager_CapabilitiesUpdated);}};CDLDataManager.prototype.GetUserProfiles=function(){return this._bp;};CDLDataManager.prototype.IsSupportedProfile=function(_TB){if(this._bp){return this._bp.IsSupportedProfile(_TB);}return false;};CDLDataManager.prototype.IsProfilesEmpty=function(){if(this._bp){return this._bp.IsProfilesEmpty();}return false;};CDLDataManager.prototype.IsResponseProcessed=function(){if(this._bp){return this._bp.IsResponseProcessed();}return false;};CDLDataManager.prototype.HasCapability=function(_MO){if(this._bp){return this._bp.HasCapability(_MO);}return false;};CDLDataManager.prototype.ReleaseStaledObj=function(_B5){if(this._eQ[_B5]){this._eQ[_B5][0].Notify(this._eQ[_B5][1]);delete this._eQ[_B5];}};CDLDataManager.prototype.GetGlossaryConfigration=function(){var _aBj=this.commManager.CreateConfigurationRequest();_aBj.Send(true,this,false,null,true);};CDLDataManager._fx='<item xsi:type="bus:genericOptionXMLEncodedXML">'+'<bus:name xsi:type="xsd:string">http://developer.cognos.com/ceba/constants/contentManagerCacheOptionEnum#context</bus:name>'+'<bus:value xsi:type="bus:xmlEncodedXML">'+'@CACHECONTEXT@'+'</bus:value>'+'</item>';CDLDataManager.prototype.IssueInitialRequest=function(_zK){var q=null;var _0n=null;if(this._xt!=null){q=this._xt;}else{q=this.appobj.GetDefaultAnalysis();_0n=this.appobj.GetDynamicContext();}var _Jj=new CDLAction();_Jj.type='init';var _AE=new Array();_AE[0]=_Jj;if(q==null)q='false';_Jj._eW('query',q);_Jj._eW('package',this._ea);_Jj._eW('default',this.appobj.GetDefaultAnalysis());if(_0n!=null&&_0n!=''){Debug.Assert(q=='false');_Jj._eW('context',_0n);}if(this.appobj.GetDrillTargetParms()){this.commManager.SetParameterValues(this.appobj.GetDrillTargetParms());}var _aBj;if(q!='false'&&q!=DefaultAnalysis.kServerDefault){_aBj=this.commManager.CreateEditObjRequest(q,_AE);}else{_Jj._eW('defBlockSize',this.appobj._sE);_Jj._eW('maxBlockSize',this.appobj._ft);_Jj._eW('defExpand',this.appobj._jB);_Jj._eW('maxExpand',this.appobj._al);_aBj=this.commManager.CreateExploreRequest(_AE);}if(_zK){_aBj.SetDeferredCallBackFunction(_zK);}var _aDj=this.appobj.GetCacheContext();if(_aDj){var _zn=CDLDataManager._fx;_zn=_zn.replace("@CACHECONTEXT@",Utilities.HtmlEncode(_aDj));_aBj.ReplaceRequestParm("@CACHECONTEXTOPTION@",_zn);}_aBj.Send(true,this,false,null,true);};CDLDataManager.prototype.GetDataMatrixById=function(_zV){return this._iF[_zV];};CDLDataManager.prototype.GetCurrentDataMatrix=function(){if(this._iF.length==0){return null;}var _alm="";var _PQ=0;for(var s in this._iF){var dm=this._iF[s];if(dm.IsScratchPadDataMatrix()==false){_alm=this._iF[s]._ks;}_PQ++;}return this._iF[_alm];};CDLDataManager.prototype.GetCurrentCrosstab=function(){var _alm="";for(var s in this._pv){_alm=this._pv[s]._ks;}return this._pv[_alm];};CDLDataManager.prototype.GetCurrentWorkSheet=function(){var _alm="";for(var s in this._wn){_alm=this._wn[s]._ks;}return this._wn[_alm];};CDLDataManager.prototype.GetCurrentChart=function(){for(var i in this._fz){return this._fz[i];}return null;};CDLDataManager.prototype.GetCurrentWSFilterSet=function(){for(var s in this.oFilterSetArray){return this.oFilterSetArray[s];}};CDLDataManager.prototype.HasContextItemUsedAsParam=function(){var _aoY=this.GetCurrentWSFilterSet();for(var i=0;i<_aoY._vP.length;i++){var _EB=_aoY._vP[i];if(_EB.bUsedAsParam==1)return true;}return false;};CDLDataManager.prototype.FindCMObjectIdByPath=function(_y8){for(var i in this._kE){if(this._kE[i]._qI==_y8){return i;}}return null;};CDLDataManager.prototype.SetSearchPath=function(_EG){this._an=_EG;};CDLDataManager.prototype.GetSearchPath=function(){return this._an;};CDLDataManager.prototype.SetRealSavedAnalysisName=function(_Vj){this.realSavedAnalysisName=_Vj;};CDLDataManager.prototype.GetRealSavedAnalysisName=function(){return this.realSavedAnalysisName;};CDLDataManager.prototype.GetFolderPath=function(){var _5q=this.GetCurrentWorkSheet().GetInitAnalysisFolderPath();var _Cw=this.GetCurrentWorkSheet().GetCurrentFolderId();if(_Cw&&this._kE[_Cw]){_5q=this._kE[_Cw]._qI;}return _5q;};CDLDataManager.prototype.ProcessFailedRequest=function(_Ou){var _Np="";for(var i=1;i<_Ou.childNodes.length;i++){var _FA=_Ou.childNodes[i];if((_FA.nodeName=='errormessage')&&(_FA.childNodes.length>0)){_Np+=_FA.childNodes[0].nodeValue+"\n";}}this._uJ.AddStatus(false,_Np);return _Np;};CDLDataManager.prototype.GetErrorMsg=function(_Ou){var _2y="";var _FA=_Ou.childNodes[0];if((_FA.nodeName=='errormessage')&&(_FA.childNodes.length>0)){_2y=_FA.childNodes[0].nodeValue;}return _2y;};CDLDataManager.prototype.IsInMissingMUNState=function(){return this._fH;};CDLDataManager.prototype.ForceFullRefresh=function(){return this._uU;};CDLDataManager.prototype.ProcessCommands=function(_zw,_zR){Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CDLDataManager::ProcessCommands"]);this._uJ.AddStatus(true);Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CDLDataManager::ProcessCommands::PreProcess"]);var _agS=new Array();var _arh=_zw.selectNodes(ExpAPIXml.kEleCommand);var _6M=_arh.length;for(var i=0;i<_6M;i++){var _2H=_arh[i];var _Wz=Dom.GetNodeTextShallow(_2H,ExpAPIXml.kEleCmdTarget);if(_Wz!==''){var _Hx=this._wR(_Wz,_2H);if(_Hx){_agS.push(_Hx);}}else{_agS.push("Unknown");}}Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CDLDataManager::ProcessCommands::PreProcess"]);Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CDLDataManager::ProcessCommands::ReOrder"]);var _aiX=new Array();_aiX=_aiX.concat(Utilities.GetObjIndices(_agS,ExpAPIXml.kEleVersionInfo));_aiX=_aiX.concat(Utilities.GetObjIndices(_agS,ExpAPIXml.kEleMetadata));_aiX=_aiX.concat(Utilities.GetObjIndices(_agS,ExpAPIXml.kEleDimension));_aiX=_aiX.concat(Utilities.GetObjIndices(_agS,ExpAPIXml.kEleHierarchy));_aiX=_aiX.concat(Utilities.GetObjIndices(_agS,ExpAPIXml.kEleLevel));_aiX=_aiX.concat(Utilities.GetObjIndices(_agS,ExpAPIXml.kEleMember));_aiX=_aiX.concat(Utilities.GetObjIndices(_agS,ExpAPIXml.kEleDescriptiveStats));var _aJH=Utilities.GetObjIndices(_agS,ExpAPIXml.kEleAnalysis);var _ai3=(_aJH.length>0);_aiX=_aiX.concat(_aJH);_aiX=_aiX.concat(Utilities.GetObjIndices(_agS,ExpAPIXml.kCustomSet));_aiX.push(CDLDataManager.kMetadataReleaseToken);_aiX=_aiX.concat(Utilities.GetObjIndices(_agS,ExpAPIXml.kEleSearchResult));_aiX=_aiX.concat(Utilities.GetObjIndices(_agS,ExpAPIXml.kEleCMAnalysis));var _aiR=Utilities.GetObjIndices(_agS,ExpAPIXml.kEleFilterSet);var _amj=(_aiR.length>0);_aiX=_aiX.concat(_aiR);var _af5=Utilities.GetObjIndices(_agS,ExpAPIXml.kEleDataMatrix);var _ant=(_af5.length>0);_aiX=_aiX.concat(_af5);var _aCN=Utilities.GetObjIndices(_agS,ExpAPIXml.kEleCrosstab);var _6L=(_aCN.length>0);_aiX=_aiX.concat(_aCN);_aiX=_aiX.concat(Utilities.GetObjIndices(_agS,ExpAPIXml.kEleWorksheet));_aiX=_aiX.concat(Utilities.GetObjIndices(_agS,ExpAPIXml.kEleLayout));this._uU=false;var _aaL=Utilities.GetObjIndices(_agS,ExpAPIXml.kEleMissing);var _1N=(_aaL.length>0);if(_1N==false&&this._fH){this._uU=true;}this._fH=_1N;_aiX=_aiX.concat(_aaL);_aiX=_aiX.concat(Utilities.GetObjIndices(_agS,ExpAPIXml.kEleChart));var _awy=Utilities.GetObjIndices(_agS,ExpAPIXml.kEleData);var _agK=(_awy.length>0);this._rN=_agK;_aiX=_aiX.concat(_awy);_aiX=_aiX.concat(Utilities.GetObjIndices(_agS,ExpAPIXml.kEleCMFolder));_aiX=_aiX.concat(Utilities.GetObjIndices(_agS,"Unknown"));Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CDLDataManager::ProcessCommands::ReOrder"]);if(this._kX!=null){this._kX.SetFullXtabRefresh(false);this._kX.resetPaperSizeResponse();if(_ai3&&(_ant||_6L||_agK)){this._kX.SetFullXtabRefresh(true);}}if(this.GetCurrentWSFilterSet()!=null){this.GetCurrentWSFilterSet().SetFullXtabRefresh(false);if(_amj&&(_ant||_6L||_agK)){this.GetCurrentWSFilterSet().SetFullXtabRefresh(true);}}Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CDLDataManager::ProcessCommands::ProcessCommands"]);for(var i=0;i<_aiX.length;i++){if(!_arh[_aiX[i]]){this.ReleaseStaledObj(_aiX[i]);}else{this._nD(_arh[_aiX[i]],_zR);}}Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CDLDataManager::ProcessCommands::ProcessCommands"]);if(this._uU){Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CDLDataManager::ProcessCommands::FullRefresh"]);this._vw.Clear();this._vw=null;this.Notify(ExpEvent.kCDLDataManager_MissingDataDelete);Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CDLDataManager::ProcessCommands::FullRefresh"]);}if(Utilities.bDiffMiningEnabled){if(this.GetCurrentDataMatrix().bShowDiffMiningDlg){this.GetCurrentDataMatrix().showDiffMiningDlg();this.GetCurrentDataMatrix().bShowDiffMiningDlg=false;}}Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CDLDataManager::ProcessCommands::NotifyUpdate"]);if(!_zR){this.Notify(ExpEvent.kCDLDataManager_UpdateViews);}Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CDLDataManager::ProcessCommands::NotifyUpdate"]);Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CDLDataManager::ProcessCommands"]);};CDLDataManager.prototype._nD=function(_Wg,_zR){var _acg=Dom.GetNodeText(Dom.GetImmediateChildByName(_Wg,ExpAPIXml.kEleCmdAction));switch(_acg){case ExpAPIXml.kActionCreate:this._bT(_Wg,_zR);break;case ExpAPIXml.kActionDelete:this._wh(_Wg);break;case ExpAPIXml.kActionMerge:this._cR(_Wg,_zR);break;case ExpAPIXml.kActionData:this._gv(_Wg);break;case ExpAPIXml.kActionReplace:this._s9(_Wg);break;case ExpAPIXml.kActionGetReport:this._gE(_Wg);break;case ExpAPIXml.kActionGetHLS:this._em(_Wg);break;default:throw new COTUnexpectedObjectException("Unexpected action in CDLDataManager::_processCommand");}};CDLDataManager.prototype._Q=function(_zw){for(var i=0;i<_zw.childNodes.length;i++){if(_zw.childNodes[i].nodeName==ExpAPIXml.kEleCommand){var _aky=Dom.GetImmediateChildByName(_zw.childNodes[i],ExpAPIXml.kEleCmdTarget);if(_aky){var _Wz=Dom.GetNodeText(_aky);var _Hx=this._wR(_Wz,_zw.childNodes[i]);if(_Hx==ExpAPIXml.kEleResource){var _amv=Dom.GetImmediateChildByName(_zw.childNodes[i],ExpAPIXml.kEleCmdAction);Debug.Assert(Dom.GetNodeText(_amv)==ExpAPIXml.kActionCreate);this._bT(_zw.childNodes[i]);break;}}}}};CDLDataManager.prototype._gE=function(_Wg){var _aky=Dom.GetImmediateChildByName(_Wg,"reportspec");var _YR=Dom.GetNodeText(_aky);var _asE=Dom.GetNodeText(Dom.GetImmediateChildByName(_Wg,"reportcmd"));if(_asE=="copytoclipboard"){CopyPasteHLS.CopyV5SpecToClipboard(_YR);}else{this.appobj.RunReport(_YR);}};CDLDataManager.prototype._em=function(_Wg){var _4T=Dom.GetImmediateChildByName(_Wg,"hls");var _aBy=Dom.GetImmediateChildByName(_4T,"analysisReport");if(this.GetCurrentWorkSheet()._Z){this.GetCurrentWorkSheet()._Z=null;window.originHLS=_aBy.xml;}else{CopyPasteHLS.CopyHLSToClipboard(_aBy);}};CDLDataManager.prototype._fK=function(){this.appobj.EditReport(this.GetSearchPath(),this.GetFolderPath());};CDLDataManager.prototype._n9=function(_Wz,_Wg){if(_o.is_ie5_5up){var _amc=Utilities.F_ToXPathString(_Wz,true);}else{var _amc=Utilities.F_ToXPathString(_Wz);}var obj=_Wg.selectSingleNode("./*[@"+ExpAPIXml.kEleElcid+"="+_amc+"]");if(!obj){obj=_Wg.selectSingleNode("./*["+ExpAPIXml.kEleElcid+"="+_amc+"]");}if(!obj){Debug.Assert(false);return null;}return obj;};CDLDataManager.prototype._wR=function(_Wz,_Wg){if(_o.is_ie5_5up){var _amc=Utilities.F_ToXPathString(_Wz,true);}else{var _amc=Utilities.F_ToXPathString(_Wz);}var obj=_Wg.selectSingleNode("./*[@"+ExpAPIXml.kEleElcid+"="+_amc+"]");var _avZ=null;if(!obj){obj=_Wg.selectSingleNode("./*["+ExpAPIXml.kEleElcid+"="+_amc+"]");}if(obj){_avZ=obj.nodeName;}else{_avZ=CDLDataManager.ObjectTypeMap[_Wz];if(!_avZ){_avZ=Dom.GetNodeTextShallow(_Wg,ExpAPIXml.kEleCmdAction);}if(!_avZ){Debug.Assert(false,"Unknown command target");_avZ="Unknown";}}return _avZ;};CDLDataManager.prototype._hP=function(_Wz){var obj=null;var _aGZ=CDLDataManager.ObjectTypeMap[_Wz];if(CDLDataManager.CategorizedObjectMap[_aGZ]){obj=CDLDataManager.CategorizedObjectMap[_aGZ][_Wz];}if(!obj){Debug.Assert(false,"could not find object");return null;}return obj;};CDLDataManager.prototype._bT=function(_Wg,_zR){Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CDLDataManager::_processCreateCommand"]);var _aky=Dom.GetImmediateChildByName(_Wg,ExpAPIXml.kEleCmdTarget);var _Wz=Dom.GetNodeText(_aky);var obj=this._n9(_Wz,_Wg);if(!obj){Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CDLDataManager::_processCreateCommand"]);return;}var _aCb=obj.nodeName;var id=_Wz;Debug.Assert(id!=null);switch(_aCb){case ExpAPIXml.kEleDescriptiveStats:this.setDescriptiveStats(obj);break;case ExpAPIXml.kEleLayout:var _95=new Object();_95[ExpAPIXml.kAttrFixedXtabColWidth]=this._aF?true:null;this.appobj.uiManager.CreateDefaultView(obj,_95);break;case ExpAPIXml.kEleWorksheet:var _alG=Dom.GetImmediateChildByName(obj,ExpAPIXml.kEleDataMatrix);var dm=null;if(_alG!=null){var _BV=Dom.GetNodeText(_alG);dm=this._iF[_BV];}var _acJ=new CDLWorksheet(dm,this);_acJ.Create(obj,id);var _am1=obj.getAttribute(ExpAPIXml.kAttrNoDataMode);if(_am1){_acJ._fD=(_am1===ExpAPIXml.kTrue);}this._wn[id]=_acJ;CDLDataManager.ObjectTypeMap[id]=ExpAPIXml.kEleWorksheet;break;case ExpAPIXml.kEleDataMatrix:if(this._iF[id]==null)this._iF[id]=new CDLDataMatrix(obj,this,id);this._iF[id].Create(obj);CDLDataManager.ObjectTypeMap[id]=ExpAPIXml.kEleDataMatrix;this.Notify(ExpEvent.kCDLDataManager_DataMatrixCreate);break;case ExpAPIXml.kEleCrosstab:if(this._pv[id]==null){this._pv[id]=new CDLCrosstab(this,id);}this._pv[id].Create(obj);CDLDataManager.ObjectTypeMap[id]=ExpAPIXml.kEleCrosstab;this.Notify(ExpEvent.kCDLCrosstab_Create);break;case ExpAPIXml.kEleMetadata:this.metadata=new CDLMetadata(this);this.metadata.Create(obj);break;case ExpAPIXml.kEleFilterSet:if(this.oFilterSetArray[id]==null){this.constructFilterSet(obj,id);}this.oFilterSetArray[id].Create(obj,id);CDLDataManager.ObjectTypeMap[id]=ExpAPIXml.kEleFilterSet;break;case ExpAPIXml.kEleChart:this._fz[id]=new CDLChart(this);this._fz[id].Create(obj);CDLDataManager.ObjectTypeMap[id]=ExpAPIXml.kEleChart;break;case ExpAPIXml.kEleCMFolder:var _C7=obj.getAttribute(ExpAPIXml.kEleElcid);if(this._kE[_C7]){this._kE[_C7].Merge(obj);}else if(this._ez&&this._ez[_C7]){this._ez[_C7].Merge(obj);}else{var _zM=obj.getAttribute(ExpAPIXml.eCMRootBase);if(_zM=="true"){if(_zR&&(_zR==this._o5._jj)){this._o5.PopulateRootsForTree(obj);}else{this._dE.PopulateRoots(obj);}}}break;case ExpAPIXml.kEleResource:break;case ExpAPIXml.kEleVersionInfo:this.setVersionInfo(obj);break;case ExpAPIXml.kEleAnalysis:this._kX=new CDLAnalysis(this);this.Notify(ExpEvent.kCDLDataManager_AnalysisCreate);this._kX.ProcessXML(obj);break;case ExpAPIXml.kEleMissing:this._vw=new CDLMissingData(this);this._vw.Create(obj);this.Notify(ExpEvent.kCDLDataManager_MissingDataCreate);break;default:throw new COTUnexpectedObjectException("Unexpected object in CDLDataManager::_processCreateCommand");}Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CDLDataManager::_processCreateCommand"]);};CDLDataManager.prototype.setDescriptiveStats=function(_Bk){var _Cz=this._i4.loadDSObject(_Bk);if(_Cz){this.descriptiveStatsInserted=true;}};CDLDataManager.prototype.setVersionInfo=function(_EM){var _as7=Dom.GetImmediateChildByName(_EM,ExpAPIXml.kEleBuildString);if(_as7){this._xb=Dom.GetNodeText(_as7);}var _2m=Dom.GetImmediateChildByName(_EM,ExpAPIXml.kEleApiVersion);if(_2m){this._pe=Dom.GetNodeText(_2m);}};CDLDataManager.prototype.constructFilterSet=function(_VY,id){this.oFilterSetArray[id]=new CDLWSFilterSet(this);this.oFilterSetArray[id].Init();this.Notify(ExpEvent.kCDLDataManager_CurrentWSFSChange);};CDLDataManager.prototype._cR=function(_Wg,_zR){Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CDLDataManager::_processMergeCommand"]);var _aky=Dom.GetImmediateChildByName(_Wg,ExpAPIXml.kEleCmdTarget);var _Wz=Dom.GetNodeText(_aky);var obj=this._n9(_Wz,_Wg);if(!obj){Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CDLDataManager::_processMergeCommand"]);return;}var _aCb=obj.nodeName;var id=_Wz;Debug.Assert(id!=null);switch(_aCb){case ExpAPIXml.kEleMember:var _azr=this.metadata.GetData(id);if(!_azr){_azr=this.metadata.AddOrphan(obj,id);}Debug.Assert(_azr!=null);if(_azr!=null){_azr.Merge(obj,_zR,true);}break;case ExpAPIXml.kEleHierarchy:var _VU=this.metadata.GetHierarchyById(id);Debug.Assert(_VU!=null);_VU.Merge(obj,_zR);break;case ExpAPIXml.kEleLevel:var _S8=this.metadata.GetLevel(id);Debug.Assert(_S8!=null);_S8.Merge(obj);break;case ExpAPIXml.kEleWorksheet:var ws=this._wn[id];Debug.Assert(ws!=null);ws.Merge(obj);break;case ExpAPIXml.kEleDataMatrix:var dm=this._iF[id];Debug.Assert(dm!=null);dm.Merge(obj);break;case ExpAPIXml.kEleFilterSet:var fs=this.oFilterSetArray[id];Debug.Assert(fs!=null);fs.Merge(obj);break;case ExpAPIXml.kEleMetadata:this.metadata.Merge(obj);break;case ExpAPIXml.kEleDimension:var _NR=this.metadata.GetDimById(id);Debug.Assert(_NR!=null);_NR.Merge(obj);break;default:throw new COTUnexpectedObjectException("Unexpected object in CDLDataManager::_processMergeCommand");}Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CDLDataManager::_processMergeCommand"]);};CDLDataManager.prototype._gv=function(_Wg){Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CDLDataManager::_processDataCommand"]);var _aky=Dom.GetImmediateChildByName(_Wg,ExpAPIXml.kEleCmdTarget);var _Wz=Dom.GetNodeText(_aky);var obj=this._hP(_Wz);obj.ProcessData(_Wg);Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CDLDataManager::_processDataCommand"]);};CDLDataManager.prototype._s9=function(_Wg){Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CDLDataManager::_processReplaceCommand"]);var _aky=Dom.GetImmediateChildByName(_Wg,ExpAPIXml.kEleCmdTarget);var _Wz=Dom.GetNodeText(_aky);var obj=this._n9(_Wz,_Wg);if(!obj){Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CDLDataManager::_processReplaceCommand"]);return;}var _aCb=obj.nodeName;var id=_Wz;Debug.Assert(id!=null);switch(_aCb){case ExpAPIXml.kEleDataMatrix:var dm=this._iF[id];if(dm!=null){dm.Replace(obj);}else{this._bT(_Wg);}break;case ExpAPIXml.kEleCrosstab:var oCrosstab=this._pv[id];if(oCrosstab!=null){oCrosstab.Replace(obj);}else{this._bT(_Wg);}break;case ExpAPIXml.kEleFilterSet:var _as2=this.oFilterSetArray[id];if(_as2!=null){_as2.Replace(obj);}else{this._bT(_Wg);}break;case ExpAPIXml.kEleMetadata:var _8B=this.metadata;if(_8B!=null){Debug.Assert(_8B._ks==id);_8B.Replace(obj);var _Rq=new Array(_8B,ExpEvent.kCDLMetadata_Replace);this.SetObjToStale(CDLDataManager.kMetadataReleaseToken,_Rq);}else{this._bT(_Wg);}break;case ExpAPIXml.kEleSearchResult:var _Xc=obj.getAttribute(ExpAPIXml.kEleSearchResultId);Debug.Assert(_Xc!=null);this._k5[_Xc].Replace(obj);break;case ExpAPIXml.kEleCMFolder:case ExpAPIXml.kEleCMAnalysis:case ExpAPIXml.kEleCMReportTemplate:var _C7=obj.getAttribute(ExpAPIXml.kEleElcid);if(this._kE[_C7]){this._kE[_C7].Replace(obj,true);}break;case ExpAPIXml.kEleChart:if(this._fz[id]){this._fz[id].Replace(obj);}else{this._fz[id]=new CDLChart(this);this._fz[id].Create(obj);}break;case ExpAPIXml.kEleWorksheet:this._wn[id].Create(obj,id);break;case ExpAPIXml.kEleAnalysis:if(this._kX!=null){this._kX.ProcessXML(obj);}else{this._bT(_Wg);}break;case ExpAPIXml.kEleMissing:if(this._vw!=null){this._vw.Replace(obj);}else{this._bT(_Wg);}break;default:throw new COTUnexpectedObjectException("Unexpected object in CDLDataManager::_processReplaceCommand");}Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CDLDataManager::_processReplaceCommand"]);};CDLDataManager.prototype._wh=function(_Wg){Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CDLDataManager::_processDeleteCommand"]);var _aky=Dom.GetImmediateChildByName(_Wg,ExpAPIXml.kEleCmdTarget);var _Wz=Dom.GetNodeText(_aky);var obj=this._n9(_Wz,_Wg);if(!obj){Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CDLDataManager::_processDeleteCommand"]);return;}var _aCb=obj.nodeName;var id=_Wz;Debug.Assert(id!=null);switch(_aCb){case ExpAPIXml.kEleChart:if(this._fz[id]){this._fz[id].Release();delete this._fz[id];this.Notify(ExpEvent.kCDLDataManager_ChartRefresh);}break;case ExpAPIXml.kCustomSet:this._kX.deleteCustomSet(id);this.Notify(ExpEvent.kCDLCustomSet_Deleted);break;case ExpAPIXml.kEleCMFolder:case ExpAPIXml.kEleCMAnalysis:case ExpAPIXml.kEleCMReportTemplate:var _C7=obj.getAttribute(ExpAPIXml.kEleElcid);Debug.Assert(_C7!=null);if(_C7!=""){this._kE[_C7].Release(true);}break;default:throw new COTUnexpectedObjectException("Unexpected object in CDLDataManager::_processDeleteCommand");}Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CDLDataManager::_processDeleteCommand"]);};CDLDataManager.prototype.UnSubscribe=function(obj,_Dy){if(this._e6&&this._e6[_Dy]){Utilities.DeleteFromArray(this._e6[_Dy],obj);}};CDLDataManager.prototype.Subscribe=function(obj,event){if(this._e6[event]){this._e6[event].push(obj);}if(event==ExpEvent.kCDLDataManager_DataMatrixCreate){for(var s in this._iF){this.Notify(ExpEvent.kCDLDataManager_DataMatrixCreate);}}if(event==ExpEvent.kCDLDataManager_CurrentWSFSChange){for(var s in this.oFilterSetArray){this.Notify(ExpEvent.kCDLDataManager_CurrentWSFSChange);}}if(event==ExpEvent.kCDLDataManager_AnalysisCreate){if(this._kX){this.Notify(ExpEvent.kCDLDataManager_AnalysisCreate);}}if(event==ExpEvent.kCDLCrosstab_Create){for(var s in this._pv){this.Notify(ExpEvent.kCDLCrosstab_Create);}}if(event==ExpEvent.kCDLDataManager_MissingDataCreate){if(this._vw){this.Notify(ExpEvent.kCDLDataManager_MissingDataCreate);}}};CDLDataManager.prototype.Notify=function(event){var _alZ=null;_alZ=this._e6[event];for(var i=0;_alZ&&i<_alZ.length;i++){_alZ[i].Notify(event);}};CDLDataManager.prototype.ClientPostProcessing=function(_G1){for(var i in this._mw){if(_G1==i){this.Notify(this._mw[i]);Utilities.RemoveObjXObjectArray(this._mw,i);}}};CDLDataManager.prototype.AddToPostProcessingStack=function(_G1,event){this._mw[_G1]=event;};CDLDataManager.CreateSetExpression=function(_OA,_Rb,_Us){var _atH=_c.CreateElement(ExpAPIXml.kEleFilterType,ExpAPIXml.kBlock);var _UR='';if(_Us){_UR=_c.CreateElement(ExpAPIXml.kEleFLPosition,_Us);}var _Hx=_c.CreateElement(ExpAPIXml.kEleAxisOpExprType,_OA);var _adE="";for(var i=0;i<_Rb.length;i++){var _aHg=_c.CreateElement(ExpAPIXml.kEleMemberPtr,_Rb[i]);var _asa=_c.CreateElement(ExpAPIXml.kEleMemberType,ExpAPIXml.kMemberTypeInherit);_adE+=_c.CreateElement(ExpAPIXml.kEleAxisExprMember,_aHg+_asa,true);}var _aE3=_c.CreateElement(ExpAPIXml.kEleMemberList,_adE,true);var _Fu=_c.CreateElement(ExpAPIXml.kEleAxisOpExpression,_Hx+_aE3,true);var _abt=_atH+_UR+_Fu;return _abt;};CDLDataManager.CreateSetExpressionFromBlock=function(_FK){var _atH=_c.CreateElement(ExpAPIXml.kEleFilterType,ExpAPIXml.kBlock);var _OA=_FK.IsHAMC()?ExpAPIXml.kAxisExprMemberset:ExpAPIXml.kAxisExprChildren;var _Hx=_c.CreateElement(ExpAPIXml.kEleAxisOpExprType,_OA);var _adE="";for(var i=0;i<_FK._nx.length;i++){var _aHg=_c.CreateElement(ExpAPIXml.kEleMemberPtr,_FK._nx[i]);var _asa=_c.CreateElement(ExpAPIXml.kEleMemberType,ExpAPIXml.kMemberTypeInherit);_adE+=_c.CreateElement(ExpAPIXml.kEleAxisExprMember,_aHg+_asa,true);}var _aE3=_c.CreateElement(ExpAPIXml.kEleMemberList,_adE,true);if(_FK.GetUserDefFLT()){_aE3+=_FK.GetUserDefFLT().GetAsXML(ExpAPIXml.kEleUserDefFilter);}if(_FK.GetSubset()){_aE3+=_FK.GetSubset().GetAsXML(ExpAPIXml.kEleSubset);}var _abt=_atH+_Hx+_aE3;return _abt;};CDLDataManager.prototype.GetAnalysis=function(){return this._kX;};CDLDataManager.prototype.InitDescriptiveStatsOptions=function(_Qx){this._i4.loadFromXML(_Qx);};CDLDataManager.prototype.GetDescriptiveStatsObj=function(){return this._i4;};function CDLParameter(_R7,_zO,_E7,_Rp){Debug.Assert(_R7!=null);Debug.Assert(_zO!=null);if(_zO instanceof CDLItem){_zO=_zO.GetAsXMLString();_E7=CDLParameter.XMLType();}this._sU=_R7;this._jU=_zO;this._lW=_E7;this._tt=_Rp;};CDLParameter.XMLType=function(){return "xml";};function CDLItemList(_V3){this._ba=_V3;};CDLItemList.prototype.GetAsXMLString=function(){if(this._ba.length==1){return this._ba[0].GetAsXMLString();}else{var _VE="";for(var i=0;i<this._ba.length;i++){_VE+=_c.CreateElement(ExpAPIXml.kEleValue,this._ba[i].GetAsXMLString(),true);}return _VE;}};function CDLItemTupleList(_Ue){this._cb=_Ue;};CDLItemTupleList.prototype.GetAsXMLString=function(){var _9e="";var _PM=null;for(var i=0;i<this._cb.length;i++){_PM=new CDLItem(this._cb[i].GetValue(),this._cb[i].GetType());var _Xu=_PM.GetAsXMLString();_Xu+=_c.CreateElement(ExpAPIXml.kEleBlockId,this._cb[i].GetBlockPtr());_9e+=_c.CreateElement(ExpAPIXml.kEleEntry,_Xu,true);}_VE=_c.CreateElement(ExpAPIXml.kEleTuple,_9e,true);return _VE;};function CDLItem(_Aa,_BF){this._nr=_Aa;this._dn=_BF;};CDLItem.prototype.GetAsXMLString=function(){var _VE=_c.CreateElement(ExpAPIXml.kEleObjectPtr,this._nr);_VE+=_c.CreateElement(ExpAPIXml.kEleObjectType,this._dn);_VE=_c.CreateElement(ExpAPIXml.kEleItem,_VE,true);return _VE;};function CDLActionItem(_Aa,_BF,_QK){this._nr=_Aa;this._dn=_BF;this._sS=_QK;};CDLActionItem.prototype.GetAsXMLString=function(){var _VE=_c.CreateElement(ExpAPIXml.kEleObjectPtr,this._nr);_VE+=_c.CreateElement(ExpAPIXml.kEleObjectType,this._dn);if(this._sS){for(var i in this._sS){_VE+=_c.CreateElement(i,this._sS[i]);}}_VE=_c.CreateElement(ExpAPIXml.kEleItem,_VE,true);return _VE;};function CDLActionItemList(_z8){this._o1=new Array();this._o1[0]=_z8;};CDLActionItemList.prototype.AddActionItem=function(_Aa,_BF){this._o1[this._o1.length]=new CDLActionItem(_Aa,_BF);};function CDLAction(){this.type="";this.position="";this._rY=new Array();this._vr=new Array();this._ct=new Array();};CDLAction.prototype.AddSource=function(_Aa,_BF,_QK){var _aaJ=new CDLActionItem(_Aa,_BF,_QK);var _aCU=new CDLActionItemList(_aaJ);this._ct[this._ct.length]=_aCU;return _aCU;};CDLAction.prototype.SetMemberMeasureSource=function(_B2,_Aa){var _YC="";if(_B2.GetMeasure(_Aa)){params=new Object();params["aggregateType"]=_B2.GetMeasure(_Aa).GetRegAggregateType();this.AddSource(_Aa,ExpAPIXml.kEleMeasure,params);_YC=ExpAPIXml.kEleMeasure;}else if(_B2.datamanager._kX.GetCustomSet(_Aa)){var _aja=this.AddSource(_B2.datamanager._kX._ks,ExpAPIXml.kEleAnalysis);_aja.AddActionItem(_Aa,ExpAPIXml.kCustomSet);_YC=ExpAPIXml.kCustomSet;}else if(_B2.GetNamedSet(_Aa)){var _aja=this.AddSource(_B2._ks,ExpAPIXml.kEleMetadata);_aja.AddActionItem(_Aa,ExpAPIXml.kEleNamedSet);_YC=ExpAPIXml.kEleNamedSet;}else{this.AddSource(_Aa,ExpAPIXml.kEleMember);_YC=ExpAPIXml.kEleMember;}return _YC;};CDLAction.prototype.SetBlockSource=function(_FK,_B2){if(_FK.oAxis){var _aaJ=new CDLActionItem(_FK.oAxis._rk.GetDataMatrixId(),ExpAPIXml.kEleDataMatrix);var _aCU=new CDLActionItemList(_aaJ);_aCU.AddActionItem(_FK.oAxis.GetId(),ExpAPIXml.kEleAxis);_aCU.AddActionItem(_FK.GetId(),ExpAPIXml.kEleAxisOpExpression);this._ct[this._ct.length]=_aCU;return _aCU;}var _Oj=_B2.datamanager._kX.GetCustomSetByBlockId(_FK.GetId());if(_Oj){var _aja=this.AddSource(_B2.datamanager._kX._ks,ExpAPIXml.kEleAnalysis);_aja.AddActionItem(_Oj.GetId(),ExpAPIXml.kCustomSet);_YC=ExpAPIXml.kCustomSet;return _aja;}Debug.Assert(false);return null;};CDLAction.prototype.SetObjptr=function(_Aa){this._eW("objptr",_Aa);};CDLAction.prototype.SetObjtype=function(_BF){this._eW("objtype",_BF);};CDLAction.prototype.SetPosition=function(_UR){this._eW("position",_UR);};CDLAction.prototype.AddParameter=function(_Gh){if(this._vr==null){this._vr=new Array();}this._vr.push(_Gh);};CDLAction.prototype._eW=function(_R7,_zO){if(this._vr==null){this._vr=new Array();}if(!(_zO instanceof CDLItem)){_zO=new String(_zO);}var _alO=new CDLParameter(_R7,_zO);this._vr[this._vr.length]=_alO;};CDLAction.prototype.AddTargetItem=function(_Qg,_BF){this._rY[this._rY.length]=new CDLItem(_Qg,_BF);};CDLAction.prototype.AddTarget=function(_LR){Debug.Assert(_LR instanceof CDLItem);this._rY.push(_LR);};CDLAction.prototype.GetAsXMLString=function(){var _abn="";var _acg=_c.CreateElement(ExpAPIXml.kActionType,this.type,true);var _afw=_c.CreateElement(ExpAPIXml.kName,ExpAPIXml.kSource,true);if(this._ct.length==1){var _zn='';for(var i=0;i<this._ct[0]._o1.length;i++){_zn+=this._ct[0]._o1[i].GetAsXMLString();}_afw+=_c.CreateElement(ExpAPIXml.kEleValue,_zn,true);_acg+=_c.CreateElement(ExpAPIXml.kParameter,_afw,true);}else if(this._ct.length>1){var _aeA='';for(var i=0;i<this._ct.length;i++){var _avW=this._ct[i];for(var j=0;j<_avW._o1.length;j++){var _FT=_avW._o1[j].GetAsXMLString();_aeA+=_c.CreateElement(ExpAPIXml.kEleValue,_FT,true);}}_afw+=_c.CreateElement(ExpAPIXml.kEleMultiValue,_aeA,true);_acg+=_c.CreateElement(ExpAPIXml.kParameter,_afw,true);}for(var i=0;i<this._vr.length;i++){var _apQ=this._vr[i];var _aEx=_c.CreateElement(ExpAPIXml.kName,_apQ._sU);if(_apQ._lW==CDLParameter.XMLType()&&_apQ._tt){_aEx+=_c.CreateElement(ExpAPIXml.kEleMultiValue,_apQ._jU,true);}else if(_apQ._lW==CDLParameter.XMLType()){_aEx+=_c.CreateElement(ExpAPIXml.kEleValue,_apQ._jU,true);}else{_aEx+=_c.CreateElement(ExpAPIXml.kEleValue,_apQ._jU);}_acg+=_c.CreateElement(ExpAPIXml.kParameter,_aEx,true);}var _Wz='';if(this._rY.length>0){for(var i=0;i<this._rY.length;i++){_Wz+=this._rY[i].GetAsXMLString();}_Wz=_c.CreateElement(ExpAPIXml.kEleCmdTarget,_Wz,true);}_abn=_c.CreateElement(ExpAPIXml.kEleCmdAction,_acg+_Wz,true);return _abn;};function CDLStatus(){this._ad=10;this._lk=new Array();this._lk[0]=new Object();this._lk[0].bOK=true;};CDLStatus.prototype.AddStatus=function(_J4,_Fv){var status=new Object();if(_J4){status.bOK=true;}else{status.bOK=false;status.sMsg=_Fv;}if(this._lk.length>=this._ad){for(var i=1;i<this._lk.length;i++){this._lk[i-1]=this._lk[i];}this._lk.length=this._lk.length-1;}this._lk[this._lk.length]=status;};CDLStatus.prototype.GetLastStatusOK=function(){return this._lk[this._lk.length-1].bOK;};CDLStatus.prototype.GetLastStatusMsg=function(){if(this._lk[this._lk.length-1].bOK){return "";}else{return this._lk[this._lk.length-1].sMsg;}};function CDLAnalysis(_U9){this._he=_U9;this._a8='';this._gH='';this._d0='';this._jG='';this._tG=false;this._nY='';this._dW='';this._f7='';this._u1='';this._tP='';this._jS='';this._jz='';this._h2=ExpAPIXml.kPortrait;this._di=ExpAPIXml.kDefaultPaper;this._eb=true;this._lf=null;this._mJ=false;this._wS=true;this._jK=true;this._ku=false;this._A=true;this._yr=false;this._so='';this._jT=false;this._os=new Object();this._ey=null;this._e6=new Array();this._e6[ExpEvent.kCDLAnalysis_Replace]=new Array();this._e6[ExpEvent.kCDLAnalysis_FailedResponse]=new Array();this._rs=true;this._lP=ExpAPIXml.kNoSuppressionOnRowsOrColumns;this._iS=null;;};CDLAnalysis.prototype.SetFullXtabRefresh=function(_TO){this._rs=_TO;};CDLAnalysis.prototype.IsFullXtabRefresh=function(){return this._rs;};CDLAnalysis.prototype.Subscribe=function(obj,event){if(this._e6[event]){this._e6[event].push(obj);}else{Debug.Assert(false,"Invalid event subscription");}};CDLAnalysis.prototype.UnSubscribe=function(obj,_Dy){if(this._e6&&this._e6[_Dy]){Utilities.DeleteFromArray(this._e6[_Dy],obj);}};CDLAnalysis.prototype.Notify=function(_Dy){if(this._e6[_Dy]){var _ahS=Utilities.CopyArray(this._e6[_Dy]);for(var i=0;i<_ahS.length;i++){_ahS[i].Notify(_Dy);}}};CDLAnalysis.prototype.GetProperty=function(_DI,_V6){var _arE=_DI.getAttribute(_V6);return _arE?_arE:'';};CDLAnalysis.prototype.resetPaperSizeResponse=function(){this._v6=false;};CDLAnalysis.prototype.ProcessXML=function(_DI){var _agL=Dom.GetImmediateChildByName(_DI,ExpAPIXml.kElePaperSizes);if(_agL){var _ame=Dom.GetElementsByTagName(_DI,ExpAPIXml.kElePaperSize);if(_ame.length>0){if(this._oR){Utilities.ClearObjectArray(this._oR);}this._oR=new Object();for(var i=0;i<_ame.length;i++){var _azs=_ame[i].getAttribute(ExpAPIXml.kEleName);var _aCM=_ame[i].getAttribute(ExpAPIXml.kEleValue);this._oR[_aCM]=_azs;}this._mn=true;this._v6=true;this.Notify(ExpEvent.kCDLAnalysis_Replace);}return;}if(this._c5){for(var i in this._c5){this._c5[i].Clear();}}var _aHu=_DI.getAttribute(ExpAPIXml.kEleElcid);Debug.Assert(_aHu!=null);if(_aHu){this._ks=_aHu;}this._d0=this.GetProperty(_DI,ExpAPIXml.kEleAnnotation);this._a8=this.GetProperty(_DI,ExpAPIXml.kEleTitle);this._gH=this.GetProperty(_DI,ExpAPIXml.kEleSubtitle);this._h2=this.GetProperty(_DI,ExpAPIXml.kElePaperOrientation);this._di=this.GetProperty(_DI,ExpAPIXml.kElePaperSize);this._jG=this.GetProperty(_DI,ExpAPIXml.kEleReportTemplate);this._tG=this.GetProperty(_DI,ExpAPIXml.kEleUseReportTemplate)=="true";this._jL=this.GetProperty(_DI,ExpAPIXml.kOutputPurpose);if(!this._jL){this._jL=ExpAPIXml.kPrintPurpose;}this._kp=(this.GetProperty(_DI,ExpAPIXml.kDisplayBreadcrumb)=="true");this._ld=false;var _2P=_DI.getAttribute(ExpAPIXml.kAttrRemainder);if(_2P=="true"){this._ld=true;}var _aFX=_DI.getAttribute(ExpAPIXml.kAttrRemainderMode);this._fS=_aFX?_aFX:ExpAPIXml.kNullRemainderMode;this._mX=false;var _aFj=_DI.getAttribute(ExpAPIXml.kAttrShowVisible);if(_aFj=="true"){this._mX=true;}this._fe=false;var _aFB=_DI.getAttribute(ExpAPIXml.kAttrFilterAggr);if(_aFB=="true"){this._fe=true;}this._q8=false;var _acQ=_DI.getAttribute(ExpAPIXml.kAttrPassedFilterAggr);if(_acQ=="true"){this._q8=true;}this._gJ=false;var _als=_DI.getAttribute(ExpAPIXml.kAttrSubTotal);if(_als=="true"){this._gJ=true;}this._fZ=true;var _ayK=_DI.getAttribute(ExpAPIXml.kAttrSummary);if(_ayK=="false"){this._fZ=false;}this._tj=this.GetProperty(_DI,ExpAPIXml.kEleDisplayFilter)=="true";this._lf=this.GetProperty(_DI,ExpAPIXml.kEleDisplayFilterPos);this._mJ=this.GetProperty(_DI,ExpAPIXml.kEleDisplayDataUpdatedOn)=="true";this._wS=this.GetProperty(_DI,ExpAPIXml.kEleDisplayWarningPage)=="true";this._jK=this.GetProperty(_DI,ExpAPIXml.kEleDisplayAllItems)=="true";this._ku=this.GetProperty(_DI,ExpAPIXml.kEleDisplayOutermostGroups)=="true";this._A=this.GetProperty(_DI,ExpAPIXml.kEleHorizontalPagination)=="false";this._yr=this.GetProperty(_DI,ExpAPIXml.kEleDisplaySections)=="true";if(this._yr&&this.GetProperty(_DI,ExpAPIXml.kEleDisplaySectionItem)){this._so=this.GetProperty(_DI,ExpAPIXml.kEleDisplaySectionItem);}this._jT=this.GetProperty(_DI,ExpAPIXml.kEleDisplaySetsOnRows)=="true";var _aum=Dom.GetImmediateChildByName(_DI,ExpAPIXml.kEleFormat);if(_aum){this._jS=_aum.getAttribute(ExpAPIXml.kEleWhenDivideZero);this._nY=_aum.getAttribute(ExpAPIXml.kEleWhenMissing);this._dW=_aum.getAttribute(ExpAPIXml.kEleWhenZero);this._f7=_aum.getAttribute(ExpAPIXml.kEleWhenSecurityError);this._u1=_aum.getAttribute(ExpAPIXml.kEleWhenNotApplicable);this._tP=_aum.getAttribute(ExpAPIXml.kEleWhenAnyError);this._jz=_aum.getAttribute(ExpAPIXml.kEleWhenNumericOverflow);}var _amS=Dom.GetImmediateChildByName(_DI,ExpAPIXml.kEleRunLocale);if(_amS){Decimal.displayDecimal=_amS.getAttribute(ExpAPIXml.kEleDecSep);Decimal.displayThousand=_amS.getAttribute(ExpAPIXml.kEleThouSep);}var _aj0=Dom.GetElementsByTagName(_DI,ExpAPIXml.kEleCalcDef);if(_aj0.length>0){if(this._vW){Utilities.ClearObjectArray(this._vW);}this._vW=new Object();}for(var i=0;i<_aj0.length;i++){var _aoe=_aj0[i].getAttribute(ExpAPIXml.kEleElcid);this._vW[_aoe]=new CDLCalcDef(_aj0[i],_aoe);}this._by=false;var _aCW=_DI.getAttribute(ExpAPIXml.kTreatZerosAsNullsForSuppression);this._by=(_aCW==ExpAPIXml.kTrue);this._lP=_DI.getAttribute(ExpAPIXml.kSuppressionState);if(this._he.IsInMissingMUNState()){return;}this._a0(_DI);if(Utilities.bSingleMemExpandEnabled){if(this._es){Utilities.DeleteAllFromArray(this._es);}this._es=new Array();}this._c5=new Object();var _aok=Dom.GetImmediateChildrenByName(_DI,ExpAPIXml.kEleAxisOpExpression);for(var i=0;i<_aok.length;i++){var _afP=_aok[i];var _Od=this.GetProperty(_afP,ExpAPIXml.kEleElcid);var _FK=new CDLBlock(_Od,null,this._he);_FK.ProcessXML(_afP);this._c5[_FK.sExprId]=_FK;}this._ey=(this._ey!=null)?Utilities.ClearObjectArray(this._ey):new Object();var _atc=Dom.GetElementsByTagName(_DI,ExpAPIXml.kCustomSet);for(var i=0;i<_atc.length;i++){this.CreateCustomSet(_atc[i]);}var _D1=Dom.GetImmediateChildByName(_DI,ExpAPIXml.kEleWidthData);if(_D1){this._iS=_D1;}this.Notify(ExpEvent.kCDLAnalysis_Replace);};CDLAnalysis.prototype._a0=function(_DI){Utilities.ClearObjectArray(this._os);var _RJ=this._he.metadata;var _4u=_DI.selectNodes(ExpAPIXml.kXPathExprCalc);for(var i=0;i<_4u.length;i++){var _H7=new CDLAxisCalc(_4u[i],_RJ);this.AddCalculation(_H7);}};CDLAnalysis.prototype.AddCalculation=function(_H7){var id=_H7._ks;this._os[id]=_H7;};CDLAnalysis.prototype.GetCalculationList=function(){return this._os;};CDLAnalysis.prototype.GetCalculation=function(_Fo){if(this._os[_Fo]){return this._os[_Fo];}return null;};CDLAnalysis.prototype.getBlock=function(_Od){return this._c5[_Od];};CDLAnalysis.prototype.GetId=function(){return this._ks;};CDLAnalysis.prototype.GetWhenMissing=function(){return this._nY;};CDLAnalysis.prototype.SetWhenMissing=function(_Q0){this._nY=_Q0;};CDLAnalysis.prototype.GetWhenZero=function(){return this._dW;};CDLAnalysis.prototype.SetWhenZero=function(_Ha){this._dW=_Ha;};CDLAnalysis.prototype.GetWhenSecurityError=function(){return this._f7;};CDLAnalysis.prototype.SetWhenSecurityError=function(_QM){this._f7=_QM;};CDLAnalysis.prototype.GetWhenNotApplicable=function(){return this._u1;};CDLAnalysis.prototype.SetWhenNotApplicable=function(_Ws){this._u1=_Ws;};CDLAnalysis.prototype.GetWhenAnyError=function(){return this._tP;};CDLAnalysis.prototype.SetWhenAnyError=function(_P5){this._tP=_P5;};CDLAnalysis.prototype.GetWhenDivideZero=function(){return this._jS;};CDLAnalysis.prototype.SetWhenDivideZero=function(_Cj){this._jS=_Cj;};CDLAnalysis.prototype.GetWhenNumericOverflow=function(){return this._jz;};CDLAnalysis.prototype.SetWhenNumericOverflow=function(_DM){this._jz=_DM;};CDLAnalysis.prototype.GetAnnotation=function(){return this._d0;};CDLAnalysis.prototype.GetTitle=function(){return this._a8;};CDLAnalysis.prototype.SetTitle=function(_KP){this._a8=_KP;};CDLAnalysis.prototype.GetSubtitle=function(){return this._gH;};CDLAnalysis.prototype.SetSubtitle=function(_RQ){this._gH=_RQ;};CDLAnalysis.prototype.GetSuppressionState=function(){return this._lP;};CDLAnalysis.prototype.GetReportTemplate=function(){return this._jG;};CDLAnalysis.prototype.SetReportTemplate=function(_A9){this._jG=_A9;};CDLAnalysis.prototype.GetUseReportTemplate=function(){return this._tG;};CDLAnalysis.prototype.SetUseReportTemplate=function(_FI){this._tG=(_FI==ExpAPIXml.kReportTemplate);};CDLAnalysis.prototype.SetPaperOrientation=function(_Up){this._h2=_Up;};CDLAnalysis.prototype.GetPaperOrientation=function(){return this._h2;};CDLAnalysis.prototype.IsPortraitOrientation=function(){return this._h2==ExpAPIXml.kPortrait;};CDLAnalysis.prototype.SetPaperSize=function(_Qc){this._di=_Qc;};CDLAnalysis.prototype.GetPaperSize=function(){return this._di;};CDLAnalysis.prototype.GetPaperSizeList=function(){return this._oR;};CDLAnalysis.prototype.GetPaperSizeName=function(_Mm){return this._oR[_Mm];};CDLAnalysis.prototype.DisplayFilters=function(){return this._tj;};CDLAnalysis.prototype.SetDisplayFilters=function(_Kw){this._tj=_Kw;};CDLAnalysis.prototype.DisplayFiltersAtEnd=function(){return this._lf==ExpAPIXml.kFiltersAtBottom;};CDLAnalysis.prototype.SetFilterDisplayPos=function(_UZ){this._lf=_UZ;};CDLAnalysis.prototype.DisplayDataUpdatedOn=function(){return this._mJ;};CDLAnalysis.prototype.DisplayWarningPage=function(){return this._wS;};CDLAnalysis.prototype.SetDisplayDataUpdatedOn=function(_MT){this._mJ=_MT;};CDLAnalysis.prototype.SetDisplayWarningPage=function(_Wk){this._wS=_Wk;};CDLAnalysis.prototype.DisplayAll=function(){return this._jK;};CDLAnalysis.prototype.SetDisplayAll=function(_UP){this._jK=_UP;};CDLAnalysis.prototype.FitPage=function(){return this._A;};CDLAnalysis.prototype.SetFitPage=function(_Et){this._A=_Et;};CDLAnalysis.prototype.DisplayOutermostGroups=function(){return this._ku;};CDLAnalysis.prototype.SetDisplayOutermostGroups=function(_Gu){this._ku=_Gu;};CDLAnalysis.prototype.DisplaySections=function(){return this._yr;};CDLAnalysis.prototype.SetDisplaySections=function(_M2){this._yr=_M2;};CDLAnalysis.prototype.SetDisplaySectionItem=function(_P2){this._so=_P2;};CDLAnalysis.prototype.GetDisplaySectionItem=function(){return this._so;};CDLAnalysis.prototype.GetDisplaySectionItemLabel=function(){var _aoY=this._he.GetCurrentWSFilterSet();if(this._so){return _aoY.GetFilterById(this._so).GetLabel();}return "";};CDLAnalysis.prototype.DisplaySetsOnRows=function(){return this._jT;};CDLAnalysis.prototype.SetDisplaySetsOnRows=function(_FV){this._jT=_FV;};CDLAnalysis.prototype.Clone=function(){var _CK=new CDLAnalysis(this._he);for(var i in this){_CK[i]=this[i];}return _CK;};CDLAnalysis.SafeOnModifyDisplaySections=function(_AT){/*@if(!@bering_debug)@*/try{/*@end@*/_AT._kX.ModifyDisplaySections(_AT._kX);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CDLAnalysis.prototype.ModifyDisplaySections=function(_JE){var _CK=_JE.Clone();_CK.SetDisplaySections(false);_JE.Modify(_CK);};CDLAnalysis.prototype.GetOutputPurpose=function(){return this._jL;};CDLAnalysis.prototype.SetOutputPurpose=function(_z6){this._jL=_z6;};CDLAnalysis.prototype.IsForPrint=function(){return(this._jL==ExpAPIXml.kPrintPurpose);};CDLAnalysis.prototype.GetDisplayBreadcrumb=function(){return this._kp;};CDLAnalysis.prototype.SetDisplayBreadcrumb=function(_Oh){this._kp=_Oh;};CDLAnalysis.SafeOnModifyGlobalSubtotals=function(_AT,_CK){/*@if(!@bering_debug)@*/try{/*@end@*/_AT._kX.ModifyGlobalSubtotals(_CK);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CDLAnalysis.prototype.ModifyGlobalSubtotals=function(_CK){var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionModify;_Jj.AddTargetItem(this._ks,ExpAPIXml.kEleAnalysis);_Jj.AddParameter(new CDLParameter(ExpAPIXml.kAttrSubTotal,String(_CK._gJ)));_Jj.AddParameter(new CDLParameter(ExpAPIXml.kAttrFilterAggr,String(_CK._fe)));_Jj.AddParameter(new CDLParameter(ExpAPIXml.kAttrPassedFilterAggr,String(_CK._q8)));_Jj.AddParameter(new CDLParameter(ExpAPIXml.kAttrRemainderMode,_CK._fS));_Jj.AddParameter(new CDLParameter(ExpAPIXml.kAttrRemainder,String(_CK._ld)));_Jj.AddParameter(new CDLParameter(ExpAPIXml.kAttrSummary,String(_CK._fZ)));_Jj.AddParameter(new CDLParameter(ExpAPIXml.kAttrShowVisible,String(_CK._mX)));var _AE=new Array();_AE.push(_Jj);var _aBj=this._he.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this._he.GetCurrentWorkSheet(),true);};CDLAnalysis.prototype.ToggleZeroSuppressType=function(_zx){var _8n=(_zx==ExpAPIXml.eNullAndZeroSuppress);var _aAk=this._he._kX._by;if(!_zx||(_8n!==_aAk)){var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionModify;_Jj.AddTargetItem(this._ks,ExpAPIXml.kEleAnalysis);var _Hx=(_aAk?ExpAPIXml.kFalse:ExpAPIXml.kTrue);_Jj.AddParameter(new CDLParameter(ExpAPIXml.kTreatZerosAsNullsForSuppression,_Hx,CDLParameter.XMLType()));var _AE=new Array();_AE.push(_Jj);var _aBj=this._he.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this._he.GetCurrentWorkSheet(),true);}};CDLAnalysis.prototype.ChangeZeroSuppression=function(_zx){var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionModify;_Jj.AddTargetItem(this._ks,ExpAPIXml.kEleAnalysis);_Jj.AddParameter(new CDLParameter(ExpAPIXml.kSuppressionState,_zx,CDLParameter.XMLType()));var _AE=new Array();_AE.push(_Jj);var _aBj=this._he.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this._he.GetCurrentWorkSheet(),true);};CDLAnalysis.prototype.Modify=function(_CK,_Le){var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionModify;_Jj.AddTargetItem(this._ks,ExpAPIXml.kEleAnalysis);if(_CK._nY!=this._nY){_Jj.AddParameter(new CDLParameter(ExpAPIXml.kEleWhenMissing,_CK._nY));}if(_CK._dW!=this._dW){_Jj.AddParameter(new CDLParameter(ExpAPIXml.kEleWhenZero,_CK._dW));}if(_CK._f7!=this._f7){_Jj.AddParameter(new CDLParameter(ExpAPIXml.kEleWhenSecurityError,_CK._f7));}if(_CK._u1!=this._u1){_Jj.AddParameter(new CDLParameter(ExpAPIXml.kEleWhenNotApplicable,_CK._u1));}if(_CK._tP!=this._tP){_Jj.AddParameter(new CDLParameter(ExpAPIXml.kEleWhenAnyError,_CK._tP));}if(_CK._jS!=this._jS){_Jj.AddParameter(new CDLParameter(ExpAPIXml.kEleWhenDivideZero,_CK._jS));}if(_CK._jz!=this._jz){_Jj.AddParameter(new CDLParameter(ExpAPIXml.kEleWhenNumericOverflow,_CK._jz));}if(_CK._a8!=this._a8){_Jj.AddParameter(new CDLParameter(ExpAPIXml.kEleTitle,_CK._a8));}if(_CK._gH!=this._gH){_Jj.AddParameter(new CDLParameter(ExpAPIXml.kEleSubtitle,_CK._gH));}if(_CK._jG!=this._jG){_Jj.AddParameter(new CDLParameter(ExpAPIXml.kEleReportTemplate,_CK._jG));}if(_CK._tG!=this._tG){_Jj.AddParameter(new CDLParameter(ExpAPIXml.kEleUseReportTemplate,String(_CK._tG)));}if(_CK._h2!=this._h2){_Jj.AddParameter(new CDLParameter(ExpAPIXml.kElePaperOrientation,_CK._h2));}if(_CK._di!=this._di){_Jj.AddParameter(new CDLParameter(ExpAPIXml.kElePaperSize,_CK._di));}if(_CK._tj!=this._tj){_Jj.AddParameter(new CDLParameter(ExpAPIXml.kEleDisplayFilter,String(_CK._tj)));}if(_CK._lf!=this._lf){_Jj.AddParameter(new CDLParameter(ExpAPIXml.kEleDisplayFilterPos,_CK._lf));}if(_CK._mJ!=this._mJ){_Jj.AddParameter(new CDLParameter(ExpAPIXml.kEleDisplayDataUpdatedOn,String(_CK._mJ)));}if(_CK._wS!=this._wS){_Jj.AddParameter(new CDLParameter(ExpAPIXml.kEleDisplayWarningPage,String(_CK._wS)));}if(_CK._jK!=this._jK){_Jj.AddParameter(new CDLParameter(ExpAPIXml.kEleDisplayAllItems,String(_CK._jK)));}var _ahF=false;if(_CK._yr!=this._yr){_Jj.AddParameter(new CDLParameter(ExpAPIXml.kEleDisplaySections,String(_CK._yr)));_ahF=_CK._yr;}if((_CK._so!=this._so)||_ahF){if(!_ahF){_Jj.AddParameter(new CDLParameter(ExpAPIXml.kEleDisplaySections,String(_CK._yr)));}var _LR=new CDLItem(_CK._so,ExpAPIXml.kEleFilter);_Jj.AddParameter(new CDLParameter(ExpAPIXml.kSource,_LR));}if(_CK._ku!=this._ku){_Jj.AddParameter(new CDLParameter(ExpAPIXml.kEleDisplayOutermostGroups,String(_CK._ku)));}if(_CK._A!=this._A){_Jj.AddParameter(new CDLParameter(ExpAPIXml.kEleHorizontalPagination,String(!_CK._A)));}if(_CK._jT!=this._jT){_Jj.AddParameter(new CDLParameter(ExpAPIXml.kEleDisplaySetsOnRows,String(_CK._jT)));}if(_CK._gJ!=this._gJ){_Jj.AddParameter(new CDLParameter(ExpAPIXml.kAttrSubTotal,String(_CK._gJ)));}if(_CK._fe!=this._fe){_Jj.AddParameter(new CDLParameter(ExpAPIXml.kAttrFilterAggr,String(_CK._fe)));}if(_CK._q8!=this._q8){_Jj.AddParameter(new CDLParameter(ExpAPIXml.kAttrPassedFilterAggr,String(_CK._q8)));}if(_CK._fS!=this._fS){_Jj.AddParameter(new CDLParameter(ExpAPIXml.kAttrRemainderMode,_CK._fS));}if(_CK._ld!=this._ld){_Jj.AddParameter(new CDLParameter(ExpAPIXml.kAttrRemainder,String(_CK._ld)));}if(_CK._fZ!=this._fZ){_Jj.AddParameter(new CDLParameter(ExpAPIXml.kAttrSummary,String(_CK._fZ)));}if(_CK._mX!=this._mX){_Jj.AddParameter(new CDLParameter(ExpAPIXml.kAttrShowVisible,String(_CK._mX)));}if(_CK._jL!=this._jL){_Jj.AddParameter(new CDLParameter(ExpAPIXml.kOutputPurpose,String(_CK._jL)));}if(_CK._kp!=this._kp){_Jj.AddParameter(new CDLParameter(ExpAPIXml.kDisplayBreadcrumb,String(_CK._kp)));}if(_Le){return _Jj;}if(_Jj._vr.length==0){return null;}var _AE=new Array();_AE.push(_Jj);var _aBj=this._he.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this._he.GetCurrentWorkSheet(),true);return null;};CDLAnalysis.prototype.GetCalcDef=function(_Lx){return this._vW[_Lx];};CDLAnalysis.prototype.SendCreateCustomSetReq=function(_BV,_TE,_JI,name,_z0){var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionCreate;_Jj.AddTargetItem(this.GetId(),ExpAPIXml.kEleAnalysis);var _aja=_Jj.AddSource(_BV,ExpAPIXml.kEleDataMatrix);_aja.AddActionItem(_TE,ExpAPIXml.kEleAxis);_aja.AddActionItem(_JI,ExpAPIXml.kEleAxisOpExpression);_Jj._eW(ExpAPIXml.kParamType,ExpAPIXml.kCustomSet);_Jj._eW(ExpAPIXml.kName,name);_Jj._eW(ExpAPIXml.kEleAnnotation,_z0);var _AE=new Array();_AE[0]=_Jj;var _aBj=this._he.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this._he.GetCurrentWorkSheet(),true);};CDLAnalysis.prototype.SendCreateCustomSetFromSelectedMembersReq=function(_C9,name,_z0){var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionCreate;_Jj.AddTargetItem(this.GetId(),ExpAPIXml.kEleAnalysis);for(var i=0;i<_C9.length;i++){_Jj.SetMemberMeasureSource(this._he.metadata,_C9[i]);}_Jj._eW(ExpAPIXml.kParamType,ExpAPIXml.kCustomSet);_Jj._eW(ExpAPIXml.kName,name);_Jj._eW(ExpAPIXml.kEleAnnotation,_z0);var _AE=new Array();_AE[0]=_Jj;var _aBj=this._he.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this._he.GetCurrentWorkSheet(),true);};CDLAnalysis.prototype.OverwriteCustomSet=function(_BV,_TE,_JI,_BT,_z0){var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionModify;_Jj.AddTargetItem(this.GetId(),ExpAPIXml.kEleAnalysis);_Jj.AddTargetItem(_BT,ExpAPIXml.kCustomSet);this.tmpActItemArr=new Array();this.tmpActItemArr[this.tmpActItemArr.length]=new CDLItem(_BV,ExpAPIXml.kEleDataMatrix);this.tmpActItemArr[this.tmpActItemArr.length]=new CDLItem(_TE,ExpAPIXml.kEleAxis);this.tmpActItemArr[this.tmpActItemArr.length]=new CDLItem(_JI,ExpAPIXml.kEleAxisOpExpression);var _alg='';for(var i=0;i<this.tmpActItemArr.length;i++){_alg+=this.tmpActItemArr[i].GetAsXMLString();}_Jj.AddParameter(new CDLParameter(ExpAPIXml.kSource,_alg,CDLParameter.XMLType()));_Jj._eW(ExpAPIXml.kEleAnnotation,_z0);var _AE=new Array();_AE[0]=_Jj;var _aBj=this._he.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this._he.GetCurrentWorkSheet(),true);};CDLAnalysis.prototype.OverwriteCustomSetFromSelectedMembers=function(_C9,_BT,_z0){var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionModify;_Jj.AddTargetItem(this.GetId(),ExpAPIXml.kEleAnalysis);_Jj.AddTargetItem(_BT,ExpAPIXml.kCustomSet);for(var i=0;i<_C9.length;i++){_Jj.SetMemberMeasureSource(this._he.metadata,_C9[i]);}_Jj._eW(ExpAPIXml.kEleAnnotation,_z0);var _AE=new Array();_AE[0]=_Jj;var _aBj=this._he.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this._he.GetCurrentWorkSheet(),true);};CDLAnalysis.prototype.SetDelCSId=function(_BT){this._rZ=_BT;};CDLAnalysis.prototype.GetDelCSId=function(){return this._rZ;};CDLAnalysis.prototype.GetCustomSet=function(_BT){if(!this._ey){return null;}return this._ey[_BT];};CDLAnalysis.prototype.GetCustomSetByBlockId=function(_L7){for(var i in this._ey){if(this._ey[i]._sBlockId==_L7){return this._ey[i];}}return null;};CDLAnalysis.prototype.CreateCustomSet=function(_RW){var id=_RW.getAttribute(ExpAPIXml.kEleElcid);Debug.Assert(id!=null);if(!this._ey[id]){this._ey[id]=new CDLCustomSet(this);}this._ey[id].Create(_RW);};CDLAnalysis.prototype.DeleteCustomSet=function(_BT){this.SetDelCSId(_BT);Utilities.RemoveObjXObjectArray(this._ey,_BT);};CDLAnalysis.prototype.SendDeleteCustomSetsReq=function(_NX){var _AE=new Array();for(var i=0;i<_NX.length;i++){var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionDelete;_Jj.AddTargetItem(this.GetId(),ExpAPIXml.kEleAnalysis);_Jj.AddTargetItem(_NX[i],ExpAPIXml.kCustomSet);_AE.push(_Jj);}var _aBj=this._he.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this._he.GetCurrentWorkSheet(),true);};CDLAnalysis.prototype.DoLoadCustomSetsFromCM=function(_TI){var _AE=new Array();var _Jj=new CDLAction();_Jj.type="loadcustomsets";_Jj.AddTargetItem(this.GetId(),ExpAPIXml.kEleAnalysis);_Jj._eW("path",_TI);_AE.push(_Jj);var _aBj=this._he.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this._he.GetCurrentWorkSheet(),true);};CDLAnalysis.prototype.SendRenameCSReq=function(_BT,_HM,_WB){var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionModify;_Jj.AddTargetItem(this.GetId(),ExpAPIXml.kEleAnalysis);_Jj.AddTargetItem(_BT,ExpAPIXml.kCustomSet);_Jj._eW(ExpAPIXml.kName,_HM);_Jj._eW(ExpAPIXml.kEleAnnotation,_WB);var _AE=new Array();_AE[0]=_Jj;var _aBj=this._he.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this._he.GetCurrentWorkSheet(),true);};CDLAnalysis.prototype.SendGetPaperSizeReq=function(){var _AE=new Array();var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionGetCMPaperSize;_AE[0]=_Jj;var _aBj=this._he.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this._he.GetCurrentWorkSheet(),true);};CDLAnalysis.prototype.SetStateFailed=function(){this.Notify(ExpEvent.kCDLAnalysis_FailedResponse);};CDLAnalysis.prototype.IsSubTotalEnabled=function(){return this._gJ;};CDLAnalysis.prototype.IsRemainderEnabled=function(){return this._ld;};CDLAnalysis.prototype.GetRemainderMode=function(){return this._fS;};CDLAnalysis.prototype.SetRemainderMode=function(_Sv){this._fS=_Sv;};CDLAnalysis.prototype.IsFilterAggregateEnabled=function(){return this._fe;};CDLAnalysis.prototype.IsPassedFilterAggregateEnabled=function(){return this._q8;};CDLAnalysis.prototype.ShowSummary=function(){return this._fZ;};CDLAnalysis.prototype.IsVisibleEnabled=function(){return this._mX;};CDLAnalysis.prototype.SetSubTotal=function(_Mj){this._gJ=_Mj;};CDLAnalysis.prototype.SetRemainder=function(_Mj){this._ld=_Mj;};CDLAnalysis.prototype.SetFilterAggregateEnabled=function(_Mj){this._fe=_Mj;};CDLAnalysis.prototype.SetPassedFilterAggregateEnabled=function(_Mj){this._q8=_Mj;};CDLAnalysis.prototype.SetSummary=function(_Mj){this._fZ=_Mj;};CDLAnalysis.prototype.GetWidthData=function(){return this._iS;};function CDLCustomSet(parent){this._eo=parent;this._ii=null;};CDLCustomSet.prototype.Create=function(_Gx){this._ks=_Gx.getAttribute(ExpAPIXml.kEleElcid);Debug.Assert(this._ks!=null);var _al8=_Gx.getAttribute(ExpAPIXml.kReqDefMeasure);Debug.Assert(_al8);this._ka=(_al8==ExpAPIXml.kTrue)?true:false;this._sBlockId=_Gx.getAttribute(ExpAPIXml.kEleAxisOpExprPtr);Debug.Assert(this._sBlockId!=null);var _FK=this.getBlock();Debug.Assert(_FK!=null);this._p8=_FK.GetBlockName();Debug.Assert(this._p8!=null);this._d0="";if(_FK.GetAnnotation()){this._d0=_FK.GetAnnotation();}var _Az=_Gx.getAttribute("sourcepath");this._ii=(_Az&&_Az!=='')?_Az:null;};CDLCustomSet.prototype.SetId=function(id){this._ks=id;};CDLCustomSet.prototype.GetId=function(){return this._ks;};CDLCustomSet.prototype.SetLabel=function(_BM){this._p8=_BM;};CDLCustomSet.prototype.SetAnnotation=function(_Bf){this._d0=_Bf;};CDLCustomSet.prototype.getBlock=function(){return this._eo.getBlock(this._sBlockId);};CDLCustomSet.prototype.GetLevelPtr=function(){return this.getBlock()._dl;};CDLCustomSet.prototype.IsMultiMemberSet=function(){return this.getBlock().IsMultiMemberSet();};CDLCustomSet.prototype.IsMemberSet=function(){return this.getBlock().IsMemberSet();};CDLCustomSet.prototype.IsHAMC=function(){return this.getBlock().IsHAMC();};CDLCustomSet.prototype.GetLastDataMemberId=function(){return this.getBlock().GetLastDataMemberId();};CDLCustomSet.prototype.GetMultiMemberIds=function(){return this.getBlock().GetMultiMemberIds();};CDLCustomSet.prototype.HasMeasures=function(){return this.getBlock().HasMeasures();};CDLCustomSet.prototype.GetMemberIds=function(){return this.getBlock()._nx;};CDLCustomSet.prototype.RequiresDefaultMeasure=function(){return this._ka;};CDLCustomSet.prototype.CanUseAsBlockFilter=function(){return this.getBlock().CanBeUsedAsContextFilter();};CDLCustomSet.prototype.CanUseOnAxis=function(){if(this.RequiresDefaultMeasure()&&!this._eo._he.GetCurrentDataMatrix().GetCurrentMeasure()){return false;}return true;};CDLCustomSet.prototype.GetDimensionLabel=function(){if(this.GetLastDataMemberId()){return this._eo._he.metadata.GetData(this.GetLastDataMemberId()).GetDim()._p8;}return this._eo._he.metadata._iR[this.GetDimId()]._p8;};CDLCustomSet.prototype.GetDimId=function(){return this.getBlock().GetDimId();};CDLCustomSet.prototype.GetSortOrder=function(){var _Co=this._eo._he.appobj.oResources;if(this.getBlock().IsAscending()){return _Co.GetString('IDS_CUSTOM_SET_SORT_ASCENDING');}else if(this.getBlock().IsExplicitSort()){return _Co.GetString('IDS_CUSTOM_SET_SORT_DESCENDING');}else{return _Co.GetString('IDS_CUSTOM_SET_SORT_DEFAULT');}};CDLCustomSet.prototype.IsFromOtherAnalysis=function(){return(this._ii!==null);};function CDLCalcDef(_Do,id){this._ks=id;this.eType=_Do.getAttribute(ExpAPIXml.kEleName);this.sLabel=_Do.getAttribute(ExpAPIXml.kEleLabel);};CDLCalcDef.prototype.IsRemainder=function(){if(this.eType==ExpAPIXml.eCalcRemainder){return true;}return false;};CDLCalcDef.prototype.IsSubtotal=function(){if(this.eType==ExpAPIXml.eCalcSubtotalVisibleItems){return true;}return false;};CDLCalcDef.prototype.IsFilterSubtotal=function(){if(this.eType==ExpAPIXml.eCalcFLAggregate){return true;}return false;};CDLCalcDef.prototype.IsPassedFilterSubtotal=function(){if(this.eType==ExpAPIXml.eCalcPassedFLAggregate){return true;}return false;};CDLCalcDef.prototype.IsSummary=function(){if(this.eType==ExpAPIXml.eCalcSummary){return true;}return false;};CDLCalcDef.prototype.GetType=function(){return this.eType;};function CDLDescriptiveStats(){this.commands=[];this.commandLabels=[];};CDLDescriptiveStats.prototype.GetCommandsList=function(){return this.commands;};CDLDescriptiveStats.prototype.GetCommandByLabel=function(_Bj){if(_Bj=="DESCRIPTIVES"||_Bj=="Boxplot"||_Bj=="Histogram"){return this.GetCommandByLabel("DescriptiveStats");}for(var i=0;i<this.commands.length;i++){if(this.commands[i].name==_Bj){return this.commands[i];}}return false;};CDLDescriptiveStats.prototype.GetCommandByIndex=function(_Re){if(!this.commands[_Re])return false;return this.commands[_Re];};CDLDescriptiveStats.prototype.loadDSObject=function(_Qx){var _adB=Dom.GetElementsByTagName(_Qx,"statstype")[0];var _6E=Dom.GetElementsByTagName(_Qx,"properties")[0];var _Uq=(_adB.text=="Boxplot"||_adB.text=="Histogram"||_adB.text=="DESCRIPTIVES")?true:false;var _Vc=this.GetCommandByLabel(_adB.text);if(!_Vc)return false;_Vc.SetElcid(_Qx.getAttribute("elcid"));var _aAX=_6E.selectNodes("property");for(var a=0;a<_aAX.length;a++){var _PK=_aAX[a];var _aFE=_PK.getAttribute("name");var _Bp=_PK.text;_Vc.SetPropertyValue(_aFE,_Bp,_Uq);}var _ajB=Dom.GetElementsByTagName(_Qx,"edges")[0];if(_ajB){var _atM=Dom.GetElementsByTagName(_ajB,"edge")[0];var _aBa=Dom.GetElementsByTagName(_atM,"tuples")[0];_Vc.SetTuppleString(_aBa.xml);}return true;};CDLDescriptiveStats.data={"plugin":{"commands":{"command":[{"name":"DescriptiveStats","label":"Descriptive Statistics","smallIcon":"group_statistics_descriptive.gif","description":"Provides basic statistics such as mean, variance and standard deviation. Results are returned in a table","propertyDefaults":{"defaultValue":[{"name":"Mean","value":"true"},{"name":"Display Order","value":"Variable List"}],"defaultValues":{"defaultValue":[{"value":"Std. deviation"},{"value":"Minimum"},{"value":"Maximum"}],"name":"Dispersion"}},"propertySheet":{"properties":{"group":{"property":[{"name":"DESCRIPTIVES","label":"Statistics","type":"boolean","col":"left","isCommand":"true"},{"name":"MEAN","label":"Mean","type":"boolean","relatedTo":"DESCRIPTIVES","col":"left","padding":"10px","value":""},{"name":"SUM","label":"Sum","type":"boolean","relatedTo":"DESCRIPTIVES","col":"left","padding":"10px","value":""},{"name":"Dispersion","label":"Dispersion","type":"label","col":"left","padding":"10px"},{"name":"Dispersion","label":"Std. Deviation","type":"boolean","relatedTo":"DESCRIPTIVES","col":"left","padding":"10px","value":"","propValue":"STDDEV"},{"name":"Dispersion","label":"Variance","type":"boolean","relatedTo":"DESCRIPTIVES","col":"left","padding":"10px","value":"","propValue":"VARIANCE"},{"name":"Dispersion","label":"Range","type":"boolean","relatedTo":"DESCRIPTIVES","col":"left","padding":"10px","value":"","propValue":"RANGE"},{"name":"Dispersion","label":"Minimum","type":"boolean","relatedTo":"DESCRIPTIVES","col":"left","padding":"10px","value":"","propValue":"MIN"},{"name":"Dispersion","label":"Maximum","type":"boolean","relatedTo":"DESCRIPTIVES","col":"left","padding":"10px","value":"","propValue":"MAX"},{"name":"Dispersion","label":"S.E. mean","type":"boolean","relatedTo":"DESCRIPTIVES","col":"left","padding":"10px","value":"","propValue":"SEMEAN"},{"name":"Boxplot","label":"Box Plot","type":"boolean","isCommand":"true","col":"middle"},{"name":"MISSING","label":"Missing Values Statistics and Cases","type":"list","listView":{"listItems":{"listItem":[{"value":"LISTWISE","label":"Exclude listwise"},{"value":"VARIABLEWISE","label":"Exclude variablewise"}]},"multiSelect":"true"},"relatedTo":"Boxplot","padding":"25px","col":"middle","value":"LISTWISE"},{"name":"REPORTMISSING","label":"Missing Values for Break Variables","type":"list","listView":{"listItems":{"listItem":[{"value":"NO","label":"Exclude"},{"value":"YES","label":"Include"}]},"multiSelect":"true"},"relatedTo":"Boxplot","padding":"25px","col":"middle","value":"NO"},{"name":"Histogram","label":"Histogram","type":"boolean","isCommand":"true"},{"name":"Distribution","label":"Distribution Curve","type":"list","value":"density.normal","listView":{"listItems":{"listItem":[{"value":"density.normal","label":"NORMAL"},{"value":"density.beta","label":"Beta"},{"value":"density.chiSquare","label":"Chi-Square"},{"value":"density.exponential","label":"Exponential"},{"value":"density.f","label":"F distribution"},{"value":"density.gamma","label":"Gamma"},{"value":"density.kernel","label":"Kernel"},{"value":"density.logistic","label":"Logistic"},{"value":"density.poisson","label":"Poisson"},{"value":"density.studentizedRange","label":"Studentized Range"},{"value":"density.t","label":"T Distribution"},{"value":"density.uniform","label":"Uniform"},{"value":"density.weibull","label":"Weibull"}]},"multiSelect":"true"},"relatedTo":"Histogram","padding":"25px"},{"name":"BarStyle","label":"Bar Style","type":"list","value":"shape.square","listView":{"listItems":{"listItem":[{"value":"shape.square","label":"Bar"},{"value":"shape.ibeam","label":"I-Beam"},{"value":"shape.line","label":"Whisker"}]},"multiSelect":"true"},"relatedTo":"Histogram","padding":"25px"},{"name":"MISSING","label":"Missing Values Statistics and Cases","type":"list","value":"LISTWISE","listView":{"listItems":{"listItem":[{"value":"LISTWISE","label":"Exclude listwise"},{"value":"VARIABLEWISE","label":"Exclude variablewise"}]},"multiSelect":"true"},"relatedTo":"Histogram","padding":"25px"},{"name":"REPORTMISSING","label":"Missing Values for Break Variables","type":"list","value":"NO","listView":{"listItems":{"listItem":[{"value":"NO","label":"Exclude"},{"value":"YES","label":"Include"}]},"multiSelect":"true"},"relatedTo":"Histogram","padding":"25px"}],"hide":"true"}}}},{"name":"CurveEstimationCases","label":"Curve Estimation Cases","smallIcon":"regressionLine.gif","description":"Calculates curve fits. Results are shown in variable tables and a chart.","propertySheet":{"properties":{"group":{"property":[{"listView":{"listItems":{"listItem":[{"name":"LINEAR","label":"Linear"},{"name":"LOGRITHMIC","label":"Logrithmic"},{"name":"INVERSE","label":"Inverse"},{"name":"QUADRATIC","label":"Quadratic"},{"name":"CUBIC","label":"Cubic"},{"name":"POWER","label":"Power"},{"name":"S","label":"S"},{"name":"GROWTH","label":"Growth"},{"name":"EXPONENTIAL","label":"Exponential"},{"name":"LOGISTIC","label":"Logistic","tooltip":"Enables upper bound."}]},"multiSelect":"true"},"name":"MODEL","label":"Models"},{"name":"UPPERBOUND","label":"Logistic Upper Bound: ","type":"text","dataType":"decimal","description":"Only valid if logistic is selected from models.","relatedTo":"Logistic"},{"name":"ANOVA","label":"Display ANOVA Table","type":"boolean"},{"name":"CONSTANT","label":"Include Constant in Equation","type":"boolean"},{"name":"PLOT","label":"Plot Models","type":"boolean"}],"hide":"true"}}}},{"name":"CurveEstimationIndependent","label":"Curve Estimation Independent","smallIcon":"regressionLine.gif","description":"Calculates curve fits. Results are shown in variable tables and a chart.","propertySheet":{"properties":{"group":{"property":[{"listView":{"listItems":{"listItem":[{"name":"LINEAR","label":"Linear"},{"name":"LOGRITHMIC","label":"Logrithmic"},{"name":"INVERSE","label":"Inverse"},{"name":"QUADRATIC","label":"Quadratic"},{"name":"CUBIC","label":"Cubic"},{"name":"POWER","label":"Power"},{"name":"S","label":"S"},{"name":"GROWTH","label":"Growth"},{"name":"EXPONENTIAL","label":"Exponential"},{"name":"LOGISTIC","label":"Logistic","tooltip":"Enables upper bound."}]},"multiSelect":"true"},"name":"Models","label":"Models"},{"name":"UPPERBOUND","label":"Logistic Upper Bound: ","type":"text","dataType":"decimal","description":"Only valid if logistic is selected from models.","relatedTo":"Logistic"},{"name":"ANOVA","label":"Display ANOVA Table","type":"boolean"},{"name":"CONSTANT","label":"Include Constant in Equation","type":"boolean"},{"name":"PLOT","label":"Plot Models","type":"boolean"}],"hide":"true"}}}},{"name":"Regression","label":"Regression","smallIcon":"regressionLine.gif","description":"","propertySheet":{"properties":{"group":{"property":[{"listView":{"listItems":{"listItem":[{"value":"data","label":"Histogram"},{"value":"range","label":"Box Plot"}]}},"name":"ExpectedRange","label":"Expected Range"},{"name":"Lower","label":"Lower","type":"text","dataType":"decimal"},{"name":"Upper","label":"Upper","type":"text","dataType":"decimal"}],"hide":"true"}}}}]},"name":"cognos_stats"}};CDLDescriptiveStats.prototype.loadFromXML=function(_Qx){var _F6=CDLDescriptiveStats.data.plugin;if(_F6.commands){var _aEJ=_F6.commands.command;for(var i=0;i<_aEJ.length;i++){var _Vc=_F6.commands.command[i];var _ay2=new CDLDescriptiveStatsObj(_Vc);this.commands.push(_ay2);this.commandLabels.push(_ay2.GetLabel());}}return;var _aoX=Dom.GetElementsByTagName(_Qx,"commands");var _aEJ=_aoX[0];var _aue=Dom.GetElementsByTagName(_Qx,'plugin');if(_aue.length==1){var _aix=Dom.GetImmediateChildByNameNoNS(_aue[0],'commands');var _TC=_aix.selectNodes("command");for(var i=0;i<_TC.length;i++){var _Vc=_TC[i];var _ay2={};_ay2['name']=_Vc.getAttribute("name");_ay2['label']=_Vc.getAttribute("label");_ay2['icon']=_Vc.getAttribute("smallIcon");_ay2['description']=_Vc.getAttribute("description");_ay2['propDlg']=null;var _avq=_Vc.selectNodes("dialog");var _9l={};if(_avq.length>0){var _5y=[];var title=_avq[0].getAttribute("dialogTitle");var _9l=_avq[0].selectNodes("propertySheet");var _6E=_9l[0].selectNodes("properties");var _aEF=_6E[0].selectNodes("group");var _ahM=_aEF[0].selectNodes("property");for(var p=0;p<_ahM.length;p++){var _PK=_ahM[p];var _aft={};_aft.name=_PK.getAttribute("name");_aft.label=_PK.getAttribute("label");_aft.type=(_PK.getAttribute("type"))?_PK.getAttribute("type"):"listview";var _ahT=_PK.selectNodes("listView");if(_ahT.length>0){_aft.type="listview";_aft.list=[];var _6a=_ahT[0].selectNodes("listItems");for(var l=0;l<_6a.length;l++){var _aor=_6a[0];var _zc=_aor.selectNodes("listItem");for(var item=0;item<_zc.length;item++){var _adu={};_adu.value=_zc[item].getAttribute("value");_adu.label=_zc[item].getAttribute("label");_aft.list.push(_adu);}}}_5y.push(_aft);}_ay2['prop']=_5y;}this.commands.push(_ay2);this.commandLabels.push(_ay2.label);}}};function CDLDescriptiveStatsObj(_zz){this.description=null;this.label='';this.name='';this.smallIcon='';this.prop=[];this.selection=null;if(_zz){this.init(_zz);}};CDLDescriptiveStatsObj.prototype.init=function(_zz){this.description=_zz.description;this.label=_zz.label;this.name=_zz.name;this.icon=_zz.smallIcon;if(_zz.propertySheet.properties){this.prop=_zz.propertySheet.properties.group.property;}this.tupleString="";this.elcid=0;this.FixProperties();};CDLDescriptiveStatsObj.prototype.FixProperties=function(){if(this.prop){for(var i=0;i<this.prop.length;i++){if(!this.prop[i].type){this.prop[i].type="listview";}}}};CDLDescriptiveStatsObj.prototype.SetPropertyValue=function(_Bq,_Bp,_Uq){if(_Bq=="commandLabel"){_Bq=_Bp;_Bp=true;}if(this.prop){for(var i=0;i<this.prop.length;i++){if(this.prop[i].name==_Bq){var _atT=this.prop[i];switch(_atT.type){case 'boolean':if(_Uq){if(_atT.propValue&&_atT.propValue==_Bp){_atT['value']=true;}else if(_atT.name==_Bq){_atT['value']=true;}}else{_atT['value']=true;}break;case 'listview':var _alD=_atT.listView.listItems.listItem;for(var j=0;j<_alD.length;j++){if(_alD[j].name==_Bp){_alD[j].value=true;}}break;case 'text':_atT['value']=_Bp;break;}}}}};CDLDescriptiveStatsObj.prototype.UpdateObjProperty=function(_PK){};CDLDescriptiveStatsObj.prototype.GetLabel=function(){return this.label;};CDLDescriptiveStatsObj.prototype.GetProperties=function(){return this.prop;};CDLDescriptiveStatsObj.prototype.SetElcid=function(id){this.elcid=id;};CDLDescriptiveStatsObj.prototype.GetElcid=function(){return this.elcid;};CDLDescriptiveStatsObj.prototype.SetSelection=function(_V7){this.selection=_V7;this.SetTuppleStringFromSelection(this.selection);};CDLDescriptiveStatsObj.prototype.SetTuppleString=function(_Db){this.tupleString=_Db;};CDLDescriptiveStatsObj.prototype.SetTuppleStringFromSelection=function(_TJ){var _ale=_TJ._us;var _aBa="";for(var c=0;c<_ale.length;c++){var _Eq=_ale[c];var _Bj=_Eq._f1._gQ;var _UY=_Eq._f1.GetMemberId();var _Aa=_c.CreateElement("objptr",_UY,true);var _BF=_c.CreateElement("objtype",_Bj,true);var _zc=_c.CreateElement("item",_Aa+_BF,true);_aBa+=_c.CreateElement("tuple",_zc,true);}var _Db=_c.CreateElement("tuples",_aBa,true);this.tupleString=_Db;};CDLDescriptiveStatsObj.prototype.GetTuple=function(){return this.tupleString;};CDLDescriptiveStatsObj.prototype.GetPropXMLFor=function(_HG){var _PK=this.prop;var _X1="";for(var i=0;i<_PK.length;i++){var _atT=_PK[i];if(_atT.relatedTo==_HG){var _atR=new Object();_atR['name']=_atT.name;if(_atT.type=="radio"&&_atT.value==true){_atR['name']=_atT.propValue;_X1+=_c.CreateElement("property",_atT.value,true,_atR);}else if(_atT.type=="boolean"&&_atT.propValue!=null&&_atT.value==true){_atT.value=_atT.propValue;_X1+=_c.CreateElement("property",_atT.value,true,_atR);}else if(_atT.name=="Distribution"&&_atT.type=="list"&&_atT.value){_atR['name']=_atT.value;_atT.value=true;_X1+=_c.CreateElement("property",_atT.value,true,_atR);}else if(_atT.type!="radio"&&_atT.value){_X1+=_c.CreateElement("property",_atT.value,true,_atR);}}}return _X1;};CDLDescriptiveStatsObj.prototype.GetDescriptiveStatsCommand=function(){var _PK=this.prop;var _2K="";for(var i=0;i<_PK.length;i++){var _atT=_PK[i];if(_atT.isCommand&&_atT.value){var _adB=_c.CreateElement("statstype",_atT.name,true);var _X1="";var _atR=new Object();_atR['name']="commandLabel";_X1+=_c.CreateElement("property",_atT.name,true,_atR);_X1+=this.GetPropXMLFor(_atT.name);var _6E=_c.CreateElement("properties",_X1,true);_2K+=_c.CreateElement("statisticscommand",_adB+_6E,true);}}return _2K;};function CDLDataMatrix(_UL,_VP,_C7){this._he=_VP;this._ks=_C7;this._e6=new Array();this._e6[ExpEvent.kCDLDataMatrix_FullRefresh]=new Array();this._e6[ExpEvent.kCDLDataMatrix_AxisCreation]=new Array();var _9p=Dom.GetImmediateChildByName(_UL,ExpAPIXml.kEleScratchPad);if(_9p!=null){var _Yl=Dom.GetNodeText(_9p);if(_Yl==ExpAPIXml.kTrue){this._iy=ExpAPIXml.kTrue;}else{this._iy=ExpAPIXml.kFalse;}}else{this._iy=ExpAPIXml.kFalse;}this._wG=null;this._e3=new Date();this._c6=null;this._d4=new Object();this._x3=new Object();this._he._kX.Subscribe(this,ExpEvent.kCDLAnalysis_Replace);};CDLDataMatrix.prototype.GetDataMatrixId=function(){return this._ks;};CDLDataMatrix.prototype.IsScratchPadDataMatrix=function(){if(this._iy==ExpAPIXml.kTrue){return true;}else{return false;}};CDLDataMatrix.prototype.GetNodeLabel=function(_Lx){var _aqk=this._he.metadata.GetData(_Lx);var _BM="";if(_aqk){_BM=_aqk.GetLabel();}else{_BM=this.GetCalculation(_Lx).GetLabel();}return _BM;};CDLDataMatrix.prototype.GetBlockProxy=function(_FK){if(this._x3[_FK.GetId()]){return this._x3[_FK.GetId()];}else{this._x3[_FK.GetId()]=_FK.Clone();return this._x3[_FK.GetId()];}};CDLDataMatrix.prototype.RemoveProxy=function(_TZ){if(_TZ&&(this._x3[_TZ.GetId()])){delete this._x3[_TZ.GetId()];}};CDLDataMatrix.prototype.GetAllBlocksArray=function(){var _I3=new Array();for(var i=0;i<this.GetAxisCount();i++){_I3=_I3.concat(this.GetAxis(i).GetAllBlocksArray());}return _I3;};CDLDataMatrix.prototype.GetAllMeasureIds=function(){var _at5=new Object();for(var i=0;i<this.GetAxisCount();i++){var _O0=this.GetAxis(i);var _I3=_O0.GetAllBlocks();for(var _Lx in _I3){if(_I3[_Lx].HasMeasures()){var _F7=_O0.GetAllNodesInBlock(_I3[_Lx]);for(var i=0;i<_F7.length;i++){if(this._he.metadata.GetMeasure(_F7[i].GetMemberId())){_at5[_F7[i].GetMemberId()]=true;}}}}}return _at5;};CDLDataMatrix.prototype.GetAllMeasuresAndMeasureCalcs=function(_KJ){Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CDLDataMatrix::GetAllMeasuresAndMeasureCalcs"]);var _aho=new Object();for(var i=0;i<this.GetAxisCount();i++){var _O0=this.GetAxis(i);var _I3=_O0.GetAllBlocks();for(var _Lx in _I3){if(_I3[_Lx].HasMeasures()){var _F7=_O0.GetAllNodesInBlock(_I3[_Lx]);for(var j=0;j<_F7.length;j++){if(_F7[j].IsCalc()){if(_F7[j].IsDynamicCalc()){continue;}else{if(_KJ&&(!_F7[j].CanBeUsedInFilter())){continue;}if(!this.GetCalculation(_F7[j].GetMemberId()).CanUseAsMeasure()){continue;}}}_aho[_F7[j].GetMemberId()]=_F7[j].GetLabel();}}}}Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CDLDataMatrix::GetAllMeasuresAndMeasureCalcs"]);return _aho;};CDLDataMatrix.prototype.Create=function(_UL){Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CDLDataMatrix::Create"]);if(this._c6==null){this._c6=new Array();}if(_UL.childNodes.length>0&&!this._he.IsInMissingMUNState()){this._xy(_UL);this.SetDataMode(_UL);this._h9(_UL);this._e3=new Date();if(Utilities.bDiffMiningEnabled){this.handleDiffMining(_UL);}}Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CDLDataMatrix::Create"]);};CDLDataMatrix.prototype.handleDiffMining=function(_UL){var _7o=Dom.GetImmediateChildByName(_UL,"DiffMiningResp");if(_7o){this.bShowDiffMiningDlg=true;this.oDiffMiningResult=new Object();var _0U=Dom.GetImmediateChildByName(_7o,"diffResult");var _aCx=Dom.GetNodeText(_0U);var _avV=eval(_aCx);this.oDiffMiningResult.diffResult=_avV;Debug.Assert(this.oDiffMiningResult.diffResult);var _aAc=Dom.GetImmediateChildByName(_7o,"resultInfo");var _adM=Dom.GetNodeText(_aAc);_avV=eval(_adM);this.oDiffMiningResult.resultInfo=_avV;Debug.Assert(this.oDiffMiningResult.resultInfo);var _avQ=Dom.GetImmediateChildByName(_7o,"templateHls");var _aza=Dom.GetNodeText(_avQ);this.oDiffMiningResult.templateHls=_aza;Debug.Assert(this.oDiffMiningResult.templateHls);}};CDLDataMatrix.prototype.showDiffMiningDlg=function(){this.oDiffMiningDlg=null;this.oDiffMiningDlg=new CUIDiffMiningResultDlg(this.oDiffMiningResult);this.oDiffMiningDlg.Init(this._he.appobj.uiManager.oDialogMgr);this.oDiffMiningDlg.Display();};CDLDataMatrix.prototype.showAnalyzeDiffDlg=function(_Dz,_Fz,_DA,_Fy){this.oAnalyzeDiffDlg=null;this.oAnalyzeDiffDlg=new CUIAnalyzeDifferencesDlg(_Dz,_Fz,_DA,_Fy);this.oAnalyzeDiffDlg.Init(this._he.appobj.uiManager.oDialogMgr);this.oAnalyzeDiffDlg.Display();};CDLDataMatrix.prototype.Notify=function(_Dy){if(_Dy==ExpEvent.kCDLAnalysis_Replace){for(var i=0;i<this._c6.length;i++){this._c6[i].UpdateBlocks();}}for(var i=0;this._e6[_Dy]&&i<this._e6[_Dy].length;i++){this._e6[_Dy][i].Notify(_Dy);}};CDLDataMatrix.prototype.ClearData=function(_Vx,_Od,_UB){Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CDLDataMatrix::ClearData "]);for(var i=0;i<this._c6.length;i++){this._c6[i].ClearMembers(_Vx,_Od,_UB);}Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CDLDataMatrix::ClearData "]);};CDLDataMatrix.prototype.ProcessData=function(_NA,_Vx,_Od){Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CDLDataMatrix::ProcessData"]);var _UB=true;this.ClearData(_Vx,_Od,_UB);if(!_NA){Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CDLDataMatrix::ProcessData"]);return;}/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oProcessData.StartTimer(true);}/*@end@*/var _ahi=_NA.selectNodes(ExpAPIXml.kEleAxisData);var _aJN=_ahi.length;var oCrosstab=this._he.GetCurrentCrosstab();for(var i=0;i<_aJN;i++){var _aGd=_ahi[i];var _aIR=Dom.GetNodeTextShallow(_aGd,ExpAPIXml.kEleAxisPtr);if(!_aIR){throw new COTBadResponseException("axisdata element is missing elcid value.");}var _axd=Dom.GetNodeTextShallow(_aGd,ExpAPIXml.kEleRowCurrentPage);if(_axd!==''){oCrosstab.SetCurrentRowPageNumber(_axd);}var _aIS=Dom.GetNodeTextShallow(_aGd,ExpAPIXml.kEleRowLastPage);if(_aIS!==''){oCrosstab.SetLastRowPageNumber(_aIS);}var _4i=Dom.GetNodeTextShallow(_aGd,ExpAPIXml.kEleColCurrentPage);if(_4i!==''){oCrosstab.SetCurrentColPageNumber(_4i);}var _aIb=Dom.GetNodeTextShallow(_aGd,ExpAPIXml.kEleColLastPage);if(_aIb!==''){oCrosstab.SetLastColPageNumber(_aIb);}if(_aGd==null){continue;}var _auq=null;var _WS=false;var _T7=false;for(var j=0;j<this._c6.length&&!_WS;j++){var _afm=this._c6[j];if(_afm._ks==_aIR){_WS=true;_auq=_afm;_T7=(j==0)?true:false;}}var _aJa=(_Vx||(!_auq.HasProperitesDisplayed()));if(!_WS){Debug.Assert(false,"Trying to add data to an axis that doesn't exist");continue;}var _Zd=Dom.GetImmediateChildByName(_aGd,ExpAPIXml.kEleNode);if(_Zd==null){continue;}var _VV=null;if(_Vx){_auq._wf=new CDLAxisData(_auq,_Od);_VV=_auq._wf;}else{_auq._o3=new CDLAxisData(_auq,_Od);_VV=_auq._o3;}var _7m=new CDLAxisMember(this._he,this,_VV,_Zd);_VV.SetFirstMember(_7m);var _aId=_7m;_VV._av=1;_aId._av=0;var _adT=Dom.GetTreeWalker(_aGd);if(_adT.MoveToNextTargetNode(ExpAPIXml.kEleNode)==DomTreeWalker.eNoNext){continue;}while(!_adT.AtEnd()){var _RN=_adT.GetElement();if(this._rb(_RN)){_VV._gh[_VV._gh.length]=_aId;if(_T7&&(!_aJa)){_VV._iq[_VV._gh.length-1]=_aId.GetPropertyCount();}}else if((!_T7)&&(!_aJa)){_aId.UpdateExtraLineCountInSameRow();}var _ayU=_adT.MoveToNextTargetNode(ExpAPIXml.kEleNode);_RN=_adT.GetElement();if(_RN==null){if(!_aJa){if(_T7){while(_aId._qR){_aId=_aId._qR;if(_aId.GetPropertyCount()+1>_aId._kk){_aId.ReDistributeContentHeights();}}}else{var _axx=null;for(var _adP=0;_adP<_VV._gh.length;_adP++){var _7D=_VV._gh[_adP];if(_7D._av<(_VV._av-1)){if(!_axx){_axx=_7D;}else if(_axx.GetPropertyCount()<_7D.GetPropertyCount()){_axx=_7D;}continue;}else{_7D.UpdateExtraLineCountInSameRow();}}if(_axx){var _aaf=_axx.GetPropertyCount();var _ak8=_VV._iq[_axx._av];var _4M=_VV._av-1-_axx._av;var _aaG=_aaf+1;for(iRowIdx=_axx._av;iRowIdx<_VV._av;iRowIdx++){_aaG-=(_VV._iq[iRowIdx]+1);if(_aaG<0){break;}}if(_aaG>0){for(iStartRowIdx=_axx._av;iStartRowIdx<_VV._av;iStartRowIdx++){_VV._iq[iStartRowIdx]+=_aaG/(_4M+1);}}}}}break;}switch(_ayU){case DomTreeWalker.eChild:var parent=_aId;var axisMember=new CDLAxisMember(this._he,this,_VV,_RN);if((axisMember._gQ===ExpAxisObjType.Calc)&&(axisMember._uT===parent._uT)){axisMember._oq=true;axisMember.sBlockId=parent.sBlockId;}axisMember._qR=parent;parent._dg=axisMember;_aId=axisMember;_aId._av=parent._av+1;if(_aId._av+1>_VV._av){_VV._av=_aId._av+1;}if((!_aJa)&&_T7){parent.UpdateChildLines(axisMember.GetPropertyCount());}break;case DomTreeWalker.eSibling:var _aI9=_aId;var axisMember=new CDLAxisMember(this._he,this,_VV,_RN);axisMember._m7=_aI9;axisMember._qR=_aI9._qR;if((!_aJa)&&_T7&&axisMember._qR){axisMember._qR.UpdateChildLines(axisMember.GetPropertyCount());}_aI9._b3=axisMember;_aId=axisMember;_aId._av=_aI9._av;break;case DomTreeWalker.eOtherBranch:var _1e=this._wX(_RN,ExpAPIXml.kEleNode);var _S3=this._xg(_1e);var _VB=this._iz(_RN,ExpAPIXml.kEleNode);var _aI9=this._e1(_aId,_S3,_VB);var axisMember=new CDLAxisMember(this._he,this,_VV,_RN);axisMember._m7=_aI9;Debug.Assert(_aI9!=null);if(_aI9!=null){_aI9._b3=axisMember;axisMember._qR=_aI9._qR;}if((!_aJa)&&_T7){if(_aId._qR.GetPropertyCount()+1>_aId._qR._kk){_aId._qR.ReDistributeContentHeights();}if(axisMember._qR){axisMember._qR.UpdateChildLines(axisMember.GetPropertyCount());}else if(_aI9&&_aI9!=_aId._qR){_aI9.ReDistributeContentHeights();}}_aId=axisMember;if(_aI9!=null){_aId._av=_aI9._av;}break;}}}/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oProcessData.StopTimer(true);}/*@end@*/this.UpdateValidDisplaySettings();Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CDLDataMatrix::ProcessData"]);};CDLDataMatrix.prototype.Replace=function(_UL){Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CDLDataMatrix::Replace"]);/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oClearData.StartTimer(true);}/*@end@*/for(var i=0;i<this._c6.length;i++){this._c6[i].Clear();}Utilities.DeleteAllFromArray(this._c6);for(var i in this._x3){this._x3[i].Clear();}Utilities.ClearObjectArray(this._x3);/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oClearData.StopTimer(true);}/*@end@*//*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oDMCreate.StartTimer(true);}/*@end@*/this.Create(_UL);/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oDMCreate.StopTimer(true);}/*@end@*/Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CDLDataMatrix::Replace"]);};CDLDataMatrix.prototype.Subscribe=function(obj,event){if(event==ExpEvent.kCDLDataMatrix_FullRefresh){var _GT=this._e6[ExpEvent.kCDLDataMatrix_FullRefresh];}else if(event==ExpEvent.kCDLDataMatrix_AxisCreation){var _GT=this._e6[ExpEvent.kCDLDataMatrix_AxisCreation];for(var i=0;i<this._c6.length;i++){obj.Notify(ExpEvent.kCDLDataMatrix_AxisCreation);}}if(_GT&&!Utilities.IsInArray(_GT,obj)){_GT[_GT.length]=obj;}};CDLDataMatrix.prototype.UnSubscribe=function(obj,_Dy){if(this._e6&&this._e6[_Dy]){Utilities.DeleteFromArray(this._e6[_Dy],obj);}};CDLDataMatrix.prototype.GetCalculation=function(_Fo){return this._he._kX.GetCalculation(_Fo);};CDLDataMatrix.prototype._xy=function(_UL){var _aoF=false;for(var i=0;i<_UL.childNodes.length&&!_aoF;i++){var _4m=_UL.childNodes[i];if(_4m.nodeName==ExpAPIXml.kEleDefaultMeasure){var id=_4m.getAttribute(ExpAPIXml.kEleMeasurePtr);if(this._wG){delete this._wG;}if(id&&id!=""){this._wG=new Object();this._wG._ks=id;}else{this._wG=null;}_aoF=true;this._sb=_4m.getAttribute(ExpAPIXml.kDisplayType);this._aV=_4m.getAttribute(ExpAPIXml.kDefMeaPretType);}}};CDLDataMatrix.prototype.GetCurrentMeasure=function(){return this._wG;};CDLDataMatrix.prototype.GetCurrentMeasureId=function(){if(this._wG){return this._wG._ks;}else{return null;}};CDLDataMatrix.prototype.GetCurrentMeasureLabel=function(){var _XI="";if(this._wG){var _SE=this._he.metadata.GetMeasure(this._wG._ks);if(_SE){_XI=_SE._p8;}}return _XI;};CDLDataMatrix.prototype.SetDataMode=function(_UL){var _Hd=_UL.getAttribute(ExpAPIXml.kAttrDataMode);this._e9=(_Hd===ExpAPIXml.kAttrFasterDataMode)?false:true;};CDLDataMatrix.prototype.IsFullDataMode=function(){return this._e9;};CDLDataMatrix.prototype.ModifyDataModeProperty=function(_Hd){var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionSetProperty;_Jj._eW(ExpAPIXml.kAttrDataMode,_Hd);_Jj.AddTargetItem(this._ks,ExpAPIXml.kEleDataMatrix);this.SendDMAction(_Jj);};CDLDataMatrix.prototype._h9=function(_Va){Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CDLDataMatrix::_populateAxes"]);var _aEw=Dom.GetElementsByTagName(_Va,ExpAPIXml.kEleAxis);var _afq=_aEw.length;if(this._c6==null){this._c6=new Array();}for(var i=0;i<_afq;i++){var _BZ=0;var _ajk=_aEw[i];var _WS=false;var id=null;var _C7=_ajk.getAttribute(ExpAPIXml.kEleElcid);if(_C7){id=_C7;}else{throw new COTBadResponseException("Axis is missing elcid value.");}var _auq=null;for(var j=0;j<this._c6.length&&!_WS;j++){var _afm=this._c6[j];if(_afm._ks==id){_WS=true;_auq=_afm;}}if(!_WS){var _auq=new CDLAxis(this._c6.length,id,this,_ajk);this._c6[this._c6.length]=_auq;var _aiN=this._e6[ExpEvent.kCDLDataMatrix_AxisCreation];for(var k=0;k<_aiN.length;k++){_aiN[k].Notify(ExpEvent.kCDLDataMatrix_AxisCreation);}}else{Debug.Assert(false);}_auq._kU(_ajk);_auq._uB(_ajk);}Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CDLDataMatrix::_populateAxes"]);};CDLDataMatrix.prototype._wX=function(_RN,_L1){var _YF=null;var _ar7=_RN;while(_ar7.previousSibling!=null){_YF=_ar7.previousSibling;if(_YF.nodeName==_L1){return _YF;}_ar7=_YF;}return _YF;};CDLDataMatrix.prototype._iz=function(_RN,_L1){var _ar7=_RN;var _FU=0;while(_ar7.parentNode&&_ar7.parentNode.nodeName==_L1){_FU++;_ar7=_ar7.parentNode;}return _FU;};CDLDataMatrix.prototype._e1=function(axisMember,_S3,_VB){var _aqs=axisMember;while(_aqs._qR!=null){_aqs=_aqs._qR;if(_S3==_aqs._uT&&_aqs._av==_VB){return _aqs;}}return null;};CDLDataMatrix.prototype._xg=function(_I0){var _S3=null;if(_I0){var _W8=Dom.GetImmediateChildByName(_I0,ExpAPIXml.kEleMemberPtr);if(_W8){_S3=Dom.GetNodeText(_W8);}else{var _asH=Dom.GetImmediateChildByName(_I0,ExpAPIXml.kEleMeasurePtr);if(_asH){_S3=Dom.GetNodeText(_asH);}else{var _axw=Dom.GetImmediateChildByName(_I0,ExpAPIXml.kEleCalcPtr);if(_axw){_S3=Dom.GetNodeText(_axw);}else{var _afb=Dom.GetImmediateChildByName(_I0,ExpAPIXml.kElePropPtr);if(_afb){_S3=Dom.GetNodeText(_afb);}}}}}return _S3;};CDLDataMatrix.prototype._o7=function(_Do){var _F9='';var _W8=Dom.GetImmediateChildByName(_Do,ExpAPIXml.kEleMemberPtr);if(_W8){_F9=Dom.GetNodeText(_W8);}else{var _asH=Dom.GetImmediateChildByName(_Do,ExpAPIXml.kEleMeasurePtr);if(_asH){_F9=Dom.GetNodeText(_asH);}else{var _axw=Dom.GetImmediateChildByName(_Do,ExpAPIXml.kEleCalcPtr);if(_axw){_F9=Dom.GetNodeText(_axw);}else{var _afb=Dom.GetImmediateChildByName(_Do,ExpAPIXml.kElePropPtr);if(_afb){_F9=Dom.GetNodeText(_afb);}}}}return _F9;};CDLDataMatrix.prototype.GetAxisCount=function(){var _aIQ=0;if(this._c6){_aIQ=this._c6.length;}return _aIQ;};CDLDataMatrix.prototype._rb=function(_RN){var _aCg=_RN.getElementsByTagName(ExpAPIXml.kEleNode);if(_aCg.length==0){return true;}return false;};CDLDataMatrix.prototype.IsCompleteExpression=function(){if(this._c6&&this._c6.length>=2){var _3v=this._c6[0].GetAllBlocksArray();var _YU=this._c6[1].GetAllBlocksArray();if((_3v.length>0)&&(_YU.length>0)){if(this.GetCurrentMeasure()){return true;}else if(this._c6[0].HasMeasureBlock()||this._c6[1].HasMeasureBlock()){return true;}}}return false;};CDLDataMatrix.prototype.IsComplete=function(){if(this._c6&&this._c6.length>=2){if(this._c6[0].GetDataObj()&&this._c6[1].GetDataObj()){if(this.GetCurrentMeasure()){return true;}else if(this._c6[0].HasMeasureBlock()||this._c6[1].HasMeasureBlock()){return true;}}}return false;};CDLDataMatrix.prototype.HasMeasureBlock=function(){for(var i=0;i<this._c6.length;i++){if(this._c6[i].HasMeasureBlock()){return true;}}return false;};CDLDataMatrix.prototype.HasMeasure=function(){return(this.GetCurrentMeasure()||this.HasMeasureBlock());};CDLDataMatrix.prototype.CanChangeValueDspSetting=function(){if(!this.GetCurrentMeasure()){return false;}var _ahL=this._he.metadata.GetMeasure(this.GetCurrentMeasureId());if(!_ahL.IsAggregateable()){if(_ahL._wd===ExpAPIXml.kEleUnknownAggre&&this._he.appobj._jI){return true;}else{return false;}}if(this._c6[0].HasMeasureBlock()||this._c6[1].HasMeasureBlock()){return false;}return true;};CDLDataMatrix.prototype.GetAxis=function(_PQ){var _afU=null;if(this._c6&&_PQ<=this._c6.length-1){_afU=this._c6[_PQ];}return _afU;};CDLDataMatrix.prototype.GetAxisById=function(id){var _afU=null;if(this._c6!=null){for(var i=0;i<this._c6.length;i++){_afU=this._c6[i];if(_afU._ks==id){return _afU;}}}return null;};CDLDataMatrix.prototype.GetOppositeAxis=function(_Rx){var _afU=null;if(this._c6!=null){for(var i=0;i<this._c6.length;i++){_afU=this._c6[i];if(_afU._ks!=_Rx._ks){return _afU;}}}return null;};CDLDataMatrix.prototype.GetFirstAxisMember=function(_F8){for(var i in this._he._kX._c5){var oMem=this._he._kX._c5[i].GetFirstAxisMember(_F8);if(oMem){return oMem;}}return null;};CDLDataMatrix.prototype.GetDMAction=function(){var _Jj=new CDLAction();_Jj.AddTargetItem(this._ks,ExpAPIXml.kEleDataMatrix);return _Jj;};CDLDataMatrix.prototype.SendDMAction=function(_Jj){var _AE=new Array();_AE[0]=_Jj;this.SendDMActionArray(_AE);};CDLDataMatrix.prototype.SendDMActionArray=function(_AE){var _aBj=this._he.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this._he.GetCurrentWorkSheet(),true);};CDLDataMatrix.prototype.DrillUpOnCell=function(_zt){var _AE=new Array();var _Jj;var _anX=true;for(var i=0;i<_zt.length;i++){_Jj=null;var _azI=_zt[i].GetBlock();var _LF=_azI.GetFirstNode();var _RJ=this._he.metadata;var _VW=_RJ.GetMemberOrMeasure(_zt[i].GetMemberId()).GetParent();var _5T=null;if(_azI.IsChildren()||_azI.IsChildrenMeasureBlock()){if(_VW){_5T=_VW.GetId();}}else{_5T=_zt[i].GetMemberId();}if(_5T){_Jj=_LF.DrillUp(_5T,_anX);}else{_LF=_azI.GetFirstDataNode();if(_LF){_Jj=_LF.DrillUp(null,_anX);}}if(_Jj){_AE.push(_Jj);}}if(_AE.length>0){this.SendDMActionArray(_AE);}};CDLDataMatrix.prototype.DrillOnCell=function(_Wt,_Ei){var _AE=new Array();var _Jj;var _anX=true;for(var i=0;i<_Wt.length;i++){var _ON=_Wt[i];if(_Ei){_Jj=_ON.DrillUp(null,_anX);}else{_Jj=_ON.DrillDown(_anX);}_AE.push(_Jj);}if(_AE.length>0){this.SendDMActionArray(_AE);}};CDLDataMatrix.prototype.SetDisplayProperty=function(_yC,_TE,_Ti,_B0,_D2,_Le){var _Jj=this.GetDMAction();_Jj.type=ExpAPIXml.kActionSetProperty;_Jj._eW(ExpAPIXml.kDisplayType,_yC);if(_TE&&_Ti&&_B0){_Jj.AddTargetItem(_TE,ExpAPIXml.kEleAxis);_Jj.AddTargetItem(_Ti,ExpAPIXml.kBlock);_Jj.AddTargetItem(_B0,_D2);}if(!_Le){this.SendDMAction(_Jj);return null;}else{return _Jj;}};CDLDataMatrix.prototype.ClearAllSuppression=function(){var _AE=new Array();for(var i=0;i<this.GetAxisCount();i++){var _O0=this.GetAxis(i);var _Jj=this.GetDMAction();_Jj.type=ExpAPIXml.kActionDelete;_Jj.AddTargetItem(_O0._ks,ExpAPIXml.kEleAxis);var _9e="";for(var _aqi in _O0._pn){_9e+=_c.CreateElement(ExpAPIXml.kEleTuple,_aqi,true);}if(_9e!=""){var _avr=_c.CreateElement(ExpAPIXml.kEleTupleList,_9e,true);_Jj.AddParameter(new CDLParameter(ExpAPIXml.kEleSuppressionTuples,_avr,CDLParameter.XMLType()));_AE=_AE.concat(_Jj);}}if(this._he._kX.GetSuppressionState()!=ExpAPIXml.kNoSuppressionOnRowsOrColumns){var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionModify;_Jj.AddTargetItem(this._he._kX._ks,ExpAPIXml.kEleAnalysis);_Jj.AddParameter(new CDLParameter(ExpAPIXml.kSuppressionState,ExpAPIXml.kNoSuppressionOnRowsOrColumns,CDLParameter.XMLType()));_AE.push(_Jj);}if(_AE.length>0){this.SendDMActionArray(_AE);}};CDLDataMatrix.prototype.HasSuppression=function(){return(this.HasSelectedBasedSuppression()||this.HasAxisBasedSuppression());};CDLDataMatrix.prototype.HasSelectedBasedSuppression=function(){for(var i=0;i<this.GetAxisCount();i++){var _O0=this.GetAxis(i);if(_O0.HasSuppression()){return true;}}return false;};CDLDataMatrix.prototype.HasRowAxisSuppression=function(){var _XK=this._he._kX.GetSuppressionState();return(_XK==ExpAPIXml.kSuppressRowsOnly||_XK==ExpAPIXml.kSuppressRowsAndCols);};CDLDataMatrix.prototype.HasColAxisSuppression=function(){var _XK=this._he._kX.GetSuppressionState();return(_XK==ExpAPIXml.kSuppressColsOnly||_XK==ExpAPIXml.kSuppressRowsAndCols);};CDLDataMatrix.prototype.HasAxisBasedSuppression=function(){return(this._he._kX.GetSuppressionState()!=ExpAPIXml.kNoSuppressionOnRowsOrColumns);};CDLDataMatrix.prototype.GetSuppressionContextbarLabel=function(){var _BM=null;var _XK=this._he._kX.GetSuppressionState();switch(_XK){case ExpAPIXml.kSuppressRowsOnly:_BM=_Co.GetString('IDS_TOOLBAR_ROWS_FOR_SUPPRESSION');break;case ExpAPIXml.kSuppressColsOnly:_BM=_Co.GetString('IDS_TOOLBAR_COLS_FOR_SUPPRESSION');break;case ExpAPIXml.kSuppressRowsAndCols:_BM=_Co.ReplaceParam('IDS_TOOLBAR_SUPPRESSION_APPLIED_STRING',1,_Co.GetString('IDS_TOOLBAR_ROWS_FOR_SUPPRESSION'));_BM=_Co.ReplaceParam(_BM,2,_Co.GetString('IDS_TOOLBAR_COLS_FOR_SUPPRESSION'));break;}if(this.HasSelectedBasedSuppression()){if(this.HasAxisBasedSuppression()){var _BM=_Co.ReplaceParam('IDS_TOOLBAR_SUPPRESSION_APPLIED_STRING',1,_BM);_BM=_Co.ReplaceParam(_BM,2,_Co.GetString('IDS_TOOLBAR_SELECTED_FOR_SUPPRESSION'));}else{_BM=_Co.GetString('IDS_TOOLBAR_SELECTED_FOR_SUPPRESSION');}}_BM=_Co.ReplaceParam('IDS_TOOLBAR_SUPPRESSION_APPLIED_PERIOD',1,_BM);return _BM;};CDLDataMatrix.prototype.GetSuppressionDescription=function(){var _Co=this._he.appobj.oResources;var _ar3=this.GetAxis(CUIDataMatrix.iRowIndex);var _aC6=this.GetAxis(CUIDataMatrix.iColIndex);var _BM='';if(_ar3.HasSuppression()&&_aC6.HasSuppression()){_BM=_Co.ReplaceParam('IDS_TUPLE_BASED_ZERO_SUPP_BOTH',1,_ar3.GetSuppressionDescription(true));_BM=_Co.ReplaceParam(_BM,2,_aC6.GetSuppressionDescription());}else if(_ar3.HasSuppression()){_BM=_ar3.GetSuppressionDescription(true);}else{_BM=_aC6.GetSuppressionDescription();}return _BM;};CDLDataMatrix.prototype.GetDisplayProperty=function(){return this._sb;};CDLDataMatrix.prototype.UpdateValidDisplaySettings=function(){var _5t=new Array(ExpAPIXml.kDefDisplayDsp,ExpAPIXml.kPcntRowTotalDsp,ExpAPIXml.kPcntRowSubTotalDsp,ExpAPIXml.kPcntColTotalDsp,ExpAPIXml.kPcntColSubTotalDsp,ExpAPIXml.kPcntOfTotalDsp);for(var i=0;i<_5t.length;i++){this._d4[_5t[i]]=true;}var _abM=this.GetAxis(CUIDataMatrix.iRowIndex);if(_abM.GetAxisDepth()==1&&(!_abM.HasUnion())){this._d4[ExpAPIXml.kPcntColTotalDsp]=false;}if(_abM.HasUnion()){this._d4[ExpAPIXml.kPcntColTotalDsp]=false;this._d4[ExpAPIXml.kPcntOfTotalDsp]=false;}var _8T=this.GetAxis(CUIDataMatrix.iColIndex);if(_8T.GetAxisDepth()==1&&(!_8T.HasUnion())){this._d4[ExpAPIXml.kPcntRowTotalDsp]=false;}if(_8T.HasUnion()){this._d4[ExpAPIXml.kPcntRowTotalDsp]=false;this._d4[ExpAPIXml.kPcntOfTotalDsp]=false;}};CDLDataMatrix.prototype.GetDefMeasurePresentationType=function(){return this._aV;};CDLDataMatrix.prototype.GetBlock=function(_L7){for(var i=0;i<this._c6.length;i++){var _afU=this._c6[i];var _amM=_afU.GetBlock(_L7);if(_amM)return _amM;}return null;};function CDLAxis(_QO,id,dm,_VZ){this._l7=_QO;this._ks=id;this.expressionNode=null;this._W=50;this._rk=dm;this._pn=new Object();this._rR=new Object();this._lh=new Array();this._u4=new Object();this._rt=new Object();this._wf=null;this._o3=null;this._ah=new Array();this._k6=new Array();};CDLAxis.prototype.GetDataObj=function(){if(this._o3){return this._o3;}else if(this._wf){return this._wf;}return null;};CDLAxis.prototype.GetXtabData=function(){return this._o3;};CDLAxis.prototype.GetChartData=function(){return this._wf;};CDLAxis.prototype.IsStale=function(){return this._w7;};CDLAxis.prototype.UpdateBlocks=function(){this._w7=false;var _JE=this._rk._he._kX;for(var i in this._rR){var _ayH=_JE.getBlock(i);if(_ayH){this._rR[i]=_ayH;this._rR[i].oAxis=this;}else{delete this._rR[i];this._w7=true;}}for(var i in this._x3){this._x3[i].Clear();}Utilities.ClearObjectArray(this._x3);Utilities.ClearObjectArray(this._rt);};CDLAxis.prototype.GetOpForBlock=function(_L7){var _NG=this._u4[_L7];if(_NG<this._lh.length){return this._lh[_NG];}return null;};CDLAxis.prototype.AddFirstBlockMember=function(_L7,oMem){Debug.Assert(this.GetDataObj());if(this.GetDataObj()){this.GetDataObj().AddFirstBlockMember(_L7,oMem);}};CDLAxis.prototype.GetFirstBlockMember=function(_L7){if(this.GetDataObj()){return this.GetDataObj().GetFirstBlockMember(_L7);}return null;};CDLAxis.prototype.ClearMembers=function(_Vx,_Ns,_UB){if(_Vx&&this._wf){if(_UB||(_Ns==this._wf.GetDataContainerId())){this._wf.Clear();this._wf=null;}}else if(this._o3&&!_Vx){if(_UB||(_Ns==this._o3.GetDataContainerId())){this._o3.Clear();this._o3=null;}}};CDLAxis.prototype.Clear=function(){if(this._o3){this._o3.Clear();this._o3=null;}if(this._wf){this._wf.Clear();this._wf=null;}for(var i in this._rR){this._rR[i].oAxis=null;}Utilities.ClearObjectArray(this._rR);Utilities.ClearObjectArray(this._u4);Utilities.ClearObjectArray(this._rt);Utilities.DeleteAllFromArray(this._lh);Utilities.RemoveAllChildObjects(this);};CDLAxis.prototype.GetAxisMemberCell=function(_QZ){if(!this.GetDataObj()){Debug.Assert(false);return null;}return this.GetDataObj().GetAxisMemberCell(_QZ);};CDLAxis.prototype.GetAxisDepth=function(){if(!this.GetDataObj()){return 0;}return this.GetDataObj().GetAxisDepth();};CDLAxis.prototype.GetLength=function(){if(!this.GetDataObj()){return 0;}return this.GetDataObj().GetLength();};CDLAxis.prototype.GetBlock=function(_Ai){Debug.Assert(this._rR);if(this._rR){return this._rR[_Ai];}};CDLAxis.prototype.GetSingleBlock=function(){var i=0;var _FK=null;for(var s in this._rR){if(!this._rR[s]._ua){_FK=this._rR[s];i++;}if(i>1){Debug.Assert(false);return null;}}return _FK;};CDLAxis.prototype.processOp=function(_IY,_I3){if(!(_IY instanceof CDLAxisOp)){_I3.push(this.GetBlock(_IY));return;}if(_IY.eType==CDLAxisOp.eTypeXJoin){this.processOp(_IY.oRightOperand,_I3);}if(_IY.eType==CDLAxisOp.eTypeUnion){this.processOp(_IY.oLeftOperand,_I3);this.processOp(_IY.oRightOperand,_I3);}if(_IY.eType==CDLAxisOp.eTypeNest){this.processOp(_IY.oRightOperand,_I3);}return;};CDLAxis.prototype.GetInnerBlocks=function(){var _I3=new Array();if(this.GetAxisDepth()<2){for(var s in this._rR){_I3.push(this._rR[s]);}}else{if(Utilities.bSingleMemExpandEnabled){if(!this._lh[0]){for(var s in this._rR){if(!this._rR[s]._ua){_I3.push(this._rR[s]);}}return _I3;}}this.processOp(this._lh[0],_I3);}return _I3;};CDLAxis.prototype.processOpsForNonMeasureInnerMostBlocks=function(_IY,_I3,_BS){if(!(_IY instanceof CDLAxisOp)){var _FK=this.GetBlock(_IY);if((!_FK.HasMeasures())&&(!_FK.IsHierarchyEnabled())){_I3.push(_FK);}else{if(_BS&&_FK.HasMeasures()&&(!_FK.IsHierarchyEnabled())){_BS._nI=true;}}return;}if(_IY.eType==CDLAxisOp.eTypeXJoin){var _BS=new Object();_BS._nI=false;this.processOpsForNonMeasureInnerMostBlocks(_IY.oRightOperand,_I3,_BS);if(_BS._nI){this.processOpsForNonMeasureInnerMostBlocks(_IY.oLeftOperand,_I3);}_BS._nI=null;}else if(_IY.eType==CDLAxisOp.eTypeUnion){this.processOpsForNonMeasureInnerMostBlocks(_IY.oLeftOperand,_I3);this.processOpsForNonMeasureInnerMostBlocks(_IY.oRightOperand,_I3);}else if(_IY.eType==CDLAxisOp.eTypeNest){this.processOpsForNonMeasureInnerMostBlocks(_IY.oRightOperand,_I3);}return;};CDLAxis.prototype.GetSortableInnerBlocks=function(){var _I3=new Array();if(this.GetAxisDepth()<2){for(var s in this._rR){if((!this._rR[s].HasMeasures())&&(!this._rR[s].IsHierarchyEnabled())){_I3.push(this._rR[s]);}}}else{if(Utilities.bSingleMemExpandEnabled){if(!this._lh[0]){for(var s in this._rR){_I3.push(this._rR[s]);}return _I3;}}this.processOpsForNonMeasureInnerMostBlocks(this._lh[0],_I3);if(Utilities.bSingleMemExpandEnabled){for(var _ayF=0;_ayF<_I3.length;_ayF++){if(_I3[_ayF].HasSingleMemberExpandedSet()){var _3N=_I3[_ayF].GetAllExpandedSets();for(var _0C=0;_0C<_3N.length;_0C++){_I3.push(_3N[_0C]);}}}}}return _I3;};CDLAxis.prototype.GetFilterableInnerBlocks=function(){var _I3=this.GetSortableInnerBlocks();return _I3;};CDLAxis.prototype.IsInnerNestedBlock=function(_L7){return Utilities.IsInArray(this._k6,_L7);};CDLAxis.prototype.IsOuterNestedBlock=function(_L7){return Utilities.IsInArray(this._ah,_L7);};CDLAxis.prototype.markNestedBlocks=function(){this._k6=new Array();this._ah=new Array();if(this._lh.length>0){this.processOpsForInnerNestedBlocks(this._lh[0]);}else{for(var s in this._rR){var _FK=this._rR[s];if(_FK.IsDepthBased()){this._k6.push(_FK.GetId());}}}for(var _Lx in this._rR){var _FK=this._rR[_Lx];if(_FK._hj!=null){var _1o=_FK.GetRootParentBlockOnAxis();if(_1o!=null){this._ah.push(_1o.GetId());}}}};CDLAxis.prototype.processOpsForInnerNestedBlocks=function(_IY){if(!(_IY instanceof CDLAxisOp)){var _FK=this.GetBlock(_IY);if(_FK.IsDepthBased()){this._k6.push(_FK.GetId());}return;}if(_IY.eType==CDLAxisOp.eTypeXJoin){this.processOpsForInnerNestedBlocks(_IY.oLeftOperand);this.processOpsForInnerNestedBlocks(_IY.oRightOperand);}else if(_IY.eType==CDLAxisOp.eTypeUnion){this.processOpsForInnerNestedBlocks(_IY.oLeftOperand);this.processOpsForInnerNestedBlocks(_IY.oRightOperand);}else if(_IY.eType==CDLAxisOp.eTypeNest){this.processOpsForInnerNestedBlocks(_IY.oRightOperand);}return;};CDLAxis.prototype.GetSelectedTuple=function(_Ir,_QH,_S4,_MF){if(this.GetDataObj()){return this.GetDataObj().GetSelectedTuple(_Ir,_QH,_S4,_MF);}return null;};CDLAxis.prototype.GetSelectedSuppressionTuple=function(_Ir,_QH,_S4,_MF){if(this.GetDataObj()){return this.GetDataObj().GetSelectedSuppressionTuple(_Ir,_QH,_S4,_MF);}return null;};CDLAxis.prototype.SortInnerBlocks=function(_C9,_UN){var _I3=this.GetSortableInnerBlocks();var _AE=new Array();var _aAf;for(var i in _I3){_AE.push(_I3[i].SetProperty(ExpAPIXml.kEleAxisOpExprSorttype,ExpAPIXml.kEleAxisOpExprSorttypeDefault,true));if(_UN!=ExpAPIXml.kEleAxisOpExprSorttypeDefault){_aAf=_I3[i].SortMembers(_C9,_UN);_AE=_AE.concat(_aAf);}}this._rk.SendDMActionArray(_AE);};CDLAxis.prototype.GetAllBlocks=function(){return this._rR;};CDLAxis.prototype.HasProperitesDisplayed=function(){for(var i in this._rR){if(this._rR[i]._qS.length>0){return true;}}return false;};CDLAxis.prototype.GetAllBlocksStartFromInnerMost=function(){var _8W=new Array();for(var x=this.GetAxisDepth()-1;x>=0;x--){for(var i in this._rR){if(this._rR[i].GetAxisDepth()==x){_8W.push(this._rR[i]);}}}return _8W;};CDLAxis.prototype.GetAllBlocksArray=function(){var _I3=new Array();for(var i in this._rR){_I3.push(this._rR[i]);}return _I3;};CDLAxis.prototype.GetAllOps=function(){return this._lh;};CDLAxis.prototype.IsEmpty=function(){var _acb=(Utilities.GetObjArrayLength(this._rR)==0)?true:false;return _acb;};CDLAxis.prototype.HasNamedSetBlock=function(){for(var i in this._rR){if(this._rR[i].IsNamedSet()){return true;}}return false;};CDLAxis.prototype.HasMeasureBlock=function(){for(var i in this._rR){if(this._rR[i].HasMeasures()){return true;}}return false;};CDLAxis.prototype.HasHAMCMeasureBlocksOnly=function(){for(var i in this._rR){if(!this._rR[i].IsMeasureBlock()){return false;}}return true;};CDLAxis.prototype.HasExpandedSet=function(){for(var i in this._rR){if(this._rR[i]._ua){return true;}}return false;};CDLAxis.prototype.GetMeasureBlocks=function(){var _aCd=new Array();for(var i in this._rR){if(this._rR[i].HasMeasures()){_aCd.push(this._rR[i]);}}return _aCd;};CDLAxis.prototype.HasUniqueHamcMeasureBlock=function(){var _aHd=0;for(var i in this._rR){if(this._rR[i].HasMeasures()){if(this._rR[i].IsChildrenMeasureBlock()){return false;}_aHd++;}}if(_aHd>1){return false;}return true;};CDLAxis.prototype.GetId=function(){return this._ks;};CDLAxis.prototype._kU=function(_BO){this._pn=Utilities.ClearObjectArray(this._pn);var _adI=_BO.selectNodes(ExpAPIXml.kXpathExprSuppressionTuple);var _3z=null;for(var i=0;i<_adI.length;i++){_3z=_adI[i];var _aqi=_3z.getAttribute(ExpAPIXml.kEleElcid);if(_aqi){var _aFo=Dom.GetElementsByTagName(_3z,ExpAPIXml.kEleEntry);var _an7,_3t,_B0;var _aBA=new Array();for(var j=0;j<_aFo.length;j++){_an7=_aFo[j];_3t=Dom.GetElementsByTagName(_an7,ExpAPIXml.kEleObjectPtr);Debug.Assert(_3t.length==1);_aBA.push(Dom.GetNodeText(_3t[0]));}this._pn[_aqi]=_aBA;}}};CDLAxis.prototype.HasSuppression=function(){return!Utilities.IsObjectEmpty(this._pn);};CDLAxis.prototype.GetSuppressionDescription=function(_T7){var _JE=this._rk._he._kX;var _5i=_JE._by?'IDS_TUPLE_BASED_ZERO_AND_NULL_SUPP':'IDS_TUPLE_BASED_NULL_SUPP';_5i+=_T7?'_ROWS':'_COLS';var _Co=this._rk._he.appobj.oResources;var _BM=_Co.ReplaceParam(_5i,1,this.GetTupleListDescription());return _BM;};CDLAxis.prototype.GetTupleListDescription=function(_T7){var _aqc=new Array();var _aag=(Utilities.GetNthFromObjArray(this._pn,2)!==null);var _ait='';for(var i in this._pn){var _al6=CDLBlock.GetTupleMembersLabel(null,null,this._rk,this._pn[i]);if(_aag){_al6=_Co.ReplaceParam('IDS_SUPPRESSION_TUPLE_AUTOM_IN_MULTI_TUPLE_LIST',1,_al6);}_aqc.push(_al6);}_ait=_Co.ReplaceParamList('IDS_SUPPRESSION_TUPLE_LIST',_aqc);return _ait;};CDLAxis.prototype._uB=function(_BO){var _2e=Dom.GetImmediateChildByName(_BO,ExpAPIXml.kEleAxisExpression);this.expressionNode=_2e;var _0x=new Array();if(this.expressionNode){var _azS=Dom.GetTreeWalker(_2e.firstChild);var _aea=-1;var _AT=this._rk._he;var _JE=_AT._kX;while(!_azS.AtEnd()){var _ac2=_azS.GetElement();if(_ac2.nodeName==ExpAPIXml.kEleAxisOpExpression){var _Od=_ac2.getAttribute(ExpAPIXml.kEleElcid);var _FK=_JE.getBlock(_Od);_FK.oAxis=this;_FK.sExprId=_Od;this._u4[_Od]=_aea;this._rR[_Od]=_FK;var _aIm=_aea+1;if(this._lh[_aIm]&&this._lh[_aIm].IsComplete()){_0x.pop();}for(var x=0;x<_0x.length;x++){this._rR[_Od]._z.push(_0x[x]);}if(_aea>=0&&this._lh[_aea]){this._lh[_aea].AddOperand(_Od);}while(_aea>=0&&this._lh[_aea]&&this._lh[_aea].IsComplete()){_aea--;}}else if(_ac2.nodeName==ExpAPIXml.kEleAxisOp){var _afB=this._lh.length-1;var _aie=new CDLAxisOp(_ac2);this._lh.push(_aie);_0x.push(_aie.eType);_aea=this._lh.length-1;while(_afB>=0){if(!this._lh[_afB].IsComplete()){this._lh[_afB].AddOperand(this._lh[this._lh.length-1]);break;}Utilities.DeleteNthFromArray(_0x,_afB);_afB--;}}_azS.MoveToNext();}}this.markNestedBlocks();this._w7=false;};CDLAxis.prototype.HasUnion=function(){for(var i=0;i<this._lh.length;i++){if(this._lh[i].eType==CDLAxisOp.eTypeUnion){return true;}}return false;};CDLAxis.prototype.deleteElement=function(_GT,n){var length=_GT.length;if(n>=length||n<0)return;for(var i=n;i<length-1;i++)_GT[i]=_GT[i+1];_GT.length--;};CDLAxis.prototype.IsPropertyEnabled=function(_O9,id){};CDLAxis.prototype.DoReplace=function(_F8,_Hb,_R1,_y2,_BG){var _Jj=this._rk.GetDMAction();_Jj.type=ExpAPIXml.kActionReplace;_Jj.AddTargetItem(this._ks,ExpAPIXml.kEleAxis);var _Tc=this._rk._he.metadata;var _HF=this._rk._he._kX;if(_HF.GetCustomSet(_F8)){var _aja=_Jj.AddSource(_HF._ks,ExpAPIXml.kEleAnalysis);_aja.AddActionItem(_F8,ExpAPIXml.kCustomSet);}else{var _7U=_Jj.SetMemberMeasureSource(_Tc,_F8);_Jj._eW(ExpAPIXml.kDisplayType,ExpAPIXml.kDefDisplayDsp);_Jj._eW(ExpAPIXml.kPopulationType,_Hb);if(_y2){_Jj._eW(ExpAPIXml.kLevel,_y2);}if(_R1){for(var i=0;i<_R1.length;i++){_Jj.AddSource(_R1[i],_7U);}}}if(_BG){return _Jj;}else{this._rk.SendDMAction(_Jj);}};CDLAxis.prototype.Xjoin=function(_F8,_Hb,_UR,_J3,_R1,_y2,_DR){var _AE=new Array();if(_J3 instanceof Array){var _AE=_J3;}else{var _AE=new Array();if(_J3){_AE.push(_J3);}}var _Jj=this._rk.GetDMAction();_Jj.type=ExpAPIXml.kActionInsert;_Jj.AddTargetItem(this._ks,ExpAPIXml.kEleAxis);var _Tc=this._rk._he.metadata;var _HF=this._rk._he._kX;var _7U='';_7U=_Jj.SetMemberMeasureSource(_Tc,_F8);_Jj._eW(ExpAPIXml.kInsertType,ExpAPIXml.kAxisOpXjoin);if(!_HF.GetCustomSet(_F8)){_Jj._eW(ExpAPIXml.kDisplayType,ExpAPIXml.kDefDisplayDsp);_Jj._eW(ExpAPIXml.kPopulationType,_Hb);}_Jj._eW(ExpAPIXml.kPosition,_UR);if(_R1){for(var i=0;i<_R1.length;i++){_Jj.AddSource(_R1[i],_7U);}}if(_y2){_Jj._eW(ExpAPIXml.kLevel,_y2);}if(_DR){var _as2=this._rk._he.GetCurrentWSFilterSet();var _IK=_as2.GetFilterById(_DR);if(_IK.GetUserDefFLT()){var _Gh=new CDLParameter(ExpAPIXml.kEleUserDefFilter,_IK.GetUserDefFLT().GetAsXML(ExpAPIXml.kEleUserDefFilter),CDLParameter.XMLType());_Jj.AddParameter(_Gh);}if(_IK.GetSubset()){var _Gh=new CDLParameter(ExpAPIXml.kEleSubset,_IK.GetSubset().GetAsXML(ExpAPIXml.kEleSubset),CDLParameter.XMLType());_Jj.AddParameter(_Gh);}}_AE.push(_Jj);this._rk.SendDMActionArray(_AE);};CDLAxis.prototype.DoDeleteMultipleBlocks=function(_I3){var _AE=new Array();for(var i=0;i<_I3.length;i++){var _Jj=this._rk.GetDMAction();_Jj.type=ExpAPIXml.kActionDelete;_Jj.AddTargetItem(this._ks,ExpAPIXml.kEleAxis);_Jj.AddTargetItem(_I3[i].sExprId,ExpAPIXml.kEleAxisOpExpression);_AE[i]=_Jj;}this._rk.SendDMActionArray(_AE);};CDLAxis.prototype.IsValidDimDrop=function(_Pv,_Qp,_TW){var _acg=(_Qp!=null)?("block"+_Pv):_Pv;if(_Qp!=null){if(!this._rt[_Qp.GetId()]){if(!this.HasEmptyBlock()){var _66=this.GetDataObj().GetInvalidDropDims(_Qp);this._rt[_Qp.GetId()]=new Object();this._rt[_Qp.GetId()]["block"+ExpAPIXml.kAxisOpXjoin]=_66;var _azX=new Object();Utilities.CopyObjArray(_66,_azX);var _aEl=new Object();Utilities.CopyObjArray(_66,_aEl);if(_Qp.IsOuterNestedBlock()||_Qp.IsGroupedDescendantsAtDepth()){this._rt[_Qp.GetId()]["block"+ExpAPIXml.kActionReplace]=_azX;}else{delete _azX[_Qp.GetDimId()];this._rt[_Qp.GetId()]["block"+ExpAPIXml.kActionReplace]=_azX;}delete _aEl[_Qp.GetDimId()];this._rt[_Qp.GetId()]["block"+ExpAPIXml.kAxisOpUnion]=_aEl;}else{this._rt[_Qp.GetId()]=new Object();var _66=this.GetExistedDimIdArr();this._rt[_Qp.GetId()]["block"+ExpAPIXml.kAxisOpXjoin]=_66;var _azX=new Object();Utilities.CopyObjArray(_66,_azX);var _aEl=new Object();Utilities.CopyObjArray(_66,_aEl);if(_Qp.IsOuterNestedBlock()||_Qp.IsGroupedDescendantsAtDepth()){this._rt[_Qp.GetId()]["block"+ExpAPIXml.kActionReplace]=_azX;}else{delete _azX[_Qp.GetDimId()];this._rt[_Qp.GetId()]["block"+ExpAPIXml.kActionReplace]=_azX;}delete _aEl[_Qp.GetDimId()];this._rt[_Qp.GetId()]["block"+ExpAPIXml.kAxisOpUnion]=_aEl;}}var _aFC=this._rt[_Qp.GetId()];}else{var _aFC=new Object();_aFC[ExpAPIXml.kAxisOpUnion]=new Array();_aFC[ExpAPIXml.kAxisOpXjoin]=this.GetExistedDimIdArr();_aFC[ExpAPIXml.kActionReplace]=new Array();}var _aqe=null;var dm=this._rk;for(var i=0;i<dm._c6.length;i++){if(this!=dm._c6[i]){_aqe=dm._c6[i];break;}}if(_aqe.HasMeasureBlock()){var _Tc=this._rk._he.metadata;var _avd=_Tc.GetMeasureDimIdArr();for(var i in _aFC){for(var m=0;m<_avd.length;m++){_aFC[i][_avd[m]]=true;}}}return!(_aFC[_acg][_TW]);};CDLAxis.prototype.GetAllBlockOperandsForAxisOp=function(_IY,_I3){if(!(_IY instanceof CDLAxisOp)){_I3.push(this.GetBlock(_IY));return;}this.GetAllBlockOperandsForAxisOp(_IY.oLeftOperand,_I3);this.GetAllBlockOperandsForAxisOp(_IY.oRightOperand,_I3);return;};CDLAxis.prototype.GetBlocksInSelectedBlockXjoinLineage=function(_FK){var _Z2=new Array();var _7B=new Array();var _arz=this.GetOpForBlock(_FK.GetId());var _arK=Utilities.GetObjIndex(this._lh,_arz);var _ai7=_FK.GetId();for(var i=_arK;i>-1;i--){var _8e=this._lh[i];if(_8e.eType==CDLAxisOp.eTypeXJoin){if(_8e.oLeftOperand==_ai7){this.GetAllBlockOperandsForAxisOp(_8e.oRightOperand,_7B);}else if(_8e.oRightOperand==_ai7){this.GetAllBlockOperandsForAxisOp(_8e.oLeftOperand,_7B);}}_ai7=_8e;}return _7B;};CDLDataMatrix.prototype.IsValidActionForSameHierCompatibilityRule=function(_Pv,_Lv,_Qp,_Rx,_BQ){var _aBl=true;var ws=this._he.GetCurrentWorkSheet();if(ws&&!ws.IsSameHierarchyCompatibilityEnabled()){if(_Lv){var _HF=this._he._kX;if(_HF&&_Lv.sBlockId&&_HF.getBlock(_Lv.sBlockId)){return true;}var _4U=this._he.GetCurrentWSFilterSet();if(_4U&&_Lv.sFilterId&&_4U.GetFilterById(_Lv.sFilterId)){return true;}}if(_BQ){_aBl=this.IsValidForSameHierCompatibilityInXtab(_Pv,_Lv,_Qp,_Rx);}else{_aBl=(this.IsValidForSameHierCompatibilityInContextFilter(_Lv)&&this.IsValidForSameHierCompatibilityInXtab(_Pv,_Lv,_Qp,_Rx));}}return _aBl;};CDLDataMatrix.prototype.IsValidForSameHierCompatibilityInContextFilter=function(_Lv){var _4U=this._he.GetCurrentWSFilterSet();if(!_4U){return true;}var _I3=_4U.GetAllFilterBlocks();return(!this.IsAnyBlockFromSameHierOrDim(_Lv,_I3));};CDLDataMatrix.prototype.IsValidForSameHierCompatibilityInXtab=function(_Pv,_Lv,_Qp,_Rx){if(_Qp){return this.IsValidForSelectedBlock(_Pv,_Lv,_Qp);}else{if(_Pv&&(_Pv==ExpAPIXml.kAxisOpUnion||_Pv==ExpAPIXml.kActionReplace)){if(_Rx){var _ZZ=this.GetOppositeAxis(_Rx);if(_ZZ){var _I3=_ZZ.GetAllBlocks();if(this.IsAnyBlockFromSameHierOrDim(_Lv,_I3)){return false;}}}return true;}else{for(var i=0;i<this.GetAxisCount();i++){var _O0=this.GetAxis(i);var _I3=_O0.GetAllBlocks();if(this.IsAnyBlockFromSameHierOrDim(_Lv,_I3)){return false;}}return true;}}};CDLDataMatrix.prototype.IsValidForSelectedBlock=function(_Pv,_Lv,_Qp){if(_Pv&&(_Pv==ExpAPIXml.kAxisOpUnion||_Pv==ExpAPIXml.kActionReplace)){if(this.isSameHierOrDimInXjoinLineage(_Lv,_Qp)||this.isSameHierOrDimInOppositAxis(_Lv,_Qp)){return false;}}else{if(this.isSameHierOrDimAsTarget(_Lv,_Qp)||this.isSameHierOrDimInXjoinLineage(_Lv,_Qp)||this.isSameHierOrDimInOppositAxis(_Lv,_Qp)){return false;}}return true;};CDLDataMatrix.prototype.isSameHierOrDimAsTarget=function(_Lv,_Qp){if(this.getDropDataHireOrDim(_Lv)==this.getBlockHireOrDim(_Qp)){return true;}return false;};CDLDataMatrix.prototype.isSameHierOrDimInXjoinLineage=function(_Lv,_Qp){var _avw=this.getDropDataHireOrDim(_Lv);var _O0=this.GetAxisById(_Qp.oAxis.GetId());var _aFF=_O0.GetBlocksInSelectedBlockXjoinLineage(_Qp);for(var i=0;i<_aFF.length;i++){var _aq0=this.getBlockHireOrDim(_aFF[i]);if(_aq0==_avw){return true;}}return false;};CDLDataMatrix.prototype.isSameHierOrDimInOppositAxis=function(_Lv,_Qp){var _avw=this.getDropDataHireOrDim(_Lv);var _O0=this.GetAxisById(_Qp.oAxis.GetId());var _abx=this.GetOppositeAxis(_O0);var _I3=_abx.GetAllBlocks();if(this.IsAnyBlockFromSameHierOrDim(_Lv,_I3)){return true;}return false;};CDLDataMatrix.prototype.IsAnyBlockFromSameHierOrDim=function(_Lv,_I3){if(_I3==null){return true;}var _avw=this.getDropDataHireOrDim(_Lv);for(var _Lx in _I3){var _avt=_I3[_Lx];var _W9=this.getBlockHireOrDim(_avt);if(_W9==_avw){return true;}}return false;};CDLDataMatrix.prototype.getDropDataHireOrDim=function(_Lv){var _Tc=this._he.metadata;var _alH=_Tc.IsFunctionSupported(ExpAPIXml.kQosMultiHierOfSameDim);_aBl=_alH?_Lv.GetHierOrDimId(_Tc,this):_Lv.GetDimId(_Tc,this);return _aBl;};CDLDataMatrix.prototype.getBlockHireOrDim=function(_FK){var _Tc=this._he.metadata;var _alH=_Tc.IsFunctionSupported(ExpAPIXml.kQosMultiHierOfSameDim);_aBl=_alH?_FK.GetHierarchyOrDimId():_FK.GetDimId();return _aBl;};CDLAxis.prototype.IsValidMetadataDrop=function(_Pv,_Qp,_Lv){if(!this._rk.IsValidActionForSameHierCompatibilityRule(_Pv,_Lv,_Qp,this)){return false;}var _Tc=this._rk._he.metadata;var _alH=_Tc.IsFunctionSupported(ExpAPIXml.kQosMultiHierOfSameDim);var _avw=_alH?_Lv.GetHierOrDimId(_Tc,this._rk):_Lv.GetDimId(_Tc,this._rk);if(_Qp){var _aFF=this.GetBlocksInSelectedBlockXjoinLineage(_Qp);var _ahq=(_Pv==ExpAPIXml.kAxisOpXjoin)||_Qp.IsOuterNestedBlock()||_Qp.IsGroupedDescendantsAtDepth();if(_ahq){_aFF.push(_Qp);}for(var i=0;i<_aFF.length;i++){var _aq0=_alH?_aFF[i].GetHierarchyOrDimId():_aFF[i].GetDimId();if(_aq0==_avw){return false;}}return true;}else{if(_Pv==ExpAPIXml.kAxisOpXjoin){var _aCX=_alH?this.GetExistedHierarchyOrDimIdArr():this.GetExistedDimIdArr();return(_alH?(!Utilities.IsInArray(_aCX,_avw)):(!_aCX[_avw]));}else{return true;}}};CDLAxis.prototype.HasEmptyBlock=function(){for(var i in this._rR){if(this.GetAllNodesInBlock(this._rR[i]).length==0){return true;}}return false;};CDLAxis.prototype.GetExistedDimIdArr=function(){var _ash=new Object();var _Tc=this._rk._he.metadata;for(var i in this._rR){var _Qk=this._rR[i].GetDimId();_ash[_Qk]=true;}return _ash;};CDLAxis.prototype.GetExistedHierarchyOrDimIdArr=function(){var _azQ=new Array();for(var i in this._rR){_azQ.push(this._rR[i].GetHierarchyOrDimId());}return _azQ;};CDLAxis.prototype.GetNodeTuples=function(_S4,_MF){if(this.GetDataObj()){return this.GetDataObj().GetNodeTuples(_S4,_MF);}return new Array();};CDLAxis.prototype.GetNonMeasureNodeTuples=function(_yv,_MF){if(this.GetDataObj()){return this.GetDataObj().GetNonMeasureNodeTuples(_yv,_MF);}return new Array();};CDLAxis.prototype.FindEqualTuple=function(_Em){if(this.GetDataObj()){return this.GetDataObj().FindEqualTuple(_Em);}return null;};CDLAxis.prototype.GetAllNodesInBlock=function(_FK){if(this.GetDataObj()){return this.GetDataObj().GetAllNodesInBlock(_FK);}return new Array();};CDLAxis.prototype.HasSDN=function(){for(var i=0;i<this._lh.length;i++){if(this._lh[i].eType==CDLAxisOp.eTypeNest){return true;}}return false;};CDLAxis.prototype.CanSupportCurrentOperation=function(op){if(this.GetAxisDepth()==0){return false;}if((op==ExpAPIXml.kPcntOfTotalFunc)&&this.HasSDN()){return false;}return true;};CDLAxis.prototype.SuppressTuples=function(_Ue){var _Jj=this._rk.GetDMAction();_Jj.type=ExpAPIXml.kActionSuppress;var _TC=new Array();var _aq1=new CDLItemTupleList(_Ue);var _avr=_c.CreateElement(ExpAPIXml.kEleTupleList,_aq1.GetAsXMLString(),true);_Jj.AddParameter(new CDLParameter(ExpAPIXml.kEleSuppressionTuples,_avr,CDLParameter.XMLType()));this._rk.SendDMAction(_Jj);};CDLAxis.prototype.RemoveSuppressionTuples=function(_UH){var _Jj=this._rk.GetDMAction();_Jj.type=ExpAPIXml.kActionDelete;_Jj.AddTargetItem(this._ks,ExpAPIXml.kEleAxis);var _9e="";for(var i=0;i<_UH.length;i++){_9e+=_c.CreateElement(ExpAPIXml.kEleTuple,_UH[i],true);}var _avr=_c.CreateElement(ExpAPIXml.kEleTupleList,_9e,true);_Jj.AddParameter(new CDLParameter(ExpAPIXml.kEleSuppressionTuples,_avr,CDLParameter.XMLType()));this._rk.SendDMAction(_Jj);};CDLAxis.prototype.SuppressMultiTuples=function(_QW,_H4){var _AE=new Array();if(_QW.length>0){var _Jj=this._rk.GetDMAction();_Jj.type=ExpAPIXml.kActionSuppress;var _8k='';for(var i=0;i<_QW.length;i++){var _asg=_QW[i];var _Ue=_asg._cb;var _aq1=new CDLItemTupleList(_Ue);_8k+=_aq1.GetAsXMLString();}var _avr=_c.CreateElement(ExpAPIXml.kEleTupleList,_8k,true);_Jj.AddParameter(new CDLParameter(ExpAPIXml.kEleSuppressionTuples,_avr,CDLParameter.XMLType()));_AE[_AE.length]=_Jj;}if(_H4.length>0){var _abx=this._rk.GetOppositeAxis(this);var _Jj=_abx._rk.GetDMAction();_Jj.type=ExpAPIXml.kActionDelete;_Jj.AddTargetItem(_abx._ks,ExpAPIXml.kEleAxis);var _9e="";for(var i=0;i<_H4.length;i++){_9e+=_c.CreateElement(ExpAPIXml.kEleTuple,_H4[i],true);}var _avr=_c.CreateElement(ExpAPIXml.kEleTupleList,_9e,true);_Jj.AddParameter(new CDLParameter(ExpAPIXml.kEleSuppressionTuples,_avr,CDLParameter.XMLType()));_AE[_AE.length]=_Jj;}this._rk.SendDMActionArray(_AE);};function CDLAxisData(_O0,_Ns){this.oAxis=_O0;this._fg=null;this._gh=new Array();this._gu=new Object();this._dY=_Ns;this._iq=new Array();};CDLAxisData.prototype.GetDataContainerId=function(){return this._dY;};CDLAxisData.prototype.GetAxis=function(){return this.oAxis;};CDLAxisData.prototype.SetFirstMember=function(oMem){this._fg=oMem;};CDLAxisData.prototype.GetFirstMember=function(){return this._fg;};CDLAxisData.prototype.AddFirstBlockMember=function(_L7,oMem){if(!this._gu[_L7]){this._gu[_L7]=oMem;}};CDLAxisData.prototype.GetFirstBlockMember=function(_L7){if(this._gu[_L7]){return this._gu[_L7];}return null;};CDLAxisData.prototype.Clear=function(){for(var i=0;i<this._gh.length;i++){var _aHC=this._gh[i];if(!_aHC._b3){var _aeW=_aHC._qR;while(_aeW){var _VW=_aeW._qR;_aeW.Clear();_aeW=_VW;}}_aHC.Clear();}Utilities.DeleteAllFromArray(this._gh);Utilities.ClearObjectArray(this._gu);Utilities.DeleteAllFromArray(this._iq);Utilities.RemoveAllChildObjects(this);};CDLAxisData.prototype.GetAxisMemberCell=function(_QZ){var _EJ=_QZ[0];var _QH=_QZ[1];if(_EJ>=this._gh.length||_QH>this._av){return null;}var _IU=this._gh[_EJ];if(_QH>_IU._av){return null;}if(_QH==_IU._av){return _IU;}else{while(_IU&&_QH<_IU._av){_IU=_IU._qR;}return _IU;}};CDLAxisData.prototype.GetAllNodesInBlock=function(_FK){var _zt=new Array();var _FU=_FK.GetAxisDepth();if(_FU==-1){return _zt;}var _QZ=new Array();_QZ[0]=0;_QZ[1]=_FU;var _ael=new Object();var _aHX=new Object();for(var i=0;i<this.GetLength();i++){_QZ[0]=i;var oMem=this.GetAxisMemberCell(_QZ);if(oMem&&!_ael[oMem._ic]&&oMem.GetBlock().GetId()==_FK.GetId()){if(!_aHX[oMem._uT]||_aHX[oMem._uT]._qR==oMem._qR){_zt.push(oMem);_ael[oMem._ic]=true;_aHX[oMem._uT]=oMem;}}}return _zt;};CDLAxisData.prototype.GetAxisDepth=function(){return this._av;};CDLAxisData.prototype.GetLength=function(){if(this._gh){return this._gh.length;}else{return 0;}};CDLAxisData.prototype.GetSelectedTuple=function(_Ir,_QH,_S4,_MF){var _agi=new Array();var _auO=(_QH==this._av-1);if(!_auO){var a=new Array(_Ir,_QH);var _LF=this.GetAxisMemberCell(a);_auO=(this._gh[_Ir]==_LF);}if(_auO){_agi=this.GetNodeTuples(_S4,_MF);if(_agi[_Ir]!=null){return _agi[_Ir].GetNodeHierarchy();}else{return new Array();}}else{return new Array();}};CDLAxisData.prototype.GetSelectedSuppressionTuple=function(_Ir,_QH,_S4,_MF){var _auO=(_QH==this._av-1);if(!_auO){var a=new Array(_Ir,_QH);var _LF=this.GetAxisMemberCell(a);_auO=(this._gh[_Ir]==_LF);}return _auO?this.GetSuppressionNodeTuple(_Ir,_QH,_S4,_MF):null;};CDLAxisData.prototype.GetInvalidDropDims=function(_FK){var _RJ=this.oAxis._rk._he.metadata;var _aGr=new Object();var _aBS=false;for(var i=0;i<this._gh.length;i++){_aBS=false;var _agJ=new Object();var a=new Array();a[0]=i;a[1]=this._av-1;var _LF=this.GetAxisMemberCell(a);var _FU=this._av-1;while(!_LF&&_FU>=0){_FU--;a[1]=_FU;_LF=this.GetAxisMemberCell(a);}Debug.Assert(_LF!=null);if(_LF!=null){while(_LF){if(_LF.GetBlock().GetId()==_FK.GetId()){_aBS=true;}var _TW=_LF.GetBlock().GetDimId();Debug.Assert(_TW&&_TW!="");if(_TW!=null&&_TW!=""){_agJ[_TW]=true;}_LF=_LF._qR;}if(_aBS){for(var s in _agJ){_aGr[s]=true;}}}}return _aGr;};CDLAxisData.prototype.GetNodeTupleByNode=function(_LF,_S4,_MF){var _aBA=new Array();if(_S4&&(!_MF(_LF))){return null;}else{_aBA.push(_LF.GetMemberId());}while(_LF._qR){if(_S4&&(!_MF(_LF._qR))){return null;}else{_aBA.unshift(_LF._qR.GetMemberId());}_LF=_LF._qR;}return new CDLNodeTuple(_aBA,this);};CDLAxisData.prototype.GetNodeTuples=function(_S4,_MF){var _6p=new Array();for(var l=0;l<this.GetLength();l++){var a=new Array();a[0]=l;a[1]=this._av-1;var _LF=this.GetAxisMemberCell(a);var _FU=this._av-1;while(!_LF&&_FU>=0){_FU--;a[1]=_FU;_LF=this.GetAxisMemberCell(a);}Debug.Assert(_LF!=null);if(_LF!=null){if(_S4&&(!_MF(_LF))){_6p.push(null);continue;}var _aBA=new Array();if(!_LF.IsNoItemsNode()){_aBA.push(_LF.GetMemberId());}var _axV=_LF.GetBlock().GetHierarchyOrDimId();var _atm=false;while(_LF._qR&&!_atm){if(_S4&&(!_MF(_LF._qR))){_atm=true;}var _9i=_LF._qR.GetBlock().GetHierarchyOrDimId();if(_9i!=_axV&&!_LF._qR.IsNoItemsNode()){_aBA.unshift(_LF._qR.GetMemberId());}_axV=_9i;_LF=_LF._qR;}if(!_atm){_6p.push(new CDLNodeTuple(_aBA,this));}else{_6p.push(null);}}}this._ch=_6p;return this._ch;};CDLAxisData.prototype.GetNonMeasureNodeTuples=function(_S4,_MF){var _Xs=null;var _6p=new Array();var _aiG=new Array();for(var l=0;l<this._gh.length;l++){var a=new Array();a[0]=l;a[1]=this._av-1;var _LF=this.GetAxisMemberCell(a);var _FU=this._av-1;while(!_LF&&_FU>=0){_FU--;a[1]=_FU;_LF=this.GetAxisMemberCell(a);}Debug.Assert(_LF!=null);if(_LF!=null){if(_S4&&(!_MF(_LF))){continue;}var _aBA=new Array();var _atm=false;var _4Q="";if(!_LF.GetBlock().HasMeasures()){_aBA.push(_LF.GetMemberId());_4Q=_LF.GetMemberId();}else{if(!_LF._qR){continue;}if(!_Xs){_Xs=_LF._qR;}else if(_Xs&&(_Xs==_LF._qR)){_atm=true;}else{_Xs=_LF._qR;}}var _axV=_LF.GetBlock().GetHierarchyOrDimId();while(_LF._qR&&!_atm){if(_S4&&(!_MF(_LF._qR))){_atm=true;}var _9i=_LF._qR.GetBlock().GetHierarchyOrDimId();if(_9i!=_axV&&!_LF._qR.GetBlock().HasMeasures()){_aBA.unshift(_LF._qR.GetMemberId());_4Q=_LF._qR.GetMemberId()+"-"+_4Q;}_axV=_9i;_LF=_LF._qR;}if(!Utilities.IsInArray(_aiG,_4Q)){if(!_atm){_6p.push(new CDLNodeTuple(_aBA,this));}_aiG.push(_4Q);}}}this._ch=_6p;return this._ch;};CDLAxisData.prototype.FindEqualTuple=function(_Em){var _ax1=this.GetNodeTuples(false);for(var i=0;i<_ax1.length;i++){if(_ax1[i].IsEqualHierarchy(_Em)){return _ax1[i];}}return null;};CDLAxisData.prototype.GetSuppressionNodeTuple=function(_Ir,_QH,_S4,_MF){var a=new Array(_Ir,_QH);var _awV=new CDLSuppressionNodeTuple();var _LF=this.GetAxisMemberCell(a);var _RJ=this.oAxis._rk._he.metadata;var _Hx;var _BX;if(_S4&&(!_MF(_LF))){return null;}else{_BX=_LF.GetMemberId();_Hx=_LF.IsCalc()?ExpAPIXml.kEleCalc:(_RJ.GetMember(_BX)?ExpAPIXml.kEleMember:ExpAPIXml.kEleMeasure);_awV.AddEntry(_BX,_Hx,_LF.GetBlock().GetId());}var _axV=_LF.GetBlock().GetHierarchyOrDimId();while(_LF._qR){if(_S4&&(!_MF(_LF._qR))){return null;}else{_LF=_LF._qR;var _9i=_LF.GetBlock().GetHierarchyOrDimId();if(_9i!=_axV){_BX=_LF.GetMemberId();_Hx=_LF.IsCalc()?ExpAPIXml.kEleCalc:(_RJ.GetMember(_BX)?ExpAPIXml.kEleMember:ExpAPIXml.kEleMeasure);_awV.AddEntry(_BX,_Hx,_LF.GetBlock().GetId());}_axV=_9i;}}return _awV;};function CDLNodeTuple(_Em,_VV){this.aNodeHier=_Em;this.oAxisData=_VV;};CDLNodeTuple.prototype.GetNodeHierarchy=function(){return Utilities.CopyArray(this.aNodeHier);};CDLNodeTuple.prototype.GetLabel=function(){return CDLBlock.GetTupleMembersLabel(null,null,this.oAxisData.GetAxis()._rk,this.aNodeHier);};CDLNodeTuple.prototype.IsEqual=function(_IE){if(Utilities.AreArrayContentsEqual(this.aNodeHier,_IE.aNodeHier)&&this.oAxisData.GetAxis()==_IE.oAxisData.GetAxis()){return true;}return false;};CDLNodeTuple.prototype.IsEqualHierarchy=function(_Em){return Utilities.AreArrayContentsEqual(this.aNodeHier,_Em);};function CDLSuppressionNodeTuple(){this._cb=new Array();};CDLSuppressionNodeTuple.prototype.AddEntry=function(_UN,_zx,_GR){this._cb.unshift(new CDLTupleEntry(_UN,_zx,_GR));};function CDLTupleEntry(_UN,_zx,_GR){this._jU=_UN;this._lW=_zx;this._tr=_GR;};CDLTupleEntry.prototype.GetValue=function(){return this._jU;};CDLTupleEntry.prototype.GetType=function(){return this._lW;};CDLTupleEntry.prototype.GetBlockPtr=function(){return this._tr;};CDLAxisMember.kNodeTypePtrXPathExpr=ExpAPIXml.kEleMemberPtr+'|'+ExpAPIXml.kEleMeasurePtr+'|'+ExpAPIXml.kEleCalcPtr+'|'+ExpAPIXml.kElePropPtr;CDLAxisMember.NodePtrToTypeMap=new Object();CDLAxisMember.NodePtrToTypeMap[ExpAPIXml.kEleMemberPtr]=ExpAxisObjType.Member;CDLAxisMember.NodePtrToTypeMap[ExpAPIXml.kEleMeasurePtr]=ExpAxisObjType.Measure;CDLAxisMember.NodePtrToTypeMap[ExpAPIXml.kEleCalcPtr]=ExpAxisObjType.Calc;CDLAxisMember.NodePtrToTypeMap[ExpAPIXml.kElePropPtr]=ExpAxisObjType.PropMember;function CDLAxisMember(_VP,_R2,_QD,_Do){this._he=_VP;this._t3=_QD.GetAxis();this._qg=_QD;this._qR=null;this._b3=null;this._m7=null;this._dg=null;this._uT=null;this._av=0;this._gQ=ExpAxisObjType.None;this._kD=false;this._d5=null;this._rk=_R2;this._dt=false;this._un=null;this._tg=null;if(_Do){this.sBlockId=Dom.GetNodeTextShallow(_Do,ExpAPIXml.kEleAxisOpExprPtr);var _FK=this._t3.GetBlock(this.sBlockId);Debug.Assert(_FK,"Bad block ptr for member");this._qg.AddFirstBlockMember(this.sBlockId,this);this._kD=(Dom.GetNodeTextShallow(_Do,ExpAPIXml.kEleIsTotal)==ExpAPIXml.kTrue);var _9t=Dom.GetImmediateChildByName(_Do,ExpAPIXml.kEleSuppressionId);if(_9t){this._un=Dom.GetNodeText(_9t);}this._tg=(!_R2.IsFullDataMode())&&(_FK._fN);var _akG=_Do.selectSingleNode(CDLAxisMember.kNodeTypePtrXPathExpr);Debug.Assert(_akG);this._gQ=CDLAxisMember.NodePtrToTypeMap[_akG.nodeName];this._uT=Dom.GetNodeText(_akG);if(Utilities.bScatterPlotGraphsEnabled){var _JS=Dom.GetNodeTextShallow(_Do,ExpAPIXml.kAttrAxisOpExprSegPtr);if(_JS){this._a1=_JS;}}if(Utilities.bSingleMemExpandEnabled&&this._gQ===ExpAxisObjType.Member){var _ai1=this._he._kX.getBlock(this.sBlockId);if(_ai1.HasSingleMemberExpandedSet()){var _W2=_ai1.GetExpandedSetByMemId(this._uT);if(_W2){_W2.oAxis=this._t3;this._ie=_W2.GetId();_W2.oAxis._rR[this._ie]=_W2;this._hG=_W2.IsExpanded();}}}this._sb=ExpAPIXml.kDefDisplayDsp;var _CH=(_FK._qS.length>0)?Dom.GetImmediateChildByName(_Do,ExpAPIXml.kEleProperties):null;if(_CH){var _JP=Dom.GetElementsByTagName(_CH,ExpAPIXml.kEleProperty);var _WG=null;this._gn=new Array();for(var i=0;i<_JP.length;i++){_WG=Dom.GetNodeText(Dom.GetImmediateChildByName(_JP[i],ExpAPIXml.kEleElcid));Debug.Assert(_WG);if(_WG){var _aiQ=this._he.metadata.GetMember(this._uT);if(_aiQ!=null){var _Z1=_aiQ.GetLevel();var _ET=(_Z1!=null?_Z1:_aiQ.GetHierarchy());if(_ET&&_ET.GetProperty(_WG)){var _UN=Dom.GetNodeText(Dom.GetImmediateChildByName(_JP[i],ExpAPIXml.kEleValue));_aiQ.AddPropertyValue(new CDLPropertyValue(_WG,_UN));this._gn.push(new CDLAxisMemberProperty(_WG,_UN,this));}}}}}}this._ic=Utilities.GenerateId();this._hi=0;this._kk=0;};CDLAxisMember.prototype.Clear=function(){if(this._gn){Utilities.DeleteAllFromArray(this._gn);}Utilities.RemoveAllChildObjects(this);this.bNulledOut=true;};CDLAxisMember.prototype.GetDisplayProperty=function(){return this._sb;};CDLAxisMember.prototype.GetPropertyCount=function(){if(this._gn){return this._gn.length;}else{return 0;}};CDLAxisMember.prototype.IsCalc=function(){if(this._gQ==ExpAxisObjType.Calc){return true;}return false;};CDLAxisMember.prototype.IsDynamicCalc=function(){if(this.IsCalc()){var _aGq=this._rk.GetCalculation(this._uT);Debug.Assert(_aGq);if(_aGq){return _aGq.IsDynamicCalc();}}return false;};CDLAxisMember.prototype.IsCustomCalc=function(){if(this.IsCalc()){var _aGq=this._rk.GetCalculation(this._uT);Debug.Assert(_aGq);if(_aGq){return _aGq.IsCustomCalc();}}return false;};CDLAxisMember.prototype.IsDuplicateCalc=function(){return this._oq?true:false;};CDLAxisMember.prototype.IsMemberBasedCalc=function(){if(this.IsCalc()){var _aGq=this._rk.GetCalculation(this._uT);Debug.Assert(_aGq);if(_aGq){return _aGq.IsMemberBasedCalc();}}return false;};CDLAxisMember.prototype.IsQuadSegmentTotal=function(){return this._a1?true:false;};CDLAxisMember.prototype.IsEditable=function(){if(this.IsCalc()){var _aGq=this._rk.GetCalculation(this._uT);if(_aGq&&(!this.IsDynamicCalc())){return _aGq.IsEditable();}}return false;};CDLAxisMember.prototype.IsNoItemsNode=function(){return false;};CDLAxisMember.CanBeUsedInFilter=function(_IU){return _IU.CanBeUsedInFilter();};CDLAxisMember.prototype.CanBeUsedInFilter=function(){if(this.IsCalc()){var _aGq=this._rk.GetCalculation(this._uT);Debug.Assert(_aGq);if(_aGq){return _aGq.CanBeUsedInFilter();}}return true;};CDLAxisMember.CanBeUsedInSort=function(_IU){return _IU.CanBeUsedInSort();};CDLAxisMember.prototype.CanBeUsedInSort=function(){if(this.IsCalc()){var _aGq=this._rk.GetCalculation(this._uT);Debug.Assert(_aGq);if(_aGq){return _aGq.CanBeUsedInSort();}}return true;};CDLAxisMember.prototype.CanUseAsDimFilter=function(){if(this.IsCalc()){var _aGq=this._rk.GetCalculation(this._uT);Debug.Assert(_aGq);if(_aGq){return _aGq.CanUseAsDimFilter();}}return false;};CDLAxisMember.CanBeUsedInSuppression=function(_IU){return _IU.CanBeUsedInSuppression();};CDLAxisMember.prototype.CanBeUsedInSuppression=function(){if(this.IsCalc()){var _aGq=this._rk.GetCalculation(this._uT);Debug.Assert(_aGq);if(_aGq){return _aGq.CanBeUsedInSuppression();}}return true;};CDLAxisMember.CanBeUseAsDrillThroughContext=function(_IU){return _IU.CanBeUseAsDrillThroughContext();};CDLAxisMember.prototype.CanBeUseAsDrillThroughContext=function(){var _ahA=this._he.GetCurrentCrosstab();if(_ahA&&_ahA._i0){return((this._gQ==ExpAxisObjType.Member||this._gQ==ExpAxisObjType.Measure)&&(!this.IsSummaryOrNestedSummary()));}return true;};CDLAxisMember.prototype.IsSubtotal=function(){if(this.IsCalc()){var _aGq=this._rk.GetCalculation(this._uT);Debug.Assert(_aGq);if(_aGq){return _aGq.IsSubtotal();}}return false;};CDLAxisMember.prototype.IsRemainder=function(){if(this.IsCalc()){var _aGq=this._rk.GetCalculation(this._uT);Debug.Assert(_aGq);if(_aGq){return _aGq.IsRemainder();}}return false;};CDLAxisMember.prototype.IsInvalidCalc=function(){if(this.IsCalc()){var _aGq=this._rk.GetCalculation(this._uT);if(_aGq){return(!_aGq.IsValid());}}return false;};CDLAxisMember.prototype.IsExcludedSubtotal=function(){if(this.IsCalc()){var _aGq=this._rk.GetCalculation(this._uT);Debug.Assert(_aGq);if(_aGq){return _aGq.IsFilterSubtotal();}}return false;};CDLAxisMember.prototype.IsNotExcludedSubtotal=function(){if(this.IsCalc()){var _aGq=this._rk.GetCalculation(this._uT);Debug.Assert(_aGq);if(_aGq){return _aGq.IsPassedFilterSubtotal();}}return false;};CDLAxisMember.prototype.IsPhantom=function(){return this._dt;};CDLAxisMember.prototype.CanHide=function(){if(this.IsDynamicCalc()){return true;}var _aje=COTValidation.BlockTypeToFeatureRules[this.GetBlock().eType]['hide'];if((this.IsCalc()&&!this.IsDynamicCalc())||this.IsNoItemsNode()||!_aje){return false;}return true;};CDLAxisMember.prototype.IsSummaryOrNestedSummary=function(){return(this.IsSummaryMemOrCalc()||(this._qR&&this._qR.IsSummaryOrNestedSummary()));};CDLAxisMember.prototype.IsSummaryMemOrCalc=function(){if(this._kD||this.IsSummaryCalc()){return true;}return false;};CDLAxisMember.prototype.IsSummaryCalc=function(){if(this.IsCalc()){var _aGq=this._rk.GetCalculation(this._uT);Debug.Assert(_aGq);if(_aGq){return _aGq.IsSummary();}}return false;};CDLAxisMember.prototype.IsSummaryMem=function(){if(this.GetBlock().IsHAMC()){return false;}return this._kD;};CDLAxisMember.prototype.GetProperty=function(_PD){if(this._gn&&this._gn[_PD]){return this._gn[_PD];}return null;};CDLAxisMember.prototype.GetPropertyLabel=function(_PD){Debug.Assert(this._gn);Debug.Assert(this._gn[_PD]);if(this._gn&&this._gn[_PD]){var _aiQ=this._he.metadata.GetMember(this._uT);if(_aiQ==null)return "";var _S8=_aiQ.GetLevel();var _ET=(_S8!=null?_S8:_aiQ.GetHierarchy());if(_ET){return _ET.GetProperty(this._gn[_PD]._ks)._p8;}}return "";};CDLAxisMember.prototype.GetPropertyValue=function(_PD){Debug.Assert(this._gn);Debug.Assert(this._gn[_PD]);if(this._gn&&this._gn[_PD]){return this._gn[_PD]._jU;}return null;};CDLAxisMember.prototype.GetPropertyById=function(_O5){for(var i=0;this._gn&&i<this._gn.length;i++){if(this._gn[i]._ks==_O5){return this._gn[i];}}return null;};CDLAxisMember.prototype.GetAxis=function(){return this._t3;};CDLAxisMember.prototype.GetBlock=function(){return this._t3.GetBlock(this.sBlockId);};CDLAxisMember.prototype.GetMemberId=function(){return this._uT;};CDLAxisMember.prototype.GetUniqueID=function(){return this._ic;};CDLAxisMember.prototype.GetDepth=function(){return this._av;};CDLAxisMember.prototype.GetSummaryLevel=function(){var _RJ=this._he.metadata;if(_RJ.GetData(this._uT)){if(_RJ.GetMember(this._uT)){var oMem=_RJ.GetMember(this._uT);var _Ts=oMem.GetLevel().GetHierarchy();if(_Ts.HasLevel()){return _Ts.GetHierarchyOrdinalByLevel(oMem._iY);}else{return oMem.GetDepthInFamilyTree();}}else if(_RJ.GetMeasure(this._uT)){var _NS=_RJ.GetMeasure(this._uT);return _NS.GetDepthInFamilyTree();}}return 0;};CDLAxisMember.prototype.GetObjType=function(){return this._gQ;};CDLAxisMember.prototype.GetMemberType=function(){var _zx=this.GetObjType();if(_zx==ExpAxisObjType.Member){if(this._he.metadata.GetMeasure(this._uT)){_zx=ExpAxisObjType.Measure;}}return _zx;};CDLAxisMember.prototype.GetLabel=function(){var _UY=this._he.metadata.GetMember(this._uT);if(_UY){return _UY.GetLabel();}var _Yu=this._rk.GetCalculation(this._uT);if(_Yu){return _Yu._p8;}var _SE=this._he.metadata.GetMeasure(this._uT);if(_SE){return _SE._p8;}else{return this._uT;}};CDLAxisMember.prototype.GetDescription=function(){if(Utilities.bScatterPlotGraphsEnabled&&this._a1){var _Xx=this.GetBlock().GetQuadSegmentById(this._a1);return _Xx?_Xx.GetTooltip():null;}var _Yu=this._rk.GetCalculation(this._uT);var _RJ=this._t3._rk._he.metadata;if(_Yu){return _Yu.GetDescription();}else if(_RJ.GetMemberOrMeasure(this._uT)){if(_RJ.GetMemberOrMeasure(this._uT).GetLineageLabel){return _RJ.GetMemberOrMeasure(this._uT).GetLineageLabel();}}return null;};CDLAxisMember.prototype.GetChildrenLength=function(){var _ze=this._dg;var _Oi=0;while(_ze!=null){_Oi++;_ze=_ze._b3;}return _Oi;};CDLAxisMember.prototype.ReDistributeContentHeights=function(_Gn){var _aGV=this.GetChildrenLength();var _ags=null;var _akz=this.GetPropertyCount()+1+(_Gn?_Gn:0)-this._kk;if(_akz<=0){return;}var _aI0=this._dg;while(_aI0){var _5O=Utilities.GetObjIndex(this._qg._gh,_aI0);var _aEE=_akz/_aGV;if(_5O>-1){this._qg._iq[_5O]+=_aEE;_aI0=_aI0._b3;}else{_aI0.ReDistributeContentHeights(_aEE);_aI0=_aI0._b3;}}};CDLAxisMember.prototype.GetAllDescendantsLength=function(_ze,_Oi){_ze=this._dg;while(_ze!=null){_Oi++;_Oi=_ze.GetAllDescendantsLength(_ze,_Oi);_ze=_ze._b3;}return _Oi;};CDLAxisMember.prototype.DrillDown=function(_GM){var _Jj=this._rk.GetDMAction();_Jj.type=ExpAPIXml.kActionDrill;_Jj.AddTargetItem(this._t3._ks,ExpAPIXml.kEleAxis);_Jj.AddTargetItem(this.sBlockId,ExpAPIXml.kEleAxisOpExpression);_Jj.AddSource(this.GetMemberId(),this.GetObjType());_Jj._eW(ExpAPIXml.kDrillType,ExpAPIXml.kDown);if(_GM){return _Jj;}else{this._rk.SendDMAction(_Jj);return null;}};CDLAxisMember.prototype.DrillUp=function(_Jl,_GM){if(!_Jl||_Jl==""){var _Jl=this.GetMemberId();}return this.GetBlock().DrillUp(_Jl,_GM);};CDLAxisMember.prototype.GetDeleteAction=function(){var _Jj=null;if(this.CanDelete()){var _Jj=this.GetBlock().GetDeleteAction();var _61=this._t3._rk.GetCalculation(this.GetMemberId());if(_61){_Jj.AddSource(this.GetMemberId(),ExpAPIXml.kEleCalc);}else{var _RJ=this._t3._rk._he.metadata;_Jj.SetMemberMeasureSource(_RJ,this.GetMemberId());}}return _Jj;};CDLAxisMember.prototype.GetHideAction=function(){var _Jj=null;if(this.IsSummaryMemOrCalc()&&this.CanHide()){var _Jj=this.GetBlock().getSetPropertyAction("summary",false);}else if(this.IsSubtotal()){var _Jj=this.GetBlock().getSetPropertyAction(ExpAPIXml.eCalcSubtotalVisibleItems,false);}else if(this.IsRemainder()){var _Jj=this.GetBlock().getSetPropertyAction(ExpAPIXml.eCalcRemainder,false);}else if(this.IsExcludedSubtotal()){var _Jj=this.GetBlock().getSetPropertyAction(ExpAPIXml.eCalcFLAggregate,false);}else if(this.IsNotExcludedSubtotal()){var _Jj=this.GetBlock().getSetPropertyAction(ExpAPIXml.eCalcPassedFLAggregate,false);}else if(this.IsDynamicCalc()){Debug.Assert(false);}else if(this.CanHide()){var _Jj=this.GetBlock().GetDeleteAction();var _RJ=this._t3._rk._he.metadata;_Jj.SetMemberMeasureSource(_RJ,this.GetMemberId());}return _Jj;};CDLAxisMember.prototype.CanExclude=function(){if(this.IsCalc()||!this.GetBlock().CanExclude()||this.IsNoItemsNode()||this.IsSummaryMem()){return false;}return true;};CDLAxisMember.prototype.CanDelete=function(){var _amN=this.IsDynamicCalc()||this.IsNoItemsNode()||this.IsPhantom();if((this.IsCalc()&&!this.IsDynamicCalc())||(!_amN&&this.GetBlock().IsHAMC())){return true;}return false;};CDLAxisMember.prototype.GetExcludeAction=function(){var _Jj=null;if(this.CanExclude()){var _Jj=this.GetBlock().GetExcludeAction();_Jj.AddSource(this.GetMemberId(),ExpAPIXml.kEleMember);}return _Jj;};CDLAxisMember.prototype.IsTopMember=function(){var _ax5=this._he.metadata.GetMemberOrMeasure(this._uT);if(_ax5&&(_ax5._qR!=null)){return false;}return true;};CDLAxisMember.prototype.UpdateChildLines=function(_IR){this._hi+=_IR;this._kk+=_IR+1;};CDLAxisMember.prototype.UpdateExtraLineCountInSameRow=function(){var _aaf=this.GetPropertyCount();var _2E=this._qg._iq;if((!_2E[this._av])||(_2E[this._av]<_aaf)){_2E[this._av]=_aaf;}};function CDLAxisMemberProperty(id,_UN,_zU){this._ks=id;this._jU=_UN;this._f1=_zU;this._hY=true;};CDLAxisMemberProperty.prototype.IsEnabled=function(){return this._hY;};CDLAxisMemberProperty.prototype.Disable=function(_Le){this._hY=false;var _AE=new Array();var _Jj=this._f1._t3._rk.GetDMAction();_Jj.type=ExpAPIXml.kActionDelete;_Jj.AddSource(this._ks,ExpAPIXml.kEleProperty);_Jj.AddTargetItem(this._f1._t3._ks,ExpAPIXml.kEleAxis);_Jj.AddTargetItem(this._f1.sBlockId,ExpAPIXml.kEleAxisOpExpression);_AE[_AE.length]=_Jj;if(!_Le){this._f1._t3._rk.SendDMActionArray(_AE);}return _Jj;};function CDLAbsBlock(_Od,_AT){this.sExprId=_Od;this.oDataMgr=_AT;this._yf=CDLBlock.iDefaultSize;this._fZ=true;this._hF=false;this._va=false;this._w6=1000;this._mF=null;this._vG=null;this._xO="";this._lu="";this._mm=ExpAPIXml.kEleAxisOpExprSorttypeDefault;this._xi=-1;this._hj=null;this._c3=true;this._V=true;this._ga=true;this._aJ=true;this._hR=true;this._ma=true;this._jk=new Array();this._wM=new Array();this._kL=new Array();this._qS=new Array();this._qX="";};CDLAbsBlock.eTypeChildren=1;CDLAbsBlock.eTypeMemberSet=2;CDLAbsBlock.eTypeLevelMembers=3;CDLAbsBlock.eTypeMeasure=4;CDLAbsBlock.eTypeMeasureChildren=5;CDLAbsBlock.eTypeDescendants=6;CDLAbsBlock.eTypeNamedSet=7;CDLAbsBlock.eTypeNested=8;CDLAbsBlock.eTypeV5=9;CDLAbsBlock.eTypeSegmtQuadrant=10;CDLAbsBlock.iMaxHAMCTooltipLength=500;CDLAbsBlock.BlockTypeMap=new Object();CDLAbsBlock.BlockTypeMap[ExpAPIXml.kAxisExprLevelMembers]=CDLAbsBlock.eTypeLevelMembers;CDLAbsBlock.BlockTypeMap[ExpAPIXml.kAxisExprMemberset]=CDLAbsBlock.eTypeMemberSet;CDLAbsBlock.BlockTypeMap[ExpAPIXml.kAxisExprMeasure]=CDLAbsBlock.eTypeMeasure;CDLAbsBlock.BlockTypeMap[ExpAPIXml.kAxisExprMeasureChildren]=CDLAbsBlock.eTypeMeasureChildren;CDLAbsBlock.BlockTypeMap[ExpAPIXml.kAxisExprDescendants]=CDLAbsBlock.eTypeDescendants;CDLAbsBlock.BlockTypeMap[ExpAPIXml.kAxisExprNamedSet]=CDLAbsBlock.eTypeNamedSet;CDLAbsBlock.BlockTypeMap[ExpAPIXml.kAxisExprNested]=CDLAbsBlock.eTypeNested;CDLAbsBlock.BlockTypeMap[ExpAPIXml.kAxisExprV5]=CDLAbsBlock.eTypeV5;CDLAbsBlock.BlockTypeMap[ExpAPIXml.kAxisExprChildren]=CDLAbsBlock.eTypeChildren;CDLAbsBlock.BlockTypeMap[ExpAPIXml.kAxisExprSegmtQuadrant]=CDLAbsBlock.eTypeSegmtQuadrant;CDLAbsBlock.prototype.GetType=function(){return this.eType;};CDLAbsBlock.prototype.IsMemberListMandatory=function(){if(this.eType==CDLAbsBlock.eTypeMemberSet||this.eType==CDLAbsBlock.eTypeMeasure||this._hj!=null||this.eType==CDLAbsBlock.eTypeV5||this.eType==CDLAbsBlock.eTypeSegmtQuadrant){return false;}return true;};CDLAbsBlock.prototype.ProcessXML=function(_Do){this.oMeta=this.oDataMgr.metadata;var _aDT=_Do.getAttribute(ExpAPIXml.kEleAxisOpExprType);this.eType=CDLAbsBlock.BlockTypeMap[_aDT];this.sName="";var _ahD=_Do.getAttribute(ExpAPIXml.kEleAxisOpExprName);if(_ahD){this.sName=_ahD;}this.bRemainderEnabled=(_Do.getAttribute(ExpAPIXml.kEleAxisOpExprRemainder)===ExpAPIXml.kTrue);this.bVisibleEnabled=(_Do.getAttribute(ExpAPIXml.kEleAxisOpExprShowVisible)===ExpAPIXml.kTrue);this.bFilterAggEnabled=(_Do.getAttribute(ExpAPIXml.kEleAxisOpExprFilterAggr)===ExpAPIXml.kTrue);this.bPassedFilterAggEnabled=(_Do.getAttribute(ExpAPIXml.kEleAxisOpExprPassedFilterAggr)===ExpAPIXml.kTrue);this.bSubTotalEnabled=(_Do.getAttribute(ExpAPIXml.kEleAxisOpExprSubTotal)===ExpAPIXml.kTrue);this._fZ=(_Do.getAttribute(ExpAPIXml.kEleAxisOpExprSummary)===ExpAPIXml.kTrue);var _ayM=_Do.getAttribute(ExpAPIXml.kEleAxisOpExprBlockSize);if(_ayM){this._b8=_ayM;}var _Zq=_Do.getAttribute(ExpAPIXml.kEleAxisOpExprCanDelete);if(_Zq&&(_Zq==ExpAPIXml.kFalse)){this._c3=false;}var _Zq=_Do.getAttribute(ExpAPIXml.kEleAxisOpExprCanAscend);if(_Zq&&(_Zq==ExpAPIXml.kFalse)){this._V=false;}var _Zq=_Do.getAttribute(ExpAPIXml.kEleAxisOpExprCanDescend);if(_Zq&&(_Zq==ExpAPIXml.kFalse)){this._ga=false;}var _af3=_Do.getAttribute(ExpAPIXml.kEleAxisOpExprCanCreateCS);if(_af3&&(_af3==ExpAPIXml.kFalse)){this._aJ=false;}var _aek=_Do.getAttribute(ExpAPIXml.kEleCalcCanUseAsDimFlt);if(_aek&&(_aek==ExpAPIXml.kFalse)){this._hR=false;}var _arb=_Do.getAttribute(ExpAPIXml.kEleAxisOpExprCanUseAsGoToParam);if(_arb&&(_arb==ExpAPIXml.kFalse)){this._ma=false;}this._hF=(_Do.getAttribute(ExpAPIXml.kEleAxisOpExprIsLocked)===ExpAPIXml.kTrue);this._va=(_Do.getAttribute(ExpAPIXml.kEleAxisOpExprIsLockable)===ExpAPIXml.kTrue);this._fN=(_Do.getAttribute(ExpAPIXml.kEleAxisOpExprIsFastModeAccurate)===ExpAPIXml.kTrue);this._aL=(_Do.getAttribute(ExpAPIXml.kAttrExpanded)===ExpAPIXml.kTrue);if(Utilities.bSingleMemExpandEnabled){this._ua=Utilities.IsInArray(this.oDataMgr._kX._es,this.sExprId);}var _ayW=_Do.getAttribute(ExpAPIXml.kEleAnnotation);if(_ayW){this._d0=_ayW;}var _FU=_Do.getAttribute(ExpAPIXml.kDepth);if(_FU){this._xi=parseInt(_FU,10);}var _atB=_Do.getAttribute(ExpAPIXml.kEleRelParentBlock);if(_atB){this._hj=_atB;}var _ar5=_Do.getAttribute(ExpAPIXml.kEleAxisOpExprSorttype);if(_ar5){this._mm=_ar5;}var _aCl=Dom.GetImmediateChildByName(_Do,ExpAPIXml.kEleFLSortMeasure);if(_aCl){var _aBU=_aCl.childNodes[0];Debug.Assert(_aBU!=null);if(_aBU.nodeName==ExpAPIXml.kEleDefaultSortMeasure){this._k2=DefaultConstants.kDefMeasure;}else{this._k2=Dom.GetNodeTextShallow(_aBU,ExpAPIXml.kEleObjectPtr);}}var _am0=_Do.getAttribute(ExpAPIXml.kEleAxisOpExprSortProperty);if(_am0){this._fR=_am0;}var _axs=_Do.getAttribute(ExpAPIXml.kEleAxisOpExprSortLabel);if(_axs){this._cc=_axs;}var _axH=Dom.GetImmediateChildByName(_Do,ExpAPIXml.kEleAxisOpExprSortMember);if(_axH){var _aou=_axH.selectSingleNode(ExpAPIXml.kEleDefaultSortMember);if(_aou){this._qs.push(DefaultConstants.kDefScope);}else{var _aiY=_axH.selectNodes(ExpAPIXml.kXpathExprObjPtrText);for(i=0;i<_aiY.length;i++){this._qs.push(_aiY[i].nodeValue);}}}var _aqI=Dom.GetImmediateChildByName(_Do,ExpAPIXml.kEleSubset);if(_aqI){this._mF=new CDLFilterExpr(this.oDataMgr);this._mF.ProcessTopBottom(_aqI);}var _aff=Dom.GetImmediateChildByName(_Do,ExpAPIXml.kEleUserDefFilter);if(_aff){var _7h=Dom.GetImmediateChildByName(_aff,ExpAPIXml.kEleUserDefFilterExpr);var _H1=Dom.GetImmediateChildByName(_7h,CDLMathMLOperands.Apply);if(_H1){var _WQ=_H1.firstChild.nodeName;this._vG=new CDLUserDefFilterExpr(this.oDataMgr,_WQ);this._vG._lW=Dom.GetNodeTextShallow(_aff,ExpAPIXml.kEleOrgFilterExprType);var _TL=Dom.GetNodeTextShallow(_aff,ExpAPIXml.kEleGroupedExpr);this._vG._nt=(_TL===ExpAPIXml.kTrue)?true:false;this._vG._ni._cS=true;this._vG._ni=this._vG.ProcessUserDefFilter(_H1,this._vG._ni);if(this._vG._nt){var _5d=new CDLMathMLExprNode(null,false,true);_5d.AddOperands(this._vG._ni,null,CDLMathMLOperands.Apply);this._vG._ni=_5d;}}}var _72=(this.IsMeasureBlock()||this.IsChildrenMeasureBlock())?ExpAPIXml.kEleMeasurePtr:ExpAPIXml.kEleMemberPtr;this._nx=new Array();var _aiO=false;var _abI=Dom.GetImmediateChildByName(_Do,ExpAPIXml.kEleMemberList);if(_abI){var _zt=Dom.GetElementsByTagName(_abI,ExpAPIXml.kEleAxisExprMember);Debug.Assert((_zt.length>0)||(!this.IsMemberListMandatory()),"Block with no definition!");for(var i=0;i<_zt.length;i++){var _8E=Dom.GetImmediateChildByName(_zt[i],_72);Debug.Assert(_8E);var _8A=Dom.GetNodeText(_8E);this._nx.push(_8A);if(this.eType==CDLAbsBlock.eTypeLevelMembers){this._dl=_8A;}_aiO=true;}}if(!_aiO&&this.IsMemberListMandatory()){var _Co=this.oDataMgr.appobj.oResources;var _2h=_Co.ReplaceParam("MES_INVALID_BLOCK_DEFINITION_DETAILS",1,this.sExprId);CUIDialogMgr.DisplayMessageBox(CUIConfirmDlg._xI,"MES_BAD_SERVER_RESPONSE",_2h);return;}var _awe=Dom.GetImmediateChildByName(_Do,ExpAPIXml.kEleHiddenList);if(_awe){var _2c=Dom.GetElementsByTagName(_awe,ExpAPIXml.kEleAxisExprMember);for(var i=0;i<_2c.length;i++){var _8E=Dom.GetImmediateChildByName(_2c[i],_72);Debug.Assert(_8E);this._wM.push(Dom.GetNodeText(_8E));}}var _Yw=Dom.GetImmediateChildByName(_Do,ExpAPIXml.kEleExcludedList);if(_Yw){var _aoA=Dom.GetElementsByTagName(_Yw,ExpAPIXml.kEleAxisExprMember);for(var i=0;i<_aoA.length;i++){var _8E=Dom.GetImmediateChildByName(_aoA[i],_72);Debug.Assert(_8E);this._kL.push(Dom.GetNodeText(_8E));}}this._d1=new Object();var _7A=Dom.GetImmediateChildByName(_Do,ExpAPIXml.kEleExpandedMemList);if(_7A){var _axt=Dom.GetElementsByTagName(_7A,ExpAPIXml.kEleAxisExprMember);for(var i=0;i<_axt.length;i++){var _aCE=_axt[i].getAttribute(ExpAPIXml.kAttrMemberPtr);this._d1[_aCE]=_axt[i].getAttribute(ExpAPIXml.kAttrExpandedSet);if(Utilities.bSingleMemExpandEnabled){this.oDataMgr._kX._es.push(_axt[i].getAttribute(ExpAPIXml.kAttrExpandedSet));}}}var _ID=Dom.GetElementsByTagName(_Do,ExpAPIXml.kElePropId);for(var i=0;i<_ID.length;i++){this._qS.push(_ID[i].getAttribute(ExpAPIXml.kElePropPtr));}var _avg=Dom.GetImmediateChildByName(_Do,ExpAPIXml.kEleAxisOpExprLockContext);if(_avg){for(var i=0;i<_avg.childNodes.length;i++){this._jk.push(_avg.childNodes[i].getAttribute(ExpAPIXml.kEleElcid));}}var _Xq=Dom.GetImmediateChildByName(_Do,ExpAPIXml.kEleAxisOpExprV5BlockProps);if(_Xq){this._lu=_Xq.getAttribute(ExpAPIXml.kEleHierarchyPtr);var _VU=this.oDataMgr.metadata.GetHierarchyById(this._lu);this._xO=_VU.GetDimension().GetId();this._qX=_Xq.getAttribute(ExpAPIXml.kEleLabel);}if(Utilities.bScatterPlotGraphsEnabled){if(this.eType==CDLAbsBlock.eTypeSegmtQuadrant){this.oDataMgr.GetCurrentDataMatrix()._bF=this.sExprId;this.processQuadSegmentData(_Do);}}};CDLAbsBlock.prototype.processQuadSegmentData=function(_B3){var _ad8=Dom.GetImmediateChildByName(_B3,ExpAPIXml.kEleAxisOpExprSegments);var _alT=Dom.GetImmediateChildrenByName(_ad8,ExpAPIXml.kEleAxisOpExprSegment);this._kB=new Object();for(var i=0;i<_alT.length;i++){var _53=_alT[i];var _Q8=Dom.GetNodeTextShallow(_53,ExpAPIXml.kEleAxisOpSegId);var _aaH=Dom.GetNodeTextShallow(_53,ExpAPIXml.kEleAxisOpSegCaption);this._kB[_Q8]=new CDLQuadrantSegment(_Q8,_aaH,this);}var _atn=Dom.GetImmediateChildByName(_B3,ExpAPIXml.kEleAxisOpExprQuadSegments);var _aB6=Dom.GetImmediateChildByName(_atn,ExpAPIXml.kEleAxisOpExprSegmentRules);for(var i=0;i<_aB6.childNodes.length;i++){var _1q=_aB6.childNodes[i];var _aGF=Dom.GetNodeTextDeep(_1q,ExpAPIXml.kEleMeasurePtr);var _RJ=this.oDataMgr.metadata;var _MZ=_RJ.GetMeasure(_aGF).GetLabel();var _abJ=parseInt(Dom.GetNodeTextDeep(_1q,ExpAPIXml.kEleAxisOpSegMeaCurValue));var _WL=parseInt(Dom.GetNodeTextDeep(_1q,ExpAPIXml.kEleAxisOpSegMeaMaxValue));var _0H=parseInt(Dom.GetNodeTextDeep(_1q,ExpAPIXml.kEleAxisOpSegMeaMinValue));var _ap0=Math.round((_WL-_0H)*0.05);if(i===0){this._hZ=_aGF;this._oy=_MZ;this._uZ=_abJ;this._q3=_0H;this._bW=_WL;this._k1=this._q3-_ap0;this._p9=this._bW+_ap0;}else{this._ei=_aGF;this._dL=_MZ;this._pd=_abJ;this._nZ=_0H;this._mh=_WL;this._wi=this._nZ-_ap0;this._do=this._mh+_ap0;}}var _aIz=Dom.GetImmediateChildrenByName(_atn,ExpAPIXml.kEleAxisOpExprQuadSegment);for(var i=0;i<_aIz.length;i++){var _53=_aIz[i];var _JS=_53.getAttribute(ExpAPIXml.kAttrAxisOpExprSegPtr);var _aET=parseInt(_53.getAttribute(ExpAPIXml.kAttrAxisOpExprQuadNum));var _AP=_53.getAttribute(ExpAPIXml.kEleCalcPtr);var _Xx=this._kB[_JS];if(_Xx){_Xx.SetQuadrandNum(_aET);switch(_aET){case 1:_Xx.SetMinXMeasure(this._k1);_Xx.SetMaxXMeasure(this._uZ);_Xx.SetMinYMeasure(this._wi);_Xx.SetMaxYMeasure(this._pd);break;case 2:_Xx.SetMinXMeasure(this._uZ);_Xx.SetMaxXMeasure(this._p9);_Xx.SetMinYMeasure(this._wi);_Xx.SetMaxYMeasure(this._pd);break;case 3:_Xx.SetMinXMeasure(this._k1);_Xx.SetMaxXMeasure(this._uZ);_Xx.SetMinYMeasure(this._pd);_Xx.SetMaxYMeasure(this._do);break;case 4:_Xx.SetMinXMeasure(this._uZ);_Xx.SetMaxXMeasure(this._p9);_Xx.SetMinYMeasure(this._pd);_Xx.SetMaxYMeasure(this._do);break;}_Xx.SetCalcPtr(_AP);}}};CDLAbsBlock.prototype.GetQuadSegmentById=function(_JS){return this._kB[_JS];};CDLAbsBlock.prototype.GetName=function(){return this.sName;};CDLAbsBlock.prototype.GetDataMemberIds=function(){return this._nx;};CDLAbsBlock.prototype.GetLastDataMemberId=function(){if(this._nx.length>0){var _PQ=this._nx.length-1;while(_PQ>=0){if(this.oDataMgr.metadata.GetData(this._nx[_PQ])){return this._nx[_PQ];}_PQ--;}}return null;};CDLAbsBlock.prototype.GetDrillThroughSearchData=function(){var _RJ=this.oDataMgr.metadata;var _FZ=new Array();if(this.IsLevelMembers()){_FZ.push(this.oDataMgr.metadata.GetLevel(this._dl));}else if(this.IsNamedSet()){_FZ.push(this.oDataMgr.metadata.GetNamedSet(this.GetLastDataMemberId()));}else if(this.IsMemberSet()||this.IsMeasureBlock()){for(var i=0;i<this._nx.length;i++){if(_RJ.GetMemberOrMeasure(this._nx[i])){_FZ.push(_RJ.GetMemberOrMeasure(this._nx[i]));}}}else if(this.IsChildren()||this.IsChildrenMeasureBlock()){_FZ.push(_RJ.GetData(this.GetLastDataMemberId()));}else if(this.IsOuterNestedBlock()){var _aeV=this.GetRootParentBlock();_FZ=_aeV.GetDrillThroughSearchData();}else if(this.IsDescendantsAtDepth()){var _aeV=this.GetRootParentBlock();var _TW=this.GetDimId();var _Co=this.oDataMgr.appobj.oResources;var _CN=_aeV.GetDrillThroughSearchData();for(var j=0;j<_CN.length;j++){var _BM=_CN[j].GetLabel();var _FU=this.GetAbsoluteDepth();if(_FU>1){_BM=_Co.ReplaceParam('IDS_CONTEXTBAR_DESCENDANTS_ITEM',1,_BM);_BM=_Co.ReplaceParam(_BM,2,_FU);}_FZ.push(new CDLBLKDataPair(_TW,_CN[j],_BM,ExpAPIXml.kChildAtDepth,_FU));}}return _FZ;};CDLAbsBlock.prototype.GetSearchData=function(){var _RJ=this.oDataMgr.metadata;var _FZ=null;if(this.IsLevelMembers()||this.IsNamedSet()||this.IsV5Block()){return null;}else if(this.IsMemberSet()){for(var i=0;i<this._nx.length;i++){if(_FZ==null){_FZ=new Object();}if(i==0){var _asN=_RJ.GetMemberOrMeasure(this._nx[i]).GetRootMember();_FZ[_asN.GetId()]=_asN;}if(_RJ.GetMemberOrMeasure(this._nx[i])){var _VW=_RJ.GetMemberOrMeasure(this._nx[i]).GetParent();if(_VW){_FZ[_VW.GetId()]=_VW;}}}}else if(this.IsMeasureBlock()){_FZ=new Object();_FZ[this.GetDimId()]=_RJ.GetDimById(this.GetDimId());}else if(this.IsChildren()||this.IsChildrenMeasureBlock()){_FZ=new Object();_FZ[this.GetLastDataMemberId()]=_RJ.GetData(this.GetLastDataMemberId());}else{if(_RJ.IsFunctionSupported(ExpAPIXml.kQosHierarchySrch)){_FZ=new Object();_FZ[this.GetDimId()]=_RJ.GetDimById(this.GetDimId());}else{return null;}}return _FZ;};CDLAbsBlock.prototype.GetAxisDepth=function(){if(this.GetFirstNode()){return this.GetFirstNode().GetDepth();}return-1;};CDLAbsBlock.prototype.GetRelativeDepth=function(){return this._xi;};CDLAbsBlock.prototype.GetAbsoluteDepth=function(){if(this.IsOuterNestedBlock()&&this.IsChildren()){return 1;}if(this._hj!=null){var _FU=this._xi;var _1o=this.oDataMgr._kX.getBlock(this._hj);Debug.Assert(_1o!=null);while(_1o&&(_1o._xi!=-1)){_FU+=_1o._xi;_1o=this.oDataMgr._kX.getBlock(_1o._hj);}if(_1o&&_1o.IsChildren()){_FU++;}return _FU;}else{return this._xi;}};CDLAbsBlock.prototype.GetLockContextBlockIds=function(){return this._jk;};CDLAbsBlock.prototype.GetContextLabel=function(){if(!this.IsHAMC()){var _RJ=this.oDataMgr.metadata;var _7v=this.GetFilterExprTooltip();if(this.IsChildren()&&_7v==""){if(_RJ.GetMember(this.GetLastDataMemberId()).IsRootMember()){return null;}}if(_7v==""){var _Hq='IDS_BLOCKPROP_CONTEXT_DIM_FILTER';}else{var _Hq='IDS_BLOCKPROP_CONTEXT_DIM_FILTER_W_EXCLUSIONS';}var _79=_RJ.GetDimById(this.GetDimId()).GetLabel();_Hq=this.oDataMgr.appobj.oResources.ReplaceParam(_Hq,1,_79);_Hq=this.oDataMgr.appobj.oResources.ReplaceParam(_Hq,2,this.GetLabel());if(_7v!=""){_Hq=this.oDataMgr.appobj.oResources.ReplaceParam(_Hq,3,_7v);}return _Hq;}else{return this.getHAMCFilterContext();}};CDLAbsBlock.prototype.getHAMCFilterDescription=function(){var _RJ=this.oDataMgr.metadata;var _Co=this.oDataMgr.appobj.oResources;if(this._nx.length==0){return _Co.ReplaceParam('IDS_BLOCKPROP_CONTEXT_OR_FILTER_CALC_ONLY_HAMC',1,this.GetLabel());}var _Hq='IDS_BLOCKPROP_CONTEXT_OR_FILTER';var _79=_Co.ReplaceParam('IDS_CONTEXTBAR_LIST_ITEM',1,_RJ.GetDimById(this.GetDimId()).GetLabel());_Hq=_Co.ReplaceParam(_Hq,1,_79);if(this._nx.length<2){_Hq=_Co.ReplaceParam(_Hq,2,_RJ.GetDataLabel(this._nx[0]));}else{var _Bu=new Array();for(var i=0;i<this._nx.length;i++){_Bu.push(_RJ.GetDataLabel(this._nx[i]));}var _aHB=_Co.ReplaceParamList('IDS_BLOCKPROP_CONTEXT_OR_FILTER_TOKEN_MEMBERS',_Bu);_Hq=_Co.ReplaceParam(_Hq,2,_aHB);}var _apV='IDS_CONTEXTBAR';if(this.IsLocked()){_apV+='_LOCKED';}if(this.HasExcludedList()||this.HasTopBottomRule()){_apV+='_FILTERED';}if(_apV!='IDS_CONTEXTBAR'){_apV+='_BLOCK';_Hq=_Co.ReplaceParam(_apV,1,_Hq);if(this.HasExcludedList()||this.HasTopBottomRule()){_Hq=_Co.ReplaceParam(_Hq,2,this.GetFilterExprTooltip());}}if(_Hq.length>CDLAbsBlock.iMaxHAMCTooltipLength){_Hq=Utilities.GetTruncatedString(_Hq,CDLAbsBlock.iMaxHAMCTooltipLength,_Co,true);}return _Hq;};CDLAbsBlock.prototype.getHAMCFilterContext=function(){var _afc=new Array();var _RJ=this.oDataMgr.metadata;var _Co=this.oDataMgr.appobj.oResources;var _Bu=new Array();for(var i=0;i<this._nx.length;i++){_Bu.push(_RJ.GetDataLabel(this._nx[i]));}var _aHB=_Co.ReplaceParamList('IDS_BLOCKPROP_CONTEXT_OR_FILTER_TOKEN_MEMBERS',_Bu);if(this._nx.length==0){return _Co.ReplaceParam('IDS_BLOCKPROP_CONTEXT_OR_FILTER_CALC_ONLY_HAMC',1,this.GetLabel());}var _Hq='IDS_BLOCKPROP_CONTEXT_OR_FILTER';var _79=_Co.ReplaceParam('IDS_CONTEXTBAR_LIST_ITEM',1,_RJ.GetDimById(this.GetDimId()).GetLabel());_Hq=_Co.ReplaceParam(_Hq,1,_79);var _apV='IDS_CONTEXTBAR';if(this.HasExcludedList()||this.HasTopBottomRule()){_Hq=_Co.ReplaceParam(_Hq,2,'');var _aD5=new Array();_aD5[0]=_Hq;_aD5[1]=Utilities.GetTruncatedString(_aHB,CDLAbsBlock.iMaxHAMCTooltipLength,_Co,true);_afc.push(_aD5);_Hq=_Co.ReplaceParam(_Hq,2,this.GetFilterExprTooltip());var _aD5=new Array();_aD5[0]=this.GetFilterExprTooltip();_aD5[1]=_aD5[0];_afc.push(_aD5);}else{var _79=_RJ.GetDimById(this.GetDimId()).GetLabel();_Hq=_Co.ReplaceParam(_Hq,1,_79);if(this._nx.length<2){_Hq=_Co.ReplaceParam(_Hq,2,_RJ.GetDataLabel(this._nx[0]));}else{_Hq=_Co.ReplaceParam(_Hq,2,_aHB);}}return((_afc.length>0)?_afc:_Hq);};CDLAbsBlock.prototype.DescendAscendDepth=function(_FU,_Le){var _Jj=this.oAxis._rk.GetDMAction();_Jj.type="setproperty";_Jj.AddTargetItem(this.oAxis._ks,ExpAPIXml.kEleAxis);_Jj.AddTargetItem(this.sExprId,ExpAPIXml.kEleAxisOpExpression);_Jj._eW(ExpAPIXml.kDepth,_FU);if(_Le){return _Jj;}else{this.oAxis._rk.SendDMAction(_Jj);}};CDLAbsBlock.prototype.GetRootParentBlockOnAxis=function(){Debug.Assert(this.oAxis);if(this._hj!=null&&this.oAxis){var _1o=this.oAxis._rk.GetBlock(this._hj);while(_1o&&_1o._hj&&this.oAxis._rk.GetBlock(_1o._hj)){_1o=this.oAxis._rk.GetBlock(_1o._hj);}if(_1o){return _1o;}else{return null;}}return null;};CDLAbsBlock.prototype.GetRootParentBlock=function(){if(this._hj!=null){var _1o=this.oDataMgr._kX.getBlock(this._hj);Debug.Assert(_1o!=null);while(_1o&&_1o._hj){_1o=this.oDataMgr._kX.getBlock(_1o._hj);Debug.Assert(_1o!=null);}if(_1o){return _1o;}else{return this;}}return null;};CDLAbsBlock.prototype.GetUserDefFLT=function(){if(this._vG&&(this._vG._ni._sy.length>0)){return this._vG;}else{return null;}};CDLAbsBlock.prototype.GetSubset=function(){return this._mF;};CDLAbsBlock.prototype.HasAnyTypeOfFilter=function(){if(this.HasTopBottomRule()||this.HasExcludedMembers()||this.HasFilterExpr()){return true;}return false;};CDLAbsBlock.prototype.HasTopBottomRule=function(){if(this._mF&&this._mF.HasTopBottomRule()){return true;}return false;};CDLAbsBlock.prototype.HasExcludedMembers=function(){if(this._kL){return this._kL.length>0;}return false;};CDLAbsBlock.prototype.GetExcludedMemberIds=function(){return this._kL;};CDLAbsBlock.prototype.GetExcludeMemberListLabel=function(){var _Co=this.oDataMgr.appobj.oResources;var _Bu=new Array();for(var i=0;i<this._kL.length;i++){_Bu.push(this.oDataMgr.metadata.GetDataLabel(this._kL[i]));}var _76=_Co.ReplaceParamList('IDS_BLOCKPROP_VALUE_LIST',_Bu);return _Co.ReplaceParam('IDS_EXCLUDED_ITEMS_LABEL',1,_76);};CDLAbsBlock.prototype.HasSingleMemberExpandedSet=function(){if(this._d1){return Utilities.GetObjArrayLength(this._d1)>0;}return false;};CDLAbsBlock.prototype.GetAllExpandedSets=function(){var _amb=new Array();for(var i in this._d1){_amb.push(this.GetExpandedSetByMemId(i));}return _amb;};CDLAbsBlock.prototype.GetExpandedSetByMemId=function(_F9){if(this._d1&&this._d1[_F9]){return this.oDataMgr._kX.getBlock(this._d1[_F9]);}return null;};CDLAbsBlock.prototype.IsHAMC=function(){if(this.IsMemberSet()||this.IsMeasureBlock()){return true;}return false;};CDLAbsBlock.prototype.IsMemberSet=function(){if(this.eType==CDLAbsBlock.eTypeMemberSet){return true;}return false;};CDLAbsBlock.prototype.IsGroupedDescendantsAtDepth=function(){return this.IsNestedType();};CDLAbsBlock.prototype.IsNestedType=function(){if(this.eType==CDLAbsBlock.eTypeNested){return true;}return false;};CDLAbsBlock.prototype.IsDescendantsAtDepth=function(){if(this.eType==CDLAbsBlock.eTypeDescendants){return true;}return false;};CDLAbsBlock.prototype.IsDepthBased=function(){if(this.IsDescendantsAtDepth()||this.IsNestedType()){return true;}return false;};CDLAbsBlock.prototype.IsLevelMembers=function(){if(this.eType==CDLAbsBlock.eTypeLevelMembers){return true;}return false;};CDLAbsBlock.prototype.IsChildren=function(){if(this.eType==CDLAbsBlock.eTypeChildren){return true;}return false;};CDLAbsBlock.prototype.IsMeasureBlock=function(){if(this.eType==CDLAbsBlock.eTypeMeasure){return true;}return false;};CDLAbsBlock.prototype.IsChildrenMeasureBlock=function(){if(this.eType==CDLAbsBlock.eTypeMeasureChildren){return true;}return false;};CDLAbsBlock.prototype.IsNamedSet=function(){if(this.eType==CDLAbsBlock.eTypeNamedSet){return true;}return false;};CDLAbsBlock.prototype.IsV5Block=function(){if(this.eType==CDLAbsBlock.eTypeV5){return true;}return false;};CDLAbsBlock.prototype.IsSegmentQuadrant=function(){return(this.eType==CDLAbsBlock.eTypeSegmtQuadrant);};CDLAbsBlock.prototype.IsExpandedSet=function(){return this._ua;};CDLAbsBlock.prototype.HasMeasures=function(){if(Utilities.IsInArray(this.oDataMgr.metadata.GetMeasureDimIdArr(),this.GetDimId())){return true;}return false;};CDLAbsBlock.prototype.CanApplyUserDefFilter=function(){if(COTValidation.BlockTypeToFeatureRules[this.eType]['measureattribute']&&!this.IsLocked()){return true;}return false;};CDLAbsBlock.prototype.CanApplyTopBottom=function(){if(COTValidation.BlockTypeToFeatureRules[this.eType]['topbottom']&&!this.IsLocked()){return true;}return false;};CDLAbsBlock.prototype.CanExclude=function(){if(COTValidation.BlockTypeToFeatureRules[this.eType]['exclude']&&!this.IsLocked()){return true;}return false;};CDLAbsBlock.prototype.CanApplyFilterSubtotals=function(){if(COTValidation.BlockTypeSubtotalRules[this.eType][ExpAPIXml.eCalcPassedFLAggregate]&&COTValidation.BlockTypeSubtotalRules[this.eType][ExpAPIXml.eCalcFLAggregate]){return true;}return false;};CDLAbsBlock.prototype.IsExpanded=function(){return this._aL;};CDLAbsBlock.prototype.HasFilterExpr=function(){if(this._vG){return true;}return false;};CDLAbsBlock.prototype.HasExcludedList=function(){if(this.HasExcludedMembers()||this.GetUserDefFLT()){return true;}return false;};CDLAbsBlock.prototype.GetNamedSetId=function(){Debug.Assert(this.IsNamedSet());return this.GetLastDataMemberId();};CDLAbsBlock.FLTTypeCombinationTypes=new Object();CDLAbsBlock.FLTTypeCombinationTypes['UserT_TBT_ExclT']=CUIAxisContextItem.kMultiFltCombo;CDLAbsBlock.FLTTypeCombinationTypes['UserT_TBT_ExclF']=CUIAxisContextItem.kMultiFltCombo;CDLAbsBlock.FLTTypeCombinationTypes['UserT_TBF_ExclT']=CUIAxisContextItem.kMultiFltCombo;CDLAbsBlock.FLTTypeCombinationTypes['UserT_TBF_ExclF']=CUIAxisContextItem.kUserDefFltOnly;CDLAbsBlock.FLTTypeCombinationTypes['UserF_TBT_ExclT']=CUIAxisContextItem.kMultiFltCombo;CDLAbsBlock.FLTTypeCombinationTypes['UserF_TBT_ExclF']=CUIAxisContextItem.kTBFltOnly;CDLAbsBlock.FLTTypeCombinationTypes['UserF_TBF_ExclT']=CUIAxisContextItem.kExcludeFltOnly;CDLAbsBlock.FLTTypeCombinationTypes['UserF_TBF_ExclF']=CUIAxisContextItem.kNonFlt;CDLAbsBlock.FLTTypeCombinationTypes['Locked_'+CUIAxisContextItem.kMultiFltCombo]=CUIAxisContextItem.kMultiFltComboLocked;CDLAbsBlock.FLTTypeCombinationTypes['Locked_'+CUIAxisContextItem.kUserDefFltOnly]=CUIAxisContextItem.kUserDefFltLocked;CDLAbsBlock.FLTTypeCombinationTypes['Locked_'+CUIAxisContextItem.kTBFltOnly]=CUIAxisContextItem.kTBFltLocked;CDLAbsBlock.FLTTypeCombinationTypes['Locked_'+CUIAxisContextItem.kExcludeFltOnly]=CUIAxisContextItem.kExcludeFltLocked;CDLAbsBlock.prototype.GetFilterCombinationType=function(){var _agV=this.GetUserDefFLT()?'UserT':'UserF';var _aAI=this.HasTopBottomRule()?'TBT':'TBF';var _aAs=this.HasExcludedMembers()?'ExclT':'ExclF';var _41=_agV+'_'+_aAI+'_'+_aAs;var _auW=CDLAbsBlock.FLTTypeCombinationTypes[_41];if((_auW!=CUIAxisContextItem.kNonFlt)&&this.IsLocked()){_auW=CDLAbsBlock.FLTTypeCombinationTypes['Locked_'+_auW];}return _auW;};CDLAbsBlock.prototype.GetFilterExprTooltip=function(){var _Rz="";var _Co=this.oDataMgr.appobj.oResources;var _Bu=new Array();if(this.GetSubset()&&this.GetSubset().HasTopBottomRule()){_Bu.push(this.GetSubset().GetLabel());}if(this.GetUserDefFLT()){_Bu.push(this.GetUserDefFLT().GetLabel());}if(this.HasExcludedMembers()){_Bu.push(this.GetExcludeMemberListLabel());}if(_Bu.length==0){return _Rz;}if(_Bu.length==1){return _Bu[0];}_Rz=_Co.ReplaceParamList('IDS_FILTER_TOOLTIP_LIST',_Bu);return _Rz;};CDLAbsBlock.prototype.IsInDefinition=function(_F8){return Utilities.IsInArray(this._nx,_F8);};CDLAbsBlock.prototype.GetDefinitionIds=function(){return this._nx;};CDLAbsBlock.prototype.GetMemberIdFromDim=function(){var _RJ=this.oDataMgr.metadata;var _BX=this.GetLastDataMemberId();if(_BX){if(_RJ.GetMemberOrMeasure(_BX)){return _BX;}else{var _19=_RJ.GetData(_BX);if(_19){var _asN=_19.GetHierarchy().GetChildArray(true)[0];if(!_asN){return null;}return _asN._ks;}return null;}}else if(this.IsDepthBased()){var _aeV=this.GetRootParentBlock();Debug.Assert(_aeV);if(_aeV){Debug.Assert(_aeV.GetMemberIdFromDim());if(_aeV.GetMemberIdFromDim()){return _aeV.GetMemberIdFromDim();}}}else{if(this.GetDimId()){var _Ni=_RJ.GetDimById(this.GetDimId());if(_Ni.GetDefaultHierarchy()){return _Ni.GetDefaultHierarchy().GetChildArray(true)[0]._ks;}if(_Ni.IsSingleHierarchy()){return _Ni.GetChild(0).GetChildArray(true)[0]._ks;}}}return null;};CDLAbsBlock.prototype.GetDimId=function(){if(this._xO&&(this._xO!='')){return this._xO;}else{var _BX=this.GetLastDataMemberId();if(_BX){this._xO=this.oDataMgr.metadata.GetData(_BX).GetDimId();}else if(this.IsDepthBased()){var _aeV=this.GetRootParentBlock();Debug.Assert(_aeV);if(_aeV){this._xO=_aeV.GetDimId();}}else{this._xO=this.GetDimFromCustomCalc();}}return this._xO;};CDLAbsBlock.prototype.GetDimFromCustomCalc=function(){var _Tw=true;var _auv=this.GetCustomCalcIds(_Tw);for(var i=0;i<_auv.length;i++){var _aGq=this.oDataMgr._kX.GetCalculation(_auv[i]);if(_aGq){return _aGq.GetDimId();}}return null;};CDLAbsBlock.prototype.GetHierarhcyIdOrDimFromCustomCalc=function(){var _Tw=true;var _auv=this.GetCustomCalcIds(_Tw);for(var i=0;i<_auv.length;i++){var _aGq=this.oDataMgr._kX.GetCalculation(_auv[i]);if(_aGq){if(_aGq.GetHierarchyId()){return _aGq.GetHierarchyId();}else{return _aGq.GetDimId();}}}return null;};CDLAbsBlock.prototype.GetHierarchyOrDimId=function(){if(this._lu){return this._lu;}else{var _BX=this.GetLastDataMemberId();if(_BX){this._lu=this.oDataMgr.metadata.GetData(_BX).GetHierId();if(this._lu==null){this._lu=this.GetDimId();}}else if(this.IsDepthBased()){var _aeV=this.GetRootParentBlock();Debug.Assert(_aeV);if(_aeV){this._lu=_aeV.GetHierarchyOrDimId();}}else{this._lu=this.GetHierarhcyIdOrDimFromCustomCalc();}}return this._lu;};CDLAbsBlock.prototype.CanBeUsedAsContextFilter=function(){return this._hR;};CDLAbsBlock.prototype.GetCustomCalcIds=function(_Tw){var _aye=new Array();if(this.oAxis&&(!_Tw)){var _F7=this.oAxis.GetAllNodesInBlock(this);var _Oi=0;for(var i=0;i<_F7.length;i++){if(_F7[i].IsCalc()&&!_F7[i].IsDynamicCalc()){_aye.push(_F7[i].GetMemberId());}}}else{var _auu=this.oDataMgr._kX.GetCalculationList();for(var i in _auu){if((!_auu[i].IsDynamicCalc())&&_auu[i].GetBlockRefId()==this.sExprId){_aye.push(i);}}}return _aye;};function CDLBlock(_Od,_NG,_AT){this.base=CDLAbsBlock;this.base(_Od,_AT);this.sExprId=_Od;this._yf=CDLBlock.iDefaultSize;this._fZ=true;this._hF=false;this._va=false;this._w6=1000;this._mF=null;this._vG=null;this._z=new Array();this._xO="";this._mm=ExpAPIXml.kEleAxisOpExprSorttypeDefault;this._qs=new Array();this._k2=null;this._fR=null;this._cc=false;};CDLBlock.prototype=new CDLAbsBlock;CDLBlock.superclass=CDLAbsBlock.prototype;CDLBlock.iDefaultSize=0;CDLBlock.prototype.GetFirstAxisMember=function(_F8){if(this.oAxis){var _F7=this.oAxis.GetAllNodesInBlock(this);for(var i=0;i<_F7.length;i++){if(_F7[i]._uT==_F8){return _F7[i];}}}return null;};CDLBlock.prototype.Clone=function(){var _ax7=new CDLBlock(this.sExprId,this._uo,this.oDataMgr);_ax7.oAxis=this.oAxis;_ax7.eType=this.eType;_ax7.bRemainderEnabled=this.bRemainderEnabled;_ax7.bVisibleEnabled=this.bVisibleEnabled;_ax7.bFilterAggEnabled=this.bFilterAggEnabled;_ax7.bPassedFilterAggEnabled=this.bPassedFilterAggEnabled;_ax7.bHierarchyEnabled=this.bHierarchyEnabled;_ax7.bSubTotalEnabled=this.bSubTotalEnabled;_ax7.bUsedAsParam=this.bUsedAsParam;_ax7._fZ=this._fZ;_ax7._b8=this._b8;_ax7._hF=this._hF;_ax7._va=this._va;_ax7._d0=this._d0;_ax7._mm=this._mm;_ax7._k2=this._k2;_ax7._fR=this._fR;_ax7._cc=this._cc;_ax7._qs=Utilities.CopyArray(this._qs);_ax7._mF=this._mF?this._mF.Clone(_ax7):null;_ax7._vG=this._vG?this._vG.Clone():null;_ax7._dl=this._dl;_ax7._nx=Utilities.CopyArray(this._nx);_ax7._wM=Utilities.CopyArray(this._wM);_ax7._kL=Utilities.CopyArray(this._kL);_ax7._qS=Utilities.CopyArray(this._qS);_ax7._xO=this._xO;_ax7._lu=this._lu;_ax7._hj=this._hj;_ax7._xi=this._xi;_ax7._c3=this._c3;_ax7._V=this._V;_ax7._ga=this._ga;_ax7._hR=this._hR;_ax7._ma=this._ma;_ax7._jk=Utilities.CopyArray(this._jk);return _ax7;};CDLBlock.prototype.GetBlockName=function(){return this.sName;};CDLBlock.prototype.DrillUp=function(_Jl,_GM){var _Jj=this.oAxis._rk.GetDMAction();_Jj.type=ExpAPIXml.kActionDrill;_Jj.AddTargetItem(this.oAxis._ks,ExpAPIXml.kEleAxis);_Jj.AddTargetItem(this.sExprId,ExpAPIXml.kEleAxisOpExpression);_Jj.AddSource(_Jl,ExpAPIXml.kEleMember);_Jj._eW(ExpAPIXml.kDrillType,ExpAPIXml.kUp);if(_GM){return _Jj;}else{this.oAxis._rk.SendDMAction(_Jj);return null;}};CDLBlock.prototype.AddingDataDetailToBlockLabel=function(_G4){var _3Z=_G4;if(this.IsChildren()||this.IsLevelMembers()){var _Tc=this.oDataMgr.metadata;var _B8=this.GetHierarchyOrDimId();var _ajn=_Tc.GetHierarchyById(_B8).GetLabel();var _aun='.';if(this.IsChildren()){var _akA=_Tc.GetData(this.GetLastDataMemberId());if(!_akA.IsRootMember()){_aun="..";}}_3Z=_ajn+_aun+_G4;}return _3Z;};CDLBlock.prototype.GetLabel=function(_We){if(_We==null){var _We=true;}var _BM="";var _Co=this.oDataMgr.appobj.oResources;if(!this.IsOuterNestedBlock()&&(this.IsChildren()||this.IsChildrenMeasureBlock())){_BM=this.oDataMgr.metadata.GetDataLabel(this.GetLastDataMemberId());}else if(this.IsLevelMembers()){if(this.oDataMgr.metadata.GetLevel(this._dl)){_BM=this.oDataMgr.metadata.GetLevel(this._dl)._p8;}}else if(this.IsHAMC()){if(this.IsSingleItemHAMC()){_BM=this.oDataMgr.metadata.GetData(this._nx[0]).GetLabel();}else{var _2S=this.GetLastDataMemberId();if(!_2S&&_We){var _Qk=this.GetHierarhcyIdOrDimFromCustomCalc();var _79=this.oDataMgr.metadata.GetDataById(_Qk).GetLabel();_BM=_Co.ReplaceParam('IDS_CONTEXTBAR_CALC_ITEM',1,_79);}else{var _aqx="";if(this.HasMeasures()){_aqx=this.oDataMgr.metadata.GetMeasureDimById(this.GetDimId()).GetLabel();}else{var _Na=this.oDataMgr.metadata.GetData(this.GetLastDataMemberId()).GetHierarchy();Debug.Assert(_Na);if(!_Na._rj.isHierarchyHidden(_Na._ks)){_aqx=_Na.GetLabel();}else{_aqx=_Na._rj.GetLabel();}}_BM=_Co.ReplaceParam('IDS_CONTEXTBAR_LIST_ITEM',1,_aqx);}}}else if(this.IsNamedSet()){_BM=this.oDataMgr.metadata.GetNamedSet(this.GetLastDataMemberId()).GetLabel();}else if(this.IsV5Block()){if(this._qX){_BM=this._qX;}else{_BM=this.oDataMgr.metadata.GetHierarchyById(this._lu).GetLabel();}}else{var _aiV="";var _F8=this.GetLastDataMemberId();if(_F8){var oMem=this.oDataMgr.metadata.GetData(_F8);_aiV=oMem.GetLabel();}else{var _aeV=this.GetRootParentBlock();if(!_aeV){return "";}if(!_aeV.IsChildren()&&!_aeV.IsDepthBased()){_aiV=_aeV.GetLabel();}else{var oMem=this.oDataMgr.metadata.GetData(_aeV.GetLastDataMemberId());_aiV=oMem.GetLabel();}}_BM=_aiV;var _FU=this.GetAbsoluteDepth();if(_FU>1){_BM=_Co.ReplaceParam('IDS_CONTEXTBAR_DESCENDANTS_ITEM',1,_BM);_BM=_Co.ReplaceParam(_BM,2,_FU);}}return _BM;};CDLBlock.prototype.IsInnerNestedBlock=function(){if(this.oAxis){return this.oAxis.IsInnerNestedBlock(this.GetId());}return false;};CDLBlock.prototype.IsOuterNestedBlock=function(){if(this.oAxis){return this.oAxis.IsOuterNestedBlock(this.GetId());}return false;};CDLBlock.prototype.AllowSDNDrop=function(_Lv){_Lv._ud=false;if(_Lv instanceof CUIDragDropMember){var _ab5=_Lv.GetDimId(this.oDataMgr.metadata,this.oAxis._rk);if(_ab5==this.GetDimId()&&this.CanExpand()&&this==this.GetLowestSDNBlock()){var _5J=this;while(_5J&&_5J._hj!=null){_5J=this.oAxis._rk.GetBlock(_5J._hj);}if(_5J){if(_5J.IsChildren()){_Lv._ud=(_Lv.sMemId==_5J.GetLastDataMemberId());}else if(_5J.IsLevelMembers()){_Lv._ud=(_Lv.sLevId==_5J.GetLastDataMemberId());}}}if(_Lv._ud){_Lv._b5=this.GetId();}}return _Lv._ud;};CDLBlock.prototype.GetLowestSDNBlock=function(){var _1u=this.sExprId;var _Y0=false;while(!_Y0){var _aA2=false;for(var _Lx in this.oAxis._rR){if(this.oAxis._rR[_Lx]._hj==_1u){_1u=_Lx;_aA2=true;}}if(!_aA2)_Y0=true;}return this.oAxis._rk.GetBlock(_1u);};CDLBlock.prototype.GetNumLevelsInSDN=function(){if(this.IsNestedType()){if(this.oAxis){var _4f=this.GetLowestSDNBlock();var _QH=1;while(_4f._hj!=null){_4f=this.oAxis._rk.GetBlock(_4f._hj);if(_4f!=null){_QH++;}else{break;}}return _QH;}}return 0;};CDLBlock.prototype.CanDrillUpOrDown=function(){if(this.CanDrillUp()||this.CanDrillDown()){return true;}return false;};CDLBlock.prototype.canDrill=function(){if(this.IsGroupedDescendantsAtDepth()&&!this.IsInnerNestedBlock()){return false;}if(this.IsOuterNestedBlock()){return false;}if(this.IsSegmentQuadrant()){return false;}return true;};CDLBlock.prototype.CanDrillUp=function(){if(!this.canDrill()){return false;}if(this.IsGroupedDescendantsAtDepth()){return false;}if(this.IsHAMC()||this.IsNamedSet()||this.IsDepthBased()||this.IsLevelMembers()||this.IsV5Block()){return true;}var _axm=this.oDataMgr.metadata.GetMemberOrMeasure(this.GetLastDataMemberId());if(_axm==null){Debug.Assert(false);return false;}if(_axm.IsRootMember()){return false;}return true;};CDLBlock.prototype.CanDrillDown=function(){if(!this.canDrill()){return false;}return true;};CDLBlock.prototype.HasSortMembers=function(){if(this._qs.length>0){return true;}return false;};CDLBlock.prototype.IsDefaultSortMember=function(){if(this._qs.length==1){if(this._qs[0]==DefaultConstants.kDefScope){return true;}}return false;};CDLBlock.prototype.IsDefaultSortMeasure=function(){return(this._k2&&this._k2==DefaultConstants.kDefMeasure);};CDLBlock.GetTupleMembersLabel=function(_Md,_Fr,_Li,_y5){if(_y5.length==0){var _auL=_Li._he.appobj.oResources.GetString('IDS_EMPTY_CONTEXT');if(!_Md){return _auL;}_Md=_Li._he.appobj.oResources.ReplaceParam(_Md,_Fr,_auL);}else if(_y5.length==1){var _auL='';if(_y5[0]!=DefaultConstants.kDefScope){_auL=_Li.GetNodeLabel(_y5[0]);}if(!_Md){return _auL;}_Md=_Li._he.appobj.oResources.ReplaceParam(_Md,_Fr,_auL);}else{var _aJp=_Li._he.appobj.oResources.GetString('IDS_RULE_TOPBOTTOM_NESTEDMEMBERS');var _aHB=_Li.GetNodeLabel(_y5[0]);for(var i=0;i<_y5.length-1;i++){_aHB=_Li._he.appobj.oResources.ReplaceParam(_aJp,1,_aHB);_aHB=_Li._he.appobj.oResources.ReplaceParam(_aHB,2,_Li.GetNodeLabel(_y5[i+1]));}if(!_Md){return _aHB;}_Md=_Li._he.appobj.oResources.ReplaceParam(_Md,_Fr,_aHB);}return _Md;};CDLBlock.prototype.GetFilterSortLabels=function(){var _adk=new Array();if(this.HasTopBottomRule()){_adk.push(this.GetSubset().GetLabel());}if(this.GetUserDefFLT()){_adk.push(this.GetUserDefFLT().GetLabel());}if(this.HasExcludedMembers()){_adk.push(this.GetExcludeMemberListLabel());}if(this.GetSortLabel()){_adk.push(this.GetSortLabel());}return _adk;};CDLBlock.prototype.GetLabelWithDescription=function(){var _Co=this.oAxis._rk._he.appobj.oResources;var _3x=this.GetLabel();var _adk=this.GetFilterSortLabels();if(_adk.length==0){_ayv='IDS_BLOCK_PROPERTIES_TITLE_W_SELECTION';_ayv=_Co.ReplaceParam(_ayv,1,_3x);}else if(_adk.length==1){_ayv='IDS_BLOCK_PROPERTIES_TITLE_W_SELECTION_DESC';_ayv=_Co.ReplaceParam(_ayv,1,_3x);_ayv=_Co.ReplaceParam(_ayv,2,_adk[0]);}else{var _76=_Co.ReplaceParamList('IDS_BLOCK_PROPERTIES_TITLE_TOKEN_DESC',_adk);_ayv='IDS_BLOCK_PROPERTIES_TITLE_W_SELECTION_DESC';_ayv=_Co.ReplaceParam(_ayv,1,_3x);_ayv=_Co.ReplaceParam(_ayv,2,_76);}return _ayv;};CDLBlock.prototype.GetSortLabel=function(){if(!this.IsExplicitSort()){return "";}var _Co=this.oAxis._rk._he.appobj.oResources;var _aCo=this.GetSortMeasureOrMeasureCalc();var _ay1=this.GetSortProperty();var _Hq="";var _Rz="";var _aDh=this.IsAscending();if(_ay1){_Hq=_aDh?'IDS_CONTEXTBAR_SORT_ASCENDING_BY_ATTRIBUTE':'IDS_CONTEXTBAR_SORT_DESCENDING_BY_ATTRIBUTE';_Rz=_Co.ReplaceParam(_Hq,1,_ay1.GetLabel());}else if(this.IsSortByLabel()){_Hq=_aDh?'IDS_CONTEXTBAR_SORT_ASCENDING_BY_LABEL':'IDS_CONTEXTBAR_SORT_DESCENDING_BY_LABEL';_Rz=_Co.GetString(_Hq);}else if(_aCo&&!this.HasSortMembers()){if(this.IsDefaultSortMeasure()){_Hq=_aDh?'IDS_CONTEXTBAR_SORT_ASCENDING_FOR_MEMBER':'IDS_CONTEXTBAR_SORT_DESCENDING_FOR_MEMBER';_Rz=CDLBlock.GetTupleMembersLabel(_Hq,2,this.oAxis._rk,this._qs);}else{_Hq=_aDh?'IDS_CONTEXTBAR_SORT_ASCENDING_BY_MEASURE_FOR_MEMBER':'IDS_CONTEXTBAR_SORT_DESCENDING_BY_MEASURE_FOR_MEMBER';_Rz=CDLBlock.GetTupleMembersLabel(_Hq,2,this.oAxis._rk,this._qs);_Rz=_Co.ReplaceParam(_Rz,1,_aCo.GetLabel());}}else if(this.HasSortMembers()&&!_aCo){}else if(this.HasSortMembers()&&_aCo){if(this.IsDefaultSortMember()){if(this.IsDefaultSortMeasure()){_Hq=_aDh?'IDS_CONTEXTBAR_SORT_ASCENDING':'IDS_CONTEXTBAR_SORT_DESCENDING';_Rz=_Co.GetString(_Hq);}else{_Hq=_aDh?'IDS_CONTEXTBAR_SORT_ASCENDING_BY_MEASURE':'IDS_CONTEXTBAR_SORT_DESCENDING_BY_MEASURE';_Rz=_Co.ReplaceParam(_Hq,1,_aCo.GetLabel());}}else{if(this.IsDefaultSortMeasure()){_Hq=_aDh?'IDS_CONTEXTBAR_SORT_ASCENDING_FOR_MEMBER':'IDS_CONTEXTBAR_SORT_DESCENDING_FOR_MEMBER';_Rz=CDLBlock.GetTupleMembersLabel(_Hq,2,this.oAxis._rk,this._qs);}else{_Hq=_aDh?'IDS_CONTEXTBAR_SORT_ASCENDING_BY_MEASURE_FOR_MEMBER':'IDS_CONTEXTBAR_SORT_DESCENDING_BY_MEASURE_FOR_MEMBER';_Rz=CDLBlock.GetTupleMembersLabel(_Hq,2,this.oAxis._rk,this._qs);_Rz=_Co.ReplaceParam(_Rz,1,_aCo.GetLabel());}}}else{}return _Rz;};CDLBlock.prototype.HasHiddenMembers=function(){return this._wM.length>0;};CDLBlock.prototype.GetHiddenMemberIds=function(){return this._wM;};CDLBlock.prototype.IsUnioned=function(){for(var i=0;i<this._z.length;i++){if(this._z[i]==CDLAxisOp.eTypeUnion){return true;}}return false;};CDLBlock.prototype.GetId=function(){return this.sExprId;};CDLBlock.prototype.GetAxis=function(){return this.oAxis;};CDLBlock.prototype.GetOppositeAxis=function(){var dm=this.oAxis._rk;for(var i=0;i<dm._c6.length;i++){if(this.oAxis!=dm._c6[i]){return dm._c6[i];}}return null;};CDLBlock.prototype.Clear=function(){Utilities.RemoveAllChildObjects(this);this.bNulledOut=true;};CDLBlock.prototype.GetMinSumLevel=function(){if(this.IsHierarchyEnabled()){var _LF=this.GetFirstNode();var _28=-1;var _aqE=-1;if(this.oAxis){var _F7=this.oAxis.GetAllNodesInBlock(this);for(var i=0;i<_F7.length;i++){if(this.oDataMgr.metadata.GetMember(_F7[i].GetMemberId())){var oMem=this.oDataMgr.metadata.GetMember(_F7[i].GetMemberId());var _Ts=oMem.GetLevel().GetHierarchy();if(_Ts.HasLevel()){_aqE=_Ts.GetHierarchyOrdinalByLevel(oMem._iY);}else{_aqE=oMem.GetDepthInFamilyTree();}}else if(this.oDataMgr.metadata.GetMeasure(_F7[i].GetMemberId())){var _NS=this.oDataMgr.metadata.GetMeasure(_F7[i].GetMemberId());_aqE=_NS.GetDepthInFamilyTree();}if(_28==-1||_aqE<_28){_28=_aqE;}}}if(_28==-1){_28=0;}return _28;}Debug.Assert(false);return 0;};CDLBlock.prototype.IsSubTotalEnabled=function(){return this.bSubTotalEnabled;};CDLBlock.prototype.IsRemainderEnabled=function(){return this.bRemainderEnabled;};CDLBlock.prototype.IsFilterAggregateEnabled=function(){return this.bFilterAggEnabled;};CDLBlock.prototype.IsPassedFilterAggregateEnabled=function(){return this.bPassedFilterAggEnabled;};CDLBlock.prototype.ShowSummary=function(){return this._fZ;};CDLBlock.prototype.IsVisibleEnabled=function(){return this.bVisibleEnabled;};CDLBlock.prototype.IsEmptyBlock=function(){if(!this.GetFirstNode()){return true;}return false;};CDLBlock.prototype.GetFirstNode=function(){if(this.oAxis){return this.oAxis.GetFirstBlockMember(this.GetId());}return null;};CDLBlock.prototype.IsInBlock=function(_BX){if(this.oAxis){var _F7=this.oAxis.GetAllNodesInBlock(this);for(var i=0;i<_F7.length;i++){if(_F7[i]._uT==_BX){return true;}}}return false;};CDLBlock.prototype.GetFirstDataNode=function(){if(this.oAxis){var _F7=this.oAxis.GetAllNodesInBlock(this);for(var i=0;i<_F7.length;i++){if(this.oDataMgr.metadata.GetData(_F7[i].GetMemberId())){return _F7[i];}}}return null;};CDLBlock.prototype.DisablePropertyDisplay=function(_O5,_Le){var _Jj=this.oAxis._rk.GetDMAction();_Jj.type=ExpAPIXml.kActionDelete;_Jj.AddSource(_O5,ExpAPIXml.kEleProperty);_Jj.AddTargetItem(this.oAxis._ks,ExpAPIXml.kEleAxis);_Jj.AddTargetItem(this.sExprId,ExpAPIXml.kEleAxisOpExpression);if(!_Le){this.oAxis._rk.SendDMAction(_Jj);return null;}else{return _Jj;}};CDLBlock.prototype.GetAllDistinctLevelsOrHiers=function(){var _aAr=function(_F7,_Wv,_FH){for(var i=0;i<_F7.length;i++){var oMem=_Wv.GetMember(_F7[i].GetMemberId());if(oMem){if(!_F7[i].IsSummaryMem()){var _19=oMem.GetLevel();if(!_19){_19=oMem.GetHierarchy();}if(_19&&!(_19.GetId()in _FH)){_FH[_19.GetId()]=_19;}}}}};var _afW=new Object();var _Wv=this.oDataMgr.metadata;var _18=this.GetHierarchyOrDimId();var _Ts=_Wv.GetHierarchyById(_18);if(_Ts&&_Ts.IsParentChildHier()){_afW[_Ts.GetId()]=_Ts;}else if(this.IsChildren()){var _6h=_Wv.GetMember(this.GetLastDataMemberId());var _ag4=_Ts.IsRagged();if(this.HasAnyTypeOfFilter()){if(!_ag4){var _azJ=_Ts.GetOneLevelBelow(_6h.GetLevel());if(_azJ){_afW[_azJ.GetId()]=_azJ;}}else{var _S8=_Ts.GetOneLevelBelow(_6h.GetLevel());while(_S8){_afW[_S8.GetId()]=_S8;_S8=_Ts.GetOneLevelBelow(_S8);}}}else{if(!_ag4){var _arA=this.GetFirstDataNode();if(_arA){var _akF=_Wv.GetMember(_arA.GetMemberId());var _S8=_akF.GetLevel();if(_S8){_afW[_S8.GetId()]=_S8;}}}else{var _F7=this.oAxis.GetAllNodesInBlock(this);_aAr(_F7,_Wv,_afW);}}}else if(this.IsLevelMembers()){_afW[this._dl]=_Wv.GetLevel(this._dl);}else if(this.IsNamedSet()){var _1H=_Wv.GetNamedSet(this.GetNamedSetId());if(this.HasAnyTypeOfFilter()){_afW[_Ts.GetId()]=_Ts;}else{var _F7=this.oAxis.GetAllNodesInBlock(this);_aAr(_F7,_Wv,_afW);}}else if(this.IsMemberSet()){for(var i=0;i<this._nx.length;i++){var oMem=_Wv.GetMember(this._nx[i]);var _S8=oMem.GetLevel();if(_S8&&!(_S8.GetId()in _afW)){_afW[_S8.GetId()]=_S8;}}}else if(this.IsDepthBased()||this.IsV5Block()){if(this.HasAnyTypeOfFilter()){var _Ob=this.GetHierarchyOrDimId();_afW[_Ts.GetId()]=_Ts;}else{var _F7=this.oAxis.GetAllNodesInBlock(this);_aAr(_F7,_Wv,_afW);}}else if(this.IsMeasureBlock()||this.IsChildrenMeasureBlock()){}else{Debug.Assert(false);}return _afW;};CDLBlock.prototype.GetAllDistinctProps=function(){var _JP=new Object();var _Ki=new Array();if(!this.HasMeasures()){var _Tc=this.oDataMgr.metadata;var _ap6=this.GetAllDistinctLevelsOrHiers();if(Utilities.GetObjArrayLength(_ap6)==0){var _ao1=this.GetFirstDataNode();if(_ao1){var _Ts=_Tc.GetMember(_ao1._uT).GetHierarchy();if(_Ts){var _5y=_Ts._lG;if(!_5y){_Ki.push(_Ts);}else{for(var q in _5y){_JP[q]=_5y[q];}}}}}else{for(var i in _ap6){var _Z8=_ap6[i];if(_Z8&&!_Z8.HasPropertiesBeenRetrieved()){_Ki.push(_Z8);}else{var _av8=_Z8.GetProperties();for(var q in _av8){if(!(q in _JP)){_JP[q]=_av8[q];}}}}}}var _ajT=new COTPropertiesLoadingManager(_JP,_Ki);return _ajT;};CDLBlock.prototype.IsPropertyDisplayEnabled=function(_O5){return Utilities.IsInArray(this._qS,_O5);};CDLBlock.prototype.ShowPropertyValue=function(_O5,_Le){var _Jj=this.oAxis._rk.GetDMAction();_Jj.type=ExpAPIXml.kActionPropVals;_Jj.AddSource(_O5,ExpAPIXml.kEleProperty);_Jj.AddTargetItem(this.oAxis._ks,ExpAPIXml.kEleAxis);_Jj.AddTargetItem(this.sExprId,ExpAPIXml.kEleAxisOpExpression);if(_Le){return _Jj;}else{this.oAxis._rk.SendDMAction(_Jj);return null;}};CDLBlock.prototype.ToggleProperty=function(_C0){if(_C0=="hierarchy"){if(this.bHierarchyEnabled){this.disableProperty(_C0);}else{this.enableProperty(_C0);}}else if(_C0==ExpAPIXml.eCalcSubtotalVisibleItems){if(this.bSubTotalEnabled){this.disableProperty(_C0);}else{this.enableProperty(_C0);}}else if(_C0==ExpAPIXml.eCalcSummary){if(this._fZ){this.disableProperty(_C0);}else{this.enableProperty(_C0);}}else if(_C0==ExpAPIXml.eCalcRemainder){if(this.bRemainderEnabled){this.disableProperty(_C0);}else{this.enableProperty(_C0);}}else if(_C0==ExpAPIXml.kShowSubtotalsOnly){if(this.bVisibleEnabled){this.disableProperty(_C0);}else{this.enableProperty(_C0);}}else if(_C0=="lock"){if(this._hF){this.disableProperty(_C0);}else{this.enableProperty(_C0);}}else if(_C0=="filteraggregate"){if(this.bFilterAggEnabled){this.disableProperty(_C0);}else{this.enableProperty(_C0);}}else if(_C0=="passedfilteraggregate"){if(this.bPassedFilterAggEnabled){this.disableProperty(_C0);}else{this.enableProperty(_C0);}}};CDLBlock.prototype.disableProperty=function(_O9){var _Jj=this.getSetPropertyAction(_O9,false);this.oAxis._rk.SendDMAction(_Jj);};CDLBlock.prototype.getSetPropertyAction=function(_O9,_Vh){var _Jj=this.oAxis._rk.GetDMAction();_Jj.type="setproperty";_Jj.AddTargetItem(this.oAxis._ks,ExpAPIXml.kEleAxis);_Jj.AddTargetItem(this.sExprId,ExpAPIXml.kEleAxisOpExpression);if(_Vh){_Jj._eW(_O9+"enabled","true");}else{_Jj._eW(_O9+"enabled","false");}return _Jj;};CDLBlock.prototype.enableProperty=function(_O9){var _Jj=this.getSetPropertyAction(_O9,true);this.oAxis._rk.SendDMAction(_Jj);};CDLBlock.prototype.IsHierarchyEnabled=function(){return this.bHierarchyEnabled;};CDLBlock.prototype.CanHierarchize=function(){if(this.IsChildrenMeasureBlock()||this.HasNoItemsNode()){return false;}return true;};CDLBlock.prototype.GetBlockSize=function(){return this._b8;};CDLBlock.prototype.IsSingleItemBlock=function(){if(this.GetFirstNode()._b3){return false;}return true;};CDLBlock.prototype.IsLocked=function(){return this._hF;};CDLBlock.prototype.IsLockable=function(){return this._va;};CDLBlock.prototype.GetAnnotation=function(){return this._d0?this._d0:null;};CDLBlock.prototype.GetSortType=function(){return this._mm;};CDLBlock.prototype.IsExplicitSort=function(){if(this._mm&&this._mm!=ExpAPIXml.kEleAxisOpExprSorttypeDefault){return true;}return false;};CDLBlock.prototype.IsAscending=function(){if(this._mm&&this._mm==ExpAPIXml.kEleAxisOpExprSorttypeBottom){return true;}return false;};CDLBlock.prototype.IsDescending=function(){if(this._mm&&this._mm==ExpAPIXml.kEleAxisOpExprSorttypeTop){return true;}return false;};CDLBlock.prototype.GetSortMeasureOrMeasureCalc=function(){if(this._k2){if(this.oDataMgr.metadata.GetMeasure(this._k2)){return this.oDataMgr.metadata.GetMeasure(this._k2);}else if(this.oDataMgr._kX.GetCalculation(this._k2)){return this.oDataMgr._kX.GetCalculation(this._k2);}else if(this._k2==DefaultConstants.kDefMeasure){return this._k2;}}return null;};CDLBlock.prototype.IsCustomSort=function(){if(this.IsExplicitSort()&&(!this.IsSortByLabel())){var _1c=!this.IsDefaultSortMeasure();var _ac6=(!this.IsDefaultSortMember())||(!this.HasSortMembers());var _atk=this.GetSortProperty();return(_1c||_ac6||_atk);}return false;};CDLBlock.prototype.IsSortByLabel=function(){return this._cc;};CDLBlock.prototype.GetSortProperty=function(){if(this._fR){return(this.GetAllDistinctProps().GetExistProps())[this._fR];}else{return null;}};CDLBlock.prototype.IsSingleItemHAMC=function(){if(this.IsHAMC()&&this._nx.length==1){return true;}};CDLBlock.prototype.HasNoItemsNode=function(){if(this.oAxis!=null){var _F7=this.oAxis.GetAllNodesInBlock(this);for(var i=0;i<_F7.length;i++){if(_F7[i].IsNoItemsNode()){return true;}}}return false;};CDLBlock.prototype.HasOnlyNoItemsNode=function(){if(this.IsSingleItemBlock()&&this.GetFirstNode().IsNoItemsNode()){return true;}return false;};CDLBlock.prototype.CanApplySetBasedCalc=function(){if(this.IsEmptyBlock()){return false;}if(this.IsGroupedDescendantsAtDepth()){return false;}return true;};CDLBlock.prototype.CanApplyUserDefCalculation=function(){if(this.IsEmptyBlock()){return false;}if(Utilities.bSingleMemExpandEnabled){if(this.IsExpandedSet()){return false;}}return true;};CDLBlock.prototype.CanApplyAutoSubtotals=function(){if(this.IsHierarchyEnabled()){return false;}for(var i in COTValidation.BlockTypeSubtotalRules[this.eType]){if(COTValidation.BlockTypeSubtotalRules[this.eType][i]){return true;}}return false;};CDLBlock.prototype.IsInsideSuppressedAxis=function(){var _O0=this.oAxis;var _R2=_O0._rk;var _BZ=-1;if(!this.IsHAMC()){for(var i=0;i<_R2._c6.length;i++){if(_R2._c6[i]._ks==_O0._ks){_BZ=i;break;}}}return((_BZ==0&&_R2.HasRowAxisSuppression())||(_BZ==1&&_R2.HasColAxisSuppression()));};CDLBlock.prototype.IsInsideRowAxis=function(){var _O0=this.oAxis;var _R2=_O0._rk;var _BZ=-1;for(var i=0;i<_R2._c6.length;i++){if(_R2._c6[i]._ks==_O0._ks){_BZ=i;break;}}return(_BZ==0);};CDLBlock.prototype.CanApplyRemainder=function(){return COTValidation.BlockTypeSubtotalRules[this.eType]['remainder'];};CDLBlock.prototype.CanApplySubtotalVisibleItems=function(){return COTValidation.BlockTypeSubtotalRules[this.eType]['subtotal'];};CDLBlock.prototype.CanApplySummary=function(){return COTValidation.BlockTypeSubtotalRules[this.eType]['summary'];};CDLBlock.prototype.CanApplyShowSubtotalsOnly=function(){return COTValidation.BlockTypeSubtotalRules[this.eType]['visible'];};CDLBlock.prototype.CanSort=function(){if(!COTValidation.BlockTypeToFeatureRules[this.eType]['sort']){return false;}if(this.bHierarchyEnabled||this.IsEmptyBlock()||this.IsLocked()){return false;}else{return true;}};CDLBlock.prototype.IsValidForCustomSuppress=function(){var _O0=this.oAxis;var _R2=_O0._rk;var _aBl=false;if(this.GetAxisDepth()+1==_O0.GetAxisDepth()){_aBl=true;}return _aBl;};CDLBlock.prototype.CanSaveAsCustomSet=function(){return this._aJ;};CDLBlock.prototype.SortMembers=function(_GQ,_So){var _AE=new Array();_AE.push(this.SetProperty(ExpAPIXml.kEleAxisOpExprSorttype,_So,true));var _aqb=null;var _20=Utilities.CopyArray(_GQ);for(var i=0;i<_GQ.length;i++){var _aGq=this.oDataMgr._kX.GetCalculation(_GQ[i]);if(this.oDataMgr.metadata.GetMeasure(_GQ[i])||(_aGq&&_aGq.CanUseAsMeasure())){_aqb=_GQ[i];Utilities.DeleteNthFromArray(_20,i);}}if(_20.length>0){_AE.push(this.SetSortMembers(_20,true));}else{_AE.push(this.SetSortMembers(new Array(DefaultConstants.kDefScope),true));}if(_aqb!=null){_AE.push(this.SetProperty(ExpAPIXml.kEleAxisOpExprSortMeasure,_aqb,true));}else{_AE.push(this.SetProperty(ExpAPIXml.kEleAxisOpExprSortMeasure,DefaultConstants.kDefMeasure,true));}return _AE;};CDLBlock.prototype.SetSortMembers=function(_GQ,_Le){var _Jj=this.oAxis._rk.GetDMAction();_Jj.type="setproperty";_Jj.AddTargetItem(this.oAxis._ks,ExpAPIXml.kEleAxis);_Jj.AddTargetItem(this.sExprId,ExpAPIXml.kEleAxisOpExpression);var _TC=new Array();for(var i=0;i<_GQ.length;i++){var _D2;if(_GQ[i]==DefaultConstants.kDefScope){_TC.push(new CDLItem("0",ExpAPIXml.kEleDefaultMember));break;}else{var _W1=this.oDataMgr.metadata.GetData(_GQ[i])?false:true;var _D2=_W1?ExpAxisObjType.Calc:ExpAPIXml.kEleMember;_TC.push(new CDLItem(_GQ[i],_D2));}}var _aq1=new CDLItemList(_TC);var _Rp=_TC.length>1?true:false;_Jj.AddParameter(new CDLParameter(ExpAPIXml.kEleAxisOpExprSortMember,_aq1.GetAsXMLString(),CDLParameter.XMLType(),_Rp));if(_Le){return _Jj;}else{this.oAxis._rk.SendDMAction(_Jj);return null;}};CDLBlock.prototype.CanDelete=function(){return this._c3;};CDLBlock.prototype.CanAscend=function(){return this._V;};CDLBlock.prototype.CanDescend=function(){return(this._ga&&!this.IsEmptyBlock());};CDLBlock.prototype.CanExpand=function(){var _5k=true;if((this.GetNumLevelsInSDN()>2)||this.IsEmptyBlock()||this.HasMeasures()||this.IsOuterNestedBlock()){_5k=false;}if(Utilities.bSingleMemExpandEnabled&&this.IsExpandedSet()){_5k=false;}return _5k;};CDLBlock.prototype.SetProperty=function(_C0,_UN,_Le){var _Jj=this.oAxis._rk.GetDMAction();_Jj.type="setproperty";_Jj.AddTargetItem(this.oAxis._ks,ExpAPIXml.kEleAxis);_Jj.AddTargetItem(this.sExprId,ExpAPIXml.kEleAxisOpExpression);var _6Y='';if(_C0==ExpAPIXml.kEleAxisOpExprSortMeasure){var _D2=null;if(_UN==DefaultConstants.kDefMeasure){_UN="0";_D2=ExpAPIXml.kEleDefault;}else{_D2=this.oDataMgr.metadata.GetData(_UN)?ExpAPIXml.kEleMeasure:ExpAxisObjType.Calc;}var _ahx=new CDLItem(_UN,_D2);_6Y=_ahx.GetAsXMLString();_Jj.AddParameter(new CDLParameter(_C0,_6Y,CDLParameter.XMLType()));}else if(_C0==ExpAPIXml.kEleUserDefFilter){var _SA=_UN?_UN:new CDLUserDefFilterExpr(this.oAxis._rk._he);_Jj.AddParameter(new CDLParameter(_C0,_SA.GetAsXML(_C0),CDLParameter.XMLType()));}else if(_C0==ExpAPIXml.kEleSubset){var _SA=_UN;_Jj.AddParameter(new CDLParameter(_C0,_SA.GetAsXML(_C0),CDLParameter.XMLType()));}else if(_C0==ExpAPIXml.kEleAxisOpExprSortProperty){this._fR=_UN;_Jj._eW(_C0,_UN);}else{_Jj._eW(_C0,_UN);}if(_Le){return _Jj;}else{this.oAxis._rk.SendDMAction(_Jj);return null;}};CDLBlock.prototype.DoReplace=function(_Il,_DL,_DF,_R1,_L7,_y2,_DR){var _AE=new Array();if(_DF&&_DF instanceof Array){_AE=_DF;}var _Jj=this.oAxis._rk.GetDMAction();_Jj.type=ExpAPIXml.kActionReplace;_Jj.AddTargetItem(this.oAxis._ks,ExpAPIXml.kEleAxis);_Jj.AddTargetItem(this.sExprId,ExpAPIXml.kEleAxisOpExpression);var _Tc=this.oAxis._rk._he.metadata;var _HF=this.oAxis._rk._he._kX;if(_DR){_Jj.AddSource(_DR,ExpAPIXml.kEleFilter);}else if(_L7){var _abf=this.oAxis._rk.GetBlock(_L7).GetAxis();var _aja=_Jj.AddSource(this.oAxis._rk._ks,ExpAPIXml.kEleDataMatrix);_aja.AddActionItem(_abf._ks,ExpAPIXml.kEleAxis);_aja.AddActionItem(_L7,ExpAPIXml.kBlock);}else{var _YC=_Jj.SetMemberMeasureSource(_Tc,_Il);if(!_HF.GetCustomSet(_Il)){_Jj._eW(ExpAPIXml.kDisplayType,ExpAPIXml.kDefDisplayDsp);_Jj._eW(ExpAPIXml.kPopulationType,_DL);if(_R1){for(var i=0;i<_R1.length;i++){_Jj.AddSource(_R1[i],_YC);}}if(_y2){_Jj._eW(ExpAPIXml.kLevel,_y2);}}}_AE.push(_Jj);this.oAxis._rk.SendDMActionArray(_AE);};CDLBlock.prototype.GetDeleteAction=function(){var _Jj=this.oAxis._rk.GetDMAction();_Jj.type=ExpAPIXml.kActionDelete;_Jj.AddTargetItem(this.oAxis._ks,ExpAPIXml.kEleAxis);_Jj.AddTargetItem(this.sExprId,ExpAPIXml.kEleAxisOpExpression);return _Jj;};CDLBlock.prototype.GetExcludeAction=function(){var _Jj=this.oAxis._rk.GetDMAction();_Jj.type=ExpAPIXml.kActionExclude;_Jj.AddTargetItem(this.oAxis._ks,ExpAPIXml.kEleAxis);_Jj.AddTargetItem(this.sExprId,ExpAPIXml.kEleAxisOpExpression);return _Jj;};CDLBlock.prototype.GetNodeByMemberId=function(_F9){var _F7=this.oAxis.GetAllNodesInBlock(this);var _On=_F7.length;for(var i=0;i<_On;i++){if(_F9==_F7[i]._uT){return _F7[i];}}return null;};CDLBlock.prototype.GetLogicalCalcPosition=function(_Fs){var _aDm=new Object();var _aI1=new Array();var _6S=true;var _azx=null;var _aFf=this.GetRootParentBlock();for(var i=_Fs.length-1;i>=0;i--){var _IY=_Fs[i];if(_IY._lW==CDLMathMLOperands.CIOperand){var _LF=this.GetNodeByMemberId(_IY._jU);if(_LF){if(_6S){_6S=false;_azx=_IY;}else{var _IE=this.oAxis.GetDataObj().GetNodeTupleByNode(_LF);_aI1.push(_IE);}}}}var _VW=null;var _azB=null;if(_azx){var _LF=this.GetNodeByMemberId(_azx._jU);if(_LF){_VW=_LF._qR;}var _ava=false;while(_VW){var _akB=true;var _4g=_VW._uT;for(var j=0;j<_aI1.length;j++){var _8v=_aI1[j].GetNodeHierarchy();if(!Utilities.IsInArray(_8v,_4g)){_akB=false;break;}}if(_akB){_aDm.sibling=_LF;_aDm.parent=_VW;_aDm.tgtBlkId=_LF.GetBlock().GetId();break;}if(_VW.GetBlock()==_aFf||_VW.GetBlock().IsDescendantsAtDepth()){_ava=true;break;}_LF=_VW;_VW=_LF._qR;}if(_ava){_aDm.sibling=_VW;_aDm.tgtBlkId=_VW.GetBlock().GetId();_aDm.parent=null;}}else{_aDm.tgtBlkId=_aFf.GetId();}return _aDm;};CDLBlock.prototype.GetCalcParent=function(_Fs){var _VW=null;for(var j=_Fs.length-1;j>=0;j--){var _IY=_Fs[j];if(_IY._lW==CDLMathMLOperands.CIOperand){var _LF=this.GetNodeByMemberId(_IY._jU);if(_LF){_VW=_LF._qR;break;}}else if(_IY instanceof CDLMathMLExprNode){_VW=this.GetCalcParent(_IY._sy);if(_VW){break;}}}return _VW;};CDLBlock.prototype.CreateMathMLCalcExpr=function(_Ic,_KR,_Jd,_AN,_A1){var _Np=_KR.GetAsXMLForCalc(_KR,'',this.oAxis._rk);var _Jj=this.oAxis._rk.GetDMAction();_Jj.type=ExpAPIXml.kActionInsert;var _Lh=_c.CreateElement(ExpAPIXml.kEleCalcName,_Jd);_Lh+=_c.CreateElement(ExpAPIXml.kEleCalcLabel,_Ic);_Lh+=_c.CreateElement(ExpAPIXml.kEleAxisOpExprCalcExpr,_Np,true);var _apo=this.sExprId;if(this.IsGroupedDescendantsAtDepth()){if(Utilities.bMultiParentCalcEnabled){var _ayy=this.GetLogicalCalcPosition(_KR._sy);if(_ayy){var _RJ=this.oDataMgr.metadata;if(_ayy.sibling){var _aJx=_ayy.sibling;var _alV=_aJx._uT;var _Hx=_aJx.IsCalc()?ExpAPIXml.kEleCalc:(_RJ.GetMember(_alV)?ExpAPIXml.kEleMember:ExpAPIXml.kEleMeasure);var _PM=new CDLItem(_ayy.sibling._uT,_Hx);_Lh+=_c.CreateElement(ExpAPIXml.kCalcSibling,_PM.GetAsXMLString(),true);}if(_ayy.parent){var _Ky=_ayy.parent;var _XT=_Ky._uT;var _Hx=_Ky.IsCalc()?ExpAPIXml.kEleCalc:(_RJ.GetMember(_XT)?ExpAPIXml.kEleMember:ExpAPIXml.kEleMeasure);var _PM=new CDLItem(_XT,_Hx);_Lh+=_c.CreateElement(ExpAPIXml.kCalcParent,_PM.GetAsXMLString(),true);}_apo=_ayy.tgtBlkId;}}else{var _VW=this.GetCalcParent(_KR._sy);if(_VW){var _PM=new CDLItem(_VW._uT,ExpAPIXml.kEleMember);_Lh+=_c.CreateElement(ExpAPIXml.kCalcParent,_PM.GetAsXMLString(),true);}}}var _aq3=_c.CreateElement(ExpAPIXml.kEleAxisOpExprCalc,_Lh,true);_Jj.AddParameter(new CDLParameter(ExpAPIXml.kCalculation,_aq3,CDLParameter.XMLType()));_Jj._eW(ExpAPIXml.kPopulationType,ExpAPIXml.kMemberPopulation);_Jj._eW(ExpAPIXml.kInsertType,ExpAPIXml.kAxisOpUnion);_Jj._eW(ExpAPIXml.kPosition,ExpAPIXml.kEleOuter);_Jj.AddTargetItem(this.oAxis._ks,ExpAPIXml.kEleAxis);_Jj.AddTargetItem(_apo,ExpAPIXml.kEleAxisOpExpression);if(_A1)return _Jj;else this.SendDMAction(_Jj);};CDLBlock.prototype.SendDMAction=function(_Jj){this.oAxis._rk.SendDMAction(_Jj);};CDLBlock.prototype.AppendMembers=function(_IH,_Le){var _Jj=this.oAxis._rk.GetDMAction();_Jj.type=ExpAPIXml.kActionAppend;_Jj.SetMemberMeasureSource(this.oDataMgr.metadata,_IH[0]);_Jj._eW(ExpAPIXml.kDisplayType,ExpAPIXml.kDefDisplayDsp);_Jj.AddTargetItem(this.oAxis._ks,ExpAPIXml.kEleAxis);_Jj.AddTargetItem(this.sExprId,ExpAPIXml.kEleAxisOpExpression);if(_IH.length>1){for(var i=1;i<_IH.length;i++){_Jj.AddSource(_IH[i],ExpAPIXml.kEleMember);}}if(_Le){return _Jj;}else{this.oAxis._rk.SendDMAction(_Jj);return null;}};CDLBlock.prototype.CreateQuadrantBaseBlock=function(_IH){var _Jj=this.oAxis._rk.GetDMAction();_Jj.type='segmentbyquadrant';var _aFg=new Array();for(var i=0;i<_IH.length;i++){var _PM=new CDLItem(_IH[i],ExpAPIXml.kEleMeasure);_aFg.push(_PM);if(i===0){this.oAxis._rk.sSegMea1Mun=_IH[i];}else{this.oAxis._rk.sSegMea2Mun=_IH[i];}}var _aq1=new CDLItemList(_aFg);_Jj.AddParameter(new CDLParameter('segmeasures',_aq1.GetAsXMLString(),CDLParameter.XMLType(),true));_Jj.AddTargetItem(this.oAxis._ks,ExpAPIXml.kEleAxis);_Jj.AddTargetItem(this.sExprId,ExpAPIXml.kEleAxisOpExpression);this.oAxis._rk.SendDMAction(_Jj);};CDLBlock.prototype.ModifySegmentMeasureValue=function(_Nc,_Ev){var _Jj=this.oAxis._rk.GetDMAction();_Jj.type="setproperty";_Jj.AddTargetItem(this.oAxis._ks,ExpAPIXml.kEleAxis);_Jj.AddTargetItem(this.sExprId,ExpAPIXml.kEleAxisOpExpression);if(this._oL&&(this._oL!=this._uZ)){_Jj._eW(ExpAPIXml.kEleAxisOpExprSegMea1CurValue,this._oL);this._oL=null;}if(this._R&&(this._R!=this._pd)){_Jj._eW(ExpAPIXml.kEleAxisOpExprSegMea2CurValue,this._R);this._R=null;}this.oAxis._rk.SendDMAction(_Jj);};CDLBlock.prototype.Nest=function(){var _AE=new Array();var _Jj=this.oAxis._rk.GetDMAction();_Jj.type=ExpAPIXml.kActionInsert;_Jj.AddTargetItem(this.oAxis._ks,ExpAPIXml.kEleAxis);_Jj.AddTargetItem(this.sExprId,ExpAPIXml.kBlock);var _Tc=this.oAxis._rk._he.metadata;_Jj._eW(ExpAPIXml.kInsertType,ExpAPIXml.kAxisOpNest);_Jj._eW(ExpAPIXml.kDepth,"1");_AE.push(_Jj);this.oAxis._rk.SendDMActionArray(_AE);};CDLBlock.prototype.DoSingleMemberExpand=function(_C9){var _VI=new Array();for(var i=0;i<_C9.length;i++){var _Jj=this.oAxis._rk.GetDMAction();_Jj.type=ExpAPIXml.kActionExpandMember;_Jj.SetMemberMeasureSource(this.oDataMgr.metadata,_C9[i]);_Jj.AddTargetItem(this.oAxis._ks,ExpAPIXml.kEleAxis);_Jj.AddTargetItem(this.sExprId,ExpAPIXml.kEleAxisOpExpression);_VI=_VI.concat(_Jj);}this.oAxis._rk.SendDMActionArray(_VI);};CDLBlock.prototype.DoSingleMemberCollapse=function(_C9){var _Jj=this.oAxis._rk.GetDMAction();_Jj.type=ExpAPIXml.kActionCollapseMember;_Jj.SetMemberMeasureSource(this.oDataMgr.metadata,_C9[0]);_Jj.AddTargetItem(this.oAxis._ks,ExpAPIXml.kEleAxis);_Jj.AddTargetItem(this.sExprId,ExpAPIXml.kEleAxisOpExpression);this.oAxis._rk.SendDMAction(_Jj);};CDLBlock.prototype.DoKeepSelectedMembers=function(_C9){var _Jj=this.oAxis._rk.GetDMAction();_Jj.type=ExpAPIXml.kActionKeepSelectedMembers;for(var i=0;i<_C9.length;i++){_Jj.SetMemberMeasureSource(this.oDataMgr.metadata,_C9[i]);}_Jj.AddTargetItem(this.oAxis._ks,ExpAPIXml.kEleAxis);_Jj.AddTargetItem(this.sExprId,ExpAPIXml.kEleAxisOpExpression);this.oAxis._rk.SendDMAction(_Jj);};CDLBlock.prototype.MakeV5Block=function(){alert('make a v5 block -- copying from clipboard');var _Jj=this.oAxis._rk.GetDMAction();_Jj.type="setproperty";_Jj.AddTargetItem(this.oAxis._ks,ExpAPIXml.kEleAxis);_Jj.AddTargetItem(this.sExprId,ExpAPIXml.kEleAxisOpExpression);_Jj._eW("blocktype","v5");_Jj._eW("v5expr",PasteFromClipboard("text"));this.oAxis._rk.SendDMAction(_Jj);return null;};function CDLAxisOp(_ML){var _Hx=_ML.getAttribute(ExpAPIXml.kEleAxisOpType);if(_Hx==ExpAPIXml.kAxisOpUnion){this.eType=CDLAxisOp.eTypeUnion;}else if(_Hx==ExpAPIXml.kAxisOpXjoin){this.eType=CDLAxisOp.eTypeXJoin;}else if(_Hx==ExpAPIXml.kAxisOpNest){this.eType=CDLAxisOp.eTypeNest;}else{Debug.Assert(false);}this.oLeftOperand=null;this.oRightOperand=null;};CDLAxisOp.eTypeUnion=1;CDLAxisOp.eTypeXJoin=2;CDLAxisOp.eTypeNest=3;CDLAxisOp.prototype.AddOperand=function(_IY){if(!this.oLeftOperand){this.oLeftOperand=_IY;}else if(!this.oRightOperand){this.oRightOperand=_IY;}else{Debug.Assert(false);}};CDLAxisOp.prototype.IsComplete=function(){if(this.oLeftOperand&&this.oRightOperand){return true;}};function CDLFilterExpr(_AT,_Dr,_Ql,_RC,_Rg,_y5,_Dk){this._lR=_AT;this._p8='';this._uj=null;this._aK=null;this._sA=null;this._qs=new Array();if(_Ql!=null){this._uj=_Ql;}if(_RC!=null&&_RC!=""){this._aK=_RC;}if(_Rg!=null&&_Rg!=""){this._sA=_Rg;}if(_y5!=null){this._qs=_y5;}this._sf=ExpAPIXml.eSubsetTypeInteger;if(_Dk!=null){this._sf=_Dk;}};CDLFilterExpr.prototype.GetSortSizeAsString=function(){var _adV=this._uj;if(this._sf==ExpAPIXml.eSubsetTypeSubsVar&&this._lR.metadata.GetSubsVar(this._uj)){_adV=this._lR.metadata.GetSubsVar(this._uj).GetLabel();}return _adV;};CDLFilterExpr.prototype.HasTopBottomRule=function(){return(this._aK!=null);};CDLFilterExpr.prototype.DeleteTopBottom=function(){this._uj=null;this._aK=null;this._sA=null;this._qs=new Array();this._sf=null;};CDLFilterExpr.prototype.Clone=function(){var _y5=Utilities.CopyArray(this._qs);var _ax7=new CDLFilterExpr(this._lR,null,this._uj,this._aK,this._sA,_y5,this._sf);return _ax7;};CDLFilterExpr.prototype.ProcessTopBottom=function(_Ew){if(Dom.GetImmediateChildByName(_Ew,ExpAPIXml.kEleFLSorttype)){this._aK=Dom.GetNodeText(Dom.GetImmediateChildByName(_Ew,ExpAPIXml.kEleFLSorttype));}if(Dom.GetImmediateChildByName(_Ew,ExpAPIXml.kEleFLSubsettype)){this._sf=Dom.GetNodeText(Dom.GetImmediateChildByName(_Ew,ExpAPIXml.kEleFLSubsettype));}if(Dom.GetImmediateChildByName(_Ew,ExpAPIXml.kEleFLSetSize)){this._uj=Dom.GetNodeText(Dom.GetImmediateChildByName(_Ew,ExpAPIXml.kEleFLSetSize));this._uj=Decimal.GetDisplayNum(this._uj);}var _aCl=Dom.GetImmediateChildByName(_Ew,ExpAPIXml.kEleFLSortMeasure);if(_aCl){if(_aCl.childNodes[0]&&_aCl.childNodes[0].nodeName==ExpAPIXml.kEleDefaultSortMeasure){this._sA=DefaultConstants.kDefMeasure;}else{var _Oe=Dom.GetImmediateChildByName(_aCl,ExpAPIXml.kEleItem);Debug.Assert(_Oe!=null);var _aql=Dom.GetImmediateChildByName(_Oe,ExpAPIXml.kEleObjectPtr);this._sA=Dom.GetNodeText(_aql);}}var _ao7=Dom.GetImmediateChildByName(_Ew,ExpAPIXml.kEleAxisOpExprSortMember);for(var i=0;_ao7&&i<_ao7.childNodes.length;i++){var item=_ao7.childNodes[i];if(item.nodeName==ExpAPIXml.kEleDefaultSortMember){this._qs.push(DefaultConstants.kDefScope);}else{var _aql=Dom.GetImmediateChildByName(_ao7.childNodes[i],ExpAPIXml.kEleObjectPtr);this._qs.push(Dom.GetNodeText(_aql));}}};CDLFilterExpr.prototype.SetTopBottom=function(_Ql,_RC,_Rg,_y5,_Dk){if(_Ql!=null){this._uj=_Ql;}if(_RC!=null&&_RC!=""){this._aK=_RC;}this._sA=_Rg;if(_y5!=null){this._qs=_y5;}if(_Dk!=null){this._sf=_Dk;}};CDLFilterExpr.prototype.GetAsXML=function(_C0){var _Lh="";if(this.HasTopBottomRule()){_Lh+=_c.CreateElement(ExpAPIXml.kEleFLSorttype,this._aK);if(this._sf==null){this._sf=ExpAPIXml.eSubsetTypeInteger;}_Lh+=_c.CreateElement(ExpAPIXml.kEleFLSubsettype,this._sf);_Lh+=_c.CreateElement(ExpAPIXml.kEleFLSetSize,String(Decimal.GetExpressionNum(this._uj)));var _Rg,_D2;if(this._sA){if(this._sA==DefaultConstants.kDefMeasure){_Lh+=_c.CreateElement(ExpAPIXml.kEleFLSortMeasure,'<default/>',true);}else{var _D2=this._lR.metadata.GetMeasure(this._sA)?ExpAPIXml.kEleMeasure:ExpAxisObjType.Calc;var _ahx=new CDLItem(this._sA,_D2);var _akI=_ahx.GetAsXMLString();_Lh+=_c.CreateElement(ExpAPIXml.kEleFLSortMeasure,_akI,true);}}if(this._qs.length>0){var _au8="";if(this.IsDefaultSortMember()){_au8="<defaultmember/>";}else{for(var i=0;i<this._qs.length;i++){var _W1=this._lR.metadata.GetData(this._qs[i])?false:true;var _D2=_W1?ExpAxisObjType.Calc:ExpAPIXml.kEleMember;_au8+=(new CDLItem(this._qs[i],_D2)).GetAsXMLString();}}_Lh+=_c.CreateElement(ExpAPIXml.kEleAxisOpExprSortMember,_au8,true);}return _c.CreateElement(ExpAPIXml.kEleSubset,_Lh,true);}return _c.CreateElement(ExpAPIXml.kEleSubset,_Lh,true);};CDLFilterExpr.operatorResStrMap=new Object();CDLFilterExpr.operatorResStrMap[CUIUserDefFilterDlg.kGT]='\u003E';CDLFilterExpr.operatorResStrMap[CUIUserDefFilterDlg.kLT]='\u003C';CDLFilterExpr.operatorResStrMap[CUIUserDefFilterDlg.kGTORE]='\u2265';CDLFilterExpr.operatorResStrMap[CUIUserDefFilterDlg.kLTORE]='\u2264';CDLFilterExpr.operatorResStrMap[CUIUserDefFilterDlg.kEQU]='=';CDLFilterExpr.operatorResStrMap[CUIUserDefFilterDlg.kNE]='\u2260';CDLFilterExpr.operatorResStrMap[CUIUserDefFilterDlg.kISNULL]='IDS_COMPARE_OP_ISNULL';CDLFilterExpr.operatorResStrMap[CUIUserDefFilterDlg.kISNOTNULL]='IDS_COMPARE_OP_ISNOTNULL';CDLFilterExpr.operatorResStrMap[CUIUserDefFilterDlg.kAnd]='IDS_INLINE_RULE_REL_AND';CDLFilterExpr.operatorResStrMap[CUIUserDefFilterDlg.kOr]='IDS_INLINE_RULE_REL_OR';CDLFilterExpr.operatorResStrMap[ExpAPIXml.kContain]='CONTAINS';CDLFilterExpr.operatorResStrMap[ExpAPIXml.kBeginWith]='BEGINS';CDLFilterExpr.operatorResStrMap[ExpAPIXml.kEndWith]='ENDS';CDLFilterExpr.operatorResStrMap[ExpAPIXml.kMatch]='MATCHES';CDLFilterExpr.operatorResStrMap[ExpAPIXml.kNotContain]='NOT_CONTAINS';CDLFilterExpr.operatorResStrMap[ExpAPIXml.kNotBeginWith]='NOT_BEGINS';CDLFilterExpr.operatorResStrMap[ExpAPIXml.kNotEndWith]='NOT_ENDS';CDLFilterExpr.operatorResStrMap[ExpAPIXml.kNotMatch]='NOT_MATCHES';CDLFilterExpr.constantStrMap=new Object();CDLFilterExpr.constantStrMap[ExpAPIXml.kEleItemName]='IDS_FLT_BY_NAME';CDLFilterExpr.prototype.HasSortMembers=function(){if(this._qs.length>0){return true;}return false;};CDLFilterExpr.prototype.IsDefaultSortMember=function(){if(this._qs.length==1){if(this._qs[0]==DefaultConstants.kDefScope){return true;}}return false;};CDLFilterExpr.prototype.IsDefaultSortMeasure=function(){return(this._sA&&this._sA==DefaultConstants.kDefMeasure);};CDLFilterExpr.prototype.GetLabel=function(){this._p8="";var _Co=this._lR.appobj.oResources;var _adV=this.GetSortSizeAsString();if(this._aK){var _azU="X";if(this._sf==ExpAPIXml.eSubsetTypePercentage){_azU="PERCENT";}else if(this._sf==ExpAPIXml.eSubsetTypeSum){_azU="SUM";}if(this._sA!==null){if(this.IsDefaultSortMeasure()){if(!this.IsDefaultSortMember()){var _Hq=this._aK==ExpAPIXml.kFLSortTop?'IDS_RULE_TOP_'+_azU+'_BY_MEMBER':'IDS_RULE_BOTTOM_'+_azU+'_BY_MEMBER';this._p8=_Co.ReplaceParam(_Hq,1,_adV);this._p8=CDLBlock.GetTupleMembersLabel(this._p8,3,this._lR.GetCurrentDataMatrix(),this._qs);}else{var _Hq=this._aK==ExpAPIXml.kFLSortTop?'IDS_RULE_TOP_'+_azU:'IDS_RULE_BOTTOM_'+_azU;this._p8=_Co.ReplaceParam(_Hq,1,_adV);}}else if(this.IsDefaultSortMember()){var _Hq=this._aK==ExpAPIXml.kFLSortTop?'IDS_RULE_TOP_'+_azU+'_BY_MEASURE':'IDS_RULE_BOTTOM_'+_azU+'_BY_MEASURE';this._p8=_Co.ReplaceParam(_Hq,1,_adV);var _Ba=this._lR.metadata.GetDataLabel(this._sA);if((!_Ba)||(_Ba=="")){_Ba=this._lR._kX.GetCalculation(this._sA).GetLabel();}this._p8=_Co.ReplaceParam(this._p8,2,_Ba);}else{var _Hq=this._aK==ExpAPIXml.kFLSortTop?'IDS_RULE_TOP_'+_azU+'_BY_MEMBERMEASURE':'IDS_RULE_BOTTOM_'+_azU+'_BY_MEMBERMEASURE';this._p8=_Co.ReplaceParam(_Hq,1,_adV);this._p8=CDLBlock.GetTupleMembersLabel(this._p8,3,this._lR.GetCurrentDataMatrix(),this._qs);var _Ba=this._lR.metadata.GetDataLabel(this._sA);if((!_Ba)||(_Ba=="")){_Ba=this._lR._kX.GetCalculation(this._sA).GetLabel();}this._p8=_Co.ReplaceParam(this._p8,2,_Ba);}}else if(this._qs.length>0){}this._p8=_Co.ReplaceParam(this._p8,4,'\u2211');}return this._p8;};function CDLAxisCalc(_Jr,_RJ){if(!_Jr){return;}this._ks="";var _ad0=_Jr.getAttribute(ExpAPIXml.kEleElcid);if(_ad0){this._ks=_ad0;}this._p8="";var _asp=_Jr.getAttribute(ExpAPIXml.kEleCalcName);if(_asp){this._p8=_asp;}var _azy=_Jr.getAttribute(ExpAPIXml.kEleCalcLabel);if(_azy){this._nh=_azy;}this._vT="";var _aEG=_Jr.getAttribute(ExpAPIXml.kEleCalcType);if(_aEG){this._vT=_aEG;}this._uk=_Jr.getAttribute(ExpAPIXml.kEleAxisOpExprPtr);this._vn="";var _amY=_Jr.getAttribute(ExpAPIXml.kEleCalcDefPtr);if(_amY){this._vn=_amY;this._dB=_RJ.GetCalcDef(_amY).GetType();}this._kT=false;var _aoC=_Jr.getAttribute(ExpAPIXml.kEleCalcIsValid);if(_aoC){this._kT=(_aoC==ExpAPIXml.kTrue);}this._wP=(_Jr.getAttribute(ExpAPIXml.kEleCalcCanUseAsDimFlt)===ExpAPIXml.kTrue);this._pF=(_Jr.getAttribute(ExpAPIXml.kEleCalcValidForFilter)===ExpAPIXml.kTrue);this._fC=(_Jr.getAttribute(ExpAPIXml.kEleCalcCanUseInSort)===ExpAPIXml.kTrue);this._bg=(_Jr.getAttribute(ExpAPIXml.kEleCalcCanUseAsMeasure)===ExpAPIXml.kTrue);this._n0=_RJ;this._u0=false;if(this._vT!=ExpAPIXml.eCalcTypeSpecial){var _aeq=Dom.GetElementsByTagName(_Jr,ExpAPIXml.kEleAxisOpExprCalcExprCI);this._mI=null;this._xR=null;for(var _auA=0;_auA<_aeq.length;_auA++){var _avs=_aeq[_auA];var _4K=_avs.getAttribute(ExpAPIXml.kAttrType);var _adQ=Dom.GetNodeText(_avs);var _W1=(_4K==ExpAxisObjType.Calc);var _aki=_W1?_RJ.datamanager._kX.GetCalculation(_adQ):_RJ.GetData(_adQ);if(_aki){this._mI=_aki.GetDimId();this._xR=_W1?_aki.GetHierarchyId():_aki.GetHierId();}}this._u0=((!this._mI)&&(!this._xR));var _abi=Dom.GetImmediateChildByName(_Jr,ExpAPIXml.kEleCalcExpr);if(_abi){var _H1=Dom.GetImmediateChildByName(_abi,ExpAPIXml.kEleAxisOpExprCalcExprApply);this._gV=CDLMathMLExprNode.CreateMathMLExprFromDom(_H1);}}};CDLAxisCalc.prototype.GetId=function(){return this._ks;};CDLAxisCalc.prototype.GetLabel=function(){return this._p8;};CDLAxisCalc.prototype.GetDescription=function(){return this._nh;};CDLAxisCalc.prototype.GetBlockRefId=function(){return this._uk;};CDLAxisCalc.prototype.GetDimId=function(){return this._mI;};CDLAxisCalc.prototype.GetHierarchyId=function(){return this._xR;};CDLAxisCalc.prototype.IsNumericConstant=function(){return this._u0;};CDLAxisCalc.prototype.IsDynamicCalc=function(){if(this._vT==ExpAPIXml.eCalcTypeSpecial){return true;}return false;};CDLAxisCalc.prototype.IsCustomCalc=function(){return(this._vT==ExpAPIXml.eCalcTypeCustom);};CDLAxisCalc.prototype.IsEditable=function(){if(this._gV){return this._gV.IsEditable();}return false;};CDLAxisCalc.prototype.IsValid=function(){return this._kT;};CDLAxisCalc.prototype.UseDefaultName=function(){return(this.GetLabel()==this.GetDescription());};CDLAxisCalc.prototype.IsMemberBasedCalc=function(){if(!this.IsDynamicCalc()&&this._gV){return this._gV.IsMemberBasedExpr();}return false;};CDLAxisCalc.prototype.GetMathMLExprNode=function(){return this._gV;};CDLAxisCalc.prototype.Clone=function(){var _ax7=new CDLAxisCalc();_ax7._ks=this._ks;_ax7._p8=this._p8;_ax7._nh=this._nh;_ax7._vT=this._vT;_ax7._uk=this._uk;_ax7._vn=this._vn;_ax7._kT=this._kT;_ax7._wP=this._wP;_ax7._pF=this._pF;_ax7._fC=this._fC;_ax7._bg=this._bg;_ax7._n0=this._n0;_ax7._u0=this._u0;_ax7._mI=this._mI;_ax7._xR=this._xR;if(this._gV){_ax7._gV=this._gV.Clone();}return _ax7;};CDLAxisCalc.prototype.CanBeUsedInFilter=function(){return this._pF;};CDLAxisCalc.prototype.CanBeUsedInSort=function(){return this._fC;};CDLAxisCalc.prototype.CanUseAsDimFilter=function(){return this._wP;};CDLAxisCalc.prototype.IsRemainder=function(){return this._dB?(this._dB===ExpAPIXml.eCalcRemainder):false;};CDLAxisCalc.prototype.IsSubtotal=function(){return this._dB?(this._dB===ExpAPIXml.eCalcSubtotalVisibleItems):false;};CDLAxisCalc.prototype.IsFilterSubtotal=function(){return this._dB?(this._dB===ExpAPIXml.eCalcFLAggregate):false;};CDLAxisCalc.prototype.IsPassedFilterSubtotal=function(){return this._dB?(this._dB===ExpAPIXml.eCalcPassedFLAggregate):false;};CDLAxisCalc.prototype.IsSummary=function(){return this._dB?(this._dB===ExpAPIXml.eCalcSummary):false;};CDLAxisCalc.prototype.CanUseAsMeasure=function(){return this._bg;};CDLAxisCalc.prototype.CanBeUsedInSuppression=function(){return this.IsSummary();};CDLMathMLExprNode.SingleGroup='singlegroup';function CDLMathMLExprNode(_J9,_yR,_VG){this._s4=_J9;this._sy=new Array();this._p6=null;this._cS=_yR?true:false;if(_VG){this._bP=DefaultConstants.kDefScope;this._eL=2;}this._p8='';this._ve=Utilities.GenerateId();this._b6=true;};CDLMathMLExprNode.CreateMathMLExprFromDom=function(_H1){var _KR;if(_H1){var _J9;for(var i=0;i<_H1.childNodes.length;i++){var _aG4=_H1.childNodes[i];if(i==0){_J9=_aG4.nodeName;_KR=new CDLMathMLExprNode(_J9,true);}else{switch(_aG4.nodeName){case CDLMathMLOperands.Apply:_KR._cS=false;var _5h=CDLMathMLExprNode.CreateMathMLExprFromDom(_aG4);_KR.AddOperands(_5h,null,CDLMathMLOperands.Apply);if(!_5h.IsEditable()){_KR._b6=false;}break;case CDLMathMLOperands.CNOperand:var _UN=Dom.GetNodeText(_aG4);var _RT=_aG4.getAttribute(ExpAPIXml.kAttrObjType);if(_RT==ExpAPIXml.kDataTypeFloat){_UN=Decimal.GetDisplayNum(_UN);}var _Ic=_UN;_KR.AddOperands(_UN,_Ic,CDLMathMLOperands.CNOperand,-1,_RT);break;case CDLMathMLOperands.CIOperand:var _UN=Dom.GetNodeText(_aG4);var _RT=_aG4.getAttribute(ExpAPIXml.kAttrObjType);_KR.AddOperands(_UN,_Ic,CDLMathMLOperands.CIOperand,-1,_RT);if(_KR.IsEditable()){_KR._b6=(_UN!=ExpAPIXml.kMissingMemberPlaceHolder);}break;}}}}return _KR;};CDLMathMLExprNode.prototype.WriteToXML=function(){var _6W="";_6W=_c.CreateElement(this._s4,"");for(var i=0;i<this._sy.length;i++){_6W+=this._sy[i].WriteToXML();}_6W=_c.CreateElement(CDLMathMLOperands.Apply,_6W,true);return _6W;};CDLMathMLExprNode.prototype.Clone=function(){var _6W=this.WriteToXML();var _BA=_c.LoadString(_6W);var _H1=Dom.GetImmediateChildByName(_BA,CDLMathMLOperands.Apply);var _ax7=CDLMathMLExprNode.CreateMathMLExprFromDom(_H1);return _ax7;};CDLMathMLExprNode.prototype.ReplaceOperand=function(_VA,_E4){this._sy[_VA].Clear();this._sy[_VA]=_E4;};CDLMathMLExprNode.prototype.IsMemberBasedExpr=function(){for(var i=0;i<this._sy.length;i++){var _Gy=this._sy[i];if(_Gy._lW==CDLMathMLOperands.CNOperand||_Gy._ja==ExpAxisObjType.Member||_Gy._ja==ExpAxisObjType.Calc||_Gy._ja==ExpAxisObjType.Measure||_Gy._ja==ExpAPIXml.kEleSubsVar){return true;}else if(_Gy instanceof CDLMathMLExprNode){return _Gy.IsMemberBasedExpr();}}return false;};CDLMathMLExprNode.prototype.IsEditable=function(){return this._b6;};CDLMathMLExprNode.prototype.IsReferencingItem=function(_R4,_E9){var _awn=false;for(var i=0;!_awn&&i<this._sy.length;i++){var _Gy=this._sy[i];if(_Gy instanceof CDLMathMLExprNode){_awn=_Gy.IsReferencingItem(_R4,_E9);}else if(_Gy._lW==CDLMathMLOperands.CIOperand){if(_Gy._jU==_R4){_awn=true;}else if(_E9){var _ahv=_E9[_Gy._jU];if(_ahv&&_ahv.IsCalcOperand()&&!_ahv.IsDynamicCalcOperand()){_awn=_ahv.GetAssociatedObj().GetMathMLExprNode().IsReferencingItem(_R4,_E9);}}}}return _awn;};CDLMathMLExprNode.prototype.GetLabelAsIs=function(_RJ,_NI){return this._p8;};CDLMathMLExprNode.prototype.GenerateExpressionLabel=function(_RJ,_NI,_UW){Debug.Assert(_RJ&&_NI);this._p8="";if(this._p6){this._p8+="(";}switch(this._s4){case ExpAPIXml.kMinusFunc:case ExpAPIXml.kDividFunc:case ExpAPIXml.kPowerFunc:case ExpAPIXml.kProdFunc:case ExpAPIXml.kPlusFunc:this._p8+=this.CreateRepeatFormatLabel(_RJ,_NI,_UW);break;case ExpAPIXml.kAbsFunc:case ExpAPIXml.kRoundFunc:case ExpAPIXml.kRoundDownFunc:case ExpAPIXml.kSquareRootFunc:case ExpAPIXml.kPercentFunc:case ExpAPIXml.kPcntOfDiffFunc:case ExpAPIXml.kSumFunc:case ExpAPIXml.kDiffFunc:case ExpAPIXml.kAvgFunc:case ExpAPIXml.kVarFunc:case ExpAPIXml.kStddevFunc:case ExpAPIXml.kMedianFunc:case ExpAPIXml.kMinFunc:case ExpAPIXml.kMaxFunc:case ExpAPIXml.kCountFunc:case ExpAPIXml.kRollUpFunc:this._p8+=this.CreateAggregateFormatLabel(_RJ,_NI,_UW);break;case ExpAPIXml.kRankFunc:case ExpAPIXml.kPercentileFunc:case ExpAPIXml.kQuartileFunc:case ExpAPIXml.kQuantile:case ExpAPIXml.kPcntOfTotalFunc:this._p8+=this.CreateRelPositionFormatLabel(_RJ,_NI,_UW);break;case ExpAPIXml.kSingleItemFunc:this._p8+=this.CreateSingleItemLabel(_RJ,_NI,_UW);break;}if(this._p6){this._p8+=")";}return this._p8;};CDLMathMLExprNode.prototype.CreateSingleItemLabel=function(_RJ,_NI,_UW){this._p8="";Debug.Assert(this._sy.length==1);this._p8=this._sy[0].GenerateExpressionLabel(_RJ,_NI,_UW);return this._p8;};CDLMathMLExprNode.prototype.CreateRepeatFormatLabel=function(_RJ,_NI,_UW){this._p8="";for(var i=0;i<this._sy.length;i++){this._p8+=this._sy[i].GenerateExpressionLabel(_RJ,_NI,_UW);this._p8+=(i==(this._sy.length-1))?'':' '+_NI._mS[this._s4]+' ';}return this._p8;};CDLMathMLExprNode.prototype.CreateAggregateFormatLabel=function(_RJ,_NI,_UW){var _Co=_NI.oRes;this._p8="";var _EF='';var _adO='IDS_CALC_EXPR_AGGR_FORMAT_'+CUIUserSelection.aResSuffixMap[this._s4];var _alN=new Array();for(var i=0;i<this._sy.length;i++){var _Gy=this._sy[i];if(_Gy instanceof CDLMathMLExprNode){var _IP=_Gy;if(_IP._s4==ExpAPIXml.kSegmentFunc){for(var j=0;j<_IP._sy.length;j++){var _aw4=_IP._sy[j];if(_aw4._ja==ExpAPIXml.kBlock){_alN[i]=_aw4.GenerateExpressionLabel(_RJ,_NI,_UW);}}}else{_alN[i]=_IP.GenerateExpressionLabel(_RJ,_NI,_UW);}}else{_alN[i]=this._sy[i].GenerateExpressionLabel(_RJ,_NI,_UW);}}if(_alN.length==1){_EF=_alN[0];}else{_EF=_Co.ReplaceParamList('IDS_CALC_EXPR_AGGR_MULTI_OPERANDS',_alN);}this._p8=_Co.ReplaceParam(_adO,2,_EF);return this._p8;};CDLMathMLExprNode.prototype.CreateRelPositionFormatLabel=function(_RJ,_NI,_UW){var _Co=_NI.oRes;this._p8="";var _Ba="";var _akH="";var _zH="";var _P0="";var _aIZ=new Array();var _ajU=new Array();var _agg="";for(var i=0;i<this._sy.length;i++){var _Gy=this._sy[i];if(_Gy instanceof CDLMathMLExprNode){var _IP=_Gy;if(_IP._s4==ExpAPIXml.kSegmentFunc||_IP._s4==ExpAPIXml.kSegmentSumFunc){for(var j=0;j<_IP._sy.length;j++){var _aw4=_IP._sy[j];if(_aw4._ja==ExpAPIXml.kAttrSegment){_ajU.push(_aw4._jU);}else if(_aw4._ja==ExpAPIXml.kBlock){_aIZ.push(_aw4.GenerateExpressionLabel(_RJ,_NI,_UW));}}}else{_akH=_IP.GenerateExpressionLabel(_RJ,_NI);}}else{Debug.Assert(_Gy._lW==CDLMathMLOperands.CIOperand);switch(_Gy._ja){case ExpAxisObjType.Measure:_Ba=_Gy.GenerateExpressionLabel(_RJ,_NI,_UW);break;case ExpAxisObjType.Calc:case ExpAxisObjType.Member:_akH=_Gy.GenerateExpressionLabel(_RJ,_NI,_UW);break;case ExpAPIXml.kOrdinalDirection:_zH=_Gy._jU;break;case ExpAPIXml.kAxis:_P0=_Gy._jU;break;case ExpAPIXml.kQuantNum:_agg=_Gy._jU;break;}}}var _Wu="";if(!_akH&&_Ba){_akH=_Ba;_Ba="";}var _agT=(_Ba=="");var _zo=(ExpAPIXml.kPcntOfTotalFunc==this._s4);if(_ajU.length>0&&_aIZ.length>0){if(!_zo){_Wu='IDS_CALC_EXPR_'+CUIUserSelection.aResSuffixMap[this._s4];_Wu+=CDLMathMLExprNode.GetOrdinalDirectionResSuffix(_zH);_Wu+=_agT?'_APP_MEASURE':'';}else{_Wu=_agT?'IDS_CALC_EXPR_PCNTOFTOTAL_CUSTOM_APP_MEASURE':'IDS_CALC_EXPR_PCNTOFTOTAL_CUSTOM';}this._p8=_Wu;if(!_agT){this._p8=_Co.ReplaceParam(this._p8,3,_Ba);}var _EF='';var _alN=new Array();for(var _YS=0;_YS<_aIZ.length;_YS++){var _5i=CDLMathMLExprNode.GetSegmentResLabelID(_ajU[_YS]);_alN[_YS]=_Co.ReplaceParam(_5i,1,_aIZ[_YS]);}if(_alN.length>1){_EF=_Co.ReplaceParamList('IDS_CALC_EXPR_MULTI_SEGMENTS',_alN);}else{_EF=_alN[0];}this._p8=_Co.ReplaceParam(this._p8,5,_EF);}else if(_P0){if(_P0==ExpAPIXml.kCurrentAxis){_Wu='IDS_CALC_EXPR_SAME_AXIS_'+CUIUserSelection.aResSuffixMap[this._s4];_Wu+=_agT?'_APP_MEASURE':'';}else{_Wu='IDS_CALC_EXPR_'+CUIUserSelection.aResSuffixMap[this._s4];_Wu+=_agT?'_APP_MEASURE':'';if((!_zo)&&(ExpAPIXml.kDefaultOrdiDirection!=_zH)){var _aJF='_OPPO_AXIS'+CDLMathMLExprNode.GetOrdinalDirectionResSuffix(_zH);_Wu+=_aJF;}}this._p8=_Wu;if(!_agT){this._p8=_Co.ReplaceParam(this._p8,3,_Ba);}}this._p8=_Co.ReplaceParam(this._p8,2,_akH);this._p8=_Co.ReplaceParam(this._p8,5,_NI._cu.GetLabel());if(_agg){this._p8=_Co.ReplaceParam(this._p8,6,_agg);}return this._p8;};CDLMathMLExprNode.GetOrdinalDirectionResSuffix=function(_zH){var _aJF="";if(_zH!=ExpAPIXml.kDefaultOrdiDirection){_aJF=_zH==ExpAPIXml.kLowestOrdiDirection?"_LOW":"_HIGH";}return _aJF;};CDLMathMLExprNode.GetSegmentResLabelID=function(_NK){var _avl="";switch(_NK){case ExpAPIXml.kIncludedSegment:_avl="IDS_INCLUDED_SEGMENT_DESC";break;case ExpAPIXml.kVisibleSegment:_avl="IDS_VISIBLE_SEGMENT_DESC";break;case ExpAPIXml.kAllSegment:_avl="IDS_ALL_SEGMENT_DESC";break;case ExpAPIXml.kIndividualMemSegment:_avl="IDS_INDIVIDUAL_MEMBER_DESC";break;}return _avl;};CDLMathMLExprNode.prototype.AddOperands=function(_Ur,_Tp,_Uo,_H9,_G5,_OR){var _IY=null;if(_Uo!=CDLMathMLOperands.Apply){_IY=new CDLMathMLOperands(_Ur,_Tp,_Uo,_G5);if(_OR){_IY._f9=true;}}else{_IY=_Ur;_IY._p6=this;}if(_H9>-1){Utilities.InsertToNthInArray(this._sy,_IY,_H9);}else{if(_IY instanceof CDLMathMLExprNode){this._cS=false;}this._sy.push(_IY);}};CDLMathMLExprNode.prototype.UpdateOperand=function(_Uo,_Ur,_Tp,_yH,_RT){if(this._sy[_yH]){this._sy[_yH]._lW=_Uo;this._sy[_yH]._jU=_Ur;this._sy[_yH]._p8=_Tp;this._sy[_yH]._ja=_RT;}};CDLMathMLExprNode.prototype.RemoveExprNodeOperands=function(_IP){var _azk=Utilities.DeleteFromArray(this._sy,_IP);};CDLMathMLExprNode.prototype.GetOperator=function(){return this._s4;};CDLMathMLExprNode.prototype.SetOperator=function(_J9){this._s4=_J9;};CDLMathMLExprNode.prototype.Clear=function(){this._s4=null;this._p6=null;this._cS=null;this._p8='';if(this._cX){this._cX=null;}for(var i=0;i<this._sy.length;i++){if(this._sy[i]instanceof CDLMathMLExprNode){this._sy[i].Clear();}}Utilities.DeleteAllFromArray(this._sy);};CDLMathMLExprNode.prototype.GetScope=function(){if(this._cS){if(this._lb){return CUIComboBox.kEmptyItem;}if(this._sy){this._eL=this._sy.length-1;return this._sy[this._eL]._jU;}}return null;};CDLMathMLExprNode.prototype.IsDefaultScope=function(){return(this.GetScope()&&(this.GetScope()==DefaultConstants.kDefScope));};CDLMathMLExprNode.prototype.GetAllLeafExprs=function(_KR,_KF){for(var i=0;i<_KR._sy.length;i++){var _as1=_KR._sy[i];if(_as1 instanceof CDLMathMLExprNode){if(_as1._cS){_KF.push(_as1);}else{_as1.GetAllLeafExprs(_as1,_KF);}}}};CDLMathMLExprNode.IsNumericOperator=function(op){switch(op){case CUIUserDefFilterDlg.kGT:case CUIUserDefFilterDlg.kLT:case CUIUserDefFilterDlg.kGTORE:case CUIUserDefFilterDlg.kLTORE:case CUIUserDefFilterDlg.kEQU:case CUIUserDefFilterDlg.kNE:return true;default:return false;}};CDLMathMLExprNode.prototype.getStringRuleLabel=function(_MR){var _asD="";var _aDU="";var _Co=_MR._lR.appobj.oResources;if(this._sy[0]._ja==ExpAPIXml.kEleItemName){_asD="IDS_LABEL_FLT_RULE_";_asD+=CDLFilterExpr.operatorResStrMap[this._s4];_aDU=_Co.GetString(_asD);}else{if(CDLMathMLExprNode.IsNumericOperator(this._s4)){_asD="IDS_ATTR_FLT_RULE_NUMERIC_TYPE";_aDU=_Co.ReplaceParam(_asD,2,CDLFilterExpr.operatorResStrMap[this._s4]);_aDU=_Co.ReplaceParam(_aDU,1,this._sy[0]._p8);}else{_asD="IDS_ATTR_FLT_RULE_";_asD+=CDLFilterExpr.operatorResStrMap[this._s4];_aDU=_Co.ReplaceParam(_asD,1,this._sy[0]._p8);}}_aDU=_Co.ReplaceParam(_aDU,3,this._sy[1]._p8);return _aDU;};CDLMathMLExprNode.prototype.GetLeafNodeLabel=function(_MR){var _Co=_MR._lR.appobj.oResources;var _aa0=false;var _aBu=false;var _WI=true;this._eL=this._sy.length-1;var _aBZ=false;if(this._sy[1]&&this._sy[1]._ja&&this._sy[1]._ja==ExpAPIXml.kAttrStringData){return this.getStringRuleLabel(_MR);}else{var _aDU="IDS_";if(this._sy[0]._jU==ExpAPIXml.kEleDefault){_aDU+="DEFAULT_";_aBu=true;}if(this._s4==CUIUserDefFilterDlg.kISNULL){_aDU+="IS_NULL_";_WI=false;}else if(this._s4==CUIUserDefFilterDlg.kISNOTNULL){_aDU+="IS_NOT_NULL_";_WI=false;}if(_aDU=="IDS_"){_aDU+="NUMERIC_";}_aDU+="FLT_RULE_LABEL";if(this._sy[0]._ja!=ExpAPIXml.kEleProperty){if(!this.IsDefaultScope()){_aa0=true;_aDU+='_SCOPE';}}else{_aBZ=true;}var _asD=_aDU;}if(_aBZ){_aDU=_Co.ReplaceParam(_aDU,1,this._sy[0]._p8);}else if(!_aBu){if(_MR._lR.metadata.GetMeasure(this._sy[0]._jU)){var _BM=_MR._lR.metadata.GetMeasure(this._sy[0]._jU).GetLabel();}else{var _BM=_MR._lR._kX.GetCalculation(this._sy[0]._jU).GetLabel();}_aDU=_Co.ReplaceParam(_aDU,1,_BM);}if(_WI){_aDU=_Co.ReplaceParam(_aDU,2,_Co.GetString(CDLFilterExpr.operatorResStrMap[this._s4]));_aDU=_Co.ReplaceParam(_aDU,3,this._sy[1]._p8);}if(_aa0){var _aCP;if(this.GetScope()==CUIComboBox.kEmptyItem){_aCP=_Co.GetString('IDS_EMPTY_CONTEXT');}else{_aCP=CDLBlock.GetTupleMembersLabel(null,null,_MR._lR.GetCurrentDataMatrix(),this._sy[this._eL]._jU);}_aDU=_Co.ReplaceParam(_aDU,4,_aCP);}if(_asD==_aDU){_aDU=_Co.GetString(_asD);}return _aDU;};CDLMathMLExprNode.prototype.GetExpressionLabel=function(_IP,_Lh,_OG){if(_IP._p6){_Lh+="(";}if(_IP._cS){_Lh+=_IP.GetLeafNodeLabel(_OG);}else{for(var k=0;k<_IP._sy.length;k++){var _as1=_IP._sy[k];var _Co=_OG._lR.appobj.oResources;if(_as1 instanceof CDLMathMLExprNode){_Lh=_as1.GetExpressionLabel(_as1,_Lh,_OG);}if(k!=(_IP._sy.length-1)){_Lh+=_Co.GetString(CDLFilterExpr.operatorResStrMap[_IP._s4]);}}}if(_IP._p6){_Lh+=")";}return _Lh;};CDLMathMLExprNode.prototype.GetAsXMLForCalc=function(_IP,_Lh,_Li){_IP._cX=_Lh;if(_IP._cS){var _aAF='';_aAF+=_c.CreateElement(_IP._s4,'');var _aa1='';var _aB7='';for(var i=0;i<_IP._sy.length;i++){var _7y=_IP._sy[i];var _atR=new Object();if(_7y._lW==CDLMathMLOperands.CNOperand){if(_7y._ja){_atR[ExpAPIXml.kAttrObjType]=_7y._ja;}_aa1=_c.CreateElement(_7y._lW,_7y._jU,true,_atR);_aAF+=_aa1;}else if(_7y._lW==CDLMathMLOperands.CIOperand){if(_7y._ja){_atR[ExpAPIXml.kAttrObjType]=_7y._ja;}_aB7=_c.CreateElement(CDLMathMLOperands.CIOperand,Utilities.HtmlEncode(_7y._jU),true,_atR);_aAF+=_aB7;}}_Lh+=_c.CreateElement(CDLMathMLOperands.Apply,_aAF,true);_IP._cX=_Lh;}else{_Lh='';if(_IP._s4){_Lh+=_c.CreateElement(_IP._s4,'',true);}for(var k=0;k<_IP._sy.length;k++){var _as1=_IP._sy[k];if(_as1 instanceof CDLMathMLExprNode){_Lh=_as1.GetAsXMLForCalc(_as1,_Lh,_Li);}else{var _atR=new Object();if(_as1._lW==CDLMathMLOperands.CNOperand){if(_as1._ja){_atR[ExpAPIXml.kAttrObjType]=_as1._ja;}_Lh+=_c.CreateElement(_as1._lW,_as1._jU,true,_atR);}else if(_as1._lW==CDLMathMLOperands.CIOperand){if(_as1._ja){_atR[ExpAPIXml.kAttrObjType]=_as1._ja;}_Lh+=_c.CreateElement(CDLMathMLOperands.CIOperand,Utilities.HtmlEncode(_as1._jU),true,_atR);}}}_IP._cX+=_c.CreateElement(CDLMathMLOperands.Apply,_Lh,true);}return _IP._cX;};CDLMathMLExprNode.prototype.GetAsXMLForSearch=function(_IP,_Lh){if(_IP._cS){var _2L='';_2L+=_c.CreateElement(_IP._s4,'');for(var i=0;i<_IP._sy.length;i++){var _7y=_IP._sy[i];var _atR=new Object();if(_7y._lW==CDLMathMLOperands.CNOperand){if(_7y._ja){_atR[ExpAPIXml.kAttrObjType]=_7y._ja;}_2L+=_c.CreateElement(_7y._lW,_7y._jU,true,_atR);}else if(_7y._lW==CDLMathMLOperands.CIOperand){if(_7y._ja){_atR[ExpAPIXml.kAttrObjType]=_7y._ja;}_2L+=_c.CreateElement(CDLMathMLOperands.CIOperand,Utilities.HtmlEncode(_7y._jU),true,_atR);}}_Lh+=_c.CreateElement(CDLMathMLOperands.Apply,_2L,true);}else{_Lh+=_c.CreateElement(_IP._s4,'');for(var k=0;k<_IP._sy.length;k++){var _as1=_IP._sy[k];if(_as1 instanceof CDLMathMLExprNode){_Lh=_as1.GetAsXMLForSearch(_as1,_Lh);}}_Lh=_c.CreateElement(CDLMathMLOperands.Apply,_Lh,true);}return _Lh;};CDLMathMLExprNode.prototype.GetAsXML=function(_IP,_Lh,_Li){if(_IP._cS){var _aHo=false;var _aAF='';_aAF+=_c.CreateElement(_IP._s4,'');var _aCP=_c.CreateElement(CDLMathMLOperands.TupleOperand,'');var _aa1='';var _avB=false;var _aB7='';for(var i=0;i<_IP._sy.length;i++){var _7y=_IP._sy[i];var _atR=new Object();if(_7y._lW==CDLMathMLOperands.CNOperand||_7y._ja==ExpAPIXml.kEleSubsVar){if(_7y._ja){_atR[ExpAPIXml.kAttrObjType]=_7y._ja;}if(_IP._s4!=CUIUserDefFilterDlg.kISNULL&&_IP._s4!=CUIUserDefFilterDlg.kISNOTNULL)_aa1+=_c.CreateElement(_7y._lW,Utilities.HtmlEncode(_7y._jU),true,_atR);}else{if(_7y._lW==CDLMathMLOperands.CIOperand){if(_7y._ja){_atR[ExpAPIXml.kAttrObjType]=_7y._ja;if(_7y._ja==ExpAPIXml.kEleMeasure||(_Li.GetCalculation(_7y._jU)&&_Li.GetCalculation(_7y._jU).CanUseAsMeasure())){_aHo=true;}}_aB7=_c.CreateElement(CDLMathMLOperands.CIOperand,Utilities.HtmlEncode(_7y._jU),true,_atR);_aCP+=_aB7;}else if(_7y._lW==CDLMathMLOperands.TupleOperand){_avB=true;if(_7y._jU!=DefaultConstants.kDefScope){for(var j=0;j<_IP.GetScope().length;j++){if(_Li._he.metadata.GetMember(_IP.GetScope()[j])){_atR[ExpAPIXml.kAttrObjType]=ExpAxisObjType.Member;}else{_atR[ExpAPIXml.kAttrObjType]=ExpAxisObjType.Calc;}_aCP+=_c.CreateElement(CDLMathMLOperands.CIOperand,Utilities.HtmlEncode(_IP.GetScope()[j]),true,_atR);}}else{_atR[ExpAPIXml.kAttrObjType]=ExpAPIXml.kAttrContext;_aCP+=_c.CreateElement(CDLMathMLOperands.CIOperand,ExpAPIXml.kEleDefault,true,_atR);}}}}if(_avB||(_aHo&&(!_avB))){_aAF+=_c.CreateElement(CDLMathMLOperands.Apply,_aCP,true);}else{_aAF+=_aB7;}_aAF+=_aa1;_Lh+=_c.CreateElement(CDLMathMLOperands.Apply,_aAF,true);}else{var _ars='';if(_IP._s4){_ars+=_c.CreateElement(_IP._s4,'',true);}for(var k=0;k<_IP._sy.length;k++){var _as1=_IP._sy[k];if(_as1 instanceof CDLMathMLExprNode){_ars+=_as1.GetAsXML(_as1,_Lh,_Li);}}if(_IP._s4){_Lh=_c.CreateElement(CDLMathMLOperands.Apply,_ars,true);}else{_Lh=_ars;}}return _Lh;};CDLMathMLExprNode.prototype.IsValidExpr=function(){var _7k=true;for(var i=0;_7k&&i<this._sy.length;i++){var _Gy=this._sy[i];if(_Gy instanceof CDLMathMLExprNode){_7k=_Gy.IsValidExpr();}else if(_Gy._lW==CDLMathMLOperands.CIOperand){if(_Gy._jU==ExpAPIXml.kMissingBlockPlaceHolder){_7k=false;}}}return _7k;};CDLMathMLOperands.CIOperand='ci';CDLMathMLOperands.CNOperand='cn';CDLMathMLOperands.TupleOperand='tuple';CDLMathMLOperands.Apply='apply';function CDLMathMLOperands(_UN,_Ic,_zx,_RT){this._jU=_UN;this._p8=_Ic;this._lW=_zx;this._ja=_RT;};CDLMathMLOperands.prototype.WriteToXML=function(){var _6W="";var _atR=null;if(this._ja){_atR=new Object();_atR[ExpAPIXml.kAttrObjType]=this._ja;}this._jU=""+this._jU;_6W=_c.CreateElement(this._lW,Utilities.HtmlEncode(this._jU),true,_atR);return _6W;};CDLMathMLOperands.prototype.GetLabelAsIs=function(_RJ,_NI){return this._p8;};CDLMathMLOperands.prototype.GenerateExpressionLabel=function(_RJ,_NI,_UW){var _Co=_NI.oRes;this._p8="";if(this._lW==CDLMathMLOperands.CNOperand){this._p8=this._jU;}else{switch(this._ja){case ExpAxisObjType.Member:case ExpAPIXml.kEleSubsVar:var _zQ=_RJ.GetData(this._jU);if(_zQ){this._p8=_zQ.GetLabel();}break;case ExpAxisObjType.Measure:if(this._jU!=ExpAPIXml.kEleCurrentMeasure){if(this._jU==ExpAPIXml.kEleDefault){this._p8=_Co.GetString('IDS_CALC_EXPR_DEFAULT_MEASURE');}else{var _NS=_RJ.GetMeasure(this._jU);if(_NS){this._p8=_NS.GetLabel();}}}break;case ExpAxisObjType.TempCalc:if(_UW){for(var i in _UW){var _Gy=_UW[i];if(_Gy.GetAssociatedObjId()==this._jU){var _aGq=_Gy.GetAssociatedObj();break;}}}if(_aGq){this._p8+="(";this._p8+=_aGq.GetLabel(_RJ,_NI,_UW);this._p8+=")";}break;case ExpAxisObjType.Calc:if(_UW){for(var i in _UW){var _Gy=_UW[i];if(_Gy.GetAssociatedObjId()==this._jU){var _aGq=_Gy.GetAssociatedObj();break;}}}if(_aGq){this._p8+="(";this._p8+=_aGq.GetLabel();this._p8+=")";}else{var _aGq=_RJ.datamanager._kX.GetCalculation(this._jU);if(_aGq){this._p8=_aGq.GetLabel();}}break;case ExpAPIXml.kBlock:var _FK=_RJ.datamanager._kX.getBlock(this._jU);if(_FK){this._p8=_FK.GetLabel();}break;default:this._p8=this._jU;}}return this._p8;};function CDLUserDefFilterExpr(_AT,_J9,_zx){this._lR=_AT;this._ni=new CDLMathMLExprNode(_J9,false,true);this._ks=null;this._lW=_zx;this._nt=false;};CDLUserDefFilterExpr.prototype.SetExprId=function(id){this._ks=id;};CDLUserDefFilterExpr.prototype.GetExprNode=function(){return this._ni;};CDLUserDefFilterExpr.prototype.SetExprNode=function(_IP){this._ni=_IP;};CDLUserDefFilterExpr.prototype.ClearExpr=function(){if(this._ni){this._ni.Clear();this._ni=null;}};CDLUserDefFilterExpr.prototype.GetAsXML=function(_C0){var _0f='';if(this._ni._sy.length>0){_0f=_c.CreateElement(ExpAPIXml.kEleOrgFilterExprType,this._lW,true);}if((!this._ni._s4)&&(this._ni._sy.length>0)){_0f+=_c.CreateElement(ExpAPIXml.kEleGroupedExpr,ExpAPIXml.kTrue,true);this._nt=true;}var _Lh="";_Lh=this._ni.GetAsXML(this._ni,_Lh,this._lR.GetCurrentDataMatrix());if(_Lh!=''){_0f+=_c.CreateElement(ExpAPIXml.kEleUserDefFilterExpr,_Lh,true);}var _6B=_c.CreateElement(ExpAPIXml.kEleUserDefFilter,_0f,true);return _6B;};CDLUserDefFilterExpr.prototype.GetLabel=function(){this._p8='';if(this._ni._cS){this._p8=this._ni.GetLeafNodeLabel(this);}else{this._p8=this._ni.GetExpressionLabel(this._ni,this._p8,this);}return this._p8;};CDLUserDefFilterExpr.prototype.CanUseAsMeasure=function(_TA){var _aGq=this._lR._kX.GetCalculation(_TA);if(_aGq&&_aGq.CanUseAsMeasure()){return true;}return false;};CDLUserDefFilterExpr.prototype.ProcessUserDefFilter=function(_H1,_KR){var _RJ=this._lR.metadata;if(_H1){for(var i=0;i<_H1.childNodes.length;i++){var _aG4=_H1.childNodes[i];var _UN="";var _Ic="";switch(_aG4.nodeName){case CDLMathMLOperands.CNOperand:_UN=Dom.GetNodeText(_aG4);var _RT=_aG4.getAttribute(ExpAPIXml.kAttrObjType);if(_RT==ExpAPIXml.kDataTypeFloat){_UN=Decimal.GetDisplayNum(_UN);}var _Ic=_UN;_KR.AddOperands(_UN,_Ic,CDLMathMLOperands.CNOperand,1,_RT);return _KR;case CDLMathMLOperands.CIOperand:_UN=Dom.GetNodeText(_aG4);var _NG=0;var _RT=_aG4.getAttribute(ExpAPIXml.kAttrObjType);if(_RT==ExpAPIXml.kEleProperty){_Ic=_RJ.GetPropertyById(_UN).GetLabel();}else if(_RT==ExpAPIXml.kEleItemName){_Ic=gResource.GetString(CDLFilterExpr.constantStrMap[ExpAPIXml.kEleItemName]);}else if(_RT==ExpAPIXml.kEleSubsVar&&_RJ.GetSubsVar(_UN)){_Ic=_RJ.GetSubsVar(_UN).GetLabel();_NG=1;}if(_RT&&(_RT!='')){_KR.AddOperands(_UN,_Ic,CDLMathMLOperands.CIOperand,_NG,_RT);}else{_KR.AddOperands(_UN,_Ic,CDLMathMLOperands.CIOperand,_NG,ExpAPIXml.kEleMeasure);}break;case CDLMathMLOperands.Apply:var _ats=false;var _aHb=_aG4.firstChild.nodeName;if(_aHb==CDLMathMLOperands.TupleOperand){var _aBA=new Array();var _aBH=Dom.GetElementsByTagName(_aG4,CDLMathMLOperands.CIOperand);var _9O=true;for(var j=0;j<_aBH.length;j++){var _UN=Dom.GetNodeText(_aBH[j]);var _zx=_aBH[j].getAttribute(ExpAPIXml.kAttrObjType);if(_UN==ExpAPIXml.kEleDefault){if(_zx==ExpAPIXml.kEleMeasure){_Ic="";_KR.AddOperands(_UN,_Ic,CDLMathMLOperands.CIOperand,-1,_zx);}else if(_zx==ExpAPIXml.kAttrContext){_ats=true;_KR.AddOperands(DefaultConstants.kDefScope,DefaultConstants.kDefScope,CDLMathMLOperands.TupleOperand,-1,_zx);_9O=false;}}else if(_zx==ExpAPIXml.kEleMeasure||this.CanUseAsMeasure(_UN)){_KR.AddOperands(_UN,'',CDLMathMLOperands.CIOperand,-1,_zx);}else{_9O=false;_aBA.push(_UN);}}if((!_ats)&&(_aBA.length>0)){_KR.AddOperands(_aBA,'',CDLMathMLOperands.TupleOperand);}else if(_9O){_KR._lb=true;}}else{_KR._cS=false;_KR._c1=new CDLMathMLExprNode(_aHb,true,true);_KR._c1=this.ProcessUserDefFilter(_aG4,_KR._c1);_KR.AddOperands(_KR._c1,null,CDLMathMLOperands.Apply);}break;}}return _KR;}};CDLUserDefFilterExpr.prototype.Clone=function(_OX){var _aqJ=_c.LoadString(this._ni.GetAsXML(this._ni,'',this._lR.GetCurrentDataMatrix()),false,false,true);var _YQ=Dom.GetImmediateChildByName(_aqJ,CDLMathMLOperands.Apply);var _J9=(this._nt||_OX)?this._ni._sy[0]._s4:this._ni._s4;var _ax7=new CDLUserDefFilterExpr(this._lR,_J9,this._lW);_ax7._ni._cS=true;_ax7._ni=this.ProcessUserDefFilter(_YQ,_ax7._ni);_ax7._nt=this._nt;if(_ax7._nt||_OX){var _5d=new CDLMathMLExprNode(null,false,true);_5d.AddOperands(_ax7._ni,null,CDLMathMLOperands.Apply);_ax7._ni=_5d;}else{_ax7._nt=false;}return _ax7;};function CDLBLKDataPair(_Qk,_zq,_Ic,_AB,_Lf){this._bD=_zq;this._px=_AB;this._jV=_Lf;this._mI=_Qk;this._p8=_Ic;};CDLBLKDataPair.prototype.GetAdditionInfoName=function(){return this._px;};CDLBLKDataPair.prototype.GetAdditionInfoValue=function(){return this._jV;};CDLBLKDataPair.prototype.GetDimId=function(){return this._mI;};CDLBLKDataPair.prototype.GetDataItem=function(){return this._bD;};CDLBLKDataPair.prototype.GetLabel=function(){return this._p8;};function COTPropertiesLoadingManager(_QJ,_Ki){this._py=_QJ;this._y=_Ki;this._b4=new Array();this._b4[ExpEvent.kCOTPropsLoadingMgr_Merge_Complete]=new Array();};COTPropertiesLoadingManager.prototype.Subscribe=function(obj,_Dy){if(this._b4[_Dy]){this._b4[_Dy].push(obj);}};COTPropertiesLoadingManager.prototype.UnSubscribe=function(obj,_Dy){if(this._b4&&this._b4[_Dy]){Utilities.DeleteFromArray(this._b4[_Dy],obj);}};COTPropertiesLoadingManager.prototype.MergeNewProps=function(_ET){for(var i in _ET._lG){this._py[i]=_ET._lG[i];}Utilities.DeleteFromArray(this._y,_ET);if(this.IsAllPropsRetrieved()){this.Notify(ExpEvent.kCOTPropsLoadingMgr_Merge_Complete);}};COTPropertiesLoadingManager.prototype.IsAllPropsRetrieved=function(){return(this._y.length==0);};COTPropertiesLoadingManager.prototype.GetExistProps=function(){return this._py;};COTPropertiesLoadingManager.prototype.GetIncompletePropOwner=function(){return this._y;};COTPropertiesLoadingManager.prototype.Notify=function(_Dy){if(_Dy==ExpEvent.kCDLMetadata_Merge_Properties){this.MergeNewProps(this._oCurrTrigger);}var _alZ=this._b4[_Dy];if(_alZ){for(var i=0;i<_alZ.length;i++){_alZ[i].Notify(_Dy);}}};COTPropertiesLoadingManager.prototype.SetCurrentTrigger=function(_Mu){this._oCurrTrigger=_Mu;};CDLQuadrantSegment.oSegNumToPositionMap=new Object();CDLQuadrantSegment.oSegNumToPositionMap[1]=ExpAPIXml.kChartBottomLeft;CDLQuadrantSegment.oSegNumToPositionMap[2]=ExpAPIXml.kChartBottomRight;CDLQuadrantSegment.oSegNumToPositionMap[3]=ExpAPIXml.kChartTopLeft;CDLQuadrantSegment.oSegNumToPositionMap[4]=ExpAPIXml.kChartTopRight;function CDLQuadrantSegment(_Q8,_Ay,_IO){this._xU=_Ay;this._vE=_Q8;this._rB=_IO;};CDLQuadrantSegment.prototype.GetSegId=function(){return this._vE;};CDLQuadrantSegment.prototype.SetQuadrandNum=function(_Bw){this._oS=_Bw;};CDLQuadrantSegment.prototype.GetQuadrandNum=function(){return this._oS;};CDLQuadrantSegment.prototype.SetCalcPtr=function(_AP){this._cK=_AP;};CDLQuadrantSegment.prototype.GetCalcPtr=function(){return this._cK;};CDLQuadrantSegment.prototype.GetLabel=function(){return this._xU;};CDLQuadrantSegment.prototype.SetMinXMeasure=function(_It){this._k0=_It;};CDLQuadrantSegment.prototype.SetMaxXMeasure=function(_Rl){this._aZ=_Rl;};CDLQuadrantSegment.prototype.SetMinYMeasure=function(_T0){this._ns=_T0;};CDLQuadrantSegment.prototype.SetMaxYMeasure=function(_SC){this._uP=_SC;};CDLQuadrantSegment.prototype.GetTooltip=function(){if(!this._eN){var _auI=this._rB._oy;var _84=this._rB._dL;this._eN=CDLQuadrantSegment.oSegNumToPositionMap[this._oS]+" segment: \n";this._eN+=_auI+">"+this._k0+" and "+_auI+" <"+this._aZ+" \n";this._eN+=_84+">"+this._ns+" and "+_84+" <"+this._uP;}return this._eN;};CDLQuadrantSegment.prototype.GetDefaultLabel=function(){var _JE=this._rB.oDataMgr._kX;var _aGq=_JE.GetCalculation(this._cK);return _aGq?_aGq.GetLabel():'';};function CDLCrosstab(_AT,_Od){this.oDataMgr=_AT;this._ks=_Od;this._kR=0;this._t0=0;this._cG=0;this._a6=0;this._k9=[];this._gO=false;this._ql=new Array();this._i0=false;this._sU="";};CDLCrosstab.prototype.GetId=function(){return this._ks;};CDLCrosstab.prototype.GetName=function(){return this._sU;};CDLCrosstab.prototype.SetName=function(name){this._sU=name;};CDLCrosstab.prototype.HasCellData=function(){return this._gO;};CDLCrosstab.prototype.Clear=function(){this._k9.length=0;if(this._pr){this._pr=null;}if(this.oDataMatrix){var _Vx=false;var _UB=false;this.oDataMatrix.ClearData(_Vx,this._ks,_UB);}delete this.oDataMatrix;};CDLCrosstab.prototype.Create=function(_T2){this.oDataMatrix=this.oDataMgr.GetDataMatrixById(_T2.getAttribute(ExpAPIXml.kEleDataMatrixPtr));this.oDataMatrix.ProcessData(Dom.GetImmediateChildByName(_T2,ExpAPIXml.kEleData));if(_T2.getAttribute(ExpAPIXml.kEleRowPageNumber)){this._kR=parseInt(_T2.getAttribute(ExpAPIXml.kEleRowPageNumber));}if(_T2.getAttribute(ExpAPIXml.kEleRowPageNumber)){this._cG=parseInt(_T2.getAttribute(ExpAPIXml.kEleColPageNumber));}this._i0=(_T2.getAttribute(ExpAPIXml.kAttrRestrictedCellDS)==ExpAPIXml.kTrue);this.SetName(_T2.getAttribute(ExpAPIXml.kEleName));};CDLCrosstab.prototype.ProcessData=function(_PF){Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CDLCrosstab::ProcessData"]);var _asM=Dom.GetImmediateChildByName(_PF,ExpAPIXml.kEleData);var _Vx=false;var _Lx=this._ks;Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CDLCrosstab::ProcessData::ProcessData"]);this.oDataMatrix.ProcessData(_asM,_Vx,_Lx);Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CDLCrosstab::ProcessData::ProcessData"]);/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oProcessCells.StartTimer(true);}/*@end@*/this._k9.length=0;this._gO=false;if(_asM!=null){var _QQ=Dom.GetImmediateChildByName(_asM,ExpAPIXml.kEleCells);if(_QQ&&this.oDataMgr.GetCurrentDataMatrix().IsCompleteExpression()){this._xm(_QQ);Debug.Assert(this._gO,"<cells> should contain a <cell>");}}/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oProcessCells.StopTimer(true);}/*@end@*/Utilities.DeleteAllFromArray(this._ql);if(_asM!=null){var _aso=Dom.GetImmediateChildByName(_asM,ExpAPIXml.kMaxColLength);if(_aso){var _0e=_aso.selectNodes(ExpAPIXml.kXpathExprRowEdgeLen);var _ae2=_aso.selectNodes(ExpAPIXml.kXpathExprColEdgeLen);var _aoT=_0e.length;if(_aoT===0){this._ql[_aoT]=0;_aoT++;}else{for(var _ahw=0;_ahw<_aoT;_ahw++){this._ql[_ahw]=_0e[_ahw].nodeValue;}}var _aop=_ae2.length;if(_aop===0){this._ql[_aoT]=0;}else{var _aAv=_aop+_aoT;for(var _1J=_aoT;_1J<_aAv;_1J++){this._ql[_1J]=_ae2[_1J-_aoT].nodeValue;}}}}Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CDLCrosstab::ProcessData::Notify"]);this.oDataMatrix.Notify(ExpEvent.kCDLDataMatrix_FullRefresh);Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CDLCrosstab::ProcessData::Notify"]);Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CDLCrosstab::ProcessData"]);};CDLCrosstab.prototype.Replace=function(_T2){if(_T2.childNodes.length==0){return;}Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CDLCrosstab::Replace"]);this._k9.length=0;this.Create(_T2);Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CDLCrosstab::Replace"]);};CDLCrosstab.prototype._xm=function(_QQ){Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CDLCrosstab::_populateCells"]);Debug.Assert(this.oDataMatrix.GetAxisCount()===2);this._iM=this.oDataMatrix.GetAxis(0).GetLength();this._hM=this.oDataMatrix.GetAxis(1).GetLength();this._pr=_QQ.selectNodes("cell");this._gO=(this._pr.length>0);var _aDx=0;var _Gf=[];for(var _Cs=0;_Cs<this._hM;++_Cs){var _P1=[];for(var _EJ=0;_EJ<this._iM;++_EJ){_P1[_P1.length]=null;++_aDx;}_Gf[_Gf.length]=_P1;}this._k9=_Gf;Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CDLCrosstab::_populateCells"]);};CDLCrosstab.prototype.GetCell=function(_EJ,_Cs){var _az0=this._k9[_Cs];var _avU=_az0?_az0[_EJ]:null;if(!_avU){var _ax9=this._gO?this._pr[_Cs*this._iM+_EJ]:null;_avU={_jU:_ax9?Dom.GetNodeText(_ax9):'',_uJ:_ax9?ExpAPIXml.kStatusOK:ExpAPIXml.kStatusFail};}return _avU;};CDLCrosstab.prototype.GetDeleteAction=function(){var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionDelete;_Jj.AddTargetItem(this._ks,ExpAPIXml.kEleCrosstab);return _Jj;};CDLCrosstab.prototype.IsSingleColPage=function(){if((this._cG==0)&&(this._a6==0)){return true;}if(this.oDataMatrix&&this.oDataMatrix.GetAxis(CUIDataMatrix.iColIndex)){if(this.oDataMatrix.GetAxis(CUIDataMatrix.iColIndex).GetAllBlocksArray().length==0){return true;}}return false;};CDLCrosstab.prototype.IsSingleRowPage=function(){if((this._kR==0)&&(this._t0==0)){return true;}if(this.oDataMatrix&&this.oDataMatrix.GetAxis(CUIDataMatrix.iRowIndex)){if(this.oDataMatrix.GetAxis(CUIDataMatrix.iRowIndex).GetAllBlocksArray().length==0){return true;}}return false;};CDLCrosstab.prototype.IsSinglePage=function(){return(this.IsSingleRowPage()&&this.IsSingleColPage());};CDLCrosstab.prototype.IsTopPage=function(){return(this._kR==0);};CDLCrosstab.prototype.IsLeftmostPage=function(){return(this._cG==0);};CDLCrosstab.prototype.IsLastPage=function(){return(this._kR==this._t0);};CDLCrosstab.prototype.IsLastColPage=function(){return(this._cG==this._a6);};CDLCrosstab.prototype.SetCurrentRowPageNumber=function(_Jp){this._kR=_Jp;};CDLCrosstab.prototype.GetCurrentRowPageNumber=function(){return this._kR;};CDLCrosstab.prototype.SetCurrentColPageNumber=function(_Jp){this._cG=_Jp;};CDLCrosstab.prototype.GetCurrentColPageNumber=function(){return this._cG;};CDLCrosstab.prototype.SetLastRowPageNumber=function(_Jp){this._t0=_Jp;};CDLCrosstab.prototype.GetLastPageNumber=function(){return this._t0;};CDLCrosstab.prototype.SetLastColPageNumber=function(_Jp){this._a6=_Jp;};CDLCrosstab.prototype.GetLastColPageNumber=function(){return this._a6;};CDLCrosstab.prototype.PageDown=function(){var _Jj=new CDLAction();_Jj.AddTargetItem(this._ks,ExpAPIXml.kEleCrosstab);_Jj.type=ExpAPIXml.kActionGoToPage;var _aIF=parseInt(this._kR)+1;_Jj._eW(ExpAPIXml.kEleRowPageNumber,_aIF);var _AE=new Array();_AE.push(_Jj);var _aBj=this.oDataMgr.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this.oDataMgr.GetCurrentWorkSheet(),true);};CDLCrosstab.prototype.PageUp=function(){if(this._kR>0){var _Jj=new CDLAction();_Jj.AddTargetItem(this._ks,ExpAPIXml.kEleCrosstab);_Jj.type=ExpAPIXml.kActionGoToPage;var _aIF=parseInt(this._kR)-1;_Jj._eW(ExpAPIXml.kEleRowPageNumber,_aIF);var _AE=new Array();_AE.push(_Jj);var _aBj=this.oDataMgr.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this.oDataMgr.GetCurrentWorkSheet(),true);}};CDLCrosstab.prototype.TopPage=function(){var _Jj=new CDLAction();_Jj.AddTargetItem(this._ks,ExpAPIXml.kEleCrosstab);_Jj.type=ExpAPIXml.kActionGoToPage;_Jj._eW(ExpAPIXml.kEleRowPageNumber,String(0));var _AE=new Array();_AE.push(_Jj);var _aBj=this.oDataMgr.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this.oDataMgr.GetCurrentWorkSheet(),true);};CDLCrosstab.prototype.PageRight=function(){var _Jj=new CDLAction();_Jj.AddTargetItem(this._ks,ExpAPIXml.kEleCrosstab);_Jj.type=ExpAPIXml.kActionGoToPage;var _aIF=parseInt(this._cG)+1;_Jj._eW(ExpAPIXml.kEleColPageNumber,_aIF);var _AE=new Array();_AE.push(_Jj);var _aBj=this.oDataMgr.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this.oDataMgr.GetCurrentWorkSheet(),true);};CDLCrosstab.prototype.PageLeft=function(){if(this._cG>0){var _Jj=new CDLAction();_Jj.AddTargetItem(this._ks,ExpAPIXml.kEleCrosstab);_Jj.type=ExpAPIXml.kActionGoToPage;var _aIF=parseInt(this._cG)-1;_Jj._eW(ExpAPIXml.kEleColPageNumber,_aIF);var _AE=new Array();_AE.push(_Jj);var _aBj=this.oDataMgr.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this.oDataMgr.GetCurrentWorkSheet(),true);}};CDLCrosstab.prototype.LeftmostPage=function(){var _Jj=new CDLAction();_Jj.AddTargetItem(this._ks,ExpAPIXml.kEleCrosstab);_Jj.type=ExpAPIXml.kActionGoToPage;_Jj._eW(ExpAPIXml.kEleColPageNumber,String(0));var _AE=new Array();_AE.push(_Jj);var _aBj=this.oDataMgr.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this.oDataMgr.GetCurrentWorkSheet(),true);};function CDLWorksheet(dm,_U9){this._rk=null;this._ak=_U9;this._ks=null;this._eX=true;this._eT=true;this._h3=true;this._sl=false;this._hN=false;this._j0=true;this._bJ=false;this._b7=100;this._aP=this._ak.appobj.oResources.GetString('IDS_NEW_ANALYSIS');this._l6="";this._ok="";this._oK=new Array();this._e6=new Array();this._e6[ExpEvent.kCDLWorksheet_FullRefresh]=new Array();this._e6[ExpEvent.kCDLWorksheet_FSFullRefresh]=new Array();this._e6[ExpEvent.kCDLWorksheet_AwaitingResponse]=new Array();this._e6[ExpEvent.kCDLWorksheet_ProcessingResponse]=new Array();this._e6[ExpEvent.kCDLWorksheet_EndProcessing]=new Array();this._e6[ExpEvent.kCDLWorksheet_FailedResponse]=new Array();this._e6[ExpEvent.kCDLWorksheet_ChartRefresh]=new Array();this._e6[ExpEvent.kCDLWorksheet_NameChange]=new Array();this.SetDatamatrix(dm);this._vs=new Date();this._ak.Subscribe(this,ExpEvent.kCDLDataManager_DataMatrixCreate);this._ak.Subscribe(this,ExpEvent.kCDLDataManager_CurrentWSFSChange);this._ak.Subscribe(this,ExpEvent.kCDLDataManager_ChartRefresh);this._ak.Subscribe(this,ExpEvent.kCDLWorksheet_SaveSuccess);this._ak.Subscribe(this,ExpEvent.kCDLWorksheet_SaveContinue);this._ak.Subscribe(this,ExpEvent.kCDLWorksheet_SaveUpdateContinue);this._ak.Subscribe(this,ExpEvent.kCDLWorksheet_SaveForEditSuccess);this._ak.Subscribe(this,ExpEvent.kCDLWorksheet_LoadSuccess);this._ak.Subscribe(this,ExpEvent.kCDLWorksheet_NewSuccess);if(this._ak.GetCurrentWSFilterSet()){this._ak.GetCurrentWSFilterSet().Subscribe(this,ExpEvent.kDLFilterSet_FullRefresh);}};CDLWorksheet.prototype.IsDescriptiveStatisticsEnabled=function(){return this._ak.IsDescriptiveStatisticsEnabled();};CDLWorksheet.prototype.IsDisplayBreadcrumbEnabled=function(){return this._hN;};CDLWorksheet.prototype.IsSameHierarchyCompatibilityEnabled=function(){return this._j0;};CDLWorksheet.prototype.IsSumDiffFastCalcEnabled=function(){return this._bJ;};CDLWorksheet.prototype.GetAnalysisName=function(){return this._aP;};CDLWorksheet.prototype.IsDefaultName=function(){return this._eX;};CDLWorksheet.prototype.IsSparsityRemovalEnabled=function(){return this._eT;};CDLWorksheet.prototype.IsOverallSuppressionEnabled=function(){return this._h3;};CDLWorksheet.prototype.IsCurrentFolderPathValid=function(){return this._ok||(this._l6&&(!this._ss));};CDLWorksheet.prototype.GetInitAnalysisFolderPath=function(){var _ape=(this._l6&&(!this._ss))?this._l6:this._ak.metadata.GetPackagePath();if(!_ape){_ape="/content";}return _ape;};CDLWorksheet.prototype.GetCurrentFolderId=function(){if(this._ok){return this._ok;}else{return this._ak.FindCMObjectIdByPath(this._l6);}};CDLWorksheet.prototype.SetDatamatrix=function(_Ln){this._rk=_Ln;if(_Ln){_Ln.Subscribe(this,ExpEvent.kCDLDataMatrix_FullRefresh);}};CDLWorksheet.prototype.GetDataManager=function(){return this._ak;};CDLWorksheet.prototype.Create=function(_OL,_C7){this._ks=_C7;this._aP="";this._eX=true;for(var i=0;i<_OL.childNodes.length;i++){var _adY=_OL.childNodes[i];if(_adY.nodeName==ExpAPIXml.kCurrentName){this._aP=Dom.GetNodeText(_adY);Debug.Assert(this._aP);this._eX=false;}else if(_adY.nodeName==ExpAPIXml.kCurrentFolder){this._l6=Dom.GetNodeText(_adY);this._ss=(_adY.getAttribute(ExpAPIXml.kAttrCMFolderType)==ExpAPIXml.kAttrSessionFld);Debug.Assert(this._l6);}else if(_adY.nodeName=="copyPasteHLSEnabled"){this._ak.appobj._bf._m0=true;}else if(_adY.nodeName=="hideReportTemplate"){this._ak.appobj._cl=true;}else if(_adY.nodeName=="unknownEqualsAggregate"){this._ak.appobj._jI=true;}else if(_adY.nodeName=="allowNewDTSelectionContextModel"){this._ak.appobj._q7=(Dom.GetNodeText(_adY)==ExpAPIXml.kTrue);}else if(_adY.nodeName==ExpAPIXml.kEnableSparsityRemoval){this._eT=(Dom.GetNodeText(_adY)==ExpAPIXml.kTrue);}else if(_adY.nodeName==ExpAPIXml.kEnableOverallSuppression){this._h3=(Dom.GetNodeText(_adY)==ExpAPIXml.kTrue);}else if(_adY.nodeName==ExpAPIXml.KEnableDescriptiveStatistics){this._ak.SetDescriptiveStatisticsEnabled((Dom.GetNodeText(_adY)==ExpAPIXml.kTrue));}else if(_adY.nodeName=="enableColumnWidthPersist"){this._sl=(Dom.GetNodeText(_adY)==ExpAPIXml.kTrue);}else if(_adY.nodeName=="persistColumnWidthMRU"){this._b7=parseInt(Dom.GetNodeText(_adY));}else if(_adY.nodeName=="enableDisplayBreadcrumb"){this._hN=(Dom.GetNodeText(_adY)==ExpAPIXml.kTrue);}else if(_adY.nodeName==ExpAPIXml.kEnableSameHierarchyCompatibility){this._j0=(Dom.GetNodeText(_adY)==ExpAPIXml.kTrue);}else if(_adY.nodeName==ExpAPIXml.kEnableSumDiffFastCalc){this._bJ=(Dom.GetNodeText(_adY)==ExpAPIXml.kTrue);}else if(_adY.nodeName==ExpAPIXml.kEnableMultiRootMembersMetadataFix){this._ak.SetMultiRootMembersMetadataFixEnabled((Dom.GetNodeText(_adY)==ExpAPIXml.kTrue));}}if(this._aP==""){this._aP=this._ak.appobj.oResources.GetString('IDS_NEW_ANALYSIS');}this.UpdateViewsList(_OL);this._vs=new Date();};CDLWorksheet.prototype.UpdateViewsList=function(_S1,_Kv){Utilities.DeleteAllFromArray(this._oK);var _aoj=Dom.GetImmediateChildByName(_S1,ExpAPIXml.kEleViews);if(_aoj){this._ak._um=false;for(var i=0;i<_aoj.childNodes.length;i++){var _aD9=_aoj.childNodes[i];Debug.Assert(_aD9.nodeName==ExpAPIXml.kEleCrosstab||_aD9.nodeName==ExpAPIXml.kEleChart);var _aqF=_aD9.getAttribute(ExpAPIXml.kEleViewRef);var _9k=_aD9.getAttribute(ExpAPIXml.kEleName);var _Zs=new Object();_Zs['type']=_aD9.nodeName;_Zs[ExpAPIXml.kEleViewRef]=_aqF;_Zs[ExpAPIXml.kEleName]=_9k;_Zs['newName']=_9k;this._oK.push(_Zs);if(_aD9.nodeName==ExpAPIXml.kEleCrosstab){var _UD=this._ak.appobj.uiManager.GetCurrentWorkSheet();var _3L=_aD9.getAttribute(ExpAPIXml.kAttrFixedXtabColWidth);var _acz=!(_3L===ExpAPIXml.kFalse);if(this._ak._aF===null&&_UD){var _aI8=_UD.GetUICrosstab();if(_aI8._kK){_aI8._aF=_acz;_aI8.InitColumnResizeBar();}_aI8._kK=false;}this._ak._aF=_acz;this._ak._um=true;}}}};CDLWorksheet.prototype.GetViewRefArray=function(){var _aBl=new Array();for(var i=0;i<this._oK.length;i++){var _Zs=this._oK[i];_aBl.push(_Zs[ExpAPIXml.kEleViewRef]);}return _aBl;};CDLWorksheet.prototype.GetViewsXtabName=function(_PS){var _aBl="";for(var i=0;i<this._oK.length;i++){var _Zs=this._oK[i];if(_Zs['type']==ExpAPIXml.kEleCrosstab){if(_PS){_aBl=_Zs['newName'];}else{_aBl=_Zs[ExpAPIXml.kEleName];}break;}}return _aBl;};CDLWorksheet.prototype.SetViewsXtabName=function(_Vj){for(var i=0;i<this._oK.length;i++){var _Zs=this._oK[i];if(_Zs['type']==ExpAPIXml.kEleCrosstab){_Zs['newName']=_Vj;this._oK[i]=_Zs;break;}}};CDLWorksheet.prototype.isViewsXtabNameChanged=function(){_aBl=false;for(var i=0;i<this._oK.length;i++){var _Zs=this._oK[i];if(_Zs['type']==ExpAPIXml.kEleCrosstab){_aBl=(_Zs['newName']!=_Zs[ExpAPIXml.kEleName]);break;}}return _aBl;};CDLWorksheet.prototype.GetViewsChartName=function(_PS){var _aBl="";for(var i=0;i<this._oK.length;i++){var _Zs=this._oK[i];if(_Zs['type']==ExpAPIXml.kEleChart){if(_PS){_aBl=_Zs['newName'];}else{_aBl=_Zs[ExpAPIXml.kEleName];}break;}}return _aBl;};CDLWorksheet.prototype.SetViewsChartName=function(_Vj){for(var i=0;i<this._oK.length;i++){var _Zs=this._oK[i];if(_Zs['type']==ExpAPIXml.kEleChart){_Zs['newName']=_Vj;this._oK[i]=_Zs;break;}}};CDLWorksheet.prototype.isViewsChartNameChanged=function(){_aBl=false;for(var i=0;i<this._oK.length;i++){var _Zs=this._oK[i];if(_Zs['type']==ExpAPIXml.kEleChart){_aBl=(_Zs['newName']!=_Zs[ExpAPIXml.kEleName]);break;}}return _aBl;};CDLWorksheet.prototype.ModifyViewsXtabName=function(_Le){if(!this.isViewsXtabNameChanged()){return null;}var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionModify;_Jj.AddTargetItem(this._ak.GetCurrentCrosstab().GetId(),ExpAPIXml.kEleCrosstab);_Jj.AddParameter(new CDLParameter(ExpAPIXml.kActionDisplayName,this.GetViewsXtabName(true)));if(_Le){return _Jj;}var _AE=new Array();_AE[0]=_Jj;var _aBj=this._ak.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this,true);return _Jj;};CDLWorksheet.prototype.ModifyViewsChartName=function(_Le){if(!this.isViewsChartNameChanged()){return null;}var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionModify;_Jj.AddTargetItem(this._ak.GetCurrentChart().GetId(),ExpAPIXml.kEleChart);_Jj.AddParameter(new CDLParameter(ExpAPIXml.kActionDisplayName,this.GetViewsChartName(true)));if(_Le){return _Jj;}var _AE=new Array();_AE[0]=_Jj;var _aBj=this._ak.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this,true);return _Jj;};CDLWorksheet.prototype.AddMeasure=function(_Ba,_Le){var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionInsert;_Jj.AddTargetItem(this._rk._ks,ExpAPIXml.kEleDataMatrix);_Jj.SetMemberMeasureSource(this._ak.metadata,_Ba);_Jj._eW(ExpAPIXml.kDisplayType,ExpAPIXml.kDefDisplayDsp);if(_Le){return _Jj;}var _AE=new Array();_AE[0]=_Jj;var _aBj=this._ak.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this,true);return null;};CDLWorksheet.prototype.AddMember=function(_zV,_zn,_UR,_Wz,_DQ,_L7,_Ix,_J3,_R1,_JM,_DR){var _AE=new Array();if(_J3 instanceof Array){var _AE=_J3;}else{var _AE=new Array();if(_J3){_AE.push(_J3);}}var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionInsert;_Jj.SetMemberMeasureSource(this._ak.metadata,_zn);_Jj.AddTargetItem(_zV,ExpAPIXml.kEleDataMatrix);_Jj.AddTargetItem(_Wz,ExpAPIXml.kEleAxis);if(_L7&&_L7!=""){if(_Ix==ExpAPIXml.kBlock){_Jj.AddTargetItem(_L7,ExpAPIXml.kEleAxisOpExpression);}}if(_JM){_Jj._eW(ExpAPIXml.kLevel,_JM);}if(_DR){var _as2=this._ak.GetCurrentWSFilterSet();var _IK=_as2.GetFilterById(_DR);if(_IK.GetUserDefFLT()){var _Gh=new CDLParameter(ExpAPIXml.kEleUserDefFilter,_IK.GetUserDefFLT().GetAsXML(ExpAPIXml.kEleUserDefFilter),CDLParameter.XMLType());_Jj.AddParameter(_Gh);}if(_IK.GetSubset()){var _Gh=new CDLParameter(ExpAPIXml.kEleSubset,_IK.GetSubset().GetAsXML(ExpAPIXml.kEleSubset),CDLParameter.XMLType());_Jj.AddParameter(_Gh);}}if(!this._ak._kX.GetCustomSet(_zn)){_Jj._eW(ExpAPIXml.kDisplayType,ExpAPIXml.kDefDisplayDsp);_Jj._eW(ExpAPIXml.kPopulationType,_DQ);if(_DQ==ExpAPIXml.eChildren){_Jj._eW(ExpAPIXml.kDepth,"1");}}else{_Jj._eW(ExpAPIXml.kDepth,"1");}_Jj._eW(ExpAPIXml.kInsertType,ExpAPIXml.kAxisOpUnion);_Jj._eW(ExpAPIXml.kPosition,_UR);if(_R1){for(var i=0;i<_R1.length;i++){_Jj.AddSource(_R1[i],ExpAPIXml.kEleMember);}}_AE.push(_Jj);var _aBj=this._ak.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this,true);};CDLWorksheet.prototype.AppendMember=function(_zV,_zn,_Wz,_L7,_J3,_R1){var _AE=new Array();if(_J3 instanceof Array){var _AE=_J3;}else{var _AE=new Array();if(_J3){_AE.push(_J3);}}var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionAppend;var _Li=this._ak.GetCurrentDataMatrix();var _FK=_Li.GetBlock(_L7);if(!_FK.IsInBlock(_zn)){_Jj.SetMemberMeasureSource(this._ak.metadata,_zn);}_Jj._eW(ExpAPIXml.kDisplayType,ExpAPIXml.kDefDisplayDsp);_Jj.AddTargetItem(_zV,ExpAPIXml.kEleDataMatrix);_Jj.AddTargetItem(_Wz,ExpAPIXml.kEleAxis);_Jj.AddTargetItem(_L7,ExpAPIXml.kEleAxisOpExpression);if(_R1){for(var i=0;i<_R1.length;i++){if(!_FK.IsInBlock(_R1[i])){_Jj.AddSource(_R1[i],ExpAPIXml.kEleMember);}}}_AE.push(_Jj);var _aBj=this._ak.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this,true);};CDLWorksheet.prototype.MoveBlock=function(_Dp,_zb,_Oy,_Mw,_Go){var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionMove;var _Li=this._ak.GetCurrentDataMatrix();var _FK=_Li.GetBlock(_Dp);_Jj.SetBlockSource(_FK,this._ak.metadata);_Jj._eW(ExpAPIXml.kInsertType,_zb);_Jj._eW(ExpAPIXml.kPosition,_Oy);_Jj.AddTargetItem(_Li.GetDataMatrixId(),ExpAPIXml.kEleDataMatrix);_Jj.AddTargetItem(_Mw,ExpAPIXml.kEleAxis);if(_Go!=null){_Jj.AddTargetItem(_Go,ExpAPIXml.kEleAxisOpExpression);}var _AE=new Array();_AE[0]=_Jj;var _aBj=this._ak.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this,true);};CDLWorksheet.prototype.MoveFilter=function(_Pu,_zb,_Oy,_Mw,_Go){var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionMove;var _Li=this._ak.GetCurrentDataMatrix();_Jj.AddSource(_Pu,ExpAPIXml.kEleFilter);_Jj._eW(ExpAPIXml.kInsertType,_zb);_Jj._eW(ExpAPIXml.kPosition,_Oy);_Jj.AddTargetItem(_Li.GetDataMatrixId(),ExpAPIXml.kEleDataMatrix);_Jj.AddTargetItem(_Mw,ExpAPIXml.kEleAxis);if(_Go!=null){_Jj.AddTargetItem(_Go,ExpAPIXml.kEleAxisOpExpression);}var _AE=new Array();_AE[0]=_Jj;var _aBj=this._ak.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this,true);};CDLWorksheet.prototype.AddMemberToSet=function(_zV,_zn,_P0,_Fm){var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionInsert;_Jj.AddSource(_zn,ExpAPIXml.kEleMember);_Jj.AddTargetItem(_zV,ExpAPIXml.kEleDataMatrix);_Jj.AddTargetItem(_P0,ExpAPIXml.kEleAxis);_Jj.AddTargetItem(_Fm,ExpAPIXml.kEleAxisOpExpression);var _AE=new Array();_AE[0]=_Jj;var _aBj=this._ak.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this,true);};CDLWorksheet.prototype.XJoin=function(_zV,_zn,_V2,_UR,_Wz,_L7,_Ix,_J3,_R1,_y2,_DR){if(_J3 instanceof Array){var _AE=_J3;}else{var _AE=new Array();if(_J3){_AE.push(_J3);}}var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionInsert;_Jj.SetMemberMeasureSource(this._ak.metadata,_zn);_Jj.AddTargetItem(_zV,ExpAPIXml.kEleDataMatrix);_Jj._eW(ExpAPIXml.kInsertType,ExpAPIXml.kAxisOpXjoin);_Jj.AddTargetItem(_Wz,ExpAPIXml.kEleAxis);if(_L7&&_L7!=""){if(_Ix==ExpAPIXml.kBlock){_Jj.AddTargetItem(_L7,ExpAPIXml.kEleAxisOpExpression);}}if(!this._ak._kX.GetCustomSet(_zn)){_Jj._eW(ExpAPIXml.kDisplayType,ExpAPIXml.kDefDisplayDsp);if(_V2&&_V2!=""){_Jj._eW(ExpAPIXml.kPopulationType,_V2);}else{_Jj._eW(ExpAPIXml.kPopulationType,ExpAPIXml.kChildrenPopulation);}}_Jj._eW(ExpAPIXml.kPosition,_UR);if(_R1){var _7U=this._ak.metadata.GetMeasure(_zn)?ExpAPIXml.kEleMeasure:ExpAPIXml.kEleMember;for(var i=0;i<_R1.length;i++){_Jj.AddSource(_R1[i],_7U);}}if(_y2){_Jj._eW(ExpAPIXml.kLevel,_y2);}if(_DR){var _as2=this._ak.GetCurrentWSFilterSet();var _IK=_as2.GetFilterById(_DR);if(_IK.GetUserDefFLT()){var _Gh=new CDLParameter(ExpAPIXml.kEleUserDefFilter,_IK.GetUserDefFLT().GetAsXML(ExpAPIXml.kEleUserDefFilter),CDLParameter.XMLType());_Jj.AddParameter(_Gh);}if(_IK.GetSubset()){var _Gh=new CDLParameter(ExpAPIXml.kEleSubset,_IK.GetSubset().GetAsXML(ExpAPIXml.kEleSubset),CDLParameter.XMLType());_Jj.AddParameter(_Gh);}}_AE.push(_Jj);var _aBj=this._ak.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this,true);};CDLWorksheet.prototype.Subscribe=function(obj,event){if(this._e6[event]){this._e6[event].push(obj);}};CDLWorksheet.prototype.Notify=function(event,_FA,_LB,_zP){var _alZ=null;var _amP=null;if(event==ExpEvent.kCDLDataMatrix_FullRefresh){_amP=ExpEvent.kCDLWorksheet_FullRefresh;this._vs=new Date();}else if(event==ExpEvent.kCDLDataManager_DataMatrixCreate){if(this._rk==null){var _Li=this._ak.GetCurrentDataMatrix();this.SetDatamatrix(_Li);}}else if(event==ExpEvent.kCDLDataManager_CurrentWSFSChange){this._ak.GetCurrentWSFilterSet().Subscribe(this,ExpEvent.kDLFilterSet_FullRefresh);}else if(event==ExpEvent.kCDLWorksheet_AwaitingResponse||event==ExpEvent.kCDLWorksheet_ProcessingResponse||event==ExpEvent.kCDLWorksheet_FailedResponse||event==ExpEvent.kCDLWorksheet_EndProcessing){if(event==ExpEvent.kCDLWorksheet_FailedResponse){for(var i in this._ak._kX._x3){this._ak._kX._x3[i].Clear();}Utilities.ClearObjectArray(this._ak._kX._x3);}_amP=event;}else if(event==ExpEvent.kDLFilterSet_FullRefresh){_amP=ExpEvent.kCDLWorksheet_FSFullRefresh;}else if(event==ExpEvent.kCDLDataManager_ChartRefresh){this._ek=this._ak.GetCurrentChart();_amP=ExpEvent.kCDLWorksheet_ChartRefresh;}else if(event==ExpEvent.kCDLWorksheet_SaveContinue){this.Save(this._pz,this._j7,this._fq,this._v2,this._tY,true);}else if(event==ExpEvent.kCDLWorksheet_SaveUpdateContinue){this.SaveUpdate(this._pz,this._j7,this._v2,this._tY,true);}else if(event==ExpEvent.kCDLWorksheet_SaveSuccess){this._eX=false;var _aDr=this._ak.GetRealSavedAnalysisName();this._aP=_aDr?_aDr:this._pz;this._ok=this._j7;_amP=ExpEvent.kCDLWorksheet_NameChange;this._ak._uU=false;}else if(event==ExpEvent.kCDLWorksheet_SaveForEditSuccess){this.postSaveForEdit();}else if(event==ExpEvent.kCDLWorksheet_LoadSuccess||event==ExpEvent.kCDLWorksheet_NewSuccess){if(event==ExpEvent.kCDLWorksheet_NewSuccess){this._eX=true;}_amP=ExpEvent.kCDLWorksheet_NameChange;}if(_amP){_alZ=this._e6[_amP];for(var i=0;_alZ&&i<_alZ.length;i++){_alZ[i].Notify(_amP,_FA,_LB,_zP);}}if(event==ExpEvent.kCDLWorksheet_EndProcessing){_alZ=this._e6[_amP];for(var i=0;_alZ&&i<_alZ.length;i++){_alZ[i].Notify(ExpEvent.kCDLWorksheet_NameChange,_FA);}}};CDLWorksheet.prototype.IsDirty=function(){if(this._ak.ForceFullRefresh()){return true;}else{return this.CanUndo();}};CDLWorksheet.prototype.IsBlocked=function(){return this._qU;};CDLWorksheet.prototype.Merge=function(_A7){var _ap3=Dom.GetImmediateChildByName(_A7,ExpAPIXml.kEleDataMatrixPtr);var _az5=null;if(_ap3){_az5=Dom.GetNodeText(_ap3);}if(_az5!=null){this.SetDatamatrix(this._ak._iF[_az5]);}this.UpdateViewsList(_A7);this._vs=new Date();};CDLWorksheet.prototype.SetStateBlocked=function(){this._qU=true;this.Notify(ExpEvent.kCDLWorksheet_AwaitingResponse);};CDLWorksheet.prototype.SetStateProcessing=function(){this.Notify(ExpEvent.kCDLWorksheet_ProcessingResponse);};CDLWorksheet.prototype.SetStateFailed=function(_FA,_LB,_zP){this._qU=false;this.Notify(ExpEvent.kCDLWorksheet_FailedResponse,_FA,_LB,_zP);};CDLWorksheet.prototype.EndProcessing=function(){this._qU=false;this.Notify(ExpEvent.kCDLWorksheet_EndProcessing);};CDLWorksheet.prototype.SaveCurrent=function(_Vf){if(this.GetAnalysisName()&&!this.IsDefaultName()&&this.IsCurrentFolderPathValid()){var _aD2=null;var _avc=null;if(_Vf){var _Mg=this._ak.appobj;var _Ke=_Mg.appname;var ws=this._ak.GetCurrentWorkSheet();if(_Mg.HasDefaultAnalysis()){_aD2=Utilities.GenerateCallback(ws.DoNewFromDefault,[],ws);}else{_aD2=Utilities.GenerateCallback(ws.DoNew,[],ws);}}this.SaveUpdate(this.GetAnalysisName(),this.GetCurrentFolderId(),_aD2,_avc);return true;}return false;};CDLWorksheet.prototype.EditReport=function(){var _aBj=this._ak.commManager.CreateAddRequest('analysis','~~',ExpAPIXml.eUpdateOptReplace);this._ak.AddToPostProcessingStack(_aBj.sRequestId,ExpEvent.kCDLWorksheet_SaveForEditSuccess);_aBj.Send(false,this,true);};CDLWorksheet.prototype.postSaveForEdit=function(){this._ak._fK();};CDLWorksheet.prototype.GetAddClientDataReq=function(_Ho){var _AE=new Array();var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionAddClientData;var _Gh=new CDLParameter(ExpAPIXml.kEleWidthData,_Ho,CDLParameter.XMLType());_Jj.AddParameter(_Gh);_AE.push(_Jj);return this._ak.commManager.CreateExploreRequest(_AE);};CDLWorksheet.prototype.Save=function(_Cd,_Cw,_Iy,_Qf,_Iz,_DG){this._pz=_Cd;this._j7="";var _y8=this.GetInitAnalysisFolderPath();if(_Cw&&this._ak._kE[_Cw]){_y8=this._ak._kE[_Cw]._qI;this._j7=_Cw;}this._fq=_Iy;this._v2=_Qf;this._tY=_Iz;var _aBj;var _aI8=this._ak.appobj.uiManager.GetCurrentWorkSheet().GetUICrosstab();if(this._sl&&_aI8&&!_aI8._x2.IsEmpty()&&!_DG){var _Ho=_aI8._x2.WriteToXml(this._b7);_aBj=this.GetAddClientDataReq(_Ho);this._ak.AddToPostProcessingStack(_aBj.sRequestId,ExpEvent.kCDLWorksheet_SaveContinue);}else{_aBj=this._ak.commManager.CreateAddRequest(_Cd,_y8,_Iy);this._ak.AddToPostProcessingStack(_aBj.sRequestId,ExpEvent.kCDLWorksheet_SaveSuccess);if(_Qf){_aBj.SetDeferredCallBackFunction(_Qf,_Iz);}}_aBj.Send(false,this,true);};CDLWorksheet.prototype.SaveUpdate=function(_Cd,_Cw,_Qf,_Iz,_DG){this._pz=_Cd;this._j7="";var _y8=this.GetInitAnalysisFolderPath();if(_Cw&&this._ak._kE[_Cw]){_y8=this._ak._kE[_Cw]._qI;this._j7=_Cw;}this._v2=_Qf;this._tY=_Iz;var _aBj;var _aI8=this._ak.appobj.uiManager.GetCurrentWorkSheet().GetUICrosstab();if(this._sl&&_aI8&&!_aI8._x2.IsEmpty()&&!_DG){var _Ho=_aI8._x2.WriteToXml(this._b7);_aBj=this.GetAddClientDataReq(_Ho);this._ak.AddToPostProcessingStack(_aBj.sRequestId,ExpEvent.kCDLWorksheet_SaveUpdateContinue);}else{_aBj=this._ak.commManager.CreateUpdateRequest(_Cd,_y8);this._ak.AddToPostProcessingStack(_aBj.sRequestId,ExpEvent.kCDLWorksheet_SaveSuccess);if(_Qf){_aBj.SetDeferredCallBackFunction(_Qf,_Iz);}}_aBj.Send(false,this,true);};CDLWorksheet.prototype.Load=function(_QF,_I6){this._ak.appobj.doOpenAnalysis(_QF,_I6);};CDLWorksheet.prototype.LoadDefault=function(_QF){this._ak.appobj.doOpenModel(_QF);};CDLWorksheet.prototype.DoNewFromDefault=function(){if(this._ak.appobj._ea){this.LoadDefault(this._ak.appobj._ea);}else{this.LoadDefault(this._ak.metadata._lt);}};CDLWorksheet.prototype.DoNew=function(){var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionNew;var _AE=new Array();_AE[0]=_Jj;var _aBj=this._ak.commManager.CreateExploreRequest(_AE);this._ak.AddToPostProcessingStack(_aBj.sRequestId,ExpEvent.kCDLWorksheet_NewSuccess);_aBj.Send(true,this,true);this._ak.descriptiveStatsInserted=false;};CDLWorksheet.prototype.GetReport=function(){var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionGetReport;_Jj._eW(ExpAPIXml.kReportCmdType,ExpAPIXml.kRun);if(this.GetAnalysisName()&&!this.IsDefaultName()){_Jj._eW(ExpAPIXml.kReportName,this.GetAnalysisName());}var _AE=new Array();_AE[0]=_Jj;var _aBj=this._ak.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this,true);};CDLWorksheet.prototype.GetHLS=function(_zE){var _Ho;var _aI8=this._ak.appobj.uiManager.GetCurrentWorkSheet().GetUICrosstab();if(_aI8&&this._sl){_Ho=_aI8._x2.WriteToXml(this._b7);}var _AE=new Array();var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionGetHLS;if(_Ho){var _Gh=new CDLParameter(ExpAPIXml.kEleWidthData,_Ho,CDLParameter.XMLType());_Jj.AddParameter(_Gh);}_AE.push(_Jj);this._Z=true;var _aBj=this._ak.commManager.CreateExploreRequest(_AE);if(_zE){_aBj.SetDeferredCallBackFunction(_zE);}_aBj.Send();};CDLWorksheet.prototype.DrillToAnalysis=function(_Wt,_zE){var _AE=new Array();var _Jj=new CDLAction();_Jj.type="drill";_AE.push(_Jj);_Jj._eW(ExpAPIXml.kDrillType,"analysis");for(var i=0;i<_Wt.length;i++){var _ON=_Wt[i];_Jj.AddSource(_ON.GetMemberId(),_ON.GetObjType());}_Jj.AddTargetItem(this._rk._ks,ExpAPIXml.kEleDataMatrix);var _aBj=this._ak.commManager.CreateExploreRequest(_AE);if(_zE){_aBj.SetDeferredCallBackFunction(_zE);}_aBj.Send();};CDLWorksheet.DiffMiningReqTemplate='<DiffMining>'+'<cube>'+'@CUBE_NAME@'+'</cube>'+'<tuple1>'+'@TUPLE1_ITEMS@'+'</tuple1>'+'<value1>@VALUE1@</value1>'+'<tuple2>'+'@TUPLE2_ITEMS@'+'</tuple2>'+'<value2>@VALUE2@</value2>'+'<dontCareDims></dontCareDims>'+'<searchDepth>0</searchDepth>'+'<signAware>true</signAware>'+'<analysisScope>@ANALYSIS_SCOPE</analysisScope>'+'</DiffMining>';analysisScopeTemplate='<item>'+'<mem>@MEM_ID</mem>'+'<level>@LEVEL_ID</level>'+'</item>';CDLWorksheet.prototype.DiffMining=function(_Dz,_Fz,_DA,_Fy,_Sh){var _AE=new Array();var _Jj=new CDLAction();_Jj.type="DiffMining";_AE.push(_Jj);var _am7='';for(var i=0;i<_Dz.length;++i){_am7+='<item>'+Utilities.Descheme(_Dz[i])+'</item>';}var _XC='';for(var i=0;i<_DA.length;++i){_XC+='<item>'+Utilities.Descheme(_DA[i])+'</item>';}var _WZ=CDLWorksheet.DiffMiningReqTemplate;_WZ=_WZ.replace("@CUBE_NAME@",this._ak.metadata.GetPackageName());_WZ=_WZ.replace("@TUPLE1_ITEMS@",_am7);_WZ=_WZ.replace("@VALUE1@",_Fz);_WZ=_WZ.replace("@TUPLE2_ITEMS@",_XC);_WZ=_WZ.replace("@VALUE2@",_Fy);var _akn='';for(var i=0;i<_Sh.length;++i){var s=analysisScopeTemplate;var _azr=_Sh[i].mem;_azr=_azr.replace("mun:",'');var _E1=_Sh[i].level;_E1=_E1.replace("mun:",'');s=s.replace("@MEM_ID",_azr);s=s.replace("@LEVEL_ID",_E1);_akn+=s;}_WZ=_WZ.replace("@ANALYSIS_SCOPE",_akn);var _aoa=new CDLParameter("DiffMining",_WZ,CDLParameter.XMLType());_Jj.AddParameter(_aoa);_Jj.AddTargetItem(this._rk._ks,ExpAPIXml.kEleDataMatrix);var _aBj=this._ak.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this,true);};CDLWorksheet.prototype.CanUndo=function(){return this._ak.commManager.CanUndo();};CDLWorksheet.prototype.CanRedo=function(){return this._ak.commManager.CanRedo();};CDLWorksheet.prototype.Undo=function(){var _Pd=this._ak.commManager.GetUndoState();if(_Pd){var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionUndo;_Jj._eW(ExpAPIXml.kUndoState,"");var _AE=new Array();_AE[0]=_Jj;var _aBj=this._ak.commManager.CreateExploreRequest(_AE,_Pd);_aBj.Send(true,this,true);}};CDLWorksheet.prototype.Redo=function(){var _Pd=this._ak.commManager.GetRedoState();if(_Pd){var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionUndo;_Jj._eW(ExpAPIXml.kUndoState,"");var _AE=new Array();_AE[0]=_Jj;var _aBj=this._ak.commManager.CreateExploreRequest(_AE,_Pd);_aBj.Send(true,this,true);}};CDLWorksheet.prototype.RunChartAndXtabRequest=function(_yV){var _aBj=this._ak.commManager.CreateExploreRequest(_yV);_aBj.Send(true,this,true);delete _yV;};CDLWorksheet.prototype.RunDescriptiveStatsRequest=function(_yV){var _aBj=this._ak.commManager.CreateExploreRequest(_yV);_aBj.Send(true,this,true);delete _yV;};CDLWorksheet.prototype.GetDescriptiveStatsAction=function(_yD,_Es,_KW){if(!_KW)return;var _zz=this._ak._i4.GetCommandByIndex(_KW['index']);if(_yD==ExpAPIXml.kActionDelete){var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionDelete;_Jj.AddTargetItem(_zz.GetElcid(),"descriptivestats");return _Jj;}var _Jj=new CDLAction();_Jj.type=_yD;_Jj.AddTargetItem(this._rk._ks,ExpAPIXml.kEleDataMatrix);var _7Q=_Jj.GetAsXMLString();var _aqm=_zz.prop;var _adB=_c.CreateElement("statstype",_zz.name,true);var _agn=_c.CreateElement("defaultmeasure","mun:[national].[Measures].[Revenue]",true);var _aBa=_zz.GetTuple();var _atR=new Object();_atR['name']='variables';var _atM=_c.CreateElement("edge",_aBa,true,_atR);var _ajB=_c.CreateElement("edges",_atM,true);var _atR=new Object();_atR['name']='commandLabel';var p=_c.CreateElement("property",_Es,true,_atR);for(var i=0;i<_aqm.length;i++){var _PK=_aqm[i];var _Ic=_PK.label;var _zx=_PK.type;var name=_PK.name;var _UN="";if(_zx=="listview"){var _alD=_PK.listView.listItems.listItem;for(var k=0;k<_alD.length;k++){var _atR=new Object();_atR['name']="MODEL";if(_alD[k].value){p+=_c.CreateElement("property",_alD[k].name,true,_atR);}}}else{_UN=_PK.value;}if(_zx!="listview"){var _atR=new Object();_atR['name']=name;if(_UN){p+=_c.CreateElement("property",_UN,true,_atR);}}}var _6E=_c.CreateElement("properties",p,true);if(_zz.name=="DescriptiveStats"){var _agp=_zz.GetDescriptiveStatsCommand();}else{var _agp=_c.CreateElement("statisticscommand",_adB+_6E,true);}var _aIy=_c.CreateElement("descriptivestats",_agp+_ajB,true);var _axj=new CDLParameter("descriptivestats",_aIy,CDLParameter.XMLType());_Jj.AddParameter(_axj);return _Jj;};CDLWorksheet.prototype.GetAddChartAction=function(_Es,_KW){var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionInsert;_Jj.AddTargetItem(this._rk._ks,ExpAPIXml.kEleDataMatrix);var _Hx=_c.CreateElement(ExpAPIXml.kEleCharttype,_Es);var _ajp=_c.CreateElement(CDLChart.GetChartOptionsString(_Es),'',true,_KW);_ajp=_c.CreateElement(ExpAPIXml.kEleChartOptions,_ajp,true);var _aFN=_c.CreateElement(ExpAPIXml.kEleChart,_Hx+_ajp,true);var _axj=new CDLParameter(ExpAPIXml.kEleChart,_aFN,CDLParameter.XMLType());_Jj.AddParameter(_axj);return _Jj;};CDLWorksheet.prototype.GetAddXtabAction=function(){var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionInsert;_Jj.AddTargetItem(this._rk._ks,ExpAPIXml.kEleDataMatrix);_Jj._eW(ExpAPIXml.kEleCrosstab,"");return _Jj;};CDLWorksheet.prototype.SwapRowColumn=function(){var _aoL=false;if(this._rk._c6){for(var i=0;i<this._rk._c6.length;i++){if(this._rk._c6[i].GetLength()>0){var _aoL=true;break;}}}if(!_aoL){return;}var _AE=new Array();var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionSwap;_Jj.AddTargetItem(this._rk._ks,ExpAPIXml.kEleDataMatrix);_AE.push(_Jj);var _aBj=this._ak.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this,true);};CDLWorksheet.prototype.SetRemainderModeOnServer=function(_AS){var _AE=new Array();var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionModify;_Jj.AddTargetItem(this._ak._kX._ks,ExpAPIXml.kEleAnalysis);_Jj.AddParameter(new CDLParameter("remaindermode",_AS));_AE.push(_Jj);var _aBj=this._ak.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this,true);return;};CDLWorksheet.prototype.SetRemainderModeNull=function(){this.SetRemainderModeOnServer("null");};CDLWorksheet.prototype.SetRemainderModeSubtract=function(){this.SetRemainderModeOnServer("subtract");};CDLWorksheet.prototype.SetRemainderModeAggregate=function(){this.SetRemainderModeOnServer("aggregate");};CDLWorksheet.prototype.IsNoDataModeSupported=function(){return this._fD;};CDLWorksheet.prototype.DoDescriptiveStatistics=function(){alert('DoDescriptiveStatistics');};function CDLAbsFilter(_VW,_Ux,_AT){this.oParent=_VW;this.oDataMgr=_AT;this.elcid=null;this.sLabel=null;this.iPosition=_Ux;};CDLAbsFilter.prototype.ProcessXML=function(_Wf){this.elcid=_Wf.getAttribute(ExpAPIXml.kEleElcid);var _4W=_Wf.getAttribute(ExpAPIXml.kEleFLLabel);if(_4W){this.sLabel=_4W;}};CDLAbsFilter.prototype.Modify=function(_Wf){this.Create(_Wf);};CDLAbsFilter.prototype.GetLabel=function(){return this.sLabel;};CDLAbsFilter.prototype.GetContextLabel=function(){return null;};CDLAbsFilter.prototype.GetPosition=function(){return this.iPosition;};CDLAbsFilter.prototype.DeleteFilter=function(){this.sendActionToParent(ExpAPIXml.kActionDelete);};CDLAbsFilter.prototype.ModifyPos=function(_UT){_AG=new Array();if(_UT>this.iPosition){_UT=_UT-1;}_AG.push(new CDLParameter(ExpAPIXml.kEleFLPosition,new String(_UT)));this.sendActionToParent(ExpAPIXml.kActionModify,_AG);};CDLAbsFilter.prototype.GetDeleteAction=function(){var _AG=this.getParams();return this.oParent.constructActionObj(ExpAPIXml.kActionDelete,_AG);};CDLAbsFilter.prototype.getParams=function(_Uf){var _AG=new Array();var _LR=new CDLItem(this.elcid,ExpAPIXml.kEleFilter);_AG.push(new CDLParameter(ExpAPIXml.kSource,_LR));if(_Uf!=null){for(var i=0;i<_Uf.length;i++){_AG.push(_Uf[i]);}}return _AG;};CDLAbsFilter.prototype.sendActionToParent=function(_Pv,_Uf,_Er,_BG){var _AG=this.getParams(_Uf);return this.oParent.sendAction(_Pv,_AG,_Er,_BG);};CDLAbsFilter.prototype.Clone=function(_VW){};CDLAbsFilter.prototype.ModifySetExpression=function(_Br,_J3,_BG){var _AG=new Array();var _aqy=_c.CreateElement(ExpAPIXml.kEleFilter,_Br,true);_AG.push(new CDLParameter(ExpAPIXml.kEleFilter,_aqy,CDLParameter.XMLType()));this.sendActionToParent(ExpAPIXml.kActionModify,_AG,_J3,_BG);};function CDLBlockFilter(_VW,_Ux,_AT){this.base=CDLAbsFilter;this.base(_VW,_Ux,_AT);this._aY=null;this._rB=null;this.bUsedAsParam=0;};CDLBlockFilter.prototype=new CDLAbsFilter;CDLBlockFilter.superclass=CDLAbsFilter.prototype;CDLBlockFilter.GetMemElcid=function(_Wf){var _abI=Dom.GetImmediateChildByName(_Wf,ExpAPIXml.kEleMemberList);if(_abI){var _Rb=Dom.GetElementsByTagName(_abI,ExpAPIXml.kEleMemberPtr);return Dom.GetNodeText(_Rb[0]);}return "";};CDLBlockFilter.prototype.GetBlock=function(){return this._rB;};CDLBlockFilter.prototype.ProcessXML=function(_Wf){CDLBlockFilter.superclass.ProcessXML.call(this,_Wf);this.bUsedAsParam=false;var _93=_Wf.getAttribute(ExpAPIXml.kEleUseAsParam);if(_93=="true"){this.bUsedAsParam=true;}var _aFw=Dom.GetImmediateChildByName(_Wf,ExpAPIXml.kEleAxisOpExpression);var _Ti=_aFw.getAttribute(ExpAPIXml.kEleElcid);this._sBlockId=_Ti;this._rB=this.oDataMgr._kX.getBlock(_Ti);if(this.sLabel==null){var _We=true;this.sLabel=this._rB.GetLabel(_We);}};CDLBlockFilter.prototype.GetDim=function(){return this.oParent.oDataMgr.metadata._iR[this._rB.GetDimId()];};CDLBlockFilter.prototype.GetHierarchy=function(){return this.oParent.oDataMgr.metadata.GetHierarchyById(this._rB.GetHierarchyOrDimId());};CDLBlockFilter.prototype.GetMemberIds=function(){return this._rB.GetDataMemberIds();};CDLBlockFilter.prototype.GetMember=function(){return this.oParent.oDataMgr.metadata.GetMember(this._rB.GetMemberIdFromDim());};CDLBlockFilter.prototype.GetMemberFromId=function(_F9){return this.oParent.oDataMgr.metadata.GetMember(_F9);};CDLBlockFilter.prototype.IsRootMemberDummyFilter=function(){if(this._rB.IsChildren()&&(!this._rB.HasAnyTypeOfFilter())){var oMem=this.GetMember();if(oMem&&oMem._qR===null){return true;}}return false;};CDLBlockFilter.prototype.Clone=function(_VW){var _Zu=new CDLBlockFilter(_VW);_Zu.elcid=null;return _Zu;};CDLBlockFilter.prototype.SetFilterAsParam=function(){var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionSetProperty;_Jj.AddTargetItem(this.oParent.elcid,ExpAPIXml.kEleFilterSet);_Jj.AddTargetItem(this.elcid,ExpAPIXml.kEleFilter);_Jj.AddTargetItem(this._rB.GetId(),ExpAPIXml.kBlock);var _2d=this.bUsedAsParam?'false':'true';_Jj._eW(ExpAPIXml.kEleUseAsParam,_2d);var _AE=new Array();_AE.push(_Jj);var _aBj=this.oDataMgr.commManager.CreateExploreRequest(_AE);if(!this.bUsedAsParam&&this.oDataMgr._kX.DisplaySections()){var _aD2=null;var _AT=this.oDataMgr;_aD2=Utilities.GenerateCallback(CDLAnalysis.SafeOnModifyDisplaySections,[_AT]);if(_aD2){_aBj.SetDeferredCallBackFunction(_aD2);}}_aBj.Send(true,this.oDataMgr.GetCurrentWorkSheet(),true);};function CDLAbsFilterSet(_AT){this.oDataMgr=_AT;this.elcid=null;this._vP=new Array();this._b4=new Array();this._b4[ExpEvent.kDLFilterSet_FullRefresh]=new Array();this._bL=ExpAPIXml.eNullAndZeroSuppress;};CDLAbsFilterSet.prototype.Init=function(){this.oDataMgr._kX.Subscribe(this,ExpEvent.kCDLAnalysis_Replace);};CDLAbsFilterSet.prototype.Create=function(obj,id){if(id!=null){this.elcid=id;}if(this.oDataMgr.IsInMissingMUNState()){return;}var _aJt=Dom.GetElementsByTagName(obj,ExpAPIXml.kEleFilter);if(_aJt!=null&&_aJt.length>0){for(var i=0;i<_aJt.length;i++){var _atH=this.getFilterType(_aJt[i]);switch(_atH){case ExpAPIXml.kBlock:this._vP[i]=new CDLBlockFilter(this,i,this.oDataMgr);this._vP[i].ProcessXML(_aJt[i]);break;default:Debug.Assert(false);break;}}}this.Notify(ExpEvent.kDLFilterSet_FullRefresh);};CDLAbsFilterSet.prototype.Replace=function(_VY){for(var i=0;i<this._vP.length;i++){Utilities.RemoveAllChildObjects(this._vP[i]);}Utilities.DeleteAllFromArray(this._vP);this.Create(_VY);};CDLAbsFilterSet.prototype.getFilterType=function(_Wf){var _atH=_Wf.getAttribute(ExpAPIXml.kEleFilterType);if(_atH==ExpAPIXml.kBlock){return _atH;}else{Debug.Assert(false,'unknown filter type');}return null;};CDLAbsFilterSet.prototype.GetDrillThroughContext=function(_Ow){var _5j=this.GetDimFilters();for(var i=0;i<_5j.length;i++){var _0Z=_5j[i];var _Xy=_0Z.GetMemberIds();if(_Xy&&_Xy.length>1){for(var j=0;j<_Xy.length;j++){var _UY=_0Z.GetMemberFromId(_Xy[j]);if(_UY)_Ow.push(_UY);}}else{var _UY=_0Z.GetMember();if(_UY)_Ow.push(_UY);}}};CDLAbsFilterSet.prototype.SetSelectionContext=function(_Nu){var _5j=this.GetDimFilters();var _aqQ=new Array();for(var i=0;i<_5j.length;i++){var _0Z=_5j[i];var _Xy=_0Z.GetMemberIds();if(_Xy&&_Xy.length>1){for(var j=0;j<_Xy.length;j++){var _UY=_0Z.GetMemberFromId(_Xy[j]);if(_UY)_aqQ.push(_UY);}}else{var _UY=_0Z.GetMember();if(_UY)_aqQ.push(_UY);}}if(_aqQ.length>0){var _aEh="memberUniqueName";var _aiQ,_aGO,metadataModelItem,_2u,_ax3;var _aHE=(_Nu.selections!=null)?_Nu.selections.length:0;for(var _abz=0;(_abz<_aHE||_abz==0);_abz++){var _ab6=(_aHE>0)?_Nu.selections[_abz]:null;var _7H;for(var i=0;i<_aqQ.length;i++){_aiQ=_aqQ[i];_2u=_aiQ.GetId();_ax3=_aiQ.GetLabel();var _7J=_aiQ.GetLevel();if(!_7J){_7J=_aiQ.GetHierarchy();}_aGO=_7J.GetLabel();metadataModelItem=_7J.GetId();if(_ab6==null){_ab6=_Nu.addSelectedCell();}_7H=_ab6.addDefiningCell(_aGO,Utilities.Descheme(metadataModelItem),Utilities.Descheme(_2u),_aEh,_ax3,CANSSelectionContext.kNonMeasureUsage);_7H.addProperty('ordinal',2);}}}};CDLAbsFilterSet.prototype.GetDimFilters=function(){var _zZ=new Array();for(var i=0;i<this._vP.length;i++){if(this._vP[i]instanceof CDLBlockFilter){_zZ.push(this._vP[i]);}}return _zZ;};CDLAbsFilterSet.prototype.GetNonDimFilters=function(){var _add=new Array();for(var i=0;i<this._vP.length;i++){if(!(this._vP[i]instanceof CDLBlockFilter)){_add.push(this._vP[i]);}}return _add;};CDLAbsFilterSet.prototype.GetFilterCount=function(){return this._vP.length;};CDLAbsFilterSet.prototype.GetFilter=function(i){return this._vP[i];};CDLAbsFilterSet.prototype.GetAllFilterBlocks=function(){var _I3=new Array();for(var i=0;i<this._vP.length;i++){if(this._vP[i].GetBlock&&this._vP[i].GetBlock()){_I3.push(this._vP[i].GetBlock());}}return _I3;};CDLAbsFilterSet.prototype.GetFilterForDimensionOrHierarchy=function(_NJ){var _RJ=this.oDataMgr.metadata;var _Y6=_RJ.IsFunctionSupported(ExpAPIXml.kQosMultiHierOfSameDim);var _zZ=this.GetDimFilters();for(var i=0;i<_zZ.length;i++){var _3a=_Y6?_zZ[i].GetHierarchy():_zZ[i].GetDim();if(_NJ==_3a){return _zZ[i];}}return null;};CDLAbsFilterSet.prototype.GetFilterById=function(_Od){for(var i=0;i<this._vP.length;i++){if(this._vP[i].elcid==_Od){return this._vP[i];}}return null;};CDLAbsFilterSet.prototype.InsertDimFilter=function(_Rb,_Us,_BG){var oMem=null;var _BM=null;var _Hx=null;var _amt=null;var _RJ=this.oDataMgr.metadata;var _Y6=_RJ.IsFunctionSupported(ExpAPIXml.kQosMultiHierOfSameDim);if(_RJ.GetNamedSet(_Rb[0])){_1x=this.oDataMgr.metadata.GetNamedSet(_Rb[0]);_Hx=ExpAPIXml.kEleNamedSet;_amt=_Y6?_1x.GetHierarchy():_1x.GetDim();}else{oMem=this.oDataMgr.metadata.GetMember(_Rb[0]);_amt=_Y6?oMem.GetHierarchy():oMem.GetDim();var _35=this.oDataMgr.appobj.uiManager._jf.GetIncludeDetailFlag();if(_Rb.length==1&&_35){_Hx=ExpAPIXml.kChildrenPopulation;}else{_Hx=ExpAPIXml.kMemberPopulation;}}if(_Us==null){_Us=this._vP.length;}var _Br=CDLDataManager.CreateSetExpression(_Hx,_Rb,new String(_Us));if(_amt){var _EB=this.GetFilterForDimensionOrHierarchy(_amt);var _AE=new Array();if(_EB){_AE.push(_EB.GetDeleteAction());var _aDi=this.insertFilter(_Br,true);_AE=_AE.concat(_aDi);if(_BG){return _AE;}var _aBj=this.oDataMgr.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this.oDataMgr.GetCurrentWorkSheet(),true);return null;}}return this.insertFilter(_Br,_BG);};CDLAbsFilterSet.prototype.ReplaceFilter=function(_UU,_LJ,_Nj){var _AE=new Array();Debug.Assert(_Nj!=null);if(_Nj!=null){_AE.push(_Nj.GetDeleteAction());}var _RJ=this.oDataMgr.metadata;var _Y6=_RJ.IsFunctionSupported(ExpAPIXml.kQosMultiHierOfSameDim);var _amt=_Y6?_RJ.GetHierarchyById(_LJ):_RJ.GetDimById(_LJ);if(_amt){var _EB=this.GetFilterForDimensionOrHierarchy(_amt);if(_EB&&_EB!=_Nj){_AE.push(_EB.GetDeleteAction());}}_AE.push(_UU);var _aBj=this.oDataMgr.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this.oDataMgr.GetCurrentWorkSheet(),true);};CDLAbsFilterSet.prototype.InsertComplexFilter=function(_L7,_Us){var _FK=this.oDataMgr.GetCurrentDataMatrix().GetBlock(_L7);if(_FK==null){this.InsertCustomSet(_L7,_Us);return;}var _AE=new Array();var _amt=null;var _RJ=this.oDataMgr.metadata;var _Y6=_RJ.IsFunctionSupported(ExpAPIXml.kQosMultiHierOfSameDim);if(_Y6){_amt=_RJ.GetHierarchyById(_FK.GetHierarchyOrDimId());}else{_amt=_RJ.GetDimById(_FK.GetDimId());}if(_amt){var _EB=this.GetFilterForDimensionOrHierarchy(_amt);if(_EB){_AE.push(_EB.GetDeleteAction());}}if(_Us==null){_Us=this._vP.length;}var _Jj=this.GetInsertActionForBlock(_FK.GetId(),new String(_Us));_AE.push(_Jj);var _aBj=this.oDataMgr.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this.oDataMgr.GetCurrentWorkSheet(),true);};CDLAbsFilterSet.prototype.InsertCustomSet=function(_CJ,_Us){var _AE=new Array();var _FK=this.oDataMgr._kX.GetCustomSet(_CJ).getBlock();var _RJ=this.oDataMgr.metadata;var _Y6=_RJ.IsFunctionSupported(ExpAPIXml.kQosMultiHierOfSameDim);var _amt=_Y6?_RJ.GetHierarchyById(_FK.GetHierarchyOrDimId()):_RJ.GetDimById(_FK.GetDimId());if(_amt){var _EB=this.GetFilterForDimensionOrHierarchy(_amt);if(_EB){_AE.push(_EB.GetDeleteAction());}}if(_Us==null){_Us=this._vP.length;}var _Jj=this.GetInsertActionForCustomSet(_CJ,new String(_Us));_AE.push(_Jj);var _aBj=this.oDataMgr.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this.oDataMgr.GetCurrentWorkSheet(),true);};CDLAbsFilterSet.prototype.insertFilter=function(_Br,_BG){var _AG=new Array();var _aqy=_c.CreateElement(ExpAPIXml.kEleFilter,_Br,true);_AG.push(new CDLParameter(ExpAPIXml.kEleFilter,_aqy,CDLParameter.XMLType()));return this.sendAction(ExpAPIXml.kActionInsert,_AG,null,_BG);};CDLAbsFilterSet.prototype.GetInsertAction=function(_Br){var _AG=new Array();var _aqy=_c.CreateElement(ExpAPIXml.kEleFilter,_Br,true);_AG.push(new CDLParameter(ExpAPIXml.kEleFilter,_aqy,CDLParameter.XMLType()));return this.constructActionObj(ExpAPIXml.kActionInsert,_AG);};CDLAbsFilterSet.prototype.GetInsertActionForCustomSet=function(_CJ,_Us){var _FK=this.oDataMgr._kX.GetCustomSet(_CJ).getBlock();var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionInsert;_Jj.AddTargetItem(this.elcid,ExpAPIXml.kEleFilterSet);var _UR=new String(_Us);_Jj.SetPosition(_UR);_Jj.SetBlockSource(_FK,this.oDataMgr.metadata);return _Jj;};CDLAbsFilterSet.prototype.GetInsertActionForBlock=function(_L7,_Us){var _FK=this.oDataMgr.GetCurrentDataMatrix().GetBlock(_L7);var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionInsert;_Jj.AddTargetItem(this.elcid,ExpAPIXml.kEleFilterSet);var _UR=new String(_Us);var _atH=_c.CreateElement(ExpAPIXml.kEleFilterType,ExpAPIXml.kBlock,true);var _OA=_FK.IsHAMC()?ExpAPIXml.kAxisExprMemberset:ExpAPIXml.kAxisExprChildren;var _Hx=_c.CreateElement(ExpAPIXml.kEleAxisOpExprType,_OA,true);var _Fu=_c.CreateElement(ExpAPIXml.kEleAxisOpExpression,_Hx,true);var _aqy=_c.CreateElement(ExpAPIXml.kEleFilter,(_atH+_Fu),true);_Jj.SetPosition(_UR);_Jj.SetBlockSource(_FK,this.oDataMgr.metadata);_Jj.AddParameter(new CDLParameter(ExpAPIXml.kEleFilter,_aqy,CDLParameter.XMLType()));return _Jj;};CDLAbsFilterSet.prototype.GetInsertActionForMemberList=function(_J5,_Us){var _Hx=ExpAPIXml.kMemberPopulation;_4J=CDLDataManager.CreateSetExpression(_Hx,_J5,new String(_Us));return this.GetInsertAction(_4J);};CDLAbsFilterSet.prototype.GetInsertActionForMember=function(_BX,_Us){var _Hx=ExpAPIXml.kChildrenPopulation;_4J=CDLDataManager.CreateSetExpression(_Hx,new Array(_BX),new String(_Us));return this.GetInsertAction(_4J);};CDLAbsFilterSet.prototype.GetInsertActionForNamedSet=function(_WC,_Us){var _Hx=ExpAPIXml.kEleNamedSet;_4J=CDLDataManager.CreateSetExpression(_Hx,new Array(_WC),new String(_Us));return this.GetInsertAction(_4J);};CDLAbsFilterSet.prototype.sendAction=function(_Pv,_AG,_Er,_BG){var _AE=new Array();if(_Er){_AE.push(_Er);}_AE.push(this.constructActionObj(_Pv,_AG));if(_BG){return _AE;}var _aBj=this.oDataMgr.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this.oDataMgr.GetCurrentWorkSheet(),true);return null;};CDLAbsFilterSet.prototype.constructActionObj=function(_Pv,_AG){var _Jj=new CDLAction();_Jj.type=_Pv;_Jj.AddTargetItem(this.elcid,ExpAPIXml.kEleFilterSet);for(var i=0;i<_AG.length;i++){_Jj.AddParameter(_AG[i]);}return _Jj;};CDLAbsFilterSet.prototype.Subscribe=function(obj,_Dy){if(this._b4[_Dy]){this._b4[_Dy].push(obj);}};CDLAbsFilterSet.prototype.UnSubscribe=function(obj,_MC){if(this._b4&&this._b4[_MC]){Utilities.DeleteFromArray(this._b4[_MC],obj);}};CDLAbsFilterSet.prototype.Notify=function(_MC){if(this._b4[_MC]){for(var i=0;i<this._b4[_MC].length;i++){this._b4[_MC][i].Notify(_MC);}}if(_MC==ExpEvent.kCDLAnalysis_Replace){this.updateBlocks();}};CDLAbsFilterSet.prototype.updateBlocks=function(){for(var i=0;i<this._vP.length;i++){if(this._vP[i]._sBlockId){this._vP[i]._rB=this.oDataMgr._kX.getBlock(this._vP[i]._sBlockId);}}};CDLAbsFilterSet.prototype.SetDefaultSuppression=function(_JQ){this._bL=_JQ;this.Notify(ExpEvent.kDLFilterSet_FullRefresh);};CDLAbsFilterSet.prototype.GetDefaultSuppression=function(){return this._bL;};CDLAbsFilterSet.prototype.InsertCalcFilter=function(_FK,_Fo,_Us){var _AE=new Array();var _EB=this.GetFilterForDimension(this.oDataMgr.metadata.GetDimById(_FK.GetDimId()));if(_EB){_AE.push(_EB.GetDeleteAction());}var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionInsert;_Jj.AddTargetItem(this.elcid,ExpAPIXml.kEleFilterSet);if(_Us==null){_Us=this._vP.length;}var _UR=new String(_Us);var _atH=_c.CreateElement(ExpAPIXml.kEleFilterType,ExpAPIXml.kBlock,true);var _OA=_FK.IsHAMC()?ExpAPIXml.kAxisExprMemberset:ExpAPIXml.kAxisExprChildren;var _Hx=_c.CreateElement(ExpAPIXml.kEleAxisOpExprType,_OA,true);var _Fu=_c.CreateElement(ExpAPIXml.kEleAxisOpExpression,_Hx,true);var _aqy=_c.CreateElement(ExpAPIXml.kEleFilter,(_atH+_Fu),true);_Jj.SetPosition(_UR);_Jj._eW(ExpAPIXml.kEleCalculatedFilter,_Fo);_Jj.SetBlockSource(_FK,this.oDataMgr.metadata);_Jj.AddParameter(new CDLParameter(ExpAPIXml.kEleFilter,_aqy,CDLParameter.XMLType()));_AE.push(_Jj);var _aBj=this.oDataMgr.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this.oDataMgr.GetCurrentWorkSheet(),true);};function CDLWSFilterSet(_AT){this.base=CDLAbsFilterSet;this.base(_AT);this._rs=true;};CDLWSFilterSet.prototype=new CDLAbsFilterSet;CDLWSFilterSet.superclass=CDLAbsFilterSet.prototype;CDLWSFilterSet.prototype.SetFullXtabRefresh=function(_Sz){this._rs=_Sz;};CDLWSFilterSet.prototype.IsFullXtabRefresh=function(){return this._rs;};function CDLDMFilterSet(_AT){this.base=CDLAbsFilterSet;this.base(_AT);};CDLDMFilterSet.prototype=new CDLAbsFilterSet;CDLDMFilterSet.superclass=CDLAbsFilterSet.prototype;function CDLMetadata(_U9){this.datamanager=_U9;this._ks=null;this._iR=new Object();this._xV=new Object();this._ju=true;this._yb=new Object();this._qG=new Object();this._bO=new Object();this._i9=new Object();this._f0=new Object();this._am=new Object();this._gY=new Object();this._vW=new Object();this._sr=new Object();this._xr=new Object();this._js=null;this._j5={};this._gD={};this._xl="";this._h8=false;this._cC=50;this._kW=-1;this._lt="";this._hd="";this._bs=null;this._nJ=true;this._b4=new Array();this._b4[ExpEvent.kCDLMetadata_Replace]=new Array();this._b4[ExpEvent.kCDLMetadata_FullLineage]=new Array();this._b4[ExpEvent.kCDLMetadata_WaitLineage]=new Array();this._b4[ExpEvent.kCDLMetadata_Merge_Properties]=new Array();this._nT=new Object();this._sN=new Array();this._rw=30;this._cm=new Array();};CDLMetadata.prototype.GetMeasureDimIdArr=function(){var _abO=new Array();for(var i in this._xV){_abO.push(i);}return _abO;};CDLMetadata.prototype.GetMeasureDim=function(_Uv){Debug.Assert(this._xV[_Uv]);return this._xV[_Uv];};CDLMetadata.prototype.GetMeasureDimById=function(_Uv){return this._xV[_Uv];};CDLMetadata.prototype.Create=function(_HX){for(var i=0;i<_HX.childNodes.length;i++){switch(_HX.childNodes[i].nodeName){case ExpAPIXml.kEleQoS:var _afy=_HX.childNodes[i];if(_afy.hasChildNodes()){for(var j=0;j<_afy.childNodes.length;j++){var _aDp=_afy.childNodes[j];var _NZ=_aDp.getAttribute(ExpAPIXml.kEleName);var _54=_aDp.getAttribute(ExpAPIXml.kEleQoSLevel);var _anc;if(_54==ExpAPIXml.kOK){_anc=true;}else if((_54==ExpAPIXml.kLimited)&&(_NZ==ExpAPIXml.kQosCaseInSensitiveSrch||_NZ==ExpAPIXml.kQosStartsWithSrch||_NZ==ExpAPIXml.kQosEndsWithSrch||_NZ==ExpAPIXml.kQosContainsSrch||_NZ==ExpAPIXml.kQosHierarchySrch)){_anc=true;}else if((_54==ExpAPIXml.kRestricted)&&(_NZ==ExpAPIXml.kQosHierarchySrch)){_anc=true;}else{_anc=false;}this._nT[_NZ]=_anc;}}break;case ExpAPIXml.kEleDataSources:var _aB9=_HX.childNodes[i];for(var j=0;j<_aB9.childNodes.length;j++){var _Sd=_aB9.childNodes[j];this.ProcessDataSourceProperties(_Sd);}break;}}this._ks=_HX.getAttribute(ExpAPIXml.kEleElcid);Debug.Assert(this._ks!=null);var _aAd=_HX.getAttribute(ExpAPIXml.kEleMaxExpandSize);this._cC=parseInt(_aAd);ExpAPIXml.defaultMaxRetrievedNum=parseInt(_aAd);_aAd=_HX.getAttribute(ExpAPIXml.kEleDefExpandSize);ExpAPIXml.defaultMaxChildNum=parseInt(_aAd);_aAd=_HX.getAttribute(ExpAPIXml.kEleMaxBlockSize);ExpAPIXml.maxBlockSize=parseInt(_aAd);_aAd=_HX.getAttribute(ExpAPIXml.kEleDefBlockSize);this._kW=parseInt(_aAd);_aAd=_HX.getAttribute(ExpAPIXml.kEleOriginDefBlockSize);ExpAPIXml.originDefBlockSize=parseInt(_aAd);var _avy=_HX.getAttribute(ExpAPIXml.kModelPath);this._hd=_avy;var _PQ=_avy.indexOf('/model[');if(_PQ!=-1){this._lt=_avy.substring(0,_PQ);}this._bs=_HX.getAttribute(ExpAPIXml.kSuppressionCapability);this._nJ=(_HX.getAttribute(ExpAPIXml.kUserCanEditSuppressionOptions)!=ExpAPIXml.kFalse);this._io=_HX.getAttribute(ExpAPIXml.kPackage);Decimal.expressionDecimal=_HX.getAttribute(ExpAPIXml.kEleDecSep);};CDLMetadata.prototype.ProcessDataSourceProperties=function(_Sd){if(_Sd){var _aGY=new Object();var _aaO=new Object();_aaO[ExpAPIXml.kEleName]=_Sd.getAttribute(ExpAPIXml.kEleName);_aaO[ExpAPIXml.kEleCubeProperties]=_aGY;for(var j=0;j<_Sd.childNodes.length;j++){var _aol=_Sd.childNodes[j];var _aFE=_Sd.childNodes[j].getAttribute(ExpAPIXml.kEleName);_aGY[_aFE]=Dom.GetNodeText(_aol);}this._cm.push(_aaO);}};CDLMetadata.prototype.ProcessCubeProperties=function(_OF){};CDLMetadata.prototype.GetPackagePath=function(){return this._lt;};CDLMetadata.prototype.GetModelPath=function(){return this._hd;};CDLMetadata.prototype.GetDataUpdatedOn=function(_Cq){var _abr=this._cm;if(_abr.length>0){var _Cq=_Cq?_Cq:0;Debug.Assert(_abr[_Cq]);return _abr[_Cq][ExpAPIXml.kEleCubeProperties][ExpAPIXml.kEleCubeDataUpdatedOn];}return null;};CDLMetadata.prototype.IsFunctionSupported=function(_NZ){var _aJc=this._nT[_NZ];return(_aJc===false)?false:true;};CDLMetadata.prototype.GetCalcDef=function(_Lx){return this.datamanager._kX.GetCalcDef(_Lx);};CDLMetadata.prototype.GetHierarchyFromLevel=function(_JM){for(var i in this._j5){var _Ts=this.GetHierarchyById(i);if(_Ts&&_Ts.ContainsLevel(_JM)){return _Ts;}}return null;};CDLMetadata.prototype.GetHierarchyById=function(_Ob){var obj=this._j5[_Ob];if(obj&&obj.hierarchyCache){obj.oOwnerDim.GetHierarchy(_Ob);}return this._j5[_Ob]||null;};CDLMetadata.prototype.GetLineage=function(_Sa,_zL){var _AE=new Array();var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionGetLineage;_Jj.AddTargetItem(this._ks,ExpAPIXml.kEleMetadata);var _TC=[];for(var i=0;i<_Sa.length;i++){_TC.push(new CDLItem(_Sa[i],ExpAPIXml.kEleMember));}var _8l=new CDLItemList(_TC);var _Rp=_TC.length>1?true:false;_Jj.AddParameter(new CDLParameter(ExpAPIXml.kSource,_8l.GetAsXMLString(),CDLParameter.XMLType(),_Rp));_AE.push(_Jj);var _aBj=this.datamanager.commManager.CreateExploreRequest(_AE);if(_zL){_aBj.SetDeferredCallBackFunction(_zL);}_aBj.Send();};CDLMetadata.prototype.FetchProperties=function(_D9,_zL){var _AE=new Array();for(var i=0;i<_D9.length;i++){var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionGetProperties;_Jj.AddTargetItem(this._ks,ExpAPIXml.kEleMetadata);var _Hx=_D9[i]instanceof CDLLevel?ExpAPIXml.kEleLevel:ExpAPIXml.kEleHierarchy;var _aja=_Jj.AddSource(_D9[i].GetId(),_Hx);_AE.push(_Jj);}var _aBj=this.datamanager.commManager.CreateExploreRequest(_AE);if(_zL){_aBj.SetDeferredCallBackFunction(_zL);}_aBj.Send();};CDLMetadata.prototype.GetAllOrphansLineage=function(){var _AE=new Array();var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionGetLineage;_Jj.AddTargetItem(this._ks,ExpAPIXml.kEleMetadata);var _TC=[];for(var i in this._bO){_TC.push(new CDLItem(this._bO[i]._ks,ExpAPIXml.kEleMember));}var _8l=new CDLItemList(_TC);var _Rp=_TC.length>1?true:false;_Jj.AddParameter(new CDLParameter(ExpAPIXml.kSource,_8l.GetAsXMLString(),CDLParameter.XMLType(),_Rp));_AE.push(_Jj);/*@if(@bering_debug)@*/if(Debug.IsEnabled()){_k=new PerfMonitor("Get Lineage for all orphan members");_k.StartGlobalTimer("Get Lineage for "+_AE.length+" members");}/*@end@*/var _aBj=this.datamanager.commManager.CreateExploreRequest(_AE);_aBj.Send();};CDLMetadata.prototype.WaitForSearchCompletion=function(){if(this.datamanager.appobj.IsSearching()){var _6z=Utilities.GenerateCallback(this.WaitForSearchCompletion,[],this);setTimeout(_6z,1000);}else{this._h8=false;this.ManageLineageRequests();}};CDLMetadata.SafeDoGetLineage=function(_Ke,_E8,_zE){/*@if(!@bering_debug)@*/try{/*@end@*/var _Mg=FindApp(_Ke);_Mg.dataManager.metadata.GetLineage(_E8,_zE);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CDLMetadata.prototype.ManageLineageRequests=function(){if(this.datamanager.appobj.IsSearching()){if(!this._h8){this._h8=true;this.Notify(ExpEvent.kCDLMetadata_WaitLineage);}}else{if(!this._h8){var _aCR=0;var _ad4="";for(var i in this._bO){_aCR++;_ad4=this._bO[i]._ks;if(_aCR>1){break;}}if(_aCR==1){this._xl=_ad4;this.GetAllOrphansLineage();}else if(this._xl==""&&_aCR>0){this.GetAllOrphansLineage();}}}};CDLMetadata.prototype.GetIndependantMem=function(id){return this._hg[id];};CDLMetadata.prototype.FindMeasure=function(id){if(this._yb[id]){return this._yb[id];}for(var i in this._yb){var _SE=this._yb[i];if(_SE._sP&&_SE._sP.length>0){var _aB0=false;for(var j=0;!_aB0&&j<_SE._sP.length;j++){if(_SE._sP[j].selectSingleNode(".//member[elcid="+Utilities.F_ToXPathString(id)+"]")){_SE.Populate();if(this._yb[id]!=null){return this._yb[id];}_aB0=true;}}}}return null;};CDLMetadata.prototype.AddOrphan=function(obj,id){var _DV=(obj.getAttribute(ExpAPIXml.kEleIsMeasure)==ExpAPIXml.kTrue);if(_DV){return this.FindMeasure(id);}else{var _JM=Dom.GetNodeTextDeep(obj,ExpAPIXml.kEleLevelPtr);var _Na=this.GetHierarchyFromLevel(_JM);if(!_Na){_Na=this.GetHierarchyById(_JM);}Debug.Assert(_Na);var _AC=-1;var _aj7=new CDLMember(null,_Na,_AC,true);this._bO[id]=_aj7;_aj7.Init(obj);this.ManageLineageRequests();return _aj7;}};CDLMetadata.prototype.GetOrphanAncestor=function(_Di){for(var i in this._i9){for(var j=0;j<this._i9[i].length;j++){if(this._i9[i][j]._ks==_Di){return i;}}}return null;};CDLMetadata.prototype.GetOrphan=function(id){return this._bO[id];};CDLMetadata.prototype.RemoveOrphan=function(id){delete this._bO[id];if(id==this._xl){this._xl="";this.ManageLineageRequests();}if(Utilities.GetObjArrayLength(this._bO)==0){/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_k){_k.StopGlobalTimer();}/*@end@*/this.Notify(ExpEvent.kCDLMetadata_FullLineage);}};CDLMetadata.prototype.IsMeasure=function(_GY){var _aAD=Dom.GetImmediateChildByName(_GY,ExpAPIXml.kEleIsMeasure);var _DV=(Dom.GetNodeText(_aAD)==ExpAPIXml.kTrue);return _DV;};CDLMetadata.prototype.Replace=function(_HX){Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CDLMetadata::Replace"]);Utilities.ClearObjectArray(this._iR);Utilities.ClearObjectArray(this._xV);Utilities.ClearObjectArray(this._yb);Utilities.ClearObjectArray(this._qG);Utilities.ClearObjectArray(this._bO);Utilities.ClearObjectArray(this._i9);Utilities.ClearObjectArray(this._f0);Utilities.ClearObjectArray(this._gY);Utilities.ClearObjectArray(this._xr);Utilities.ClearObjectArray(this._sr);Utilities.ClearObjectArray(this._j5);Utilities.ClearObjectArray(this._gD);this.Create(_HX);Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CDLMetadata::Replace"]);};CDLMetadata.prototype.GetDimByIndex=function(i){var _Oi=0;for(var _Re in this._iR){if(_Oi==i){return this._iR[_Re];}_Oi++;}};CDLMetadata.prototype.GetDimById=function(id){if(this._iR[id]){return this._iR[id];}else{return this._xV[id];}};CDLMetadata.prototype.GetMemberOrMeasureOrNamedSet=function(_HY){return this.GetMember(_HY)||this.GetMeasure(_HY)||this.GetNamedSet(_HY)||null;};CDLMetadata.prototype.GetMemberOrMeasure=function(_HY){return this.GetMember(_HY)||this.GetMeasure(_HY)||null;};CDLMetadata.prototype.GetData=function(_U6){return this.GetMember(_U6)||this.GetMeasure(_U6)||this.GetLevel(_U6)||this.GetNamedSet(_U6)||this.GetSubsVar(_U6)||null;};CDLMetadata.prototype.GetDataById=function(_U6){return this.GetMember(_U6)||this.GetMeasure(_U6)||this.GetDimById(_U6)||this.GetHierarchyById(_U6)||this.GetMeasureDimById(_U6)||this.GetSubsVar(_U6)||this.GetNamedSet(_U6)||this.GetFolderObject(_U6)||null;};CDLMetadata.prototype.GetDataLabel=function(_U6){var _F6=this.GetData(_U6);return _F6?_F6.GetLabel():null;};CDLMetadata.prototype.GetMember=function(_F9){return this._qG[_F9]||this._bO[_F9]||null;};CDLMetadata.prototype.GetMeasure=function(_HT){return this._yb[_HT]||this.FindMeasure(_HT);};CDLMetadata.prototype.GetLevel=function(_y2){return this._gD[_y2]||null;};CDLMetadata.prototype.HasLevel=function(){return!Utilities.IsObjectEmpty(this._gD);};CDLMetadata.prototype.GetPackageName=function(){return this._js.GetLabel();};CDLMetadata.prototype.GetPackageId=function(){return this._js.GetId();};CDLMetadata.prototype.Notify=function(_Dy,_Mu){var _MC=this._b4[_Dy];if(_MC){for(var i=0;i<_MC.length;i++){var _ajx=_MC[i];if(_Mu){if(_ajx.SetCurrentTrigger){_ajx.SetCurrentTrigger(_Mu);}}_ajx.Notify(_Dy);}}};CDLMetadata.prototype.Subscribe=function(obj,_Dy){if(this._b4[_Dy]){this._b4[_Dy].push(obj);}};CDLMetadata.prototype.UnSubscribe=function(obj,_Dy){if(this._e6&&this._b4[_Dy]){Utilities.DeleteFromArray(this._b4[_Dy],obj);}};CDLMetadata.prototype.Merge=function(_RW){Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CDLMetadata::Merge"]);var _ajc=_RW.childNodes;for(var i=0;i<_ajc.length;i++){var _HB=_ajc[i];switch(_HB.nodeName){case ExpAPIXml.kEleDimension:var id=Dom.GetNodeTextShallow(_HB,ExpAPIXml.kEleElcid);Debug.Assert(id);if(id){if(this.IsMeasure(_HB)){this._xV[id]=new CDLMeasureDim(this);this._xV[id].Create(_HB,true);}else{this._iR[id]=new CDLDimension(this);this._iR[id].Create(_HB,false);}}break;case ExpAPIXml.kEleNamedSets:var _ZN=_HB.childNodes;for(var j=0;j<_ZN.length;j++){var _VX=_ZN[j];var ns=new CDLNamedSet(this);ns.Create(_VX);this._f0[ns._bb]=ns;}break;case ExpAPIXml.kEleSubsVars:var _ZN=_HB.childNodes;for(var j=0;j<_ZN.length;j++){var _B1=_ZN[j];var sv=new CDLSubsVar(this);sv.Create(_B1);this._gY[sv._bb]=sv;}break;case ExpAPIXml.kEleFldObjects:this.CreateFolderObjects(_HB);break;}}var _aAd=_RW.getAttribute(ExpAPIXml.kEleDefBlockSize);if(_aAd){this._kW=parseInt(_aAd);}Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CDLMetadata::Merge"]);};CDLMetadata.kFolderMap={};CDLMetadata.kFolderMap[ExpAPIXml.kEleFldDimension]=CDLFolderObjDimension;CDLMetadata.kFolderMap[ExpAPIXml.kEleFldMeasureDim]=CDLFolderObjMeasureDim;CDLMetadata.kFolderMap[ExpAPIXml.kEleFolder]=CDLFolder;CDLMetadata.kFolderMap[ExpAPIXml.eNamedSet]=CDLFolderObjNamedSet;CDLMetadata.prototype.CreateFolderObjects=function(_HB){var _aI3=_HB.childNodes;Debug.Assert(_aI3);if(!_aI3||!_aI3[0]){return;}_HB=_aI3[0];var _AC=0;var _arH=new CDLFolder(this,_AC);_arH.Create(_HB);if(this._io){_arH._p8=this._io;}this._sr[_arH._ks]=_arH;this._js=_arH;_aI3=_HB.childNodes;for(var i=0;i<_aI3.length;i++){var _Sw=_aI3[i];var _WM=_Sw.getAttribute(ExpAPIXml.kEleFldObjtype);Debug.Assert(CDLMetadata.kFolderMap[_WM]);var _Bi=new CDLMetadata.kFolderMap[_WM](this,i);_Bi.Create(_Sw);this._sr[_Bi._ks]=_Bi;this._xr[_Bi._ks]=_Bi;}};CDLMetadata.prototype.GetMaxExpandSize=function(){return this._cC;};CDLMetadata.prototype.GetDefExpandSize=function(){return this._qd;};CDLMetadata.prototype.GetMaxBlockSize=function(){return this._q1;};CDLMetadata.prototype.GetDefBlockSize=function(){return this._kW;};CDLMetadata.prototype.SetDefBlockSize=function(_P4){this._kW=_P4;};CDLMetadata.prototype.ChangeDefBlockSize=function(_Lg){var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionSetProperty;_Jj._eW(ExpAPIXml.kEleDefBlockSize,_Lg);_Jj.AddTargetItem(this._ks,ExpAPIXml.kEleMetadata);var _AE=new Array();_AE[0]=_Jj;var _aBj=this.datamanager.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this.datamanager.GetCurrentWorkSheet(),true);};CDLMetadata.prototype.GetNamedSet=function(_LN){return this._f0[_LN]||null;};CDLMetadata.prototype.HasNamedSet=function(){return!Utilities.IsObjectEmpty(this._f0);};CDLMetadata.prototype.GetSubsVar=function(_yB){return this._gY[_yB]||null;};CDLMetadata.prototype.SubsVarsExist=function(){return!Utilities.IsObjectEmpty(this._gY);};CDLMetadata.prototype.GetFolderObject=function(id){return this._sr[id]||null;};CDLMetadata.prototype.GetPropertyById=function(_WG){for(var i in this._iR){var _Ni=this._iR[i];var _PK=_Ni.GetPropertyById(_WG,true);if(_PK){return _PK;}}return null;};CDLMetadata.prototype.HasProperty=function(){for(var i in this._iR){var _Ni=this._iR[i];if(_Ni.HasProperties(true)){return true;}}return false;};CDLMetadata.prototype.HasEnoughDimensionalData=function(){return!Utilities.IsObjectEmpty(this._iR)&&!Utilities.IsObjectEmpty(this._xV);};CDLMetadata.prototype.HasMultipleMeasureDim=function(){return(Utilities.GetNthFromObjArray(this._xV,2))?true:false;};CDLMetadata.prototype.ClearOtherItemArray=function(){Utilities.DeleteAllFromArray(this._sN);};CDLMetadata.prototype.DeleteFromOtherItemArray=function(_PQ){Utilities.DeleteNthFromArray(this._sN,_PQ);};CDLMetadata.prototype.AddIntoOtherItemArray=function(_Gz){if(this._sN){if(_Gz&&!Utilities.IsInArray(this._sN,_Gz)){this._sN[this._sN.length]=_Gz;}}};CDLMetadata.prototype.GetOtherItemArrayLength=function(){return(this._sN)?this._sN.length:0;};CDLMetadata.prototype.GetNumDisplayableMeasuresInComboBox=function(){return this._rw;};CDLMetadata.prototype.ProcessProperties=function(_ET,_CH){var _6E=Dom.GetImmediateChildrenByName(_CH,ExpAPIXml.kEleProperty);for(var p=0;p<_6E.length;++p){var _afi=_6E[p];var id=_afi.getAttribute(ExpAPIXml.kEleElcid);if(id){_ET._lG[id]=new CDLProperty(_ET);_ET._lG[id].Init(_afi);}else{Debug.Assert(id);}}};function CDLDimension(_B2){this._v1=false;this._j5=new Object();this._j9=new Array();this._tK=null;this._p8=null;this._ks=null;this._qi=_B2;this._tm=null;this._nh=null;};CDLDimension.prototype.GetLabel=function(){return this._p8;};CDLDimension.prototype.GetDescription=function(){return this._nh;};CDLDimension.prototype.GetId=function(){return this._ks;};CDLDimension.prototype.Create=function(_GY){var _azc=_GY.childNodes;for(var i=0;i<_azc.length;i++){var _YL=_azc[i];var _aGZ=_YL.nodeName;switch(_aGZ){case ExpAPIXml.kEleElcid:this._ks=Dom.GetNodeText(_YL);break;case ExpAPIXml.kEleLabel:this._p8=Dom.GetNodeText(_YL);break;case ExpAPIXml.kEleHierarchies:this.createHierarchies(_YL);break;case ExpAPIXml.kEleDescription:this._nh=Dom.GetNodeText(_YL);break;}}};CDLDimension.prototype.Merge=function(_GY){this.Create(_GY);};CDLDimension.prototype.createHierarchies=function(_MA){var _aD0=0;var _aBs=_MA.childNodes;var id=null;for(var i=0;i<_aBs.length;i++){var _HB=_aBs[i];switch(_HB.nodeName){case ExpAPIXml.kEleIsComplete:if(Dom.GetNodeText(_HB)==ExpAPIXml.kTrue){this._v1=true;}break;case ExpAPIXml.eHierarchy:id=Dom.GetNodeTextShallow(_HB,ExpAPIXml.kEleElcid);this._j5[id]={hierarchyCache:true,element:_HB,iRecordOrderNum:_aD0,oOwnerDim:this};this._qi._j5[id]=this._j5[id];this.GetHierarchy(id);_aD0++;break;}}this._tm=(_aD0===1)?id:null;};CDLDimension.prototype.GetHierarchy=function(id){var obj=this._j5[id];if(obj&&obj.hierarchyCache){var _ahm=new CDLHierarchy(this,obj.iRecordOrderNum);_ahm.Init(obj.element);this._j5[id]=_ahm;}return this._j5[id]||null;};CDLDimension.prototype.SetDefaultHierarchy=function(_VU){this._tK=_VU;};CDLDimension.prototype.GetDefaultHierarchy=function(){return this._tK;};CDLDimension.prototype.HasLevel=function(){for(var j in this._j5){var _Ts=this.GetHierarchy(j);if(_Ts&&_Ts.HasLevel()){return true;}}return false;};CDLDimension.prototype.IsSingleHierarchy=function(){return(this._tm)?true:false;};CDLDimension.prototype.GetSingleHierarchy=function(){return this.GetHierarchy(this._tm);};CDLDimension.prototype.HasHierarchy=function(){return true;};CDLDimension.prototype.GetChild=function(i){if(i<this._h4.length){return this._h4[i];}return null;};CDLDimension.prototype.GetChildCount=function(){return this._h4.length-this._j9.length;};CDLDimension.prototype.GetPopulation=function(){return this.GetChildCount();};CDLDimension.prototype.GetChildArray=function(){return this._h4;};CDLDimension.prototype.SetChildArray=function(_K3){Utilities.DeleteAllFromArray(this._h4);this._h4=_K3;};CDLDimension.prototype.CopyHierarchyToChildren=function(){var a=[];for(var h in this._j5){a.push(this.GetHierarchy(h));}this.SetChildArray(a);};CDLDimension.prototype.IsComplete=function(){return this._v1;};CDLDimension.prototype.GetHierarchyFromLevel=function(_JM){var _ais=this._j5;for(var j in _ais){var _Ts=this.GetHierarchy(j);if(_Ts&&_Ts.ContainsLevel(_JM)){return _Ts;}}return null;};CDLDimension.prototype.GetHierarchyById=function(_Ob){return this.GetHierarchy(_Ob);};CDLDimension.prototype.GetPropertyById=function(_WG){for(var j in this._j5){var _Ts=this.GetHierarchy(j);if(_Ts&&_Ts.HasProperties(true)){var oProp=_Ts.GetProperty(_WG,true);if(oProp!=null){return oProp;}}}return null;};CDLDimension.prototype.HasProperties=function(_P9){for(var j in this._j5){var _Ts=this.GetHierarchy(j);if(_Ts&&_Ts.HasProperties(_P9)){return true;}}return false;};CDLDimension.prototype.isHierarchyHidden=function(id){return Utilities.IsInArray(this._j9,id);};function CDLMeasureDim(md){this.base=CDLDimension;this.base(md);this._kr=new Object();this._f4=new Array(ExpAPIXml.kEleSumAggre,ExpAPIXml.kEleTotalAggre,ExpAPIXml.kEleCountAggre,ExpAPIXml.kEleCountNonZeroAggre);};CDLMeasureDim.prototype=new CDLDimension;CDLMeasureDim.superclass=CDLDimension.prototype;CDLMeasureDim.prototype.Create=function(_JZ,_yP){var _aBm=_JZ.childNodes;for(var i=0;i<_aBm.length;i++){var _1p=_aBm[i];var _aGZ=_1p.nodeName;switch(_aGZ){case ExpAPIXml.kEleElcid:this._ks=Dom.GetNodeText(_1p);break;case ExpAPIXml.kEleLabel:this._p8=Dom.GetNodeText(_1p);break;case ExpAPIXml.kEleMembers:this.createMembers(_1p);break;case ExpAPIXml.kEleDescription:this._nh=Dom.GetNodeText(_1p);break;}}};CDLMeasureDim.prototype.createMembers=function(_z1){var _7T=0;var _YG=_z1.childNodes;for(var j=0;j<_YG.length;j++){var _atL=_YG[j];var _azr=null;switch(_atL.nodeName){case ExpAPIXml.kEleMember:_azr=new CDLMeasure(null,this,_7T);_7T++;_azr.Init(_atL);_azr.Merge(_atL);this._kr[_azr._ks]=_azr;_azr.SetLineageLabel(new Array(this.GetLabel(),_azr.GetLabel()));break;case ExpAPIXml.kEleIsComplete:var _aJy=Dom.GetNodeText(_atL);if(_aJy==ExpAPIXml.kTrue){this._v1=true;}break;}}this._h4=Utilities.CopyObjArrayToArray(this._kr);if(Utilities.GetObjArrayLength(this._qi._yb)<this._qi.GetNumDisplayableMeasuresInComboBox()){for(i in this._qi._yb){this._qi._yb[i].Populate();if(Utilities.GetObjArrayLength(this._qi._yb)>this._qi.GetNumDisplayableMeasuresInComboBox()){break;}}}};CDLMeasureDim.prototype.createLevels=function(_BB){};CDLMeasureDim.prototype.createHierarchies=function(_MA){};CDLMeasureDim.prototype.SetDefaultHierarchy=function(_VU){};CDLMeasureDim.prototype.GetDefaultHierarchy=function(){return null;};CDLMeasureDim.prototype.GetLevel=function(_TH){return null;};CDLMeasureDim.prototype.IsSingleHierarchy=function(){return true;};CDLMeasureDim.prototype.HasHierarchy=function(){return false;};CDLMeasureDim.prototype.GetChildCount=function(){return this.GetChildArray().length;};CDLMeasureDim.prototype.GetPopulation=function(){return this.GetChildCount();};CDLMeasureDim.prototype.GetChildArray=function(){if(this._fP){return this._fP.GetChildArray();}else{Debug.Assert(false);return this._h4;}};CDLMeasureDim.prototype.SetChildArray=function(_K3){if(this._fP){this._fP.SetChildArray(_K3);}};CDLMeasureDim.prototype.IsComplete=function(){return this._v1;};function CDLAbsMember(_VW,_AC,_In){this._qR=_VW;this._wU=_AC;this._bG=_In;this._v1=false;this._h4=new Array();this._hg=new Array();this._eK=0;this._p8=null;this._ks="";this._qu=CDLAbsMember.eStateLoaded;this._nV=CDLAbsMember.eStateLoaded;this._vb=(!this._qR&&!_In);this._ge=false;this._nF=0;};CDLAbsMember.eStateLoading=0;CDLAbsMember.eStateLoaded=1;CDLAbsMember.eStateNoResponse=2;CDLAbsMember.eStateFailedResponse=3;CDLAbsMember.prototype.Init=function(_RZ,_DV){this._e6=new Array();this._e6[ExpEvent.kCDLMember_Merge]=new Array();this._e6[ExpEvent.kCDLMember_Merge_NoResponse]=new Array();this._fA='';var _atp=null;var _aJO=_RZ.childNodes;for(var i=0;i<_aJO.length;i++){var obj=_aJO[i];switch(obj.nodeName){case ExpAPIXml.kEleElcid:this._ks=Dom.GetNodeText(obj);break;case ExpAPIXml.kEleLabel:this._p8=Dom.GetNodeText(obj);break;case ExpAPIXml.kEleLevelPtr:this._iY=Dom.GetNodeText(obj);if(this.IsLeafLevelMember&&this.IsLeafLevelMember(this._iY)){this._v1=true;this._eK=0;}break;default:break;}}};CDLAbsMember.prototype.manageMemberArrays=function(){if(!this._bG&&this.GetMetadata().GetOrphan(this._ks)){var _RJ=this.GetMetadata();var _ayT=_RJ.GetOrphan(this._ks);var _axP=_ayT.GetChildArray();for(var i=0;i<_axP.length;i++){var _axJ=_axP[i];var _aqS=false;for(var j=0;j<this._h4.length;j++){if(this._h4[j]._ks==_axJ._ks){_aqS=true;break;}}if(!_aqS){this._h4.push(_axJ);_axJ._qR=this;}}for(var i=0;i<_ayT._hg.length;i++){var _axJ=_ayT._hg[i];var _aqS=false;for(var j=0;j<this._hg.length;j++){if(this._hg[j]._ks==_axJ._ks){_aqS=true;break;}}if(!_aqS){this._hg.push(_axJ);_axJ._qR=this;}}if(_RJ._i9[this._ks]){Utilities.DeleteAllFromArray(_RJ._i9[this._ks]);delete _RJ._i9[this._ks];}_RJ.RemoveOrphan(this._ks);}};CDLAbsMember.prototype.Merge=function(_RZ,_zR,_Vk){var _B2=this.GetMetadata();this._qu=CDLAbsMember.eStateLoaded;var _aBM=Dom.GetImmediateChildByName(_RZ,ExpAPIXml.kEleMembers);var _YG=_aBM.childNodes;for(var i=0;i<_YG.length;i++){var obj=_YG[i];if(obj.nodeName==ExpAPIXml.kEleMember){if(_zR==this._ks){this.TreeMerge(_RZ,_zR,_Vk);break;}else{var _04=null;var _C7=Dom.GetNodeTextShallow(obj,ExpAPIXml.kEleElcid);Debug.Assert(obj.nodeName==ExpAPIXml.kEleMember);Debug.Assert(_C7!=null);var _ac5=false;for(var j=0;j<this._h4.length&&!_ac5;j++){if(this._h4[j]._ks==_C7){_ac5=true;_04=_B2._qG[_C7];}}var _3e=false;for(var n=0;n<this._hg.length&&!_3e;n++){if(this._hg[n]._ks==_C7){_3e=true;_04=_B2._qG[_C7];break;}}if(!_ac5){if(_zR==this._ks){if(this._eK<0){this._eK=1;}else{this._eK++;}if(_3e){var _ans=Utilities.GetShallowClone(_04);Utilities.DeleteFromArray(this._hg,_04);}var _AC=this._h4.length;_04=this.addChild(obj,_AC);if(_ans){_04._hg=Utilities.CopyArray(_ans._hg);}}else{if(!_3e){_04=this.addIndependantChild(obj);if(_B2&&_04._qR){_B2.AddIntoOtherItemArray(_04._qR._ks);}if(this._bG){_B2._i9[this._ks]=[_04];}var _Zf=_B2.GetOrphanAncestor(this._ks);if(_Zf){_B2._i9[_Zf].push(_04);}}}}_04.Merge(obj,_zR);}}else if(obj.nodeName==ExpAPIXml.kEleIsComplete){var _aJy=null;_aJy=Dom.GetNodeText(obj);if(_aJy==ExpAPIXml.kTrue&&_zR==this._ks){this._v1=true;}}}if(!this._v1){if(this._eK>=_B2.GetMaxExpandSize()){this._ge=true;}}var _6E=_RZ.selectNodes(ExpAPIXml.kEleProperties+'/'+ExpAPIXml.kEleProperty);for(var p=0;p<_6E.length;++p){var obj=_6E[p];var _WG=Dom.GetNodeTextShallow(obj,ExpAPIXml.kEleElcid);var _UN=Dom.GetNodeTextShallow(obj,ExpAPIXml.kEleValue);if(_WG&&_UN){this.AddPropertyValue(new CDLPropertyValue(_WG,_UN));this._nV=CDLAbsMember.eStateLoaded;}}this.manageMemberArrays();this.Notify(ExpEvent.kCDLMember_Merge);if(_Vk){_B2.datamanager.Notify(ExpEvent.kCDLDataManager_UpdateTree);}};CDLAbsMember.prototype.TreeMerge=function(_RZ,_zR,_Vk){var _apl=_RZ.selectNodes(ExpAPIXml.kEleMembers+'/'+ExpAPIXml.kEleMember);for(var m=0;m<_apl.length;m++){var obj=_apl[m];var _04=null;var _C7=Dom.GetNodeTextShallow(obj,ExpAPIXml.kEleElcid);Debug.Assert(_C7);var _3e=false;for(var n=0;n<this._hg.length&&!_3e;n++){if(this._hg[n]._ks==_C7){_3e=true;_04=this._hg[n];break;}}if(this._eK<0){this._eK=1;}else{this._eK++;}if(_3e){var _ans=Utilities.GetShallowClone(_04);Utilities.DeleteFromArray(this._hg,_04);}var _AC=this._h4.length;_04=this.addChild(obj,_AC);if(_ans){_04._hg=Utilities.CopyArray(_ans._hg);}}this.GetMetadata()._qG[this._ks]=this;};CDLAbsMember.prototype.IsComplete=function(){return this._v1;};CDLAbsMember.prototype.GetChildCount=function(_Gg){var _YV=this._h4;if(_Gg){_YV=_YV.concat(this._hg);}return _YV.length;};CDLAbsMember.prototype.GetChildArray=function(_Gg){var _YV=this._h4;if(_Gg){_YV=_YV.concat(this._hg);}return _YV;};CDLAbsMember.prototype.SetChildArray=function(_K3){Utilities.DeleteAllFromArray(this._h4);this._h4=_K3;};CDLAbsMember.prototype.GetOtherChildCount=function(){var _aBl=0;if(this._hg){_aBl=this._hg.length;}return _aBl;};CDLAbsMember.prototype.GetOtherChildArray=function(){return this._hg;};CDLAbsMember.prototype.SetOtherChildArray=function(_NE){Utilities.DeleteAllFromArray(this._hg);this._hg=_NE;};CDLAbsMember.prototype.GetChild=function(i,_Gg){var _YV=this._h4;if(_Gg){_YV=_YV.concat(this._hg);}return _YV[i];};CDLAbsMember.prototype.GetChildIndex=function(oMem,_Gg){var _Re=-1;var _YV=this._h4;if(_Gg){_YV=_YV.concat(this._hg);}for(var i=0;i<_YV.length;i++){if(_YV[i]==oMem){_Re=i;break;}}return _Re;};CDLAbsMember.prototype.IsChild=function(oMem,_Gg){if(this.GetChildIndex(oMem,_Gg)!=-1){return true;}return false;};CDLAbsMember.prototype.Populate=function(){if(this._v1||this._h4.length>=this.GetMetadata().GetMaxExpandSize()||this._qu==CDLAbsMember.eStateLoading){return;}this._qu=CDLAbsMember.eStateLoading;var _Jj=new CDLAction();_Jj.type='expand';_Jj.AddSource(this._ks,ExpAPIXml.kEleMember);_Jj.AddTargetItem(this.GetMetadata()._ks,ExpAPIXml.kEleMetadata);var _AE=new Array();_AE[0]=_Jj;var _aBj=this.GetMetadata().datamanager.commManager.CreateExploreRequest(_AE);_aBj.sRequestedMemberId=this._ks;_aBj.Send(true,this);var _6z=Utilities.GenerateCallback(this.HandleNonResponse,[],this);setTimeout(_6z,Utilities.GetServerResponseTimeout());};CDLAbsMember.prototype.HandleNonResponse=function(){if(this._qu==CDLAbsMember.eStateLoaded){return;}this._qu=CDLAbsMember.eStateNoResponse;this.Notify(ExpEvent.kCDLMember_Merge_NoResponse);Utilities.IncrementServerTimeout();};CDLAbsMember.prototype.SetStateFailed=function(_FA,_Kr,_zP){this._qu=CDLAbsMember.eStateFailedResponse;if(!_zP){CUIDialogMgr.DisplayMessageBox(CUIMessageBox.kCritical,(_FA)?_FA:'MES_SERVER_ERROR',_Kr);}};CDLAbsMember.prototype.IsRootMember=function(){return this._qR==null;};CDLAbsMember.prototype.GetRootMember=function(){var _aeW=this;var _VW=this._qR;while(_VW!=null){_aeW=_VW;_VW=_VW._qR;}return _aeW;};CDLAbsMember.prototype.GetBreadCrumbText=function(_CB,_En){var _aoK="";var _UY=this;if(_UY._p8==null){var _B2=this.GetMetadata();_UY=_B2._qG[this._ks];}var _aBp=new Array();_aBp[0]=_UY._p8;var _VW=_UY._qR;var i=1;while(_VW!=null&&_VW._p8!=null){_aBp[i]=_VW._p8;_VW=_VW._qR;i++;}if(_CB){if(this instanceof CDLMember){_aBp.push(this._re.GetLabel());}_aBp.push(this.GetDim().GetLabel());}if(document.dir==""||document.dir=="ltr"){var _aBp=_aBp.reverse();}if(_aBp.length==1){return _aBp[0];}if(_En==null){_En='IDS_BREADCRUMB_LIST';}_aoK=this.GetMetadata().datamanager.appobj.oResources.ReplaceParamList(_En,_aBp);return _aoK;};CDLAbsMember.prototype.SetLineageLabel=function(_Sc){if(_Sc){this._fA=this.GetMetadata().datamanager.appobj.oResources.ReplaceParamList('IDS_BREADCRUMB_LIST',_Sc);}};CDLAbsMember.prototype.GetLineageLabel=function(){if(this._fA!=''){return this._fA;}else{var _aBp=new Array();_aBp[0]=this._p8;var _VW=this._qR;var i=1;while(_VW!=null&&(_VW._fA=='')){if(!_VW._p8){return this._p8;}Utilities.InsertToNthInArray(_aBp,_VW._p8,0);_VW=_VW._qR;}if(_VW){Utilities.InsertToNthInArray(_aBp,_VW._fA,0);}this.SetLineageLabel(_aBp);return this._fA;}};CDLAbsMember.prototype.Subscribe=function(obj,_Dy){if(this._e6[_Dy]){for(var i=0;i<this._e6[_Dy].length;i++){if(this._e6[_Dy][i]==obj){return;}}this._e6[_Dy].push(obj);}};CDLAbsMember.prototype.Notify=function(_Dy){var _ay7=this._e6[_Dy];for(var i in _ay7){_ay7[i].Notify(_Dy);if(_Dy==ExpEvent.kCDLMember_Merge_NoResponse||_Dy==ExpEvent.kCDLMember_Merge){delete _ay7[i];}if(_Dy==ExpEvent.kCDLMember_Merge){delete this._e6[ExpEvent.kCDLMember_Merge_NoResponse][i];}else if(_Dy==ExpEvent.kCDLMember_Merge_NoResponse){delete this._e6[ExpEvent.kCDLMember_Merge][i];}}};CDLAbsMember.prototype.GetState=function(){return this._qu;};CDLAbsMember.prototype.GetLabel=function(){return this._p8;};CDLAbsMember.prototype.GetId=function(){return this._ks;};CDLAbsMember.prototype.GetParent=function(){return this._qR;};CDLAbsMember.prototype.GetPopulation=function(){return this._eK;};CDLAbsMember.prototype.GetOriginalRecordOrder=function(){return this._wU;};CDLAbsMember.prototype.AddPropertyValue=function(_Bp){var _aoF=false;for(var i=0;i<this._u7&&_aoF==false;i++){if(this._u7[i]._ks==_Bp._ks){_aoF=true;}}if(_aoF==false){this._u7[this._u7.length]=_Bp;}};CDLAbsMember.prototype.GetPropertyValues=function(){if(this._nV==CDLAbsMember.eStateLoading){return;}var _acj=new Array();var _S8=this.GetLevel();var _ET=(_S8!=null?_S8:this.GetHierarchy());if(_ET){for(var n in _ET._lG){var _aoF=false;for(var i=0;i<this._u7.length;i++){if(this._u7[i]._ks==_ET._lG[n]._ks){_aoF=true;}}if(_aoF==false){_acj[_acj.length]=_ET._lG[n]._ks;}}}if(_acj.length==0){return;}var _AE=new Array();var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionMemPropVals;_Jj.AddSource(this._ks,ExpAPIXml.kEleMember);_Jj.AddTargetItem(this.GetMetadata()._ks,'metadata');var _awi='';_awi+="<properties>";for(var i=0;i<_acj.length;i++){_awi+="<property>";_awi+=_acj[i];_awi+="</property>";}_awi+="</properties>";_Jj.AddParameter(new CDLParameter(ExpAPIXml.kEleProperties,_awi,CDLParameter.XMLType()));this._nV=CDLAbsMember.eStateLoading;_AE[0]=_Jj;var _aBj=this.GetMetadata().datamanager.commManager.CreateExploreRequest(_AE);_aBj.Send();var _Ke=this.GetMetadata().datamanager.appobj.appname;var _6z=Utilities.GenerateCallback(this.HandleNoPropertiesResponse,[],this);setTimeout(_6z,Utilities.GetServerResponseTimeout());return;};CDLAbsMember.prototype.HandleNoPropertiesResponse=function(){if(this._nV==CDLAbsMember.eStateLoaded){return;}this._nV=CDLAbsMember.eStateNoResponse;Utilities.IncrementServerTimeout();};CDLAbsMember.prototype.GetPropertyValueById=function(_WG){for(var i=0;i<this._u7.length;i++){if(this._u7[i]._ks==_WG){return this._u7[i]._jU;}}var _aaR=false;var _S8=this.GetLevel();var _ET=(_S8!=null?_S8:this.GetHierarchy());if(_ET&&_ET._lG&&_ET._lG[_WG]){_aaR=true;}if(!_aaR){Debug.Assert(false,"Invalid property requested for this member.");return null;}this.GetPropertyValues();return null;};CDLAbsMember.prototype.IsDescendant=function(_HK){var _30=false;var _VW=_HK._qR;while(!_30&&_VW){if(_VW==this){_30=true;}_VW=_VW._qR;}return _30;};CDLAbsMember.prototype.GetDepthInFamilyTree=function(){var _FU=0;var _FZ=this;while(!_FZ._vb){_FZ=_FZ._qR;_FU++;}return _FU;};function CDLMeasure(parent,_RG,_AC,_In){this.base=CDLAbsMember;this.base(parent,_AC,_In);this._cN=_RG;this._wd=null;this._nh=null;this._sP=new Array();};CDLMeasure.prototype=new CDLAbsMember;CDLMeasure.superclass=CDLAbsMember.prototype;CDLMeasure.prototype.GetHierId=function(){return null;};CDLMeasure.prototype.GetDescription=function(){return this._nh;};CDLMeasure.prototype.Init=function(_RZ){CDLMeasure.superclass.Init.call(this,_RZ,true);this._wd=Dom.GetNodeTextShallow(_RZ,ExpAPIXml.kEleRegAggregate);this._nh=Dom.GetNodeTextShallow(_RZ,ExpAPIXml.kEleDescription);this._mi=Dom.GetNodeTextShallow(_RZ,ExpAPIXml.kElePropertyDataType2);var _apl=Dom.GetImmediateChildByName(_RZ,ExpAPIXml.kEleMembers);var _YG=_apl.childNodes;var _aFW=0;var _aJy=ExpAPIXml.kFalse;for(var i=0;i<_YG.length;i++){var _HB=_YG[i];if(_HB.nodeName==ExpAPIXml.kEleMember){_aFW++;break;}else if(_HB.nodeName==ExpAPIXml.kEleIsComplete){_aJy=Dom.GetNodeText(_HB);}}if(_aFW==0&&_aJy==ExpAPIXml.kTrue){this._v1=true;}this._cN._qi._yb[this._ks]=this;};CDLMeasure.prototype.addChild=function(_HB,_AC){var _aFd=new CDLMeasure(this,this._cN,_AC);this._h4.push(_aFd);_aFd.Init(_HB);_aFd.SetLineageLabel(new Array(this.GetLabel(),_aFd.GetLabel()));return this._h4[this._h4.length-1];};CDLMeasure.prototype.GetDimId=function(){return this._cN._ks;};CDLMeasure.prototype.GetDim=function(){return this._cN;};CDLMeasure.prototype.GetMetadata=function(){return this._cN._qi;};CDLMeasure.prototype.IsAggregateable=function(){if(Utilities.IsInArray(this._cN._f4,this._wd)){return true;}return false;};CDLMeasure.prototype.GetRegAggregateType=function(){return this._wd;};CDLMeasure.prototype.GetExplicitLabel=function(){if(this.GetMetadata().HasMultipleMeasureDim()){return this.GetBreadCrumbText(true);}else{return this._p8;}};CDLMeasure.prototype.Merge=function(_RZ){Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CDLMeasure::Merge"]);this._qu=CDLAbsMember.eStateLoaded;var _aBM=Dom.GetImmediateChildByName(_RZ,ExpAPIXml.kEleMembers);for(var i=0;i<_aBM.childNodes.length;i++){var obj=_aBM.childNodes[i];if(obj.nodeName==ExpAPIXml.kEleMember){var _04=null;var _C7=Dom.GetNodeTextShallow(obj,ExpAPIXml.kEleElcid);Debug.Assert(obj.nodeName==ExpAPIXml.kEleMember);Debug.Assert(_C7!=null);var _ac5=false;for(var j=0;j<this._h4.length&&!_ac5;j++){if(this._h4[j]._ks==_C7){_ac5=true;_04=this._h4[j];}}var _3e=false;for(var n=0;n<this._hg.length&&!_3e;n++){if(this._hg[n]._ks==_C7){_3e=true;_04=this._hg[n];break;}}if(!_ac5){if(this._eK<0){this._eK=1;}else{this._eK++;}var _AC=this._h4.length;_04=this.addChild(obj,_AC);}if(_04._sP){_04._sP.push(obj);}}else if(obj.nodeName==ExpAPIXml.kEleIsComplete){var _aJy=null;_aJy=Dom.GetNodeText(obj);if(_aJy==ExpAPIXml.kTrue){this._v1=true;}}}if(!this._v1){if(this._eK>=this.GetMetadata().GetMaxExpandSize()){this._ge=true;}}Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CDLMeasure::Merge"]);};CDLMeasure.prototype.Populate=function(){if(this._sP&&this._sP.length>0){for(var i=0;i<this._sP.length;i++){this.Merge(this._sP[i]);}Utilities.DeleteAllFromArray(this._sP);this._sP=null;}};function CDLMember(parent,_Na,_AC,_In){this.base=CDLAbsMember;this.base(parent,_AC,_In);this._re=_Na;this._iY=null;this._u7=new Array();this._dV=ExpAPIXml.kEleRegRollUp;};CDLMember.prototype=new CDLAbsMember;CDLMember.superclass=CDLAbsMember.prototype;CDLMember.prototype.Init=function(_RZ){CDLMember.superclass.Init.call(this,_RZ);this._dV=Dom.GetNodeTextShallow(_RZ,ExpAPIXml.kEleRollUpType)||this._dV;this.GetMetadata()._qG[this._ks]=this;var x=this.GetMetadata()._qG[this._mi];};CDLMember.prototype.addChild=function(_HB,_AC){var _aEy=new CDLMember(this,this._re,_AC);_aEy.Init(_HB);this._h4.push(_aEy);return this._h4[this._h4.length-1];};CDLMember.prototype.addIndependantChild=function(_HB){var _AC=-1;var _aEy=new CDLMember(this,this._re,_AC);_aEy.Init(_HB);this._hg.push(_aEy);return this._hg[this._hg.length-1];};CDLMember.prototype.GetDimId=function(){return this._re._rj._ks;};CDLMember.prototype.GetDim=function(){return this._re._rj;};CDLMember.prototype.GetMetadata=function(){return this._re._rj._qi;};CDLMember.prototype.GetLevel=function(){return this.GetMetadata().GetLevel(this._iY);};CDLMember.prototype.GetHierId=function(){return this._re.GetHierarchyId();};CDLMember.prototype.GetHierarchy=function(){return this._re;};CDLMember.prototype.IsLeafLevelMember=function(_MK){return this._re.IsLeafLevel(_MK);};CDLMember.prototype.GetChildMemLevels=function(){var _aFA=new Object();if(this._re.HasLevel()){for(var i=0;i<this._h4.length;i++){if(!_aFA[this._h4[i]._iY]){_aFA[this._h4[i]._iY]=this._h4[i].GetLevel();}}}else{_aFA[this._re.GetId()]=this._re;}return _aFA;};CDLMember.prototype.GetRollUpType=function(){return this._dV;};function CDLLevel(_VU){this._p8="";this._ks="";this._re=_VU;};CDLLevel.prototype.Init=function(_Do){this._p8=Dom.GetNodeTextShallow(_Do,ExpAPIXml.kEleLabel);this._ks=Dom.GetNodeTextShallow(_Do,ExpAPIXml.kEleElcid);this._re.GetMetadata()._gD[this._ks]=this;this._cD(_Do);};CDLLevel.prototype.Merge=function(_GV){this._cD(_GV);this._re.GetMetadata().Notify(ExpEvent.kCDLMetadata_Merge_Properties,this);};CDLLevel.prototype._cD=function(_Do){var _B2=this._re.GetMetadata();var _aug=Dom.GetImmediateChildrenByName(_Do,ExpAPIXml.kEleProperties);for(var lp=0;lp<_aug.length;lp++){this._lG=this._lG||{};_B2.ProcessProperties(this,_aug[lp]);}};CDLLevel.prototype.HasPropertiesBeenRetrieved=function(){return(this._lG!=null);};CDLLevel.prototype.GetHierarchy=function(){return this._re;};CDLLevel.prototype.GetLabel=function(){return this._p8;};CDLLevel.prototype.GetId=function(){return this._ks;};CDLLevel.prototype.GetProperty=function(id){if(this._lG&&this._lG[id]){return this._lG[id];}return null;};CDLLevel.prototype.GetProperties=function(){return this._lG;};CDLLevel.prototype.HasProperties=function(){return!Utilities.IsObjectEmpty(this._lG);};CDLLevel.prototype.GetDimId=function(){return this.GetHierarchy()._rj._ks;};CDLLevel.prototype.GetDim=function(){return this.GetHierarchy()._rj;};CDLLevel.prototype.GetHierId=function(){return this.GetHierarchy().GetId();};function CDLProperty(_VW){this._ks="";this._p8="";this._mi=ExpAPIXml.kEleUnknownProperty;this._p6=_VW;};CDLProperty.prototype.Init=function(_Do){this._ks=_Do.getAttribute(ExpAPIXml.kEleElcid);this._p8=_Do.getAttribute(ExpAPIXml.kEleLabel);var _V4=_Do.getAttribute(ExpAPIXml.kElePropertyDataType);this._mi=_V4?_V4:ExpAPIXml.kEleUnknownProperty;Debug.Assert(this._ks!=null);};CDLProperty.prototype.GetLabel=function(){return this._p8;};CDLProperty.prototype.GetId=function(){return this._ks;};CDLProperty.prototype.GetDataType=function(){return this._mi;};CDLProperty.prototype.GetBreadCrumbText=function(){if(this._p6 instanceof CDLLevel){var _Co=this._p6._re._rj._qi.datamanager.appobj.oResources;}else{var _Co=this._p6._rj._qi.datamanager.appobj.oResources;}var _BM=_Co.ReplaceParam('IDS_PROPERTY_BREADCRUMB',1,this._p6.GetLabel());_BM=_Co.ReplaceParam(_BM,2,this.GetLabel());return _BM;};CDLProperty.prototype.IsDateTimeAttribute=function(){switch(this._mi){case ExpAPIXml.kEleDateProperty:case ExpAPIXml.kEleDate2Property:case ExpAPIXml.kEleTimeProperty:case ExpAPIXml.kEleTime2Property:case ExpAPIXml.kEleDatetimeProperty:case ExpAPIXml.kEleDatetime2Property:return true;default:return false;}};CDLProperty.prototype.IsIntervalAttribute=function(){switch(this._mi){case ExpAPIXml.kEleIntervalProperty:case ExpAPIXml.kEleInterval2Property:case ExpAPIXml.kEleIntervalYMProperty:return true;default:return false;}};CDLProperty.prototype.IsNumericAttribute=function(){switch(this._mi){case ExpAPIXml.kEleInt16Property:case ExpAPIXml.kEleInt32Property:case ExpAPIXml.kEleInt64Property:case ExpAPIXml.kEleDecimalProperty:case ExpAPIXml.kEleNumericProperty:case ExpAPIXml.kEleFloatProperty:case ExpAPIXml.kEleFloat16Property:case ExpAPIXml.kEleFloat32Property:case ExpAPIXml.kEleFloat64Property:return true;default:return false;}};function CDLPropertyValue(id,_UN){this._ks=id;this._jU=_UN;};function CDLHierarchy(_EZ,_AC){this._rj=_EZ;this._wU=_AC;this._uL=false;this._ks="";this._p8="";this._nh="";this._kg=false;this._gD={};this._w9=[];this._hg=[];this._d3=[];this._h4=null;};CDLHierarchy.prototype.Init=function(_N2){this._ks=Dom.GetNodeTextShallow(_N2,ExpAPIXml.kEleElcid);this._p8=Dom.GetNodeTextShallow(_N2,ExpAPIXml.kEleLabel);if(!this._p8){this._rj._j9.push(this._ks);}this._nh=Dom.GetNodeTextShallow(_N2,ExpAPIXml.kEleDescription);var _B2=this.GetMetadata();_B2._j5[this._ks]=this;var _aCz=Dom.GetNodeTextShallow(_N2,ExpAPIXml.kEleIsRagged);this._kg=_aCz?(_aCz==ExpAPIXml.kTrue):this._kg;var _aGK=_N2.childNodes;for(var i=0;i<_aGK.length;i++){var _4m=_aGK[i];switch(_4m.nodeName){case ExpAPIXml.kEleHierDefault:this._rj.SetDefaultHierarchy(this);break;case ExpAPIXml.kEleLevels:this.createLevels(_4m);break;case ExpAPIXml.kEleProperties:this._lG=this._lG||{};_B2.ProcessProperties(this,_4m);break;default:break;}}var _aaq=Dom.GetImmediateChildByName(_N2,ExpAPIXml.kEleRootMembers);this.createMembers(_aaq);};CDLHierarchy.prototype.GetLabel=function(){return this._p8;};CDLHierarchy.prototype.GetId=function(){return this._ks;};CDLHierarchy.prototype.GetDescription=function(){return this._nh;};CDLHierarchy.prototype.IsRagged=function(){return this._kg;};CDLHierarchy.prototype.GetOriginalRecordOrder=function(){return this._wU;};CDLHierarchy.prototype.GetDimension=function(){return this._rj;};CDLHierarchy.prototype.GetProperty=function(id,_P9){if(this._lG&&this._lG[id]){return this._lG[id];}if(_P9){for(var k in this._gD){var oProp=this.GetLevel(k).GetProperty(id);if(oProp!=null){return oProp;}}}return null;};CDLHierarchy.prototype.GetProperties=function(){var _aBl=this._lG;if(!_aBl){var _1F=this._gD;if(_1F){_aBl=new Object();for(var i in _1F){var _S8=_1F[i];for(var j in _S8._lG){_aBl[j]=_S8._lG[j];}}}}return _aBl;};CDLHierarchy.prototype.HasProperties=function(_P9){for(var i in this._lG){return true;}if(_P9){for(var k in this._gD){if(this.GetLevel(k).HasProperties()){return true;}}}return false;};CDLHierarchy.prototype.HasPropertiesBeenRetrieved=function(){if(this._lG){return true;}else{var _1F=this._gD;if(_1F){if(Utilities.IsObjectEmpty(_1F)){return false;}for(var i in _1F){var _S8=_1F[i];if(!_S8||!_S8._lG){return false;}}}return true;}return false;};CDLHierarchy.prototype.createMembers=function(_z1){var _Xz=0;var _YG=_z1.childNodes;for(var j=0;j<_YG.length;j++){var _atL=_YG[j];var _azr=null;switch(_atL.nodeName){case ExpAPIXml.kEleMember:_azr=this.createMember(_atL,_Xz);_Xz++;break;case ExpAPIXml.kEleIsComplete:var _aJy=Dom.GetNodeText(_atL);if(_aJy==ExpAPIXml.kTrue){this._v1=true;}break;}}this._uL=(this._w9.length==1&&this._v1);this.DeleteChildArray();if(this._uL){this.getMember(0)._rM=this.GetLabel();}};CDLHierarchy.prototype.createMember=function(_OU,_AC){Debug.Assert(_OU.nodeName==ExpAPIXml.kEleMember);var _azr=new CDLMember(null,this,_AC);_azr.Init(_OU);_azr.Merge(_OU);this._w9.push(_azr);};CDLHierarchy.prototype.getMember=function(_PQ){return this._w9[_PQ]||null;};CDLHierarchy.prototype.createLevels=function(_BB){for(var i=0;i<_BB.childNodes.length;i++){var obj=_BB.childNodes[i];if(obj.nodeName==ExpAPIXml.kEleLevel){var _C7=Dom.GetNodeTextShallow(obj,ExpAPIXml.kEleElcid);var _Ic=Dom.GetNodeTextShallow(obj,ExpAPIXml.kEleLabel);if(_Ic){var _E1=new CDLLevel(this);_E1.Init(obj);this._gD[_C7]=_E1;}else if(this._rj.isHierarchyHidden(this._ks)){this._d3.push(_C7);}}}};CDLHierarchy.prototype.GetLevel=function(name){return this._gD[name]||null;};CDLHierarchy.prototype.HasLevel=function(){return!Utilities.IsObjectEmpty(this._gD);};CDLHierarchy.prototype.IsParentChildHier=function(){return!this.HasLevel();};CDLHierarchy.prototype.IsLeafLevel=function(_MK){if(this.HasLevel()){var _aBc=this.GetHierarchyOrdinalByLevel(_MK);if(_aBc==(Utilities.GetObjArrayLength(this._gD)-1)){return true;}}return false;};CDLHierarchy.prototype.ContainsLevel=function(_JM){var _aed=(this.GetLevel(_JM)||this._ks==_JM)?true:false;if(this._rj.isHierarchyHidden(this._ks)){_aed=Utilities.IsInArray(this._d3,_JM);}return _aed;};CDLHierarchy.prototype.GetHierarchyOrdinalByLevel=function(_y2){Debug.Assert(this.GetLevel(_y2));var _PQ=Utilities.GetObjIndexFromObjArray(this._gD,this.GetLevel(_y2));return _PQ;};CDLHierarchy.prototype.GetLevelByIndex=function(_NU){return Utilities.GetNthFromObjArray(this._gD,_NU);};CDLHierarchy.prototype.GetOneLevelBelow=function(_S8){var _Re=this.GetHierarchyOrdinalByLevel(_S8.GetId());return this.GetLevelByIndex(_Re+2);};CDLHierarchy.prototype.IsSingleRootMember=function(){return this._uL;};CDLHierarchy.prototype.GetSingleRootMember=function(){return(this.IsSingleRootMember())?this.getMember(0):null;};CDLHierarchy.prototype.GetHierarchyId=function(){return this._ks;};CDLHierarchy.prototype.GetChildCount=function(_Gg){var _ayj=this._h4?this._h4.length:this._w9.length;if(_Gg){_ayj+=this._hg;}return _ayj;};CDLHierarchy.prototype.GetPopulation=function(){return this.GetChildCount();};CDLHierarchy.prototype.DeleteChildArray=function(){Utilities.DeleteAllFromArray(this._h4);this._h4=null;};CDLHierarchy.prototype.GetChildArray=function(_Gg){if(!this._h4){this._h4=Utilities.CopyArray(this._w9);}var _YV=this._h4;if(_Gg){_YV=_YV.concat(this._hg);}return this._h4;};CDLHierarchy.prototype.SetChildArray=function(_K3){this.DeleteChildArray();this._h4=_K3;};CDLHierarchy.prototype.GetBreadCrumbText=function(_En){var _aoK="";var _aBp=new Array(this.GetLabel(),this._rj.GetLabel());if(document.dir==""||document.dir=="ltr"){var _aBp=_aBp.reverse();}if(_En==null){_En='IDS_BREADCRUMB_LIST';}_aoK=this._rj._qi.datamanager.appobj.oResources.ReplaceParamList(_En,_aBp);return _aoK;};CDLHierarchy.prototype.IsComplete=function(){return this._v1;};CDLHierarchy.prototype.Merge=function(_N2,_zR){Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CDLHierarchy::Merge"]);var _aBM=Dom.GetImmediateChildByName(_N2,ExpAPIXml.kEleRootMembers);if(_zR==this._ks){Utilities.DeleteAllFromArray(this._w9);this.createMembers(_aBM);}if(_aBM){var _YG=_aBM.childNodes;for(var i=0;i<_YG.length;i++){var obj=_YG[i];if(obj.nodeName==ExpAPIXml.kEleMember){var _C7=Dom.GetNodeTextShallow(obj,ExpAPIXml.kEleElcid);var _azr=this._rj._qi.GetData(_C7);if(!_azr||(this.GetMetadata().datamanager.IsMultiRootMembersMetadataFixEnabled()&&_azr._bG)){_azr=this.createMember(obj);}else{_azr.Merge(obj,_zR);}if(_zR=='tree_expand'){_azr._wU=this._w9.length-1;}}}this._uL=(this._w9.length===1&&this._v1);this.GetMetadata().datamanager.Notify(ExpEvent.kCDLDataManager_UpdateTree);}var _1I=Dom.GetImmediateChildByName(_N2,ExpAPIXml.kEleProperties);if(_1I){this._lG=this._lG||{};this.GetMetadata().ProcessProperties(this,_1I);this.GetMetadata().Notify(ExpEvent.kCDLMetadata_Merge_Properties,this);}var _W6=Dom.GetImmediateChildByName(_N2,ExpAPIXml.kEleLevels);if(_W6){var _aHR=null;var _6D=Dom.GetImmediateChildrenByName(_W6,ExpAPIXml.kEleLevel);for(var i=0;i<_6D.length;i++){_aHR=_6D[i];var _asJ=Dom.GetImmediateChildByName(_aHR,ExpAPIXml.kEleElcid);var _C7=Dom.GetNodeText(_asJ);var _S8=this.GetLevel(_C7);_S8.Merge(_aHR);}this.GetMetadata().Notify(ExpEvent.kCDLMetadata_Merge_Properties,this);}Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CDLHierarchy::Merge"]);};CDLHierarchy.prototype.GetMetadata=function(){return this._rj._qi;};CDLHierarchy.prototype.PopulateRootMember=function(){if(this._v1||this.GetChildCount()>=this.GetMetadata().GetMaxExpandSize()||this._qu==CDLAbsMember.eStateLoading){return;}this._qu=CDLAbsMember.eStateLoading;var _Jj=new CDLAction();_Jj.type='expand';_Jj.AddSource(this._ks,ExpAPIXml.kEleHierarchy);_Jj.AddSource(this._rj._ks,ExpAPIXml.kEleDimension);_Jj.AddTargetItem(this.GetMetadata()._ks,ExpAPIXml.kEleMetadata);var _AE=new Array();_AE[0]=_Jj;var _aBj=this.GetMetadata().datamanager.commManager.CreateExploreRequest(_AE);_aBj.sRequestedMemberId=this._ks;_aBj.Send(true,this);var _6z=Utilities.GenerateCallback(this.HandleNonResponse,[],this);setTimeout(_6z,Utilities.GetServerResponseTimeout());};CDLHierarchy.prototype.HandleNonResponse=function(){if(this._qu==CDLAbsMember.eStateLoaded){return;}this._qu=CDLAbsMember.eStateNoResponse;this.Notify(ExpEvent.kCDLMember_Merge_NoResponse);Utilities.IncrementServerTimeout();};CDLHierarchy.prototype.Notify=function(_Dy){};CDLHierarchy.prototype.SetLineageLabels=function(){for(var x=0;x<this._w9.length;x++){var _12=this.getMember(x);var _Zn=[this._rj.GetLabel(),this.GetLabel(),_12.GetLabel()];_12.SetLineageLabel(_Zn);}};function CDLNamedSet(_EU){this._mR=_EU;this._L=null;this._bb=null;this._xU=null;this._gN=null;};CDLNamedSet.prototype.GetId=function(){return this._bb;};CDLNamedSet.prototype.Create=function(_VX){var _TW=_VX.getAttribute(ExpAPIXml.kEleDimensionPtr);Debug.Assert(_TW);var _Ni=this._mR._iR[_TW];Debug.Assert(_Ni);this._L=_Ni;var _B8=_VX.getAttribute(ExpAPIXml.kEleHierarchyPtr);if(_B8&&_B8!=""){var _Ts=this._mR.GetHierarchyById(_B8);Debug.Assert(_Ts);if(_Ts){this._gN=_Ts;}}var _Lx=_VX.getAttribute(ExpAPIXml.kEleElcid);Debug.Assert(_Lx);this._bb=_Lx;var _BM=_VX.getAttribute(ExpAPIXml.kEleLabel);this._xU=_BM;};CDLNamedSet.prototype.GetDim=function(){return this._L;};CDLNamedSet.prototype.GetDimId=function(){return this._L._ks;};CDLNamedSet.prototype.GetHierarchy=function(){return this._gN;};CDLNamedSet.prototype.GetHierId=function(){if(this._gN){return this._gN._ks;}return null;};CDLNamedSet.prototype.GetLabel=function(){return this._xU;};CDLNamedSet.prototype.FromMeasureDim=function(){if(Utilities.IsInArray(this._mR.GetMeasureDimIdArr(),this._L._ks)){return true;}return false;};CDLNamedSet.prototype.GetBreadCrumbText=function(){return this._xU;};CDLNamedSet.prototype.GetChildArray=function(){return null;};function CDLSubsVar(_EU){this._mR=_EU;this._bb=null;this._xU=null;};CDLSubsVar.prototype.Create=function(_B1){var _Lx=_B1.getAttribute(ExpAPIXml.kEleElcid);Debug.Assert(_Lx);this._bb=_Lx;var _BM=_B1.getAttribute(ExpAPIXml.kEleLabel);this._xU=_BM;};CDLSubsVar.prototype.GetId=function(){return this._bb;};CDLSubsVar.prototype.GetLabel=function(){return this._xU;};function CDLAbsFolderObject(_EU,_AC){this._mR=_EU;this._ks=null;this._wU=_AC;};CDLAbsFolderObject.prototype.GetId=function(){return this._ks;};CDLAbsFolderObject.prototype.GetMetadata=function(){return this._mR;};CDLAbsFolderObject.prototype.GetOriginalRecordOrder=function(){return this._wU;};function CDLFolderObjDimension(_EU,_AC){this.base=CDLAbsFolderObject;this.base(_EU,_AC);this._cH=null;this._sr=new Object();this._sM=false;};CDLFolderObjDimension.prototype=new CDLAbsFolderObject;CDLFolderObjDimension.superclass=CDLAbsFolderObject.prototype;CDLFolderObjDimension.prototype.GetObjPtr=function(){return this._cH;};CDLFolderObjDimension.prototype.Create=function(_Sw){var _Lx=_Sw.getAttribute(ExpAPIXml.kEleElcid);Debug.Assert(_Lx);this._ks=_Lx;var _23=_Sw.getAttribute(ExpAPIXml.kEleFldObjPtr);Debug.Assert(_23);this._cH=_23;var _7r=_Sw.childNodes;for(var i=0;i<_7r.length;i++){var _awS=_7r[i];var _Bi=null;var _WM=_awS.getAttribute(ExpAPIXml.kEleFldObjtype);if(_WM==ExpAPIXml.kEleFolder){_Bi=new CDLFolder(this._mR,i);this._sM=true;}else if(_WM==ExpAPIXml.kEleFldHierarchy){_Bi=new CDLFolderObjHierarchy(this._mR,i);}_Bi.Create(_awS);this._sr[_Bi._ks]=_Bi;this.GetMetadata()._sr[_Bi._ks]=_Bi;}var _Ni=this.GetMetadata().GetDimById(_23);if(this._sM){_Ni.SetChildArray(Utilities.CopyObjArrayToArray(this._sr));}else{_Ni.CopyHierarchyToChildren();}this._v1=true;};CDLFolderObjDimension.prototype.GetLabel=function(){if(this._cH){var _Jm=this._mR.GetDataById(this._cH);Debug.Assert(_Jm);return _Jm.GetLabel();}return "";};function CDLFolderObjHierarchy(_EU,_AC){this.base=CDLAbsFolderObject;this.base(_EU,_AC);this._cH=null;};CDLFolderObjHierarchy.prototype=new CDLAbsFolderObject;CDLFolderObjHierarchy.superclass=CDLAbsFolderObject.prototype;CDLFolderObjHierarchy.prototype.GetObjPtr=function(){return this._cH;};CDLFolderObjHierarchy.prototype.Create=function(_Sw){var _Lx=_Sw.getAttribute(ExpAPIXml.kEleElcid);Debug.Assert(_Lx);this._ks=_Lx;var _23=_Sw.getAttribute(ExpAPIXml.kEleFldObjPtr);Debug.Assert(_23);this._cH=_23;};CDLFolderObjHierarchy.prototype.GetLabel=function(){if(this._cH){var _Jm=this._mR.GetDataById(this._cH);Debug.Assert(_Jm);return _Jm.GetLabel();}return "";};CDLFolderObjDimension.prototype.GetLabel=function(){if(this._cH){var _Jm=this._mR.GetDataById(this._cH);Debug.Assert(_Jm);return _Jm.GetLabel();}return "";};function CDLFolderObjMeasureDim(_EU,_AC){this.base=CDLAbsFolderObject;this.base(_EU,_AC);this._cH=null;this._sr=new Object();};CDLFolderObjMeasureDim.prototype=new CDLAbsFolderObject;CDLFolderObjMeasureDim.superclass=CDLAbsFolderObject.prototype;CDLFolderObjMeasureDim.prototype.Create=function(_Sw){var _Lx=_Sw.getAttribute(ExpAPIXml.kEleElcid);Debug.Assert(_Lx);this._ks=_Lx;var _23=_Sw.getAttribute(ExpAPIXml.kEleFldObjPtr);Debug.Assert(_23);this._cH=_23;for(var i=0;i<_Sw.childNodes.length;i++){var _awS=_Sw.childNodes[i];var _Bi=null;var _WM=_awS.getAttribute(ExpAPIXml.kEleFldObjtype);if(_WM==ExpAPIXml.kEleFldMeasure){_Bi=new CDLFolderObjMeasure(this._mR,i);}else if(_WM==ExpAPIXml.kEleFldMeasureFolder){_Bi=new CDLMeasureFolder(this._mR,i);}_Bi.Create(_awS);this._sr[_Bi._ks]=_Bi;this.GetMetadata()._sr[_Bi._ks]=_Bi;}this._h4=Utilities.CopyObjArrayToArray(this._sr);this._v1=true;};CDLFolderObjMeasureDim.prototype.GetLabel=function(){if(this._cH){var _Jm=this._mR.GetDataById(this._cH);Debug.Assert(_Jm);return _Jm.GetLabel();}return "";};CDLFolderObjMeasureDim.prototype.GetChildCount=function(){return this._h4.length;};CDLFolderObjMeasureDim.prototype.GetPopulation=function(){return this.GetChildCount();};CDLFolderObjMeasureDim.prototype.GetChildArray=function(){return this._h4;};CDLFolderObjMeasureDim.prototype.SetChildArray=function(_K3){Utilities.DeleteAllFromArray(this._h4);this._h4=_K3;};CDLFolderObjMeasureDim.prototype.IsComplete=function(){return this._v1;};function CDLFolderObjMeasure(_EU,_AC){this.base=CDLAbsFolderObject;this.base(_EU,_AC);this._cH=null;};CDLFolderObjMeasure.prototype=new CDLAbsFolderObject;CDLFolderObjMeasure.superclass=CDLAbsFolderObject.prototype;CDLFolderObjMeasure.prototype.Create=function(_Sw){var _Lx=_Sw.getAttribute(ExpAPIXml.kEleElcid);Debug.Assert(_Lx);this._ks=_Lx;var _23=_Sw.getAttribute(ExpAPIXml.kEleFldObjPtr);Debug.Assert(_23);this._cH=_23;this._v1=true;};CDLFolderObjMeasure.prototype.GetLabel=function(){if(this._cH){var _Jm=this._mR.GetDataById(this._cH);Debug.Assert(_Jm);return _Jm.GetLabel();}};function CDLFolderObjNamedSet(_EU,_AC){this.base=CDLAbsFolderObject;this.base(_EU,_AC);this._cH=null;};CDLFolderObjNamedSet.prototype=new CDLAbsFolderObject;CDLFolderObjNamedSet.superclass=CDLAbsFolderObject.prototype;CDLFolderObjNamedSet.prototype.Create=function(_Sw){var _Lx=_Sw.getAttribute(ExpAPIXml.kEleElcid);Debug.Assert(_Lx);this._ks=_Lx;var _23=_Sw.getAttribute(ExpAPIXml.kEleFldObjPtr);Debug.Assert(_23);this._cH=_23;this._v1=true;this._mR._am[_23]=true;};CDLFolderObjNamedSet.prototype.GetLabel=function(){if(this._cH){var _Jm=this._mR.GetDataById(this._cH);Debug.Assert(_Jm);return _Jm.GetLabel();}};CDLFolderObjNamedSet.prototype.GetObjPtr=function(){return this._cH;};CDLFolderObjNamedSet.prototype.GetChildArray=function(){return null;};CDLFolderObjNamedSet.prototype.GetChildCount=function(){return 0;};function CDLFolder(_EU,_AC){this.base=CDLAbsFolderObject;this.base(_EU,_AC);this._p8=null;this._sr=new Object();this._tf=false;};CDLFolder.prototype=new CDLAbsFolderObject;CDLFolder.superclass=CDLAbsFolderObject.prototype;CDLFolder.kFolderMap={};CDLFolder.kFolderMap[ExpAPIXml.kEleFldDimension]=CDLFolderObjDimension;CDLFolder.kFolderMap[ExpAPIXml.kEleFldMeasureDim]=CDLFolderObjMeasureDim;CDLFolder.kFolderMap[ExpAPIXml.kEleFolder]=CDLFolder;CDLFolder.kFolderMap[ExpAPIXml.kEleFldHierarchy]=CDLFolderObjHierarchy;CDLFolder.kFolderMap[ExpAPIXml.eNamedSet]=CDLFolderObjNamedSet;CDLFolder.prototype.Create=function(_Sw){var _Lx=_Sw.getAttribute(ExpAPIXml.kEleElcid);Debug.Assert(_Lx);this._ks=_Lx;var _BM=_Sw.getAttribute(ExpAPIXml.kEleLabel);Debug.Assert(_BM);this._p8=_BM;this._tf=_Sw.getAttribute("isnamespace")==ExpAPIXml.kTrue;for(var i=0;i<_Sw.childNodes.length;i++){var _awS=_Sw.childNodes[i];var _WM=_awS.getAttribute(ExpAPIXml.kEleFldObjtype);Debug.Assert(CDLFolder.kFolderMap[_WM]);var _Bi=new CDLFolder.kFolderMap[_WM](this._mR,i);_Bi.Create(_awS);this._sr[_Bi._ks]=_Bi;this.GetMetadata()._sr[_Bi._ks]=_Bi;}this._h4=Utilities.CopyObjArrayToArray(this._sr);this._v1=true;};CDLFolder.prototype.GetChildCount=function(){return this._h4.length;};CDLFolder.prototype.GetPopulation=function(){return this.GetChildCount();};CDLFolder.prototype.GetChildArray=function(){return this._h4;};CDLFolder.prototype.SetChildArray=function(_K3){Utilities.DeleteAllFromArray(this._h4);this._h4=_K3;};CDLFolder.prototype.IsComplete=function(){return this._v1;};CDLFolder.prototype.GetLabel=function(){return this._p8;};CDLFolder.prototype.ContainsOnlyNamedSets=function(){if(this._wb){return true;}for(var i in this._sr){if(!(this._sr[i]instanceof CDLFolderObjNamedSet)){return false;}}this._wb=true;return true;};CDLFolder.prototype.IsNamespaceFolder=function(){return this._tf;};CDLFolder.prototype.GetLabel=function(){return this._p8;};function CDLMeasureFolder(_EU,_AC){this.base=CDLAbsFolderObject;this.base(_EU,_AC);this._p8=null;this._sr=new Object();};CDLMeasureFolder.prototype=new CDLAbsFolderObject;CDLMeasureFolder.superclass=CDLAbsFolderObject.prototype;CDLMeasureFolder.prototype.Create=function(_Sw){var _Lx=_Sw.getAttribute(ExpAPIXml.kEleElcid);Debug.Assert(_Lx);this._ks=_Lx;var _BM=_Sw.getAttribute(ExpAPIXml.kEleLabel);Debug.Assert(_BM);this._p8=_BM;for(var i=0;i<_Sw.childNodes.length;i++){var _awS=_Sw.childNodes[i];var _Bi=null;var _WM=_awS.getAttribute(ExpAPIXml.kEleFldObjtype);if(_WM==ExpAPIXml.kEleFldMeasure){_Bi=new CDLFolderObjMeasure(this._mR,i);}else if(_WM==ExpAPIXml.kEleFldMeasureFolder){_Bi=new CDLMeasureFolder(this._mR,i);}_Bi.Create(_awS);this._sr[_Bi._ks]=_Bi;this.GetMetadata()._sr[_Bi._ks]=_Bi;}this._h4=Utilities.CopyObjArrayToArray(this._sr);this._v1=true;};CDLMeasureFolder.prototype.GetChildCount=function(){return this._h4.length;};CDLMeasureFolder.prototype.GetPopulation=function(){return this.GetChildCount();};CDLMeasureFolder.prototype.SetChildArray=function(_K3){Utilities.DeleteAllFromArray(this._h4);this._h4=_K3;};CDLMeasureFolder.prototype.GetChildArray=function(){return this._h4;};CDLMeasureFolder.prototype.IsComplete=function(){return this._v1;};CDLMeasureFolder.prototype.GetLabel=function(){return this._p8;};function CDLMissingData(_U9){this.datamanager=_U9;this._ks=null;this._oT=true;this._o9=false;this._cW=new Object();this._e6=new Array();this._er=new Object();};CDLMissingData.prototype.IsValidSubstitutionPossible=function(){for(var i in this._er){switch(i){case ExpAPIXml.kEleLevel:if(!this.datamanager.metadata.HasLevel()){return false;};break;case ExpAPIXml.eSubsetTypeSubsVar:if(!this.datamanager.metadata.SubsVarsExist()){return false;};break;case ExpAPIXml.eNamedSet:if(!this.datamanager.metadata.HasNamedSet()){return false;}break;}}return true;};CDLMissingData.prototype.AreAllSubstitutionsDone=function(){for(var i in this._cW){if((!this._cW[i]._mQ)&&this._cW[i].GetReplaceItemId()==""){return false;}}return true;};CDLMissingData.prototype.Clear=function(){for(var i in this._cW){delete this._cW[i];}Utilities.RemoveAllChildObjects(this);};CDLMissingData.prototype.Create=function(_Jv){this._ks=_Jv.getAttribute(ExpAPIXml.kEleElcid);Debug.Assert(this._ks!=null);var _awr=_Jv.getAttribute(ExpAPIXml.kAttrInvalideError);this._oT=_awr&&(_awr==ExpAPIXml.kTrue);var _4s=_Jv.getAttribute(ExpAPIXml.kAttrInaccessibleError);this._o9=_4s&&(_4s==ExpAPIXml.kTrue);for(var i=0;i<_Jv.childNodes.length;i++){var _aGZ=_Jv.childNodes[i].nodeName;switch(_aGZ){case ExpAPIXml.kEleMuns:this.CreateMissingDataList(_Jv.childNodes[i]);break;default:break;}}};CDLMissingData.prototype.Replace=function(_Jv){};CDLMissingData.prototype.CreateMissingDataList=function(_Ry){for(var j=0;j<_Ry.childNodes.length;j++){var _aeK=_Ry.childNodes[j];var _5B=_aeK.getAttribute(ExpAPIXml.kAttrMissing);Debug.Assert(_5B!=null);var _apO=new CDLMissingDataItem(this,_5B);_apO.SetDataType(_aeK.getAttribute(ExpAPIXml.kAttrType));_apO.SetReplaceItemId(_aeK.getAttribute(ExpAPIXml.kAttrReplacement));this._cW[_5B]=_apO;this._er[_aeK.getAttribute(ExpAPIXml.kAttrType)]=true;}};CDLMissingData.prototype.GetMissingDataList=function(_Ry){return this._cW;};CDLMissingData.prototype.Subscribe=function(obj,event){if(this._e6[event]){this._e6[event].push(obj);}else{Debug.Assert(false,"Invalid event subscription");}};CDLMissingData.prototype.Notify=function(_Dy){};CDLMissingData.prototype.SubstituteMUNs=function(_T9){var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionSubstitute;var _AE=new Array();_AE[0]=_Jj;if(!_T9){for(var i in this._cW){if(this._cW[i].IsPruned()){_Jj._eW(this._cW[i].GetId(),'');}else{_Jj._eW(this._cW[i].GetId(),this._cW[i].GetReplaceItemId());}}}var _aBj=this.datamanager.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this.datamanager.GetCurrentWorkSheet(),true);};CDLMissingData.prototype.IsFixable=function(){return this._oT;};function CDLMissingDataItem(_PO,_C7){this._vw=_PO;this._ks=_C7;this._mi=null;this._q2="";this._mQ=false;};CDLMissingDataItem.prototype.GetId=function(){return this._ks;};CDLMissingDataItem.prototype.SetDataType=function(_V4){this._mi=_V4;};CDLMissingDataItem.prototype.GetDataType=function(){return this._mi;};CDLMissingDataItem.prototype.SetReplaceItemId=function(_KQ){this._q2=_KQ;};CDLMissingDataItem.prototype.GetReplaceItemId=function(){return this._q2;};CDLMissingDataItem.prototype.IsPruned=function(){return this._mQ;};CDLMissingDataItem.prototype.SetToBePruned=function(_Ov){this._mQ=_Ov;};function CDLSearchResult(_VP){this._he=_VP;this._pJ=null;this._u8=Utilities.GenerateId();this._k8=new Array();this._dm=null;this._ff=false;this._ki=false;this._lS=false;this._rJ=ExpAPIXml.eMember;_VP._k5[this._u8]=this;this._e6=new Array();this._e6[ExpEvent.kCDLSearchResult_Replace]=new Array();this._e6[ExpEvent.kCDLSearchResult_NoResponse]=new Array();this._e6[ExpEvent.kCDLSearchResult_FailedResponse]=new Array();this._e6[ExpEvent.kCDLSearchResult_WaitingResp]=new Array();};CDLSearchResult.prototype.Release=function(){this._k8=null;if(this._dm){this._dm.Clear();}this._dm=null;this._he._k5[this._u8]=null;this._ki=null;this._lS=null;this._rJ=null;};CDLSearchResult.prototype.DefineSearchMemberSet=function(_IP,_Jm,_GC,_G2){var _atw=new CDLMathMLExprNode(ExpAPIXml.kDefineMemSet,true,false);var _aa6=null;if(_Jm instanceof CDLHierarchy){_aa6=ExpAPIXml.eHierarchy;}else if(_Jm instanceof CDLMeasureDim){_aa6=ExpAPIXml.kMeasureDimension;}else if(_Jm instanceof CDLMeasureFolder){_aa6=ExpAPIXml.eMeasureFolder;}else{_aa6=(_Jm instanceof CDLMember)?ExpAPIXml.eMember:ExpAPIXml.eMeasure;}_atw.AddOperands(_Jm._ks,_Jm.GetLabel(),CDLMathMLOperands.CIOperand,0,_aa6);_atw.AddOperands(_G2,_G2,CDLMathMLOperands.CIOperand,1,_GC);_IP.AddOperands(_atw,null,CDLMathMLOperands.Apply);};CDLSearchResult.prototype.DefineStringConstraint=function(_IP,_J9,_Np,_LW,_QV,_D6){var _aFD=new CDLMathMLExprNode(_J9,true,false);_aFD.AddOperands(_QV,_QV,CDLMathMLOperands.CIOperand,0,_LW);_aFD.AddOperands(_Np,_Np,CDLMathMLOperands.CNOperand,1,ExpAPIXml.kAttrStringData);var _ata=_D6?ExpAPIXml.kFalse:ExpAPIXml.kTrue;_aFD.AddOperands(_ata,_ata,CDLMathMLOperands.CIOperand,2,ExpAPIXml.kCaseInSensitive);_IP.AddOperands(_aFD,null,CDLMathMLOperands.Apply);};CDLSearchResult.prototype.AddConstraint=function(_IP){this._dm=_IP;};CDLSearchResult.prototype.RunRequest=function(){var _AE=new Array();var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionSearch;var _aid=this._dm.GetAsXMLForSearch(this._dm,'');var _0f=_c.CreateElement(ExpAPIXml.kEleSearchExpr,_aid,true);var _axI=_c.CreateElement(ExpAPIXml.kEleSearchConstraint,_0f,true);_Jj.AddParameter(new CDLParameter(ExpAPIXml.kEleSearchConstraint,_axI,CDLParameter.XMLType()));_Jj.AddParameter(new CDLParameter(ExpAPIXml.kEleSearchResultId,this._u8));_Jj.AddParameter(new CDLParameter(ExpAPIXml.kEleSearchType,this._rJ));_AE[0]=_Jj;var _aBj=this._he.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this,false);this.SetStateBlocked();return;};CDLSearchResult.prototype.Replace=function(_PV){for(var i=0;i<_PV.childNodes.length;i++){switch(_PV.childNodes[i].nodeName){case ExpAPIXml.kEleMember:var _azr=_PV.childNodes[i];var _OE=_azr.getAttribute(ExpAPIXml.kEleElcid);var _FZ=this._he.metadata.GetData(_OE);if(_FZ==null&&_azr.getAttribute(ExpAPIXml.kEleIsMeasure)&&_azr.getAttribute(ExpAPIXml.kEleIsMeasure)==ExpAPIXml.kTrue){_FZ=this._he.metadata.AddOrphan(_PV.childNodes[i],_OE);}this._k8[this._k8.length]=_FZ;break;}}var _abF=_PV.getAttribute(ExpAPIXml.kEleIsComplete);this._v1=false;if(_abF==ExpAPIXml.kTrue){this._v1=true;}this._ff=true;var _ay7=this._e6[ExpEvent.kCDLSearchResult_Replace];for(var i in _ay7){_ay7[i].Subscribe(this,ExpEvent.kCDLSearchResult_Release);}this.Notify(ExpEvent.kCDLSearchResult_Replace);};CDLSearchResult.prototype.HasResults=function(_PV){return this._ff;};CDLSearchResult.prototype.Subscribe=function(obj,_Dy){if(this._e6[_Dy]){for(var i=0;i<this._e6[_Dy].length;i++){if(this._e6[_Dy]==obj){return;}}this._e6[_Dy].push(obj);}};CDLSearchResult.prototype.Notify=function(_Dy){if(_Dy==ExpEvent.kCDLSearchResult_Replace){var _ay7=this._e6[_Dy];for(var i in _ay7){_ay7[i].Notify(_Dy);}}else if(_Dy==ExpEvent.kCDLSearchResult_Release){this.Release();}else if(_Dy==ExpEvent.kCDLSearchResult_FailedResponse){var _ay7=this._e6[_Dy];for(var i in _ay7){_ay7[i].Notify(_Dy);}this.Notify(ExpEvent.kCDLSearchResult_Release);}else if(_Dy==ExpEvent.kCDLSearchResult_WaitingResp){var _ay7=this._e6[_Dy];for(var i in _ay7){_ay7[i].Notify(_Dy);}}else if(_Dy==ExpEvent.kCDLSearchResult_Cancellable){this._ki=true;}};CDLSearchResult.prototype.SetStateFailed=function(){this.Notify(ExpEvent.kCDLSearchResult_FailedResponse);};CDLSearchResult.prototype.SetStateBlocked=function(){this.Notify(ExpEvent.kCDLSearchResult_WaitingResp);};CDLSearchResult.prototype.SetCancelParam=function(_ST,_Je){this._ki=true;this._mo=_ST;this._xn=_Je;};CDLSearchResult.prototype.IsCancellable=function(){return this._ki;};CDLSearchResult.prototype.SendCancelRequest=function(){this._he.commManager.CancelRequest(this,null,this._mo,this._xn,this._lS);};CDLSearchResult.prototype.IgnoreResponse=function(){var _y7=true;this._he.commManager.HandleIgnoreResponse(this,null,this._lS,_y7);this._lS=true;};function CDLAbsCMFolder(_VP,_C7,_BR){this._he=_VP;this._qI="";this._p8="";this._ks=_C7?_C7:"";this._ff=false;this._tF=ExpAPIXml.eCMRegularFolder;this._e8=null;this._ih=new Object();if(_BR){this._e8=_BR;this._e8._ih[this._ks]=this;}this._xX=new Object();this._e6=new Array();};CDLAbsCMFolder.prototype.HasResults=function(_PV){return this._ff;};CDLAbsCMFolder.prototype.SetPath=function(_Az){this._qI=_Az;};CDLAbsCMFolder.prototype.Subscribe=function(obj,_Dy){if(this._e6[_Dy]){for(var i=0;i<this._e6[_Dy].length;i++){if(this._e6[_Dy]==obj){return;}}this._e6[_Dy].push(obj);}};CDLAbsCMFolder.prototype.Notify=function(_Dy,_FA,_LB,_zP){var _alZ=this._e6[_Dy];for(var i=0;_alZ&&i<_alZ.length;i++){_alZ[i].Notify(_Dy,_FA,_LB,_zP);}};CDLAbsCMFolder.prototype.SetStateFailed=function(_FA,_LB,_zP){this.Notify(ExpEvent.kCDLCMFolder_FailedResponse,_FA,_LB,_zP);};CDLAbsCMFolder.prototype.SetStateBlocked=function(){};CDLAbsCMFolder.prototype.RunGetCMFolder=function(){var _AE=new Array();var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionCM;_Jj.AddParameter(new CDLParameter(ExpAPIXml.kActionCMType,ExpAPIXml.kActionGetCMFolder));_Jj.AddParameter(new CDLParameter(ExpAPIXml.kEleElcid,this._ks));_Jj.AddParameter(new CDLParameter(ExpAPIXml.kCMPath,this._qI));_AE[0]=_Jj;var _aBj=this._he.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this,true);return;};CDLAbsCMFolder.prototype.ChildExist=function(_BM){_BM=_BM.toUpperCase();for(var i in this._ih){var _anY=this._ih[i]._p8;if(_anY.toUpperCase()==_BM)return true;}for(var i in this._xX){var _anY=this._xX[i]._p8;if(_anY.toUpperCase()==_BM)return true;}for(var i in this._yo){var _anY=this._yo[i]._p8;if(_anY.toUpperCase()==_BM)return true;}return false;};function CDLCMFolder(_VP,_C7,_BR,_K0){this.base=CDLAbsCMFolder;this.base(_VP,_C7,_BR);this._yo=new Object();this._e6[ExpEvent.kCDLCMFolder_Replace]=new Array();this._e6[ExpEvent.kCDLCMFolder_FailedResponse]=new Array();};CDLCMFolder.prototype=new CDLAbsCMFolder;CDLCMFolder.superclass=CDLAbsCMFolder.prototype;CDLCMFolder.prototype.Merge=function(_II,_NQ){Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CDLCMFolder::Merge"]);if(_NQ){this._p8=_II.getAttribute(ExpAPIXml.kEleLabel);Debug.Assert(this._p8!=null);this._qI=_II.getAttribute(ExpAPIXml.kCMPath);Debug.Assert(this._qI!=null);var _zx=_II.getAttribute(ExpAPIXml.kAttrCMFolderType);if(_zx=="content"){this._tF=ExpAPIXml.eCMRootPublicFolder;}else if(_zx=="fmpackage"){this._tF=ExpAPIXml.eCMFMPackage;}else if(_zx=="metricpackage"){this._tF=ExpAPIXml.eCMMetricPackage;}else if(_zx=="contributorpackage"){this._tF=ExpAPIXml.eCMContributorPackage;}else if(_zx=="folder"){this._tF=ExpAPIXml.eCMRegularFolder;}}for(var i=0;i<_II.childNodes.length;i++){if(_II.childNodes[i].nodeName==ExpAPIXml.kEleCMFolder){var _ap9=_II.childNodes[i];var _aHh=_ap9.getAttribute(ExpAPIXml.kCMPath);Debug.Assert(_aHh!=null);var _BU=null;for(var _Cw in this._ih){if(this._ih[_Cw]._qI==_aHh){_BU=this._ih[_Cw];break;}}if(!_BU){var _C7=_ap9.getAttribute(ExpAPIXml.kEleElcid);Debug.Assert(_C7!=null);_BU=new CDLCMFolder(this._he,_C7,this);this._he._kE[_C7]=_BU;}_BU.Merge(_ap9,true);this._ff=true;}else if(_II.childNodes[i].nodeName==ExpAPIXml.kEleCMAnalysis){var _and=_II.childNodes[i];var _aHh=_and.getAttribute(ExpAPIXml.kCMPath);Debug.Assert(_aHh!=null);var _JE=null;for(var sAnalysisId in this._xX){if(this._xX[sAnalysisId]._qI==_aHh){_JE=this._xX[sAnalysisId];break;}}if(!_JE){var _C7=_and.getAttribute(ExpAPIXml.kEleElcid);Debug.Assert(_C7!=null);_JE=new CDLCMAnalysis(this._he,_C7,this);this._he._kE[_C7]=_JE;}_JE.Replace(_and);this._ff=true;}else if(_II.childNodes[i].nodeName==ExpAPIXml.kEleCMReportTemplate){var _arm=_II.childNodes[i];var _aHh=_arm.getAttribute(ExpAPIXml.kCMPath);Debug.Assert(_aHh!=null);var _ahz=null;for(var sReportTemplateId in this._yo){if(this._yo[sReportTemplateId]._qI==_aHh){_ahz=this._yo[sReportTemplateId];break;}}if(!_ahz){var _C7=_arm.getAttribute(ExpAPIXml.kEleElcid);Debug.Assert(_C7!=null);_ahz=new CDLCMReportTemplate(this._he,_C7,this);}_ahz.Replace(_arm);this._ff=true;}}if(!_NQ){this.Notify(ExpEvent.kCDLCMFolder_Replace);}Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CDLCMFolder::Merge"]);};CDLCMFolder.prototype.RemoveChild=function(){for(var i in this._ih){this._ih[i].Release();}for(var i in this._xX){this._xX[i].Release();}for(var i in this._yo){this._yo[i].Release();}};CDLCMFolder.prototype.Release=function(_Vk){this.RemoveChild();if(this._e8){delete this._e8._ih[this._ks];if(_Vk){this._e8.Notify(ExpEvent.kCDLCMFolder_Replace);}}var _2w=this._he;Utilities.RemoveAllChildObjects(this._he._kE[this._ks]);delete _2w._kE[this._ks];};CDLCMFolder.prototype.PopulateRoots=function(_II){Debug.Assert(_II.childNodes.length==2);for(var i=0;i<_II.childNodes.length;i++){var _ap9=_II.childNodes[i];var _C7=_ap9.getAttribute(ExpAPIXml.kEleElcid);Debug.Assert(_C7!=null);var _BU=new CDLCMFolder(this._he,_C7,this);this._he._kE[_C7]=_BU;_BU.Merge(_ap9,true);if(_BU._tF==ExpAPIXml.eCMRegularFolder){_BU._tF=ExpAPIXml.eCMRootMyFolder;}this._ff=true;}this.Notify(ExpEvent.kCDLCMFolder_Replace);};CDLCMFolder.prototype.RunGetCMRoot=function(_L0){var _AE=new Array();var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionCM;var _atb=this._he.GetCurrentWorkSheet().GetInitAnalysisFolderPath();Debug.Assert(_atb);_Jj.AddParameter(new CDLParameter(ExpAPIXml.kActionCMType,ExpAPIXml.kActionGetCMRoot));_Jj.AddParameter(new CDLParameter(ExpAPIXml.kCMPath,_atb));_AE[0]=_Jj;var _aBj=this._he.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this,true);return;};CDLCMFolder.prototype.RunDelete=function(){var _AE=new Array();var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionCM;_Jj.AddParameter(new CDLParameter(ExpAPIXml.kActionCMType,ExpAPIXml.kActionDeleteCMFolder));_Jj.AddParameter(new CDLParameter(ExpAPIXml.kEleElcid,this._ks));_Jj.AddParameter(new CDLParameter(ExpAPIXml.kCMPath,this._qI));_AE[0]=_Jj;var _aBj=this._he.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this,true);};CDLCMFolder.prototype.CreateSubFolder=function(_BM){var _AE=new Array();var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionCM;_Jj.AddParameter(new CDLParameter(ExpAPIXml.kActionCMType,ExpAPIXml.kActionCreateCMFolder));_Jj.AddParameter(new CDLParameter(ExpAPIXml.kEleElcid,this._ks));_Jj.AddParameter(new CDLParameter(ExpAPIXml.kCMPath,this._qI));_Jj.AddParameter(new CDLParameter(ExpAPIXml.kEleName,_BM));_AE[0]=_Jj;var _aBj=this._he.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this,true);};CDLCMFolder.prototype.RunRename=function(_BM){var _AE=new Array();var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionCM;_Jj.AddParameter(new CDLParameter(ExpAPIXml.kActionCMType,ExpAPIXml.kActionRenameCMFolder));_Jj.AddParameter(new CDLParameter(ExpAPIXml.kEleElcid,this._ks));_Jj.AddParameter(new CDLParameter(ExpAPIXml.kCMPath,this._qI));_Jj.AddParameter(new CDLParameter(ExpAPIXml.kEleName,_BM));_AE[0]=_Jj;var _aBj=this._he.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this,true);};CDLCMFolder.prototype.Replace=function(_Eq,_Vk){this._qI=_Eq.getAttribute(ExpAPIXml.kCMPath);Debug.Assert(this._qI!=null);this._p8=_Eq.getAttribute(ExpAPIXml.kEleLabel);Debug.Assert(this._p8!=null);if(_Vk)this._e8.Notify(ExpEvent.kCDLCMFolder_Replace);};function CDLCMAnalysis(_VP,_C7,_BR){this._he=_VP;this._qI="";this._p8="";Debug.Assert(_C7!=null);this._ks=_C7;if(_BR){this._e8=_BR;this._e8._xX[this._ks]=this;}};CDLCMAnalysis.prototype.Replace=function(_Eq,_Vk){this._qI=_Eq.getAttribute(ExpAPIXml.kCMPath);Debug.Assert(this._qI!=null);this._p8=_Eq.getAttribute(ExpAPIXml.kEleLabel);Debug.Assert(this._p8!=null);if(_Vk)this._e8.Notify(ExpEvent.kCDLCMFolder_Replace);};CDLCMAnalysis.prototype.Release=function(_Vk){if(this._e8){delete this._e8._xX[this._ks];if(_Vk){this._e8.Notify(ExpEvent.kCDLCMFolder_Replace);}}var _2w=this._he;Utilities.RemoveAllChildObjects(this._he._kE[this._ks]);delete _2w._kE[this._ks];};CDLCMAnalysis.prototype.RunDelete=function(){var _AE=new Array();var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionCM;_Jj.AddParameter(new CDLParameter(ExpAPIXml.kActionCMType,ExpAPIXml.kActionDeleteCMAnalysis));_Jj.AddParameter(new CDLParameter(ExpAPIXml.kEleElcid,this._ks));_Jj.AddParameter(new CDLParameter(ExpAPIXml.kCMPath,this._qI));_AE[0]=_Jj;var _aBj=this._he.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this,true);};CDLCMAnalysis.prototype.RunRename=function(_BM){var _AE=new Array();var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionCM;_Jj.AddParameter(new CDLParameter(ExpAPIXml.kActionCMType,ExpAPIXml.kActionRenameCMAnalysis));_Jj.AddParameter(new CDLParameter(ExpAPIXml.kEleElcid,this._ks));_Jj.AddParameter(new CDLParameter(ExpAPIXml.kCMPath,this._qI));_Jj.AddParameter(new CDLParameter(ExpAPIXml.kEleName,_BM));_AE[0]=_Jj;var _aBj=this._he.commManager.CreateExploreRequest(_AE);_aBj.Send(true,this,true);};CDLCMAnalysis.prototype.SetStateFailed=function(){};CDLCMAnalysis.prototype.SetStateBlocked=function(){};function CDLCMReportTemplate(_VP,_C7,_BR){this._he=_VP;this._qI="";this._p8="";Debug.Assert(_C7!=null);if(_C7){this._ks=_C7;_VP._kE[this._ks]=this;}if(_BR){this._e8=_BR;this._e8._yo[this._ks]=this;}};CDLCMReportTemplate.prototype.Replace=function(_Eq,_Vk){this._qI=_Eq.getAttribute(ExpAPIXml.kCMPath);Debug.Assert(this._qI!=null);this._p8=_Eq.getAttribute(ExpAPIXml.kEleLabel);Debug.Assert(this._p8!=null);if(_Vk)this._e8.Notify(ExpEvent.kCDLCMFolder_Replace);};CDLCMReportTemplate.prototype.Release=function(_Vk){if(this._e8){delete this._e8._yo[this._ks];if(_Vk){this._e8.Notify(ExpEvent.kCDLCMFolder_Replace);}}var _2w=this._he;Utilities.RemoveAllChildObjects(this._he._kE[this._ks]);delete _2w._kE[this._ks];};CDLCMReportTemplate.prototype.RunDelete=function(){Debug.Assert(false);};CDLCMReportTemplate.prototype.RunRename=function(_BM){Debug.Assert(false);};CDLCMReportTemplate.prototype.SetStateFailed=function(){};CDLCMReportTemplate.prototype.SetStateBlocked=function(){};function CDLTreeCMFolder(_VP,_C7,_BR){this.base=CDLAbsCMFolder;this.base(_VP,_C7,_BR);this._e6[ExpEvent.kTreeCDLCMFolder_Replace]=new Array();this._e6[ExpEvent.kTreeCDLCMFolder_FailedResponse]=new Array();};CDLTreeCMFolder.prototype=new CDLAbsCMFolder;CDLTreeCMFolder.superclass=CDLAbsCMFolder.prototype;CDLTreeCMFolder.prototype.Merge=function(_II){this._p8=_II.getAttribute(ExpAPIXml.kEleLabel);Debug.Assert(this._p8!=null);this._qI=_II.getAttribute(ExpAPIXml.kCMPath);Debug.Assert(this._qI!=null);var _zx=_II.getAttribute(ExpAPIXml.kAttrCMFolderType);if(_zx=="content"){this._tF=ExpAPIXml.eCMRootPublicFolder;}else if(_zx=="fmpackage"){this._tF=ExpAPIXml.eCMFMPackage;}else if(_zx=="metricpackage"){this._tF=ExpAPIXml.eCMMetricPackage;}else if(_zx=="contributorpackage"){this._tF=ExpAPIXml.eCMContributorPackage;}else if(_zx=="folder"){this._tF=ExpAPIXml.eCMRegularFolder;}for(var i=0;i<_II.childNodes.length;i++){if(_II.childNodes[i].nodeName==ExpAPIXml.kEleCMFolder){var _ap9=_II.childNodes[i];var _aHh=_ap9.getAttribute(ExpAPIXml.kCMPath);Debug.Assert(_aHh!=null);var _BU=null;for(var _Cw in this._ih){if(this._ih[_Cw]._qI==_aHh){_BU=this._ih[_Cw];break;}}if(!_BU){var _C7=_ap9.getAttribute(ExpAPIXml.kEleElcid);Debug.Assert(_C7!=null);_BU=new CDLTreeCMFolder(this._he,_C7,this);this._he._ez[_C7]=_BU;}_BU.Merge(_ap9);this._ff=true;}else if(_II.childNodes[i].nodeName==ExpAPIXml.kEleCMAnalysis){var _and=_II.childNodes[i];var _aHh=_and.getAttribute(ExpAPIXml.kCMPath);Debug.Assert(_aHh!=null);var _JE=null;for(var sAnalysisId in this._xX){if(this._xX[sAnalysisId]._qI==_aHh){_JE=this._xX[sAnalysisId];break;}}if(!_JE){var _C7=_and.getAttribute(ExpAPIXml.kEleElcid);Debug.Assert(_C7!=null);_JE=new CDLCMAnalysis(this._he,_C7,this,true);this._he._ez[_C7]=_JE;}_JE.Replace(_and);this._ff=true;}}this.Notify(ExpEvent.kTreeCDLCMFolder_Replace);};CDLTreeCMFolder.prototype.PopulateRootsForTree=function(_II){var _K0=true;for(var i=0;i<_II.childNodes.length;i++){var _ap9=_II.childNodes[i];var _C7=_ap9.getAttribute(ExpAPIXml.kEleElcid);Debug.Assert(_C7!=null);var _BU=new CDLTreeCMFolder(this._he,_C7,this);this._he._ez[_C7]=_BU;_BU.Merge(_ap9);if(_BU._tF==ExpAPIXml.eCMRootPublicFolder){this._he.appobj.uiManager._np._ms=_BU._ks;}if(_BU._tF==ExpAPIXml.eCMRegularFolder){_BU._tF=ExpAPIXml.eCMRootMyFolder;}this._ff=true;}this.Notify(ExpEvent.kTreeCDLCMFolder_Replace);};CDLTreeCMFolder.prototype.RunGetCMFolderForAnalysis=function(_Uw){var _AE=new Array();var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionCM;if(_Uw){_Jj.AddParameter(new CDLParameter(ExpAPIXml.kActionCMType,ExpAPIXml.kActionGetCMRoot));}else{_Jj.AddParameter(new CDLParameter(ExpAPIXml.kActionCMType,ExpAPIXml.kActionGetCMFolder));}if(this._ks){_Jj.AddParameter(new CDLParameter(ExpAPIXml.kEleElcid,this._ks));}var _atb=this._he.metadata.GetPackagePath();if(this._qI){_Jj.AddParameter(new CDLParameter(ExpAPIXml.kCMPath,this._qI));}else{_Jj.AddParameter(new CDLParameter(ExpAPIXml.kCMPath,_atb));}_Jj.AddParameter(new CDLParameter('package',_atb));if(_Uw){_Jj.AddParameter(new CDLParameter('populateroot',ExpAPIXml.kTrue));}_AE[0]=_Jj;var _aBj=this._he.commManager.CreateExploreRequest(_AE);if(_Uw){_aBj.sRequestedMemberId=this._jj;}_aBj.Send(true,this,true);return;};function CDLChart(_VP){this._he=_VP;this._ks=null;this._mt=null;this._lr=null;this._nq=-1;this._xx=-1;this._qY=false;this._w2=false;this._pQ=true;this._sU="";};CDLChart.prototype.GetId=function(){return this._ks;};CDLChart.prototype.GetWidth=function(){return this._nq;};CDLChart.prototype.GetHeight=function(){return this._xx;};CDLChart.prototype.EnableTransparency=function(){return this._pQ;};CDLChart.prototype.IsInErrorState=function(){if(this._g7.indexOf("chart_unavailable.gif")!=-1){return true;}if(!this._qY){return true;}return false;};CDLChart.prototype.SupportsThreeDEffect=function(){return this._w2;};CDLChart.prototype.GetName=function(){return this._sU;};CDLChart.prototype.SetName=function(name){this._sU=name;};CDLChart.prototype.Release=function(){this.clearData();Utilities.RemoveAllChildObjects(this);};CDLChart.prototype.clearData=function(){for(var i=0;this._lr&&i<this._lr.length;i++){this._lr[i].Clear();}Utilities.DeleteAllFromArray(this._lr);this._qY=false;var _ac3=this._he.GetDataMatrixById(this.sDataMatrixId);if(_ac3){var _Vx=true;var _UB=false;_ac3.ClearData(_Vx,this._ks,_UB);}};CDLChart.prototype.Create=function(_Wx){this._ks=_Wx.getAttribute(ExpAPIXml.kEleElcid);this._mt=_Wx.getAttribute(ExpAPIXml.kEleCharttype);this.sDataMatrixId=_Wx.getAttribute(ExpAPIXml.kEleDataMatrixPtr);var _y4=Dom.GetImmediateChildByName(_Wx,ExpAPIXml.kEleChartOptions);this.ProcessOptions(_y4);this._lr=new Array();this._sI=new Array();this.SetName(_Wx.getAttribute(ExpAPIXml.kEleName));if(this._he.IsInMissingMUNState()){this._he.Notify(ExpEvent.kCDLDataManager_ChartRefresh);}};CDLChart.prototype.ProcessOptions=function(_y4){this._p7=false;this._hD=false;this._nb=false;this._w2=false;this._le=false;this._ug=false;switch(this._mt){case ExpAPIXml.eChartTypePie:var _akd=Dom.GetImmediateChildByName(_y4,ExpAPIXml.eChartOptionsPie);if(!_akd){break;}if(_akd.getAttribute(ExpAPIXml.kEleChartIs3D)=="true"){this._p7=true;}if(_akd.getAttribute(ExpAPIXml.kEleChartShowAsPercent)=="true"){this._hD=true;}if(_akd.getAttribute(ExpAPIXml.kEleChartShowValues)=="true"){this._nb=true;}this._w2=true;break;case ExpAPIXml.eChartTypeBar:var _akd=Dom.GetImmediateChildByName(_y4,ExpAPIXml.eChartOptionsBar);if(!_akd){break;}if(_akd.getAttribute(ExpAPIXml.kEleChartIs3D)=="true"){this._p7=true;}if(_akd.getAttribute(ExpAPIXml.kEleChartShowValues)=="true"){this._nb=true;}if(_akd.getAttribute(ExpAPIXml.kEleChartIsStacked)=="true"){this._le=true;}if(_akd.getAttribute(ExpAPIXml.kEleChartIsStacked100Percent)=="true"){this._ug=true;}this._w2=true;break;case ExpAPIXml.eChartTypeColumn:var _akd=Dom.GetImmediateChildByName(_y4,ExpAPIXml.eChartOptionsColumn);if(!_akd){break;}if(_akd.getAttribute(ExpAPIXml.kEleChartIs3D)=="true"){this._p7=true;}if(_akd.getAttribute(ExpAPIXml.kEleChartShowValues)=="true"){this._nb=true;}if(_akd.getAttribute(ExpAPIXml.kEleChartIsStacked)=="true"){this._le=true;}if(_akd.getAttribute(ExpAPIXml.kEleChartIsStacked100Percent)=="true"){this._ug=true;}this._w2=true;break;case ExpAPIXml.eChartTypePareto:var _akd=Dom.GetImmediateChildByName(_y4,ExpAPIXml.eChartOptionsPareto);if(!_akd){break;}if(_akd.getAttribute(ExpAPIXml.kEleChartIs3D)=="true"){this._p7=true;}if(_akd.getAttribute(ExpAPIXml.kEleChartShowValues)=="true"){this._nb=true;}this._w2=true;break;case ExpAPIXml.eChartTypeLine:var _akd=Dom.GetImmediateChildByName(_y4,ExpAPIXml.eChartOptionsLine);if(!_akd){break;}if(_akd.getAttribute(ExpAPIXml.kEleChartIs3D)=="true"){this._p7=true;}if(_akd.getAttribute(ExpAPIXml.kEleChartShowValues)=="true"){this._nb=true;}if(_akd.getAttribute(ExpAPIXml.kEleChartIsStacked)=="true"){this._le=true;}if(_akd.getAttribute(ExpAPIXml.kEleChartIsStacked100Percent)=="true"){this._ug=true;}this._w2=true;break;case ExpAPIXml.eChartTypeArea:var _akd=Dom.GetImmediateChildByName(_y4,ExpAPIXml.eChartOptionsArea);if(!_akd){break;}if(_akd.getAttribute(ExpAPIXml.kEleChartIs3D)=="true"){this._p7=true;}if(_akd.getAttribute(ExpAPIXml.kEleChartShowValues)=="true"){this._nb=true;}if(_akd.getAttribute(ExpAPIXml.kEleChartIsStacked)=="true"){this._le=true;}if(_akd.getAttribute(ExpAPIXml.kEleChartIsStacked100Percent)=="true"){this._ug=true;}this._w2=true;break;case ExpAPIXml.eChartTypeScatter:var _akd=Dom.GetImmediateChildByName(_y4,ExpAPIXml.eChartOptionsScatter);if(!_akd){break;}if(_akd.getAttribute(ExpAPIXml.kEleChartShowValues)=="true"){this._nb=true;}break;case ExpAPIXml.eChartTypePolar:var _akd=Dom.GetImmediateChildByName(_y4,ExpAPIXml.eChartOptionsPolar);if(!_akd){break;}if(_akd.getAttribute(ExpAPIXml.kEleChartShowValues)=="true"){this._nb=true;}break;case ExpAPIXml.eChartTypePoint:var _ae8=Dom.GetImmediateChildByName(_y4,ExpAPIXml.eChartOptionsPoint);if(!_ae8){break;}if(_ae8.getAttribute(ExpAPIXml.kEleChartShowValues)=="true"){this._nb=true;}break;case ExpAPIXml.eChartTypeRadar:var _akd=Dom.GetImmediateChildByName(_y4,ExpAPIXml.eChartOptionsRadar);if(!_akd){break;}if(_akd.getAttribute(ExpAPIXml.kEleChartShowValues)=="true"){this._nb=true;}if(_akd.getAttribute(ExpAPIXml.kEleChartIsStacked)=="true"){this._le=true;}break;case ExpAPIXml.eChartType3DBar:var _XQ=Dom.GetImmediateChildByName(_y4,ExpAPIXml.eChartOptions3DBar);if(!_XQ){break;}if(_XQ.getAttribute(ExpAPIXml.kEleChartShowValues)=="true"){this._nb=true;}this._w2=false;break;case ExpAPIXml.eChartType3DArea:var _Yh=Dom.GetImmediateChildByName(_y4,ExpAPIXml.eChartOptions3DArea);if(!_Yh){break;}if(_Yh.getAttribute(ExpAPIXml.kEleChartShowValues)=="true"){this._nb=true;}this._w2=false;break;case ExpAPIXml.eChartTypeColumnLine:var _akd=Dom.GetImmediateChildByName(_y4,ExpAPIXml.eChartOptionsColumnLine);if(!_akd){break;}if(_akd.getAttribute(ExpAPIXml.kEleChartIs3D)=="true"){this._p7=true;}if(_akd.getAttribute(ExpAPIXml.kEleChartShowValues)=="true"){this._nb=true;}if(_akd.getAttribute(ExpAPIXml.kEleChartIsStacked)=="true"){this._le=true;}if(_akd.getAttribute(ExpAPIXml.kEleChartIsStacked100Percent)=="true"){this._ug=true;}this._w2=true;break;case ExpAPIXml.eChartType3DLine:var _3n=Dom.GetImmediateChildByName(_y4,ExpAPIXml.eChartOptions3DLine);if(!_3n){break;}if(_3n.getAttribute(ExpAPIXml.kEleChartShowValues)=="true"){this._nb=true;}this._w2=false;break;default:break;}};CDLChart.prototype.addBlockIds=function(_KD,_Tu){for(var i=0;i<_Tu.length;i++){_KD[_Tu[i]]=true;}};CDLChart.prototype.ProcessData=function(_Ve){Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CDLChart::ProcessData"]);this.clearData();var _Wx=Dom.GetImmediateChildByName(_Ve,ExpAPIXml.kEleChart);this._pw(Dom.GetNodeText(Dom.GetImmediateChildByName(_Wx,ExpAPIXml.kEleURL)));var _agv=Dom.GetElementsByTagName(_Wx,ExpAPIXml.kEleArea);var _KD=new Object();var _awt=new Array();var _IX=(this._mt===ExpAPIXml.eChartTypeScatter);for(var i=0;i<_agv.length;i++){var _JC=new CDLChartArea(_IX);_JC.Init(_agv[i],this._he);this._lr.push(_JC);}var oChart=Dom.GetImmediateChildByName(_Wx,ExpAPIXml.kEleOChart);if(oChart){this._nq=oChart.getAttribute(ExpAPIXml.kEleChartWidth);this._xx=oChart.getAttribute(ExpAPIXml.kEleChartHeight);this._pQ=Utilities.StringToBool(oChart.getAttribute(ExpAPIXml.kEleChartTransparency));this._qY=true;}var _asM=Dom.GetImmediateChildByName(_Wx,ExpAPIXml.kEleData);if(!this._he._um){var _ac3=this._he.GetDataMatrixById(this.sDataMatrixId);_ac3.ProcessData(_asM,true);this._rW=null;}else{this._rW=_asM;}this._he.Notify(ExpEvent.kCDLDataManager_ChartRefresh);Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CDLChart::ProcessData"]);};CDLChart.prototype.GetChartAreaCount=function(){return this._lr.length;};CDLChart.prototype.GetChartArea=function(i){Debug.Assert(i<this._lr.length);return this._lr[i];};CDLChart.prototype.Replace=function(_Wx){Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CDLChart::Replace"]);this.Create(_Wx);Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CDLChart::Replace"]);};CDLChart.prototype._pw=function(_yK){if(_yK.substr(0,1)=="?"){this._g7=this._he.appobj.GetGatewayURL()+_yK;}else{this._g7=_yK;}};CDLChart.prototype.RunDeleteRequest=function(_Cc){var _AE=new Array();_AE[0]=this.GetDeleteAction();var _aBj=this._he.commManager.CreateExploreRequest(_AE);_aBj.Send(true,_Cc,true);return;};CDLChart.prototype.GetDeleteAction=function(){var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionDelete;_Jj.AddTargetItem(this._ks,ExpAPIXml.kEleChart);return _Jj;};CDLChart.prototype.GetURL=function(){return this._g7;};CDLChart.prototype.GetChartType=function(){return this._mt;};CDLChart.GetChartOptionsString=function(_F5){if(_F5==ExpAPIXml.eChartType3DBar){return "threedbarchartoptions";}if(_F5==ExpAPIXml.eChartType3DArea){return "threedareachartoptions";}if(_F5==ExpAPIXml.eChartType3DLine){return "threedlinechartoptions";}else{return _F5+"chartoptions";}};CDLChart.prototype.GetLeftMostChartArea=function(){var _W5=null;var _alX=10000;for(var i=0;i<this._lr.length;i++){var _aDb=this._lr[i];if(_aDb._hf=="chartElement"){if(_aDb.iXCoord<_alX){_W5=_aDb;_alX=_aDb.iXCoord;}}}return _W5;};CDLChart.prototype.GetRightMostChartArea=function(){var _8q=null;var _3C=-1;for(var i=0;i<this._lr.length;i++){var _aDb=this._lr[i];if(_aDb._hf=="chartElement"){if(_aDb.iXCoord>_3C){_8q=_aDb;_3C=_aDb.iXCoord;}}}return _8q;};CDLChart.prototype.GetTopMostChartArea=function(){var _aEq=null;var _aqu=10000;for(var i=0;i<this._lr.length;i++){var _aDb=this._lr[i];if(_aDb._hf=="chartElement"){if(_aDb.iYCoord<_aqu){_aEq=_aDb;_aqu=_aDb.iYCoord;}}}return _aEq;};CDLChart.prototype.GetBottomMostChartArea=function(){var _azb=null;var _aIV=-1;for(var i=0;i<this._lr.length;i++){var _aDb=this._lr[i];if(_aDb._hf=="chartElement"){if(_aDb.iYCoord>_aIV){_azb=_aDb;_aIV=_aDb.iYCoord;}}}return _azb;};function CDLChartArea(_IX){this._gU=null;this._bQ=null;this._wZ=null;this._mg=_IX;this._fT=null;this._hf=null;this._pH=null;this._b1=null;};CDLChartArea.prototype.Init=function(_Ma,_AT){this.oDataMgr=_AT;var _RJ=_AT.metadata;this._gU=_Ma.getAttribute(ExpAPIXml.kEleShape);this._bQ=_Ma.getAttribute(ExpAPIXml.kEleCoords);this._hf=_Ma.getAttribute(ExpAPIXml.kAttrObjType);if(Utilities.bScatterPlotGraphsEnabled&&this._mg&&(this._hf=="chartElement")){this.ExtractCoords();var _avj=Dom.GetImmediateChildrenByName(_Ma,ExpAPIXml.kEleChartMeasure);if(_avj.length>1){this._w=new Array();for(var _atF=0;_atF<_avj.length;_atF++){var _NS=new CDLChartMeasure();_NS.Init(_avj[_atF],_RJ,_AT._kX);this._w.push(_NS);}}}else{var _ao4=Dom.GetImmediateChildByName(_Ma,ExpAPIXml.kEleChartMeasure);if(_ao4){var _NS=new CDLChartMeasure();_NS.Init(_ao4,_RJ,_AT._kX);this._hp=_NS;}}this._wZ=new Array();var _zt=Dom.GetElementsByTagName(_Ma,ExpAPIXml.kEleChartMember);var _akL=new Object();for(var i=0;i<_zt.length;i++){var _aC9=new CDLChartMember();_aC9.Init(_zt[i],_RJ,_AT._kX);var _0c=((this._hf==ExpAPIXml.kLegendTitle)||(this._hf==ExpAPIXml.kOrdinalAxisTitle))&&_aC9.sMeasurePtr;if(_aC9.GetMemberId()=='mun:null'||_akL[_aC9.GetBlockId()]||_0c){delete _aC9;}else{this._wZ.push(_aC9);_akL[_aC9.GetBlockId()]=true;}}};CDLChartArea.prototype.GetShape=function(){return this._gU;};CDLChartArea.prototype.GetCoords=function(){return this._bQ;};CDLChartArea.prototype.ExtractCoords=function(){var _aoM=new Array();var _aFi=this._bQ.split(",");var _3C=-1;var _alX=10000;var _aIV=-1;var _aqu=10000;for(var i=0;i<_aFi.length;i++){if((i%2)==1){if(_aFi[i]>_aIV){_aIV=parseInt(_aFi[i]);}else if(_aFi[i]<_aqu){_aqu=parseInt(_aFi[i]);}}else{if(_aFi[i]>_3C){_3C=parseInt(_aFi[i]);}else if(_aFi[i]<_alX){_alX=parseInt(_aFi[i]);}}}this.iXCoord=(_alX+_3C)/2;this.iYCoord=(_aqu+_aIV)/2;};CDLChartArea.prototype.GetChartMemberCount=function(){return this._wZ.length;};CDLChartArea.prototype.GetChartMember=function(i){return this._wZ[i];};CDLChartArea.prototype.GetChartMeasure=function(){return this._hp;};CDLChartArea.prototype.GetChartMeasures=function(){return this._w;};CDLChartArea.prototype.CanDrillUp=function(){if(this._cq){return this._pH;}this._pH=false;if(this.IsTitle()){var _Li=this.oDataMgr.GetCurrentDataMatrix();var _RJ=this.oDataMgr.metadata;for(var i=0;i<this._wZ.length;i++){if(this._wZ[i]&&this._wZ[i].GetMemberId()){var _FK=_Li.GetBlock(this._wZ[i].GetBlockId());var _aHf=_RJ.GetMemberOrMeasure(this._wZ[i].GetMemberId());if(_aHf&&!_aHf.IsRootMember()&&_FK.CanDrillUp()){this._pH=true;break;}}}}this._cq=true;return this._pH;};CDLChartArea.prototype.CanDrillDown=function(){if(this.IsTitle()){return false;}else{var _Li=this.oDataMgr.GetCurrentDataMatrix();for(var i=0;i<this._wZ.length;i++){if(this._wZ[i]._tW){continue;}var _FK=_Li.GetBlock(this._wZ[i].GetBlockId());if(!this._wZ[i].IsCalc()&&_FK.CanDrillDown()){return true;}}}return false;};CDLChartArea.prototype.IsTitle=function(){if(this._hf==ExpAPIXml.kOrdinalAxisTitle||this._hf==ExpAPIXml.kLegendTitle){return true;}};CDLChartArea.prototype.IsChartElement=function(){return(this._hf==ExpAPIXml.kChartElement);};CDLChartArea.prototype.IsOrdinalLabel=function(){return(this._hf==ExpAPIXml.kOrdinalAxisLabel);};CDLChartArea.prototype.GetBlockIds=function(){var _Tu=new Array();for(var i=0;i<this._wZ.length;i++){if(this._wZ[i].sBlockId!=null&&this._wZ[i].sBlockId!=""){_Tu.push(this._wZ[i].sBlockId);}}return _Tu;};CDLChartArea.prototype.RemoveMemberByBlockId=function(_L7){for(var i=0;i<this._wZ.length;i++){if(this._wZ[i].sBlockId==_L7){Utilities.DeleteNthFromArray(this._wZ,i);break;}}};CDLChartArea.prototype.RemoveMeasure=function(){this._hp=null;};CDLChartArea.prototype.DoDrill=function(){if(this._wZ.length==0){return;}var _AE=new Array();var _O1;if(this.CanDrillDown()){_O1=ExpAPIXml.kDown;}else if(this.CanDrillUp()){_O1=ExpAPIXml.kUp;}if(_O1){for(var i=0;i<this._wZ.length;i++){var _Jj=this.getDrillAction(i,_O1);if(_Jj!=null){_AE.push(_Jj);}}if(_AE.length>0){var _Li=this.oDataMgr.GetCurrentDataMatrix();_Li.SendDMActionArray(_AE);}}};CDLChartArea.prototype.getDrillAction=function(i,_O1){var _Li=this.oDataMgr.GetCurrentDataMatrix();var _Jj=_Li.GetDMAction();_Jj.type=ExpAPIXml.kActionDrill;if(this._wZ[i].IsCalc()||!this._wZ[i].GetBlockId()){return null;}var _FK=_Li.GetBlock(this._wZ[i].GetBlockId());Debug.Assert(_FK!=null,"No Block");var _ajS=false;if(_O1==ExpAPIXml.kDown&&_FK.CanDrillDown()){_ajS=true;}if(_O1==ExpAPIXml.kUp&&_FK.CanDrillUp()){_ajS=true;}if(_FK!=null&&_ajS){var _O0=_FK.GetAxis();Debug.Assert(_O0!=null,"No axis");if(_O0!=null){_Jj.AddTargetItem(_O0.GetId(),ExpAPIXml.kEleAxis);_Jj.AddTargetItem(this._wZ[i].GetBlockId(),ExpAPIXml.kEleAxisOpExpression);var _NS=this.oDataMgr.metadata.GetMeasure(this._wZ[i].GetMemberId());var _OA=(_NS!=null)?ExpAxisObjType.Measure:ExpAxisObjType.Member;_Jj.AddSource(this._wZ[i].GetMemberId(),_OA);_Jj._eW(ExpAPIXml.kDrillType,_O1);return _Jj;}}return null;};CDLChartArea.prototype.Clear=function(){Utilities.RemoveAllChildObjects(this);};function CDLChartBlock(_Ma){this._gU=_Ma.getAttribute(ExpAPIXml.kEleShape);this._bQ=_Ma.getAttribute(ExpAPIXml.kEleCoords);};function CDLAbsChartMember(){this._uW="";this.sMemberPtr=null;this.sCalcPtr=null;this._tM=false;};CDLAbsChartMember.prototype.Init=function(_GE,_RJ,_JE){this.sMemberPtr=_GE.getAttribute(ExpAPIXml.kEleMemberPtr);this.sMeasurePtr=_GE.getAttribute(ExpAPIXml.kEleMeasurePtr);if(this.sMeasurePtr){this.sMemberPtr=this.sMeasurePtr;}if(this.sMemberPtr){this._uW=_RJ.GetDataLabel(this.sMemberPtr);if(this._uW==""){this._uW=Dom.GetNodeText(_GE);}}this.sUseTooltip=_GE.getAttribute(ExpAPIXml.kAttUseTootip);this.sCalcPtr=_GE.getAttribute(ExpAPIXml.kEleCalcPtr);if(this.sCalcPtr&&_JE.GetCalculation(this.sCalcPtr)){this._uW=_JE.GetCalculation(this.sCalcPtr).GetLabel();this._tM=true;}if(!(this.sMemberPtr||this.sCalcPtr)){this._tW=true;}};CDLAbsChartMember.prototype.GetCaption=function(){return this._uW;};CDLAbsChartMember.prototype.GetMemberId=function(){return this.sMemberPtr;};CDLAbsChartMember.prototype.IsCalc=function(){return this._tM;};function CDLChartMember(){this.base=CDLAbsChartMember;this.base();this.sLevelPtr=null;this.sLevel="";this.sBlockId="";};CDLChartMember.prototype=new CDLAbsChartMember;CDLChartMember.superclass=CDLAbsChartMember.prototype;CDLChartMember.prototype.Init=function(_GE,_RJ,_JE){CDLChartMember.superclass.Init.call(this,_GE,_RJ,_JE);this.sBlockId=_GE.getAttribute("blockptr");if(this._tM){if(this.sBlockId!=null){this.sLevel=_RJ.GetDimById(_JE.getBlock(this.sBlockId).GetDimId()).GetLabel();}}else{if(this.sMemberPtr){if(this.sMeasurePtr){this.sLevel=_RJ.GetMeasure(this.sMeasurePtr).GetDim().GetLabel();}else{var oMem=_RJ.GetMember(this.sMemberPtr);var _aIG=oMem.GetLevel();if(!_aIG){_aIG=oMem.GetHierarchy();}this.sLevel=_aIG.GetLabel();}}}};CDLChartMember.prototype.GetLevelLabel=function(){return this.sLevel;};CDLChartMember.prototype.GetBlockId=function(){return this.sBlockId;};function CDLChartMeasure(){this.base=CDLAbsChartMember;this.base();this.sMeasure="";};CDLChartMeasure.prototype=new CDLAbsChartMember;CDLChartMeasure.superclass=CDLAbsChartMember.prototype;CDLChartMeasure.prototype.Init=function(_GE,_RJ,_JE){CDLChartMeasure.superclass.Init.call(this,_GE,_RJ,_JE);this._uW=Dom.GetNodeText(_GE);if(this.sMeasurePtr){this.sMeasure=_RJ.GetDataLabel(this.sMemberPtr);}else if(this.sCalcPtr&&_JE.GetCalculation(this.sCalcPtr)){this.sMeasure=_JE.GetCalculation(this.sCalcPtr).GetLabel();}};CDLChartMeasure.prototype.GetMeasureLabel=function(){return this.sMeasure;};function CDLCapability(_VP){this._he=_VP;this._as=new Object();this._gL=new Object();this._dA=false;};CDLCapability.prototype.SetSupportedProfiles=function(_Sx){if(_Sx){Utilities.CopyObjArray(_Sx,this._gL);}};CDLCapability.prototype.IsSupportedProfile=function(_Ar){return this._gL[_Ar];};CDLCapability.prototype.IsProfilesEmpty=function(){return Utilities.IsObjectEmpty(this._gL);};CDLCapability.prototype.SetCapabilities=function(_N6,_CG){this._as[_N6]=_CG;};CDLCapability.prototype.HasCapability=function(_MO){return this._as[_MO];};CDLCapability.prototype.SetResponseProcessed=function(_LM){this._dA=_LM;};CDLCapability.prototype.IsResponseProcessed=function(){return this._dA;};CDLCapability.K_sProfessional="Professional";CDLCapability.K_sFinancial="Express";CDLCapability.K_sFinancialAuthors="Express Authors";CDLCapability.K_sCanUseReportStudio="canUseReportStudio";CDLCapability.K_sCanIndexSearch="canUseIndexSearch";CDLCapability.K_sCanViewLineage="canUseLineage";CDLCapability.K_sCanUseGlossary="canUseGlossary";CDLCapability.K_sCanGenerateCSVOutput="canGenerateCSVOutput";CDLCapability.K_sCanGenerateExcelOutput="canGenerateXLSOutput";CDLCapability.K_sCanGenerateXMLOutput="canGenerateXMLOutput";CDLCapability.K_sCanGeneratePDFOutput="canGeneratePDFOutput";function CDLConfiguration(_VP){this._he=_VP;this._qj=new Object();};CDLConfiguration.prototype.SetProperty=function(_LW,_Qs){this._qj[_LW]=_Qs;};CDLConfiguration.prototype.GetProperty=function(_LW){return this._qj[_LW];};CDLConfiguration.prototype.HasProperty=function(_LW){return this._qj[_LW];};CDLConfiguration.K_sLineageURL="metadataInformationURI";CDLConfiguration.K_sDefaultLineageURL="";CDLConfiguration.K_sGlossaryURL="glossaryURI";CDLConfiguration.K_sDefaultGlossaryURL="";function CCMCommManager(_N0,_RA){this.appobj=_N0;this._ot=_RA;this._tO=null;this._xE=null;this._yl=new Array();this._in=new Array();this._hv=new Array();this._yp=new Array();this._v0=new CCMRedoStack();this._sz=new CCMUndoStack(this._v0);_f.SetCommManager(this);};CCMCommManager.prototype.SetParameterValues=function(_Rh){this._xE=_Rh;};CCMCommManager.prototype.GetParameterValues=function(){return this._xE;};CCMCommManager.prototype.CreateConfigurationRequest=function(){var _AV='request'+Utilities.GenerateId();var _CW='<bus:getConfiguration>'+'<properties xsi:type="SOAP-ENC:Array" SOAP-ENC:arrayType="bus:propEnum[]">'+'<item>metadataInformationURI</item>'+'<item>glossaryURI</item>'+'</properties>'+'</bus:getConfiguration>';var _aBj=new CCMBiBusRequest(this,this._ot,this.appobj,_AV,"Configuration");_aBj.SetText(_CW);return _aBj;};CCMCommManager.prototype.CreateCancelRequest=function(_ST){var _AV='request'+Utilities.GenerateId();var _aBj=new CCMBiBusRequest(this,this._ot,this.appobj,_AV,"cancel");var _aut=CCMCommManager._su;_aut=_aut.replace("@CONVERSATION@",_ST);_aBj.SetText(_aut);return _aBj;};CCMCommManager.prototype.CreateExploreRequest=function(_AE,_Pd){/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_l){g_oHTMLEncoding.ClearTimer();g_oCreateXMLDoc.ClearTimer();_l.StartGlobalTimer("Create Explore Request");}/*@end@*/if(_q){PerfMonitor.StartPerceivedUserTime();}if(_AE.length>0){if(!_Pd){this._v0.Clear();}if(_AE[0].type==ExpAPIXml.kActionLoad){this._sz.Clear();}else if(_AE[0].type==ExpAPIXml.kActionSubstitute||_AE[0].type==ExpAPIXml.kActionNew){this._sz.ClearAll();}}var _AV='request'+Utilities.GenerateId();var _aBj=new CCMBiBusRequest(this,this._ot,this.appobj,_AV,"explore");var _ani=this.getContextText(_Pd);var _NB=this.getCommandString(_AV,_AE);var _CW=CCMCommManager._ou;_CW=_CW.replace("@PPSCONTEXT@",_ani);/*@if(@bering_test)@*/if(Debug.IsEnabled()){var _4t=_CW.replace("@ACTIONS@",_NB);_4t=_4t.replace("@PPSCONTEXT@",_ani);RegressionTest.RecordActions(_4t);}/*@end@*/if(this._xE){_CW=_CW.replace("@PARAMETERVALUES@",this._xE);}/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_l){g_oHTMLEncoding.StartTimer();}/*@end@*/_CW=_CW.replace("@ACTIONS@",Utilities.HtmlEncode(_NB));/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_l){g_oHTMLEncoding.StopTimer();}/*@end@*/_aBj.SetText(_CW);/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_l){_l.StopGlobalTimer();}/*@end@*/return _aBj;};CCMCommManager.prototype.CreateUserCapabilityAndProfileQueryRequest=function(){var _AV='request'+Utilities.GenerateId();var _aBj=new CCMBiBusRequest(this,this._ot,this.appobj,_AV,"CMquery");var _CW=CCMCommManager._kI;var _Z9=Utilities.HtmlEncode(this.appobj.dataManager.metadata._lt);_CW=_CW.replace("@SearchPath@",_Z9);_aBj.SetText(_CW);return _aBj;};CCMCommManager.prototype.SearchUserCapabilityAndProfiles=function(){var _aBj=this.CreateUserCapabilityAndProfileQueryRequest();_aBj.Send(true,this,false);};CCMCommManager.prototype.CreateRoutingServerGroupRequest=function(_EG){var _AV='request'+Utilities.GenerateId();var _aBj=new CCMBiBusRequest(this,this._ot,this.appobj,_AV,"CMquery");var _CW=CCMCommManager._jQ;var _Z9=Utilities.HtmlEncode(_EG);_CW=_CW.replace("@SearchPath@",_Z9);_aBj.SetText(_CW);return _aBj;};CCMCommManager.prototype.SearchRoutingServerGroup=function(_EG){var _aBj=this.CreateRoutingServerGroupRequest(_EG);_aBj.Send(true,this,false);};CCMCommManager.prototype.getContextText=function(_Pd){var _ani="";if(_Pd){this._tO=_Pd;}if(this._tO!=null){_ani=this._tO;}return _ani;};CCMCommManager.prototype.getClientStateString=function(_AV){var _4E=CCMCommManager._iu;_4E=_4E.replace("@APPNAME@",Utilities.HtmlEncode(this.appobj.appname));_4E=_4E.replace("@REQUESTID@",_AV);return _4E;};CCMCommManager.prototype.getCommandString=function(_AV,_AE){var _aFS="<cmd>";_aFS+=this.getClientStateString(_AV);_aFS+=this.getActionsString(_AE);_aFS+="</cmd>";return _aFS;};CCMCommManager.prototype.getCommandText=function(_AV,_AE){return Utilities.HtmlEncode(this.getCommandString(_AV,_AE));};CCMCommManager.prototype.getActionsString=function(_AE){var _NB='<actions>';for(var i in _AE){var _Jj=_AE[i];_NB+=_Jj.GetAsXMLString();}_NB+='</actions>';return _NB;};CCMCommManager.prototype.CreateEditObjRequest=function(_K7,_AE){/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_l){g_oHTMLEncoding.ClearTimer();g_oCreateXMLDoc.ClearTimer();_l.StartGlobalTimer("Create EditAnalysis Request");}/*@end@*/this._sz.Clear();var _AV='request'+Utilities.GenerateId();var _aBj=new CCMBiBusRequest(this,this._ot,this.appobj,_AV,"edit");var _CW=CCMCommManager._u6;var _aFS=this.getCommandText(_AV,_AE);_CW=_CW.replace("@PPSOBJ@",Utilities.HtmlEncode(_K7));_CW=_CW.replace("@ACTIONS@",_aFS);if(this._xE){_CW=_CW.replace("@PARAMETERVALUES@",this._xE);}_aBj.SetText(_CW);/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_l){_l.StopGlobalTimer();}/*@end@*/return _aBj;};CCMCommManager.prototype.CreateAddRequest=function(_EQ,_Cm,_Iy){/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_l){g_oHTMLEncoding.ClearTimer();g_oCreateXMLDoc.ClearTimer();_l.StartGlobalTimer("Create RSVP Add Request");}/*@end@*/var _AV='request'+Utilities.GenerateId();var _aBj=new CCMBiBusRequest(this,this._ot,this.appobj,_AV,"add");var _CW=CCMCommManager._tV;_CW=_CW.replace("@LOCATION@",Utilities.HtmlEncode(_Cm));_CW=_CW.replace("@NAME@",Utilities.HtmlEncode(_EQ));ss=this._tO;_CW=_CW.replace("@SERVERSTATE@",ss);var _aiH=_Iy?_Iy:ExpAPIXml.eUpdateOptFail;_CW=_CW.replace("@UPDATEOPTION@",_aiH);_aBj.SetText(_CW);/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_l){_l.StopGlobalTimer();}/*@end@*/return _aBj;};CCMCommManager.prototype.CreateUpdateRequest=function(_EQ,_Cm){/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_l){g_oHTMLEncoding.ClearTimer();g_oCreateXMLDoc.ClearTimer();_l.StartGlobalTimer("Create RSVP update Request");}/*@end@*/var _AV='request'+Utilities.GenerateId();var _aBj=new CCMBiBusRequest(this,this._ot,this.appobj,_AV,"update");var _CW=CCMCommManager._q0;_CW=_CW.replace("@LOCATION@",Utilities.HtmlEncode(_Cm));if(_EQ.indexOf('"')>=0){_CW=_CW.replace("@NAME@","'"+Utilities.HtmlEncode(_EQ)+"'");}else{_CW=_CW.replace("@NAME@",'"'+Utilities.HtmlEncode(_EQ)+'"');}ss=this._tO;_CW=_CW.replace("@SERVERSTATE@",ss);_aBj.SetText(_CW);/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_l){_l.StopGlobalTimer();}/*@end@*/return _aBj;};CCMCommManager.prototype.AddToCurrentRequests=function(_AV,_RH,_Am,_Ta){if(_Am){this._yl[_AV]=_RH;}else{this._yp[_AV]=_RH;}this._hv[_AV]=_Ta;};CCMCommManager.prototype.GetRequestObject=function(_AV){if(this._yl[_AV]){return this._yl[_AV];}else if(this._yp[_AV]){return this._yp[_AV];}return null;};CCMCommManager.prototype.DeleteRequestObject=function(_AV){if(this._yl[_AV]){delete this._yl[_AV];}else if(this._yp[_AV]){delete this._yp[_AV];}delete this._hv[_AV];};CCMCommManager.prototype.ReleaseConnections=function(){if(this.appobj.okToRelease()){var _AV='request'+Utilities.GenerateId();var _aBj=new CCMBiBusRequest(this,this._ot,this.appobj,_AV,"release");var _8K=CCMCommManager._pI;_aBj.SetText(_8K);_aBj.SendSynchronous(this,"reportService/201505/.absolute");}for(var s in this._hv){this._hv[s].Abort();}Utilities.ClearObjectArray(this._hv);Utilities.ClearObjectArray(this._yl);Utilities.ClearObjectArray(this._yp);};CCMCommManager.prototype.CancelRequest=function(_Pk,_Th,_ST,_Je,_Ef){if(_ST&&_Je){var _aBj=this.CreateCancelRequest(_ST);_aBj.Send(false,_Pk,false,_Je);}this.HandleIgnoreResponse(_Pk,_Th,_Ef);};CCMCommManager.prototype.HandleIgnoreResponse=function(_Pk,_Th,_Ef,_y7){for(var i in this._yl){if(this._yl[i]==_Pk){if(!_Ef){this._in[i]=true;if(_Pk==this.oBlockedObject){this.FreeBlockedObject();}}if(_Th&&_Th!=""){CUIDialogMgr.DisplayMessageBox(CUIMessageBox.kWarning,_Th);}if(!_y7){delete this._yl[i];}break;}}};CCMCommManager.prototype.IgnoreResponse=function(_AV){if(this._in[_AV]){delete this._in[_AV];if(this._yl[_AV]){delete this._yl[_AV];}return true;}return false;};CCMCommManager.prototype.IsRequestCancelable=function(_AV){if(this._yl[_AV]){return true;}return false;};CCMCommManager.prototype.SetCurrentResponse=function(_AV,_A3){if(this._tO==null){this.SetServerState(_A3);}else{this.DeleteRequestObject(_AV);if(_AV==this.sBlockingRequest){Debug.Assert(this.oBlockedObject);if(this.oBlockedObject instanceof CDLWorksheet){this.SetServerState(_A3);}if(this.oBlockedObject.SetStateProcessing){this.oBlockedObject.SetStateProcessing();}}}};CCMCommManager.prototype.EndResponse=function(_AV,_AK){if(_AK&&this.oBlockedObject){this.oBlockedObject.SetStateProcessing();}if(_AV==this.sBlockingRequest&&this.oBlockedObject){if(this.oBlockedObject.EndProcessing){this.oBlockedObject.EndProcessing();}this.FreeBlockedObject(true);}};CCMCommManager.prototype.SetFailedResponse=function(_AV,_FA,_Kr,_zP){var _agN=this.GetRequestObject(_AV);if(_agN){if(_AV==this.sBlockingRequest){Debug.Assert(this.oBlockedObject);var _agN=this.oBlockedObject;this.FreeBlockedObject();if(_agN.SetStateFailed){_agN.SetStateFailed(_FA,_Kr,_zP);}else{if(!_zP){CUIDialogMgr.DisplayMessageBox(CUIMessageBox.kCritical,(_FA)?_FA:'MES_SERVER_ERROR',_Kr);}if(Debug&&Debug._sj&&_Kr!=""){alert('Request to Server Failed: '+_Kr);}}}else{if(_agN.SetStateFailed){_agN.SetStateFailed(_FA,_Kr,_zP);}else{if(!_zP){if(_agN instanceof CDLDataManager&&!_agN.GetCurrentWorkSheet()){var _aDB=Utilities.GenerateCallback(CUIDialogMgr.SafeHandleExit,[_agN.appobj.appname]);CUIDialogMgr.DisplayMessageBox(CUIMessageBox.kCritical,(_FA)?_FA:'MES_SERVER_ERROR',_Kr,_aDB);}else{CUIDialogMgr.DisplayMessageBox(CUIMessageBox.kCritical,(_FA)?_FA:'MES_SERVER_ERROR',_Kr);}}if(Debug&&Debug._sj&&_Kr!=""){alert('Request to Server Failed: '+_Kr);}}}this.DeleteRequestObject(_AV);}};CCMCommManager.prototype.IsBlocked=function(){if(this.oBlockedObject){return true;}return false;};CCMCommManager.prototype.SetBlockedObject=function(_QL,_AV){if(this.oBlockedObject){return false;}this.oBlockedObject=_QL;this.sBlockingRequest=_AV;Debug.Assert(this.oBlockedObject.SetStateBlocked);this.oBlockedObject.SetStateBlocked();return true;};CCMCommManager.prototype.FreeBlockedObject=function(){delete this.oBlockedObject;delete this.sBlockingRequest;};CCMCommManager.prototype.SetServerState=function(_Wq){/*@if(@bering_debug)@*/if(this.appobj._wJ._mE){return;}/*@end@*/var _ay5='<serverstate>';var _af8='</serverstate>';var _Wq=_Wq.replace(_ay5,Utilities.HtmlEncode(_ay5));_Wq=_Wq.replace(_af8,Utilities.HtmlEncode(_af8));if(this._sz.Push(_Wq)){this._tO=_Wq;}};CCMCommManager.prototype.CanUndo=function(){return this._sz.CanUndo();};CCMCommManager.prototype.CanRedo=function(){return this._v0.CanRedo();};CCMCommManager.prototype.GetUndoState=function(){return this._sz.Pull();};CCMCommManager.prototype.GetRedoState=function(){return this._v0.Pull();};CCMCommManager._ou='<editAnalysisSpecification xmlns="http://developer.cognos.com/schemas/reportService/1">'+'<specification xsi:type="bus:reportServiceAnalysisSpecification">'+'<bus:value xsi:type="bus:specification">'+'<item>'+'@PPSCONTEXT@'+'</item>'+'</bus:value>'+'</specification>'+'<action>'+'@ACTIONS@'+'</action>'+'<parameterValues SOAP-ENC:arrayType="bus:parameterValue[]" xsi:type="SOAP-ENC:Array">'+'@PARAMETERVALUES@'+'</parameterValues>'+'<options SOAP-ENC:arrayType="bus:option[]" xsi:type="SOAP-ENC:Array">'+'<item xsi:type="bus:asynchOptionEncoding">'+'<bus:name xsi:type="bus:asynchOptionEnum">attachmentEncoding</bus:name>'+'<bus:value xsi:type="bus:encodingEnum">base64</bus:value>'+'</item>'+'<item xsi:type="bus:asynchOptionInt">'+'<bus:name xsi:type="bus:asynchOptionEnum">primaryWaitThreshold</bus:name>'+'<bus:value xsi:type="xsd:int">7</bus:value>'+'</item>'+'@CACHECONTEXTOPTION@'+'</options>'+'</editAnalysisSpecification>';CCMCommManager._u6='<editAnalysis xmlns="http://developer.cognos.com/schemas/reportService/1">'+'<objectPath>'+'@PPSOBJ@'+'</objectPath>'+'<action>'+'@ACTIONS@'+'</action>'+'<parameterValues SOAP-ENC:arrayType="bus:parameterValue[]" xsi:type="SOAP-ENC:Array">'+'@PARAMETERVALUES@'+'</parameterValues>'+'<options SOAP-ENC:arrayType="bus:option[]" xsi:type="SOAP-ENC:Array">'+'<item xsi:type="bus:asynchOptionEncoding">'+'<bus:name xsi:type="bus:asynchOptionEnum">attachmentEncoding</bus:name>'+'<bus:value xsi:type="bus:encodingEnum">base64</bus:value>'+'</item>'+'<item xsi:type="bus:asynchOptionInt">'+'<bus:name xsi:type="bus:asynchOptionEnum">primaryWaitThreshold</bus:name>'+'<bus:value xsi:type="xsd:int">7</bus:value>'+'</item>'+'@CACHECONTEXTOPTION@'+'</options>'+'</editAnalysis>';CCMCommManager._su='<cancel xmlns="http://developer.cognos.com/schemas/reportService/1">'+'@CONVERSATION@'+'</cancel>';CCMCommManager._pI='<rns1:release xmlns:rns1="http://developer.cognos.com/schemas/reportService/1">'+'<bus:conversation xsi:type="bus:asynchRequest" xsi:nil="true"/>'+'</rns1:release>';CCMCommManager._iu='<clientstate>'+'<appname>'+'<value>'+'@APPNAME@'+'</value>'+'</appname>'+'<requestId>'+'@REQUESTID@'+'</requestId>'+'</clientstate>';CCMCommManager._tV='<rns:add xmlns:rns="http://developer.cognos.com/schemas/reportService/1">'+'<parentPath>'+'@LOCATION@'+'</parentPath>'+'<object xsi:type="bus:analysis">'+'<defaultName>'+'<value xsi:type="xsd:string">'+'@NAME@'+'</value>'+'</defaultName>'+'<specification>'+'<value xsi:type="xsd:string" xml:space="preserve">'+'@SERVERSTATE@'+'</value>'+'</specification>'+'<parameters xsi:type="bus:parameterValueArrayProp" SOAP-ENC:arrayType="bus:parameterValue[]">'+'<value xsi:type="SOAP-ENC:Array" SOAP-ENC:arrayType="bus:parameterValue[]"/>'+'</parameters>'+'</object>'+'<options xsi:type="bus:addOptions">'+'<updateAction xsi:type="bus:updateActionEnum">'+'@UPDATEOPTION@'+'</updateAction>'+'</options>'+'</rns:add>';CCMCommManager._q0='<rns:update xmlns:rns="http://developer.cognos.com/schemas/reportService/1">'+'<object xsi:type="bus:analysis">'+'<searchPath xsi:type="bus:stringProp">'+'<schemaInfo xsi:nil="true"/>'+'<value xsi:type="xsd:string">'+'@LOCATION@/analysis[@name=@NAME@]'+'</value>'+'</searchPath>'+'<specification>'+'<value xsi:type="xsd:string" xml:space="preserve">'+'@SERVERSTATE@'+'</value>'+'</specification>'+'</object>'+'<options xsi:type="bus:updateOptions"/>'+'</rns:update>';CCMCommManager._kI='<bus:query>'+'<requests xsi:type="SOAP-ENC:Array" SOAP-ENC:arrayType="bus:queryRequest[2]">'+'<item xsi:type="bus:queryRequest">'+'<search>@SearchPath@</search>'+'<properties xsi:type="SOAP-ENC:Array" SOAP-ENC:arrayType="bus:propEnum[1]">'+'<item xsi:type="bus:propEnum">effectiveUserCapabilities</item>'+'</properties>'+'</item>'+'<item xsi:type="bus:queryRequest">'+'<search xsi:type="xsd:string">/configuration/uiProfileFolder//uiProfile[permission("execute")]</search>'+'<properties xsi:type="SOAP-ENC:Array" SOAP-ENC:arrayType="bus:propEnum[3]">'+'<item xsi:type="bus:propEnum">defaultName</item>'+'<item xsi:type="bus:propEnum">userInterface</item>'+'<item xsi:type="bus:propEnum">name</item>'+'</properties>'+'</item>'+'</requests>'+'</bus:query>';CCMCommManager._jQ='<bus:query>'+'<requests xsi:type="SOAP-ENC:Array" SOAP-ENC:arrayType="bus:queryRequest[1]">'+'<item xsi:type="bus:queryRequest">'+'<search>@SearchPath@</search>'+'<properties xsi:type="SOAP-ENC:Array" SOAP-ENC:arrayType="bus:propEnum[1]">'+'<item xsi:type="bus:propEnum">routingServerGroup</item>'+'</properties>'+'</item>'+'</requests>'+'</bus:query>';function CCMUndoStack(_Ez){this._oG=new Array();this._v0=_Ez;};CCMUndoStack.prototype.Push=function(_JH){var _azN=false;if(this._oG.length>0){if(_JH==this._oG[this._oG.length-1]){return _azN;}}if(this._oG.length>10){for(var i=0;i<this._oG.length-1;i++){this._oG[i]=this._oG[i+1];}this._oG.length=this._oG.length-1;}this._oG[this._oG.length]=_JH;_azN=true;return _azN;};CCMUndoStack.prototype.Pull=function(){if(this._oG.length>1){this._v0.Push(this._oG[this._oG.length-1]);var _abn=this._oG[this._oG.length-2];this._oG.length=this._oG.length-2;return _abn;}else{return null;}};CCMUndoStack.prototype.CanUndo=function(){return this._oG.length>1;};CCMUndoStack.prototype.Clear=function(){if(this._oG.length>0){var _as6=this._oG[this._oG.length-1];Utilities.DeleteAllFromArray(this._oG);if(_as6){this._oG.push(_as6);}}this._v0.Clear();};CCMUndoStack.prototype.ClearAll=function(){if(this._oG.length>0){Utilities.DeleteAllFromArray(this._oG);}this._v0.Clear();};function CCMRedoStack(){this._oG=new Array();};CCMRedoStack.prototype.Push=function(_JH){if(this._oG.length>10){for(var i=0;i<this._oG.length-1;i++){this._oG[i]=this._oG[i+1];}this._oG.length=this._oG.length-1;}this._oG[this._oG.length]=_JH;};CCMRedoStack.prototype.Pull=function(){if(this._oG.length>0){var _abn=this._oG[this._oG.length-1];this._oG.length=this._oG.length-1;return _abn;}else{return null;}};CCMRedoStack.prototype.Clear=function(){this._oG.length=0;};CCMRedoStack.prototype.CanRedo=function(){return this._oG.length>0;};function CCMBiBusRequest(_G9,_RA,_Wr,_AV,_z6){this._n1=_G9;this._ot=_RA;this._vI=null;this.oAppObj=_Wr;this.sRequestId=_AV;this.sRequestedMemberId=null;if(_z6=="add"){this.sReportService="reportService/201505/";}else if(_z6=="update"){this.sReportService="reportService/201505/";}else if(_z6=="CMquery"){this.sReportService="http://www.ibm.com/xmlns/prod/cognos/contentManagerService/201505/";}else if(_z6=="Configuration"){this.sReportService="systemService/201505/";}else{this.sReportService="reportService/201505/.session";}this.deferredCallBackOK=null;this.deferredCallBackCancel=null;};CCMBiBusRequest.prototype.SetText=function(_Wy){this._vI=_Wy;};CCMBiBusRequest.prototype.SetDeferredCallBackFunction=function(_MW,_HW){this.deferredCallBackOK=_MW;this.deferredCallBackCancel=_HW;};CCMBiBusRequest.prototype.clearDeferredCallBackFunction=function(){this.deferredCallBackOK=null;this.deferredCallBackCancel=null;};CCMBiBusRequest.prototype.ReplaceRequestParm=function(_R7,_zO){this._vI=this._vI.replace(_R7,_zO);};CCMBiBusRequest.prototype.Send=function(_Am,_RH,_Dd,_Je,_Ap){this.m_oBIBus=new CBIBus(this.sReportService,this,this.oAppObj);var _adJ=this.m_oBIBus.createSOAPRequest(this._vI);this._n1.AddToCurrentRequests(this.sRequestId,_RH,_Am,this);if(_Dd){if(!this._n1.SetBlockedObject(_RH,this.sRequestId)){Debug.Assert(false,"The worksheet is currently busy");throw new COTWorkSheetBusyException();}}this.m_oBIBus.Send(_adJ,_Je,_Ap);};CCMBiBusRequest.prototype.SendSynchronous=function(_RH,_VK){this.m_oBIBus=new CBIBus(_VK,this,this.oAppObj);var _adJ=this.m_oBIBus.createSOAPRequest(this._vI);this.m_oBIBus.SendSynch(_adJ);};CCMBiBusRequest.prototype.Abort=function(){if(this.m_oBIBus){this.m_oBIBus.Abort();}};CCMBiBusRequest.prototype._rx=function(_VQ){if(_VQ.documentElement.nodeName==ExpAPIXml.kEleCommands){return _VQ;}var _0t=Dom.GetElementsByTagName(_VQ,ExpAPIXml.kEleCommands);if(_0t.length==0)return null;return _0t;};CCMBiBusRequest.prototype._tX=function(_VQ){if(_VQ.documentElement.nodeName==ExpAPIXml.kEleRequestState)return _VQ;var _0I=Dom.GetElementsByTagName(_VQ,ExpAPIXml.kEleRequestState);if(_0I.length<1)return null;return _0I[0];};CCMBiBusRequest.prototype.OnCMRequestComplete=function(_VQ,_Vo){var _AK=true;this.oAppObj.commManager.EndResponse(this.sRequestId,_AK);var _afS=Dom.GetElementsByTagName(_VQ,'rns1:addResponse');if(_afS.length<1)_afS=Dom.GetElementsByTagName(_VQ,'rns1:updateResponse');if(_afS.length>0){var _aFx=Dom.GetElementsByTagName(_afS[0],'bus:searchPath');if(_aFx.length>0){var _avm=Dom.GetElementsByTagName(_aFx[0],'bus:value');if(_avm.length>0){var _EG=Dom.GetNodeText(_avm[0]);this.oAppObj.dataManager.SetSearchPath(_EG);}}var _acI=Dom.GetElementsByTagName(_afS[0],'bus:defaultName');if(_acI.length>0){var _avm=Dom.GetElementsByTagName(_acI[0],'bus:value');if(_avm.length>0){var _afK=Dom.GetNodeText(_avm[0]);this.oAppObj.dataManager.SetRealSavedAnalysisName(_afK);}}}if(_Vo){this.oAppObj.commManager._sz.Clear();}this.oAppObj.dataManager.ClientPostProcessing(this.sRequestId);if(this.deferredCallBackOK){this.deferredCallBackOK();this.clearDeferredCallBackFunction();}};CCMBiBusRequest.prototype.PromptRequired=function(_VQ){var _ZO=this._tX(_VQ);if(_ZO&&_ZO.getAttribute(ExpAPIXml.kEleStatus)==ExpAPIXml.kStatusPrompt){return true;}return false;};CCMBiBusRequest.prototype.OnRequestComplete=function(_VQ,_FA,_Kr,_zP,_QS){Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CCMBiBusRequest::OnRequestComplete"]);var _Xg=true;var _Kr=_Kr?_Kr:'';if(_VQ!=null){if(this.GetUserCapabilitiesAndProfiles(_VQ)){return;}else if(this.IsConfigurationResponse(_VQ)){this.GetConfigurationOptions(_VQ);this.GetLineageConfigOptions(_VQ);return;}else if(this.GetRoutingServerGroup(_VQ)){return;}var _akb=this.GetClientState(_VQ);Debug.Assert(_akb,"Server response should contain a client state element");if(!_akb&&(!Debug||!Debug._sj)&&this.oAppObj.commManager.IsBlocked()){CUIDialogMgr.DisplayMessageBox(CUIMessageBox.kCritical,'MES_SERVER_ERROR');return;}var _Ke=this.GetAppName(_akb);Debug.Assert(_Ke!=null);var _AV=this.GetRequestId(_akb);Debug.Assert(_AV==this.sRequestId);var _Mg=this.oAppObj;if(!_Mg.commManager.IgnoreResponse(_AV)){var _ZO=this._tX(_VQ);if(_ZO&&_ZO.getAttribute(ExpAPIXml.kEleStatus)==ExpAPIXml.kStatusOK){_Mg.commManager.SetCurrentResponse(_AV,_QS);var _ajb=this._rx(_VQ);if(_ajb){Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CCMBiBusRequest::OnRequestComplete::ProcessCommands"]);for(var i=0;i<_ajb.length;i++){FindApp(_Ke).dataManager.ProcessCommands(_ajb[i],this.sRequestedMemberId);_Xg=false;}Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CCMBiBusRequest::OnRequestComplete::ProcessCommands"]);}else{CUIDialogMgr.DisplayMessageBox(CUIMessageBox.kInformation,'IDS_SERVER_INTERACTION_SUCCESSFUL');_Xg=false;}Debug.Call(Debug.kUnitHooks,Debug.kStartTimer,["CCMBiBusRequest::OnRequestComplete::PostProcessing"]);_Mg.commManager.EndResponse(_AV);FindApp(_Ke).dataManager.ClientPostProcessing(_AV);Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CCMBiBusRequest::OnRequestComplete::PostProcessing"]);}else{var _ajb=this._rx(_VQ);if(_ajb){for(var i=0;i<_ajb.length;i++){FindApp(_Ke).dataManager._Q(_ajb[i]);}}_Kr=FindApp(_Ke).dataManager.ProcessFailedRequest(_ZO);_agU=FindApp(_Ke).dataManager.GetErrorMsg(_ZO);if(_agU){_FA=_agU;}}}}if(_Xg&&this.oAppObj){this.oAppObj.commManager.SetFailedResponse(this.sRequestId,_FA,_Kr,_zP);if(this.deferredCallBackCancel){this.deferredCallBackCancel();this.clearDeferredCallBackFunction();}}if(this.deferredCallBackOK){this.deferredCallBackOK();this.clearDeferredCallBackFunction();}Debug.Call(Debug.kUnitHooks,Debug.kStopTimer,["CCMBiBusRequest::OnRequestComplete"]);};CCMBiBusRequest.prototype.GetClientState=function(_VQ){var _L8=_VQ.documentElement;if(_L8.nodeName!=ExpAPIXml.kEleClientState){var _aaX=Dom.GetElementsByTagName(_VQ,ExpAPIXml.kEleClientState);if(_aaX.length==0)return null;_L8=_aaX[0];}return _L8;};CCMBiBusRequest.prototype.GetRoutingServerGroup=function(_VQ){var _5v=_VQ.selectSingleNode(Utilities.xPathStringHelper("/SOAP-ENV:Envelope/SOAP-ENV:Body/*/returns/item[0]/queryResult"));if(_5v){var _aaZ=_5v.selectSingleNode("item/routingServerGroup/value");var _I6="";if(_aaZ){_I6=Dom.GetNodeText(_aaZ);}this.oAppObj.uiManager.oDialogMgr._jg.cacheRoutingServerGroup(_I6);return true;}return false;};CCMBiBusRequest.prototype.IsConfigurationResponse=function(_VQ){var _ahh=_VQ.selectSingleNode("/SOAP-ENV:Envelope/SOAP-ENV:Body/bus:getConfigurationResponse/*");if(_ahh){return true;}return false;};CCMBiBusRequest.prototype.GetConfigurationOptions=function(_VQ){var _Do=_VQ.selectSingleNode(Utilities.xPathStringHelper("/SOAP-ENV:Envelope/SOAP-ENV:Body/*/configuration/glossaryURI/item[0]"));var _azL=null;if(_Do){_azL=Dom.GetNodeText(_Do);}if(_azL!=null){this.oAppObj.dataManager._eF.SetProperty("glossaryURI",(_azL==""?CDLConfiguration.K_sDefaultGlossaryURL:_azL));return true;}return false;};CCMBiBusRequest.prototype.GetLineageConfigOptions=function(_VQ){var _Do=_VQ.selectSingleNode(Utilities.xPathStringHelper("/SOAP-ENV:Envelope/SOAP-ENV:Body/*/configuration/"+CDLConfiguration.K_sLineageURL+"/item[0]"));var _azL=null;if(_Do){_azL=Dom.GetNodeText(_Do);}if(_azL!=null){this.oAppObj.dataManager._eF.SetProperty(CDLConfiguration.K_sLineageURL,(_azL==""?CDLConfiguration.K_sDefaultLineageURL:_azL));return true;}return false;};CCMBiBusRequest.prototype.GetUserCapabilitiesAndProfiles=function(_VQ){if(this.GetPackageSupportedCapabilities(_VQ)){if(this.oAppObj.dataManager.HasCapability(CDLCapability.K_sCanUseReportStudio)){this.GetUserSupportedProfiles(_VQ);}return true;}return false;};CCMBiBusRequest.prototype.GetPackageSupportedCapabilities=function(_VQ){var _auZ=_VQ.selectSingleNode(Utilities.xPathStringHelper("/SOAP-ENV:Envelope/SOAP-ENV:Body/*/returns/item[0]/queryResult/item/effectiveUserCapabilities"));if(_auZ){var _AT=this.oAppObj.dataManager;var _R5=_AT.GetUserProfiles();_R5.SetCapabilities(CDLCapability.K_sCanUseReportStudio,(_auZ.selectSingleNode("value/item[text()='"+CDLCapability.K_sCanUseReportStudio+"']")!=null));_R5.SetCapabilities(CDLCapability.K_sCanViewLineage,(_auZ.selectSingleNode("value/item[text()='"+CDLCapability.K_sCanViewLineage+"']")!=null));var _anx=_auZ.selectSingleNode("value/item[text()='"+CDLCapability.K_sCanUseGlossary+"']");if(_anx){_R5.SetCapabilities(CDLCapability.K_sCanUseGlossary,true);this.oAppObj.dataManager.GetGlossaryConfigration();}_R5.SetResponseProcessed(true);return true;}return false;};CCMBiBusRequest.prototype.GetUserSupportedProfiles=function(_VQ){var _5v=_VQ.selectSingleNode(Utilities.xPathStringHelper("/SOAP-ENV:Envelope/SOAP-ENV:Body/*/returns/item[1]/queryResult"));if(_5v){var _AT=this.oAppObj.dataManager;var _R5=_AT.GetUserProfiles();var _aiE=new Object();var nl=_5v.selectNodes(".//item/userInterface/value[text()='reportStudio']");for(var i=0;i<nl.length;i++){if(_o.is_ie5_5up){var _ayn=nl.item(i).parentNode.parentNode;}else{var _ayn=nl[i].parentNode.parentNode;}var _anO=_ayn.selectSingleNode("name/value/item[locale[text()='en']]/value[text()='"+CDLCapability.K_sProfessional+"' or text()='"+CDLCapability.K_sFinancial+"']");if(_anO){_aiE[Dom.GetNodeText(_anO)]=true;}}_R5.SetSupportedProfiles(_aiE);return true;}return false;};CCMBiBusRequest.prototype.GetAppName=function(_L8){var _1V=Dom.GetElementsByTagName(_L8,ExpAPIXml.kEleAppName);if(_1V.length==0)return null;var _aiM=_1V[0];var _aih=Dom.GetNodeText(Dom.GetImmediateChildByName(_aiM,ExpAPIXml.kEleValue));return _aih;};CCMBiBusRequest.prototype.GetRequestId=function(_L8){var _aij=Dom.GetImmediateChildByName(_L8,ExpAPIXml.kEleRequestId);return Dom.GetNodeText(_aij);};CCMBiBusRequest.prototype.CancelNotify=function(_ST,_Je){if(!this._n1.IsRequestCancelable(this.sRequestId)){return;}var _RH=this._n1.GetRequestObject(this.sRequestId);if(_RH&&(_RH instanceof CDLSearchResult)){_RH.SetCancelParam(_ST,_Je);_RH.Notify(ExpEvent.kCDLSearchResult_Cancellable);return;}if(this.oAppObj.uiManager._jf){this.oAppObj.uiManager._jf.Refresh(_ST,_Je);}if(this.oAppObj.uiManager._qi){if(_RH){this.oAppObj.uiManager._qi.ShowCancel(_RH._ks,_ST,_Je);}}};var _s=0;var _j=null;var _i=null;CBIBus.k_iPollPromptWindow=1000;function CBIBus(_MI,_E5,_Wr){if(_MI.indexOf("http:")<0){this._cd="http://www.ibm.com/xmlns/prod/cognos/"+_MI;}else{this._cd=_MI;}this._wr=_E5?_E5:null;this._bR=_Wr;};CBIBus.prototype.Send=function(_CW,_C2,_Ap){if(_CW===null||_CW===''){return;}if(_Ap){CBIBus.bIsInit=true;}else{CBIBus.bIsInit=false;}if(_C2==null){_C2=this._bR.getRequestTracking();_j=_CW;CBIBus.biBus=this;}_CW=_CW.replace("@TRACKING@",_C2);this.m_bAbortedRequest=false;try{this.m_oXMLHTTP=_c.CreateHTTPObject();}catch(e){throw new COTXMLHttpException();}if(_s==1)alert('ready to send '+_CW+"to "+this._bR.GetGatewayURL());if(_o.is_supported){this.m_oXMLHTTP.Open("POST",this._bR.GetGatewayURL(),true);}else{try{netscape.security.PrivilegeManager.enablePrivilege('UniversalBrowserRead');this.m_oXMLHTTP.Open("POST",this._bR.GetGatewayURL(),true);netscape.security.PrivilegeManager.revertPrivilege('UniversalBrowserRead');}catch(e){if(Debug&&Debug._sj){alert('Refresh and grant privileges to continue. \n Make sure that prefs.js has been modified as per the "HowToRunInNetscape" page on the Wiki site');}return;}}var _alJ=CBIBus.m_iRequestID++;CBIBus.m_oRequests[_alJ]=this;this.m_fnOnReadyStateChange=Utilities.GenerateCallback(CBIBus.OnReadyStateChange,[_alJ]);_c.SetLoadCallback(this.m_oXMLHTTP,this.m_fnOnReadyStateChange);this.m_oXMLHTTP.setRequestHeader("Content-Type","text/xml; charset=utf-8");this.m_oXMLHTTP.setRequestHeader("SOAPAction",this._cd);this.m_oXMLHTTP.Send(_CW);CBIBus.m_sLastSOAPRequest=_CW;};CBIBus.prototype.SendSynch=function(_CW){if(_CW===null||_CW===''){return;}var _C2=this._bR.getRequestTracking();if(_C2){_j=_CW;CBIBus.biBus=this;_CW=_CW.replace("@TRACKING@",_C2);this.m_bAbortedRequest=false;this.m_oXMLHTTP=_c.CreateHTTPObject();if(_s==1)alert('ready to send Synchronous'+_CW+"to "+this._bR.GetGatewayURL());if(_o.is_ie5_5up||_o.is_firefox){this.m_oXMLHTTP.Open("POST",this._bR.GetGatewayURL(),false);}else{try{netscape.security.PrivilegeManager.enablePrivilege('UniversalBrowserRead');this.m_oXMLHTTP.Open("POST",this._bR.GetGatewayURL(),false);netscape.security.PrivilegeManager.revertPrivilege('UniversalBrowserRead');}catch(e){if(Debug&&Debug._sj){alert('Refresh and grant privileges to continue. \n Make sure that prefs.js has been modified as per the "HowToRunInNetscape" page on the Wiki site');}return;}}this.m_oXMLHTTP.setRequestHeader("Content-Type","text/xml; charset=utf-8");this.m_oXMLHTTP.setRequestHeader("SOAPAction",this._cd);this.m_oXMLHTTP.Send(_CW);}};CBIBus.prototype.Abort=function(){this.m_bAbortedRequest=true;if(this.m_oXMLHTTP){this.m_oXMLHTTP.abort();delete this.m_oXMLHTTP;}};CBIBus.prototype.getResponseErrorMsg=function(_VQ){var _7e=Dom.GetElementsByTagName(_VQ,'bus:messageString');if(_7e.length==0){_7e=Dom.GetElementsByTagName(_VQ,'messageString');}var _auB=new Array();for(var i=0;i<_7e.length;i++){_auB.push(Dom.GetNodeText(_7e[i]));}if(_auB.length>0){return _auB;}return _c.ToString(_VQ);};CBIBus.prototype.showErrors=function(_yF,_VQ){if(this.m_winError&&!this.m_winError.closed){this.m_winError.close();}if(_VQ){var _apY=_c.ToString(_VQ);this.m_docSOAPFault=null;var _8u=document.getElementById("idServerErrorMsgForm");_8u.action=this._bR.GetGatewayURL();_8u.soapFault.value=_apY;if(this._bR.isRunning){_8u.target="rsServerErr_"+(new Date()).getTime();this.m_winError=window.open("",_8u.target,"directories=no,location=no,status=no,toolbar=no,resizable=yes,scrollbars=yes,top=100,left=100,height=480,width=640");this.m_winError.focus();}else{_8u.target=window.name;}_8u.submit();}else{if(!Debug||!Debug._sj){CUIDialogMgr.DisplayMessageBox(CUIMessageBox.kCritical,'MES_SERVER_ERROR');}else{var _azp="rsServerErr_"+(new Date()).getTime();this.m_winError=window.open("",_azp,"directories=no,location=no,status=no,toolbar=no,resizable=yes,scrollbars=yes,top=100,left=100,height=480,width=640");var _BA=this.m_winError.document;_BA.open();var _aeU=_yF.responseText;_BA.write(_aeU?_aeU:"Unknown BI Bus Error. Please ensure the server is running.");_BA.close();_BA.title="BI Bus Error";this.m_winError.focus();}}};CBIBus.prototype.onRequestCompleted=function(){this.m_oXMLHTTP.onreadystatechange=Utilities.DoNothing;if(!this.m_bAbortedRequest){this.processResponse();}};CBIBus.prototype.authenticationRequired=function(_VQ){var _zJ="";var _agl=Dom.GetElementsByTagName(_VQ,'bus:biBusHeader');var _0Y=new Array();if(_agl.length==1){_0Y=Dom.GetElementsByNameNoNS(_agl[0],'CAM');}var _au5=new Array();if(_0Y.length==1){_au5=Dom.GetElementsByNameNoNS(_0Y[0],'exception');}var _aGH=new Array();if(_au5.length==1){_aGH=Dom.GetElementsByNameNoNS(_au5[0],'promptInfo');}var _anr=new Array();if(_aGH.length==1){_anr=Dom.GetElementsByNameNoNS(_aGH[0],'displayObjects');_zJ=(CBIBus.biBus._bR.GetGatewayURL()+"?b_action=xts.run&m=portal/close.xts");if(_anr.length==1){var _PM=new Array();_PM=Dom.GetImmediateChildrenByName(_anr[0],'item');for(var i=0;i<_PM.length;i++){if(Dom.GetNodeTextShallowNoNS(_PM[i],'type')=='hidden'){var name=(Dom.GetNodeTextShallowNoNS(_PM[i],'name'));var _UN=(Dom.GetNodeTextShallowNoNS(_PM[i],'value'));_zJ=_zJ+"&"+name+"="+_UN;}}}_zJ+="&md.callBack=";}return _zJ;};CBIBus.prototype.getAuthenticityToken=function(){if(!this._jH){try{this._jH=(new CAMAuthenticityTokenSession()).generate();}catch(e){}}return this._jH;};CBIBus.prototype.createSOAPRequest=function(_CW){var _adJ=CBIBus.m_sSOAPTemplate;var _acL="";var _agh=this.getAuthenticityToken();if(_agh){_acL=CBIBus.m_sSOAPCAM.replace("@AUTHENTICITYTOKEN@",_agh);}var _az2="";if(this._bR.GetRoutingServerGroup()){_az2=CBIBus.m_sSOAPRouting.replace("@SERVERNAME@",Utilities.HtmlEncode(this._bR.GetRoutingServerGroup()));}_adJ=_adJ.replace("@PRODLOCALE@",this._bR._aB);_adJ=_adJ.replace("@ROUTING@",_az2);_adJ=_adJ.replace("@CAM@",_acL);_adJ=_adJ.replace("@REQUEST@",_CW);_adJ=_adJ.replace("@CAFCONTEXTID@",this._bR.GetCAFContextID());_adJ=_adJ.replace("@CACHECONTEXTOPTION@",'');return _adJ;};CBIBus.prototype.createWaitCommand=function(_GA){this._cd="http://www.ibm.com/xmlns/prod/cognos/reportService/201505/.absolute";var _2q=CBIBus.m_sWaitTemplate;var _acV=CBIBus.m_sParametersTemplate;_2q=_2q.replace("@CONVERSATION@",_GA);_2q=_2q.replace("@PARAMETERS@",_acV);var _aBn=this.createSOAPRequest(_2q);return _aBn;};CBIBus.prototype.getServerState=function(_VQ){var _ag0=null;var _apP=Dom.GetElementsByTagName(_VQ,'bus:primaryRequest');if(_apP[0]){var _XE=Dom.GetElementsByTagName(_apP[0],'bus:specification');if(_XE[0]){var item=Dom.GetElementsByTagName(_XE[0],'item');if(item[0]){_UN=Dom.GetElementsByTagName(item[0],'bus:value');if(_UN[0]){_ag0=Dom.GetNodeText(_UN[0]);}}}}return _ag0;};CBIBus.prototype.getConversationContext=function(_VQ){var _GA='<bus:conversation xsi:type="bus:asynchRequest"/>';var _aE2=Dom.GetElementsByTagName(_VQ,'bus:primaryRequest');if(_aE2&&_aE2.length>0){var _5I=_c.ToString(_aE2[0]);var _atq=/bus:primaryRequest/gi;_GA=_5I.replace(_atq,"bus:conversation");}return _GA;};CBIBus.prototype.getTracking=function(_VQ){var _C2=null;var _Je=Dom.GetElementsByTagName(_VQ,'bus:tracking');if(_Je.length==0){_Je=Dom.GetElementsByTagName(_VQ,'tracking');}if(_Je.length>0){_C2=_c.ToString(_Je[0]);}return _C2;};CBIBus.prototype.getRequestStatus=function(_VQ){var _ZU=null;var _amg=Dom.GetElementsByTagName(_VQ,'bus:conversationContext');if(_amg[0]){var status=Dom.GetElementsByTagName(_amg[0],'bus:status');if(status[0]){_ZU=Dom.GetNodeText(status[0]);}}return _ZU;};CBIBus.prototype.onCancelNotify=function(_ST,_Je){if(this._wr){this._wr.CancelNotify(_ST,_Je);}};CBIBus.prototype.getQFCommand=function(_VQ){var _afu=null;var _6t=Dom.GetElementsByTagName(_VQ,ExpAPIXml.kEleQFCommand);if(!_6t||(_6t&&(!(_6t.length>0)))){_6t=Dom.GetElementsByTagName(_VQ,ExpAPIXml.kEleQFCommandNoPreFix);}if(_6t.length>0){_afu=_6t[0];}if(_afu){return _c.ToString(_afu);}var _7S=null;var _5c=Dom.GetElementsByTagName(_VQ,ExpAPIXml.kEleQFReport);if(_5c&&_5c.length>0){_7S=_5c[0];}if(_7S){return _c.ToString(_7S);}return '';};CBIBus.prototype.processResponse=function(){if(_s==1)alert('processing response '+this.m_oXMLHTTP.responseText);var _yF=this.m_oXMLHTTP;delete this.m_oXMLHTTP;var _VQ=null;try{_VQ=_yF.responseXML;}catch(e){_VQ=null;}var _ZU=null;if(_VQ){if(CBIBus.bIsInit||this._bR._bf._m0){CBIBus.sLastSoapResonse=_c.ToString(_VQ);}var _zJ=this.authenticationRequired(_VQ);var _LG=null;if(_zJ!=""){if(this._wr){_LG=this._wr.sRequestId;}CBIBus.Logon(_zJ,_LG);return;}try{_ZU=this.getRequestStatus(_VQ);}catch(e){_ZU=null;}}else{CBIBus.sLastSoapResonse='null soap response received!';}if(_ZU!=null){var _Je=this.getTracking(_VQ);if(_ZU==ExpAPIXml.kStatusWorking||_ZU==ExpAPIXml.kStatusStillWorking){var _ST=this.getConversationContext(_VQ);if(_ST!=null){if(_ZU==ExpAPIXml.kStatusWorking){this.onCancelNotify(_ST,_Je);}var _ae7=this.createWaitCommand(_ST);this.Send(_ae7,_Je,CBIBus.bIsInit);return;}}var _QS=this.getServerState(_VQ);var _aoX=Dom.GetElementsByTagName(_VQ,'rns1:editAnalysisSpecificationResponse');if(_aoX.length==0){_aoX=Dom.GetElementsByTagName(_VQ,'rns1:editAnalysisResponse');}if(_aoX.length==0){if(_ZU=='complete'){_aoX=Dom.GetElementsByTagName(_VQ,'rns1:waitResponse');}}if(_aoX.length>0){if(CBIBus.bIsInit){this._bR.dataManager.CreateUserCapabilityProfile();this._bR.dataManager.CheckGlobalUserCapability(_VQ);this._bR.dataManager.CreateConfiguration();this._bR.dataManager.CheckConfiguration(_VQ);}var _aH1=Dom.GetElementsByTagName(_aoX[0],'bus:outputPages');var _aoZ=Dom.GetElementsByTagName(_aH1[0],'item');var _alU=Dom.GetNodeText(_aoZ[0]);var _5g=Debug&&Debug._sj;var _aBv=_c.LoadString(_alU,true,_5g,true);_VQ=_aBv;}else{this._bR.dataManager.CheckGlobalUserCapability(_VQ);var _agM=Dom.GetElementsByTagName(_VQ,'rns1:cancelResponse');if(_agM.length>0){this._bR.addRequestTracking(_Je);return;}else{var _XS=Dom.GetElementsByTagName(_VQ,'rns1:addResponse');if(_XS.length>0){if(this._wr){if(this._bR.commManager.oBlockedObject&&(this._bR.commManager.oBlockedObject instanceof CDLWorksheet)){if(Utilities.GetObjIndexFromObjArray(this._bR.commManager.oBlockedObject._ak._mw,ExpEvent.kCDLWorksheet_SaveForEditSuccess)>=0){this._wr.OnCMRequestComplete(_VQ,false);return;}}this._wr.OnCMRequestComplete(_VQ,true);}return;}else{var _XS=Dom.GetElementsByTagName(_VQ,'rns1:updateResponse');if(_XS.length>0){if(this._wr){this._wr.OnCMRequestComplete(_VQ,true);}return;}}}}this._bR.addRequestTracking(_Je);}if(_VQ&&_VQ.documentElement){var _aeR=Dom.GetElementsByTagName(_VQ,'SOAP-ENV:Fault');if(_aeR.length==0){if(this._wr){if(this._wr.PromptRequired(_VQ)){this.invokePrompt(_VQ,this._wr.sRequestId);}else{if(this._bR._wJ._mE){_QS=_VQ;}this._wr.OnRequestComplete(_VQ,null,null,false,_QS);if(!this._bR.dataManager.IsResponseProcessed()){this._bR.commManager. SearchUserCapabilityAndProfiles();}}return;}return;}Debug.Print("BI Bus Error:");Debug.Print(_aeR.xml);if(this._wr&&this._bR.isRunning){var _7R=this.getResponseErrorMsg(_VQ);var _aFr=_7R[0];var _apx='';for(var _aIW=1;_aIW<_7R.length;_aIW++){_apx+=_7R[_aIW]+'\n';}this._wr.OnRequestComplete(null,_aFr,_apx);return;}this.showErrors(_yF,_VQ);return;}var _Zp="";try{_Zp=_yF.statusText;}catch(e){_Zp="";}Debug.Print("Unknown BI Bus Error:"+_Zp);this.showErrors(_yF,null);if(this._wr){this._wr.OnRequestComplete(null);}return;};CBIBus.prototype.invokePrompt=function(_VQ,_LG){var _aGn=this.getQFCommand(_VQ);var _Rh=this._bR.commManager.GetParameterValues();var _71=document.getElementById("idInvokePromptForm");_71.target="InvokePromptForm";_71.action=this._bR.GetGatewayURL();_71.specification.value=_aGn;if(this._bR.GetRoutingServerGroup()){if(!_71.routingServerGroup)_71.appendChild(createHiddenFormField("routingServerGroup",this._bR.GetRoutingServerGroup()));else _71.routingServerGroup.value=this._bR.GetRoutingServerGroup();}if(_Rh){_71.parameterValues.value=_Rh;}_i=window.open("about:blank",_71.target,"menubar=no,directories=no,location=no,status=no,toolbar=no,resizable=yes,scrollbars=yes,alwaysRaised=yes,top=100,left=100,height=310,width=630");_71.submit();var _6z=Utilities.GenerateCallback(CBIBus.CheckPromptWindowState,[_LG]);setTimeout(_6z,CBIBus.k_iPollPromptWindow);};function ccModalCallBack(_Vc,_F6){if(_Vc.indexOf("ok")!=-1){if(_j.indexOf("<bus:CAM")!=-1){var _apZ='<id xsi:type="xsd:string">';var _4I=_j.indexOf(_apZ);var _amz=_j.indexOf('</id>');if(_4I!=-1){_4I+=_apZ.length;var _aJT=_j.substring(0,_4I);var _agh=CBIBus.getAuthenticityToken();if(_agh){_aJT+=_agh;}if(_amz!=-1){_aJT+=_j.substring(_amz,_j.length);_j=_aJT;}}}CBIBus.biBus.Send(_j,null,CBIBus.bIsInit);_i=null;}else{CBIBus.OnPromptClosed();}};function pdsCallback(_zv){var _aaF=_zv.parameters;if(_aaF&&_aaF.length>0&&CBIBus.biBus){var _7L="";for(var i=0;i<_aaF.length;i++){_7L+=decodeURIComponent(_aaF[i]);}if(_j.indexOf("@PARAMETERVALUES@")!=-1){_j=_j.replace("@PARAMETERVALUES@",_7L);}else{var _aBY=_j.indexOf('<item xsi:type="bus:parameterValue');if(_aBY!=-1){var _aJT=_j.substring(0,_aBY);_aJT+=_7L;var _aEW=_j.indexOf('</parameterValues>');if(_aEW!=-1){_aJT+=_j.substring(_aEW,_j.length);_j=_aJT;}}}CBIBus.biBus._bR.commManager.SetParameterValues(_7L);CBIBus.biBus.Send(_j,null,CBIBus.bIsInit);_i=null;}else{CBIBus.OnPromptClosed();}};CBIBus.Logon=function(_zJ,_LG){/*@if(!@bering_debug)@*/try{/*@end@*/_i=window.open(_zJ,"_blank","directories=no,location=no,status=no,toolbar=no,resizable=yes,scrollbars=yes,top=100,left=100,height=310,width=630");var _6z=Utilities.GenerateCallback(CBIBus.CheckPromptWindowState,[_LG]);setTimeout(_6z,CBIBus.k_iPollPromptWindow);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CBIBus.CheckPromptWindowState=function(_LG){/*@if(!@bering_debug)@*/try{/*@end@*/if(_i){if(_i.closed){CBIBus.OnPromptClosed(_LG);}else{var _6z=Utilities.GenerateCallback(CBIBus.CheckPromptWindowState,[_LG]);setTimeout(_6z,CBIBus.k_iPollPromptWindow);}}/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CBIBus.OnPromptClosed=function(_LG){/*@if(!@bering_debug)@*/try{/*@end@*/var _arI=CBIBus.biBus._wr;if(_arI){if(_LG&&(_arI.sRequestId!=_LG)){return;}CBIBus.biBus._wr.OnRequestComplete(null,null,null,true);if(CBIBus.bIsInit==true){window.close();}if(_i){_i.close();_i=null;}}return;/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};CBIBus.Logoff=function(){};CBIBus.m_sSOAPCAM='<bus:CAM xsi:type="bus:CAM">'+'<authenticityToken xsi:type="xsd:base64Binary">'+'@AUTHENTICITYTOKEN@'+'</authenticityToken>'+'</bus:CAM>';CBIBus.m_sSOAPRouting='<bus:routing>'+'<routingServerGroup>@SERVERNAME@</routingServerGroup>'+'</bus:routing>';CBIBus.m_sSOAPTemplate='<SOAP-ENV:Envelope SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:bus="http://developer.cognos.com/schemas/bibus/3/">'+'<SOAP-ENV:Header>'+'<bus:biBusHeader xsi:type="bus:biBusHeader">'+'@TRACKING@'+'@ROUTING@'+'@CAM@'+'<bus:CAF xsi:type="bus:CAF">'+'<bus:contextID xsi:type="xs:string">'+'@CAFCONTEXTID@'+'</bus:contextID>'+'</bus:CAF>'+'<bus:dispatcherTransportVars xsi:type="SOAP-ENC:Array" SOAP-ENC:arrayType="bus:dispatcherTransportVar[]">'+'<item xsi:type="bus:dispatcherTransportVar">'+'<name xsi:type="xsd:string">as</name>'+'<value xsi:type="xsd:string">true</value>'+'</item>'+'</bus:dispatcherTransportVars>'+'<bus:userPreferenceVars SOAP-ENC:arrayType="bus:userPreferenceVar[]" xsi:type="SOAP-ENC:Array">'+'<item>'+'<bus:name xsi:type="xsd:string">productLocale</bus:name>'+'<bus:value xsi:type="xsd:string">@PRODLOCALE@</bus:value>'+'</item>'+'</bus:userPreferenceVars>'+'</bus:biBusHeader>'+'</SOAP-ENV:Header>'+'<SOAP-ENV:Body>@REQUEST@</SOAP-ENV:Body>'+'</SOAP-ENV:Envelope>';CBIBus.m_sWaitTemplate='<wait xmlns="http://developer.cognos.com/schemas/reportService/1">'+'@CONVERSATION@'+'@PARAMETERS@'+'</wait>';CBIBus.m_sParametersTemplate='<parameterValues SOAP-ENC:arrayType="bus:parameterValue[]" xsi:type="SOAP-ENC:Array"/>'+'<options SOAP-ENC:arrayType="bus:option[]" xsi:type="SOAP-ENC:Array">'+'<item xsi:type="bus:asynchOptionEncoding">'+'<bus:name xsi:type="bus:asynchOptionEnum">attachmentEncoding</bus:name>'+'<bus:value xsi:type="bus:encodingEnum">base64</bus:value>'+'</item>'+'<item xsi:type="bus:asynchOptionInt">'+'<bus:name xsi:type="bus:asynchOptionEnum">primaryWaitThreshold</bus:name>'+'<bus:value xsi:type="xsd:int">7</bus:value>'+'</item>'+'<item xsi:type="bus:runOptionString">'+'<bus:name xsi:type="bus:runOptionEnum">promptFormat</bus:name>'+'<bus:value xsi:type="xsd:string">HTML</bus:value>'+'</item>'+'</options>';CBIBus.m_oRequests=new Object();CBIBus.m_iRequestID=1;CBIBus.OnReadyStateChange=function(_AV){var _afD=CBIBus.m_oRequests[_AV];if(_afD.m_oXMLHTTP.readyState==4){delete CBIBus.m_oRequests[_AV];_afD.onRequestCompleted();}};CBIBus.GetLastSoapRequest=function(){CopyToClipboard('text',CBIBus.m_sLastSOAPRequest);};CBIBus.GetLastSoapResponse=function(){CopyToClipboard('text',CBIBus.sLastSoapResonse);};function CopyToClipboard(_Ac,_HJ){if(_Ac!='text'||(typeof _HJ!="string")||_HJ==''){return false;}if(_o.is_ie5_5up){clipboardData.setData(_Ac,_HJ);return;}netscape.security.PrivilegeManager.enablePrivilege('UniversalXPConnect');var _Np=Components.classes["@mozilla.org/supports-string;1"]. createInstance(Components.interfaces.nsISupportsString);if(!_Np)return false;_Np.data=_HJ;var _ayq=Components.classes["@mozilla.org/widget/transferable;1"]. createInstance(Components.interfaces.nsITransferable);if(!_ayq)return false;_ayq.addDataFlavor("text/unicode");_ayq.setTransferData("text/unicode",_Np,_HJ.length*2);var _Xm=Components.interfaces.nsIClipboard;var _aCG=Components.classes["@mozilla.org/widget/clipboard;1"].getService(_Xm);if(!_aCG)return false;_aCG.setData(_ayq,null,_Xm.kGlobalClipboard);return true;};function PasteFromClipboard(_Ju){if(_o.is_ie5_5up){Debug.Assert(_Ju=="text");return clipboardData.getData(_Ju);}netscape.security.PrivilegeManager.enablePrivilege('UniversalXPConnect');this.clipboardid=Components.interfaces.nsIClipboard;this.clipboard=Components.classes['@mozilla.org/widget/clipboard;1'].getService(this.clipboardid);this.clipboardstring=Components.classes['@mozilla.org/supports-string;1'].createInstance(Components.interfaces.nsISupportsString);netscape.security.PrivilegeManager.enablePrivilege('UniversalXPConnect');var _aBI=Components.classes['@mozilla.org/widget/transferable;1'].createInstance(Components.interfaces.nsITransferable);_aBI.addDataFlavor('text/unicode');this.clipboard.getData(_aBI,this.clipboardid.kGlobalClipboard);var _Np=new Object();var _4P=new Object();_aBI.getTransferData('text/unicode',_Np,_4P);_Np=_Np.value.QueryInterface(Components.interfaces.nsISupportsString);var _aIP=_Np.toString();return _aIP;};if(document.implementation.hasFeature("XPath","3.0")){XMLDocument.prototype.selectSingleNode=function(_Mk,_Nr){var _aq7=this.selectNodes(_Mk,_Nr);if(_aq7.length>0){return _aq7[0];}else{return null;}};Element.prototype.selectSingleNode=function(_Mk){if(this.ownerDocument.selectSingleNode){return this.ownerDocument.selectSingleNode(_Mk,this);}else{throw "For XML Elements Only";}};XMLDocument.prototype.selectNodes=function(_Mk,_Nr){var _Xd=[];var _aym=_Mk;if(!_Nr){_Nr=this;}try{var _afn=this.createNSResolver(this.documentElement);if(_aym.indexOf('rns1:')!=-1||_aym.indexOf('SOAP-ENV:')!=-1||_aym.indexOf('SOAP-ENC:')!=-1||_aym.indexOf('qs:')!=-1||_aym.indexOf('cm:')!=-1){var _TC=this.evaluate(_aym,_Nr,nsResolver,XPathResult.UNORDERED_NODE_SNAPSHOT_TYPE,null);}else{var _TC=this.evaluate(_aym,_Nr,_afn,XPathResult.UNORDERED_NODE_SNAPSHOT_TYPE,null);}for(var i=0;i<_TC.snapshotLength;i++){_Xd[i]=_TC.snapshotItem(i);}}catch(e){}return _Xd;};function nsResolver(prefix){var ns={'rns1':'http://developer.cognos.com/schemas/reportService/1','SOAP-ENV':'http://schemas.xmlsoap.org/soap/envelope/','SOAP-ENC':'http://schemas.xmlsoap.org/soap/encoding/','bus':'http://developer.cognos.com/schemas/bibus/3/','xsi':'http://www.w3.org/2001/XMLSchema-instance','xs':'http://www.w3.org/2001/XMLSchema','xsd':'http://www.w3.org/2001/XMLSchema','qs':'http://developer.cognos.com/schemas/qsapi/2/','cm':'http://developer.cognos.com/schemas/bibus/3/'};return ns[prefix]||null;};Element.prototype.selectNodes=function(_Mk){if(this.ownerDocument.selectNodes){return this.ownerDocument.selectNodes(_Mk,this);}else{throw "For XML Elements Only";}};XMLDocument.prototype.nodeFromID=function(_FG){return this.getElementById(_FG);};XMLDocument.prototype.loadXML=function(_Jk){var _BA=(new DOMParser()).parseFromString(_Jk,"text/xml");if(_BA.childNodes[0].tagName=='parsererror'){return false;}while(this.hasChildNodes()){this.removeChild(this.lastChild);}var _Xk=_BA.childNodes.length;for(var i=0;i<_Xk;i++){this.appendChild(this.importNode(_BA.childNodes.item(i),true));}return true;};XMLDocument.prototype.__defineGetter__("parseError",function(){var _aI4='http://www.mozilla.org/newlayout/xml/parsererror.xml';var n=this.documentElement;var _apb={};_apb.errorCode=0;if(n.nodeName=='parsererror'&&n.namespaceURI==_aI4){_apb.errorCode=1;var _ajg=n.getElementsByTagNameNS(_aI4,'sourcetext')[0];if(_ajg!=null){_apb.srcText=_ajg.firstChild.data;}var _XZ=n.firstChild.data;var _aJD=_XZ.indexOf("Location: ");var _aIk=_aJD+(String("Location: ").length);var _aI6=_XZ.indexOf("Line Number ");var _anq=_aI6+(String("Line Number ").length);var _azz=_XZ.indexOf("Column ");var _aJG=_azz+(String("Column ").length);if(_aJD!=-1&&_aI6!=-1&&_azz!=-1){_apb.reason=_XZ.substring(0,_aJD);_apb.url=_XZ.substring(_aIk,_aI6);_apb.line=_XZ.substring(_anq,_azz);_apb.line=parseInt(_apb.line,10);_apb.linepos=_XZ.substring(_aJG);_apb.linepos=parseInt(_apb.linepos,10);}else{_apb.reason=n.firstChild.data;}}return _apb;});};var _c=new Object();_c.NODE_ELEMENT=1;_c.NODE_ATTRIBUTE=2;_c.NODE_TEXT=3;_c.NODE_CDATA_SECTION=4;_c.NODE_ENTITY_REFERENCE=5;_c.NODE_ENTITY=6;_c.NODE_PROCESSING_INSTRUCTION=7;_c.NODE_COMMENT=8;_c.NODE_DOCUMENT=9;_c.NODE_DOCUMENT_TYPE=10;_c.NODE_DOCUMENT_FRAGMENT=11;_c.NODE_NOTATION=12;_c.CreateDocument=function(){if(_o.is_ie5_5up){try{var _BA=new ActiveXObject("Msxml2.DOMDocument.3.0");}catch(e){var _BA=new ActiveXObject("Microsoft.XMLDOM");}_BA.validateOnParse=false;_BA.async=false;}else{var _BA=document.implementation.createDocument("","",null);}return _BA;};_c.SetResource=function(_Co){_c.oRes=_Co;};_c.CreateHTTPObject=function(){return _c.CreateHTTPObjectImpl();};_c.bJSUnitTest=false;_c.CreateHTTPObjectImpl=function(){var _yF=null;if(_c.bJSUnitTest){_yF=new MockXmlHttpRequest();}else{if(_o.is_ie5_5up){try{_yF=new ActiveXObject("Msxml2.XMLHTTP.3.0");}catch(e){_yF=new ActiveXObject("Microsoft.XMLHTTP");}}else{_yF=new XMLHttpRequest();_yF.Send=_yF.send;_yF.Open=_yF.open;}}return _yF;};_c.CreateFakeHTTPObject=function(){return new FakeHTTPObject();};function FakeHTTPObject(){};FakeHTTPObject.prototype.Open=function(v1,v2,v3){};FakeHTTPObject.prototype.setRequestHeader=function(v1,v2,v3){};FakeHTTPObject.prototype.Send=function(_CW){};_c.SetLoadCallback=function(_Gb,_OM){if(_o.is_ie5_5up){_Gb.onreadystatechange=_OM;}else{_Gb.onload=_OM;}};_c.LoadDocument=function(_SM,_CA,_D8,_LU){var d=_c.CreateDocument();d.async=false;d.validateOnParse=(_CA!=false);d.preserveWhiteSpace=(_LU==true);try{if(!d.load(_SM)){if(!_D8){var _ZJ=d.parseError;}return null;}}catch(e){if(!_D8){var _ZJ=d.parseError;}return null;}return d;};_c.LoadString=function(_VE,_B4,_Ms,_UK){if(_o.is_ie5_5up){return _c.LoadStringIE(_VE,_B4,_Ms,_UK);}else{return _c.LoadStringNS(_VE,_B4,_Ms,_UK);}};_c.LoadStringIE=function(_VE,_B4,_Ms,_UK){try{var _BA=new ActiveXObject("Msxml2.DOMDocument.3.0");}catch(e){var _BA=new ActiveXObject("Microsoft.XMLDOM");}_BA.async=false;_BA.validateOnParse=(_B4!=false);_BA.preserveWhiteSpace=(_UK==true);if(_o.is_ie5_5up){_BA.setProperty("SelectionLanguage","XPath");_BA.setProperty("SelectionNamespaces",'xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" xmlns:bus="http://developer.cognos.com/schemas/bibus/3/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:qs="http://developer.cognos.com/schemas/qsapi/2/"');}try{if(!_BA.loadXML(_VE)){if(!_Ms){var _YK=_BA.parseError;this._m3(_YK);}return null;}}catch(e){if(!_Ms){var _YK=_BA.parseError;this._m3(_YK);}return null;}return _BA;};_c.LoadStringNS=function(_VE,_B4,_Ms,_UK){var _apy=new DOMParser();var _ajO=_apy.parseFromString(_VE,"text/xml");if(!_UK){var _adT=new DomTreeWalker(_ajO);while(_adT.MoveToNext()!=DomTreeWalker.eNoNext){if(_adT.GetElement().nodeType==_c.NODE_TEXT){var _aBN=_adT.GetElement().nodeValue;if(!_aBN.match(/\S+/)){_adT.GetElement().nodeValue="";}}}}return _ajO;};_c._m3=function(_Pl){if((Debug&&Debug._sj)||!_c.oRes){if(_Pl){alert("XML Error. Reason: "+_Pl.reason+". URL: "+_Pl.url+" Line: "+_Pl.line+" pos: "+_Pl.linepos+" Source: "+_Pl.srcText);}else{alert("XML Parsing Error Encountered");}}else{CUIDialogMgr.DisplayMessageBox(CUIMessageBox.kCritical,'MES_XML_LOADSTRING_ERROR');}};_c.ToString=function(_Do){if(_o.is_ie5_5up){return _Do.xml;}else{var s=new XMLSerializer();var _Np=s.serializeToString(_Do);return _Np;}};_c.CreateElement=function(_L1,_zu,_CT,_Vt){var _aEe='';if(_Vt){for(var i in _Vt){_aEe+=' '+i+'="'+_Vt[i]+'"';}}if(_CT){var _6W='<'+_L1+_aEe+'>'+_zu+'</'+_L1+'>';}else{var _6W='<'+_L1+Utilities.HtmlEncode(_aEe)+'>'+Utilities.HtmlEncode(_zu)+'</'+_L1+'>';}return _6W;};_c.RemoveXMLPI=function(_Jk){return _Jk.replace(/^<\?xml.*?\?>/i,"");};_c.CleanupCRLF=function(_Jk){var _0W=/\n/;if(_0W.test(_Jk)){var _az9=/\r/;if(!_az9.test(_Jk)){return _Jk.replace(/\n/g,"\r\n");}}return _Jk;};function XMLLoader(){};XMLLoader.m_bPreventFileCaching=true;XMLLoader.F_SetCaching=function(_QU){this.m_bPreventFileCaching=_QU;};XMLLoader.prototype.Load=function(_NW,_Vd,_Lm){var _Kp=new Object();var _all=new Array();for(var i=0;i<_Vd.length;i++){var _asj=XMLLoader.m_iRequestID;XMLLoader.m_iRequestID++;var _27=new Object();XMLLoader.m_oRequests[_asj.toString()]=_27;_27.m_oFileCache=_Kp;_27.m_oListener=_NW;_27.m_sFile=_Vd[i];_27.m_sFullFilePath=_Lm?(_Lm+_Vd[i]):_Vd[i];_27.m_oXMLHTTP=_c.CreateHTTPObject();_27.m_oXMLHTTP.open("GET",_27.m_sFullFilePath,true);if(XMLLoader.m_bPreventFileCaching){_27.m_oXMLHTTP.setRequestHeader("If-Modified-Since","Thu, 01 Jan 1970 00:00:00 GMT");}_27.m_fnOnReadyStateChange=Utilities.GenerateCallback(XMLLoader.F_OnReadyStateChange,[_asj]);_c.SetLoadCallback(_27.m_oXMLHTTP,_27.m_fnOnReadyStateChange);_all.push(_27.m_oXMLHTTP);}for(var i=0;i<_all.length;i++){_all[i].send("");}};XMLLoader.m_oRequests=new Object();XMLLoader.m_iRequestID=1;XMLLoader.F_OnReadyStateChange=function(_AW){var _27=XMLLoader.m_oRequests[_AW];if(_27.m_oXMLHTTP.readyState==4){_c.SetLoadCallback(_27.m_oXMLHTTP,Utilities.DoNothing);delete XMLLoader.m_oRequests[_AW];var _Zl=0;for(var s in XMLLoader.m_oRequests){_Zl++;}var _4j=null;if(_27.m_oXMLHTTP.status==200){if(_27.m_sFile.indexOf(".xml")>=0||_27.m_sFile.indexOf(".txt")>=0){_4j=_27.m_oXMLHTTP.responseText;}else{_4j="";}}var _azq="";if(_27.m_oXMLHTTP.status!=200){_azq=_27.m_oXMLHTTP.statusText;}_27.m_oFileCache[_27.m_sFile]=_4j;if(_27.m_oListener.XMLLoader_OnFileLoaded){_27.m_oListener.XMLLoader_OnFileLoaded(_27.m_sFile,_4j,_Zl,_azq);}if(_Zl==0){if(_27.m_oListener.XMLLoader_OnAllFilesLoaded){_27.m_oListener.XMLLoader_OnAllFilesLoaded(_27.m_oFileCache);}}}};function Dom(){};Dom.KeyCodes=new Object();Dom.KeyCodes.BackSpace=8;Dom.KeyCodes.Tab=9;Dom.KeyCodes.Enter=13;Dom.KeyCodes.Escape=27;Dom.KeyCodes.Space=32;Dom.KeyCodes.PgUp=33;Dom.KeyCodes.PgDn=34;Dom.KeyCodes.End=35;Dom.KeyCodes.Home=36;Dom.KeyCodes.ArrowLeft=37;Dom.KeyCodes.ArrowUp=38;Dom.KeyCodes.ArrowRight=39;Dom.KeyCodes.ArrowDown=40;Dom.KeyCodes.Delete=46;Dom.KeyCodes.F5=116;Dom.NodeType=new Object();Dom.NodeType.ElementNode=1;Dom.NodeType.AttributeNode=2;Dom.NodeType.TextNode=3;Dom.NodeType.DocNode=9;Dom.ignoreNS=new Array('bus:');Dom.aPropNames=new Object();Dom.SetObjRef=function(el,obj,_LW){el[_LW]=obj;Dom.aPropNames[_LW]=true;};Dom.SetWindowGlobalObject=function(_Vj,_Bt){if(!window._ae){window._ae=new Object();}window._ae[_Vj]=_Bt;};Dom.GetWindowGlobalObject=function(_Vj){if(window._ae){return window._ae[_Vj];}else{return null;}};Dom.GetScrollTop=function(){var _TM=0;if(document.documentElement&&document.documentElement.scrollTop){_TM=document.documentElement.scrollTop;}else if(document.body){_TM=document.body.scrollTop;}return _TM;};Dom.GetScrollLeft=function(){var _P6=0;if(document.documentElement&&document.documentElement.scrollLeft){_P6=document.documentElement.scrollLeft;}else if(document.body){_P6=document.body.scrollLeft;}return _P6;};Dom.GetWindowWidth=function(){var _F4=0;if(window.innerWidth){_F4=window.innerWidth;}else if(document.documentElement&&document.documentElement.clientWidth){_F4=document.documentElement.clientWidth;}else if(document.body){_F4=document.body.clientWidth;}else{Debug.Assert(false);}return _F4;};Dom.GetWindowHeight=function(){var _T6=0;if(window.innerHeight){_T6=window.innerHeight;}else if(document.documentElement&&document.documentElement.clientHeight){_T6=document.documentElement.clientHeight;}else if(document.body){_T6=document.body.clientHeight;}else{Debug.Assert(false);}return _T6;};Dom.CancelBubble=function(_MC){_MC=_MC||window.event;_MC.cancelBubble=true;if(_MC.stopPropagation)_MC.stopPropagation();};Dom.CancelEvent=function(_MC){Dom.PreventDefault(_MC);Dom.CancelBubble(_MC);return false;};Dom.PreventDefault=function(_MC){_MC=_MC||window.event;if(_MC){if(_MC.preventDefault){_MC.preventDefault();}else{_MC.returnValue=false;}}};Dom.SafePreventDefault=function(e){/*@if(!@bering_debug)@*/try{/*@end@*/if(!e){var e=window.event;}Dom.PreventDefault(e);/*@if(!@bering_debug)@*/}catch(e){_f.HandleException(e);}/*@end@*/};Dom.GetEventTarget=function(_MC){if(_MC.srcElement)return _MC.srcElement;else if(_MC.target){if(_MC.target.nodeType==Dom.NodeType.TextNode){return _MC.target.parentNode;}else{return _MC.target;}}else{Debug.Assert(false);return null;}};Dom.GetFromElement=function(_MC){if(_MC.relatedTarget){return _MC.relatedTarget;}else{return _MC.fromElement;}};Dom.GetToElement=function(_MC){if(_MC.relatedTarget){return _MC.relatedTarget;}else{return _MC.toElement;}};Dom.IsLeftButton=function(_MC){var _0X=false;if(_o.is_ie5_5up){if(_MC.button==1)_0X=true;}else{if(_MC.button==0)_0X=true;}return _0X;};Dom.GetStyleByBrowser=function(_yx){if(!(_o.is_ie5_5up)){_yx+="_NS";}return _yx;};Dom.SetCSSClassName=function(el,_E3){el.className=_E3;};Dom.AppendCSSClassName=function(el,_E3){el.className=el.className+" "+_E3;};Dom.SetFocus=function(el){el.focus();};Dom.SetTabStop=function(_Cf,_U4){Debug.Assert(_Cf.tagName=="A");if(_U4!=null){_Cf.tabIndex=_U4;}if(_o.is_netscape){}};Dom.GetOffsetY=function(_MC){if(_MC.layerY)return _MC.layerY;else if(_MC.offsetY){return _MC.offsetY;}};Dom.GetOffsetX=function(_MC){if(_MC.layerX)return _MC.layerX;else if(_MC.offsetX){return _MC.offsetX;}};Dom.FireEvent=function(el,_Ge){var _aak=null;if(el.fireEvent){_aak=el.fireEvent(_Ge);}else{var _ah2=document.createEvent("MouseEvents");var _abR=_Ge.substring(2,_Ge.length);_ah2.initEvent(_abR,true,true);_aak=el.dispatchEvent(_ah2);}return _aak;};Dom.FireMouseEvent=function(el,_Ge,_yE){var _aak=null;if(el.fireEvent){_aak=el.fireEvent(_Ge,_yE);}else{_aak=el.dispatchEvent(_yE);}return _aak;};Dom.CloneMouseEvent=function(_MC,_QE){if(_o.is_ie5_5up||_QE){if(document.createEventObject){return document.createEventObject(_MC);}else{var _ah2=document.createEvent("MouseEvents");_ah2.initMouseEvent(_MC.type,_MC.bubbles,_MC.cancelable,document.defaultView,_MC.detail,_MC.screenX,_MC.screenY,_MC.clientX,_MC.clientY,_MC.ctrlKey,_MC.altKey,_MC.shiftKey,_MC.metaKey,_MC.button,_MC.relatedTarget);return _ah2;}}else{return _MC;}};Dom.DisableTextSelection=function(el){if(_o.is_ie5_5up){el.onselectstart=Dom.CancelEvent;}else{el.onmousedown=Dom.PreventDefault;}};Dom.EnableTextSelection=function(el){if(_o.is_ie5_5up){el.onselectstart=Dom.CancelBubble;}else{el.onmousedown=Dom.CancelBubble;}};Dom.RePaint=function(el){if(!el.style)return;if(_o.is_netscape){var _TM=el.offsetTop;var _ZV=COTStyle.GetStyle(el,"top");if(_ZV!=""&&_ZV!="auto"){el.style.top=_ZV;}else{el.style.top=_TM+'px';}}};Dom.RemoveAllChildren=function(_EP){var _Gw=null;var _2r=null;if(!_EP){return;}for(var i=_EP.childNodes.length-1;i>=0;i--){_Gw=_EP.childNodes[i];Dom.ClearRefs(_Gw,true);_2r=_EP.removeChild(_Gw);_2r=null;_Gw=null;}Dom.RePaint(_EP);};Dom.ResetStyle=function(el,_FX,_KG,_Ui){var _FT=_KG;for(var i=0;i<el.attributes.length;i++){if(el.attributes[i].name=='style'){var _FT=el.attributes[i].value;var _afv=el.removeAttribute(el.attributes[i].name);var _Yr=COTStyle.GetStyle(el,_FX);if(!(_Yr.indexOf(_Ui)>0)){_FT+="; "+_KG;}}}return _FT;};Dom.RemoveObject=function(_TT,_GN){if(!_TT){return;}if(!_GN){Dom.RemoveAllChildren(_TT);}var _VW=_TT.parentNode;if(_VW){var c=_VW.removeChild(_TT);if(c){c=null;}}Dom.ClearRefs(_TT,false);_TT=null;};Dom.ClearRefs=function(_TT,_GX){if(_TT.nodeType!=Dom.NodeType.TextNode){/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oClearRefs.StartTimer(true);}/*@end@*/for(var i in Dom.aPropNames){_TT[i]=null;}/*@if(@bering_debug)@*/if(Debug.IsEnabled()&&_d){g_oClearRefs.StopTimer();}/*@end@*/if(_GX==null){var _GX=true;}if(_GX){for(var i=0;i<_TT.childNodes.length;i++){Dom.ClearRefs(_TT.childNodes[i],true);}}}};Dom.SetVerticalOverflow=function(el,_KL){if(_o.is_ie5_5up){el.style.overflowY=_KL;}else{el.style.overflow=_KL;}};Dom.HideObject=function(el){el.style.visibility="hidden";el.style.left="-1000px";};Dom.DisplayObject=function(el,_z5){if(el!=null&&el.style){if(_z5){el.style.display="block";}else{el.style.display="none";}}};Dom.ReplaceText=function(el,_zm){Dom.RemoveAllChildren(el);el.appendChild(document.createTextNode(_zm));};Dom.ReplaceTextNode=function(el,_zm,_Qh){for(var i=0;i<el.childNodes.length;i++){_Gw=el.childNodes[i];if(_Gw.nodeType==_c.NODE_TEXT){if((!_Qh)||(_Qh==_Gw.nodeValue)){el.replaceChild(document.createTextNode(_zm),_Gw);return;}}}};Dom.GetRelativeOffset=function(el,_RL){var _P6=0;var _TM=0;while(el&&el!=_RL){var _EP=el.offsetParent;_P6+=el.offsetLeft;_TM+=el.offsetTop;if(_EP&&_EP.scrollLeft){_P6-=_EP.scrollLeft;}if(_EP&&_EP.scrollTop){_TM-=_EP.scrollTop;}if(_o.is_netscape){if(_EP&&_EP.tagName=="TABLE"){var _af9=parseInt(_EP.border);if(_af9>0){_P6+=_af9;_TM+=_af9;}}}el=_EP;}return new COTPosition(_P6,_TM);};Dom.GetWidthOfWidestChild=function(_Eq){var _aar=0;for(var i=0;i<_Eq.childNodes.length;i++){var _F4=COTStyle.GetDisplayOffsetWidth(_Eq.childNodes[i]);if(_F4>_aar)_aar=_F4;}return _aar;};Dom.kXPathDeep=".//";Dom.GetNodeText=function(_Gq){Debug.Assert(_Gq);if(_Gq.text){return _Gq.text;}else if(_Gq.textContent){var _6u=_Gq.textContent.replace(/\n/g," ");return _6u;}else{var _6u="";if(_Gq.hasChildNodes()){var _anS=_Gq.childNodes;for(var i=0;i<_anS.length;i++){Debug.Assert(_anS[i].nodeType==_c.NODE_TEXT);if(_anS[i].nodeValue!=null)_6u+=_anS[i].nodeValue;}}return _6u;}};Dom.GetNodeTextShallow=function(_Do,_RV){var _Eq=_Do.selectSingleNode(_RV);if(_Eq){return Dom.GetNodeText(_Eq);}else{return "";}};Dom.GetNodeTextShallowNoNS=function(_Do,name){var _Eq=_Do.selectSingleNode(name);for(var i=0;!_Eq&&i<Dom.ignoreNS.length;i++){var _1Y=Dom.ignoreNS[i]+name;_Eq=_Do.selectSingleNode(_1Y);}if(_Eq){return Dom.GetNodeText(_Eq);}else{return "";}};Dom.GetNodeTextDeep=function(_Do,_RV){return Dom.GetNodeTextShallow(_Do,Dom.kXPathDeep+_RV);};Dom.GetImmediateChildByName=function(_Do,_Kn){if(_Do.ownerDocument!=document){try{return _Do.selectSingleNode(_Kn);}catch(e){}}else{var _4B=null;var _anS=_Do.childNodes;for(var i=0;i<_anS.length;i++){if(_anS[i].nodeName==_Kn){_4B=_anS[i];break;}}return _4B;}};Dom.GetImmediateChildByNameNoNS=function(_Do,_Kn){var _4B=null;if(_Do.ownerDocument!=document){_4B=_Do.selectSingleNode(_Kn);for(var i=0;!_4B&&i<Dom.ignoreNS.length;i++){var _1Y=Dom.ignoreNS[i]+_Kn;_4B=_Do.selectSingleNode(_1Y);}}else{var _anS=_Do.childNodes;for(var i=0;i<_anS.length;i++){if(_anS[i].nodeName==_Kn){_4B=_anS[i];break;}}}return _4B;};Dom.GetImmediateChildrenByName=function(_Do,_Kn){Debug.Assert(_Do);if(_Do.ownerDocument!=document){return _Do.selectNodes(_Kn);}else{var _aFY=new Array();var _anS=_Do.childNodes;for(var i=0;i<_anS.length;i++){if(_anS[i].nodeName==_Kn){_aFY.push(_anS[i]);}}return _aFY;}};Dom.GetNumOfChild=function(_Do,_Kn){if(_Do.ownerDocument!=document){return _Do.selectNodes(_Kn).length;}else{var length=0;var _anS=_Do.childNodes;for(var i=0;i<_anS.length;i++){if(_anS[i].nodeName==_Kn){length++;}}return length;}};Dom.GetElementsByTagName=function(_Do,nodeName){if(_Do.ownerDocument!=document){return _Do.selectNodes(Dom.kXPathDeep+nodeName);}else{if(_o.is_ie5_5up){return _Do.getElementsByTagName(nodeName);}else{var _3i=new Array();if(_Do.nodeName==nodeName){_3i[0]=_Do;}var _Y5=new Array;_Y5[0]=_Do.childNodes;var _PQ=0;while(_PQ<_Y5.length){var _ad5=_Y5[_PQ];for(var i=0;i<_ad5.length;++i){if(_ad5[i].nodeName==nodeName){_3i[_3i.length]=_ad5[i];}if(_ad5[i].childNodes.length>0){_Y5[_Y5.length]=_ad5[i].childNodes;}}++_PQ;}return _3i;}}};Dom.GetElementsByNameNoNS=function(_LC,name){var _aiB=Dom.GetElementsByTagName(_LC,name);for(var i=0;_aiB.length==0&&i<Dom.ignoreNS.length;i++){var _1Y=Dom.ignoreNS[i]+name;_aiB=Dom.GetElementsByTagName(_LC,_1Y);}return _aiB;};Dom.IsDescendant=function(_Hi,_JL){if(!_Hi||!_JL){return false;}if(_Hi.contains){return _Hi.contains(_JL);}else{var _16=Dom.GetTreeWalker(_Hi);while(!_16.AtEnd()){_16.MoveToNext();if(_16.GetElement()==_JL){return true;}}return false;}};Dom.IsOKToUse=function(){return true;};Dom.DomVisitor=function(el,_OM){var _aex=el.childNodes;var _ayj=_aex.length;for(var i=0;i<_ayj;++i){Dom.DomVisitor(_aex[i],_OM);}_OM(el);};Dom.GetTreeWalker=function(_zM){return new DomTreeWalker(_zM);};function DomTreeWalker(_Ft){this._tI=_Ft;this._g4=_Ft;};DomTreeWalker.prototype.GetElement=function(){return this._g4;};DomTreeWalker.prototype.AtEnd=function(){if(this._g4==null){return true;}else{return false;}};DomTreeWalker.prototype.MoveToNextSibling=function(){if(this._g4)this._g4=this._g4.nextSibling;};DomTreeWalker.prototype.TryMoveToNextSibling=function(){if(!this._g4)return DomTreeWalker.eNoNext;if(this._g4.nextSibling){this._g4=this._g4.nextSibling;return DomTreeWalker.eSibling;}else{return DomTreeWalker.eNoNext;}};DomTreeWalker.eChild=1;DomTreeWalker.eSibling=2;DomTreeWalker.eOtherBranch=3;DomTreeWalker.eNoNext=4;DomTreeWalker.prototype.MoveToNext=function(){var _abn=DomTreeWalker.eNoNext;if(this._g4.firstChild){this._g4=this._g4.firstChild;_abn=DomTreeWalker.eChild;}else if(this._g4.nextSibling){this._g4=this._g4.nextSibling;_abn=DomTreeWalker.eSibling;}else if(this._g4.parentNode){if(this._g4==this._tI||this._g4.parentNode.firstChild==this._tI){this._g4=null;}var _auJ=false;while((!_auJ)&&(this._g4!=null)){this._g4=this._g4.parentNode;if(this._g4==this._tI){this._g4=null;}if((this._g4)&&(this._g4.nextSibling)){this._g4=this._g4.nextSibling;_auJ=true;_abn=DomTreeWalker.eOtherBranch;}}}else{this._g4=null;}return _abn;};DomTreeWalker.prototype.MoveToNextTargetNode=function(_Ik){var _abn=DomTreeWalker.eNoNext;var _aal=this._g4.nextSibling;var _acy=Dom.GetImmediateChildByName(this._g4,_Ik);if(_acy){this._g4=_acy;_abn=DomTreeWalker.eChild;return _abn;}while(_aal){if(_aal.nodeName==_Ik){this._g4=_aal;_abn=DomTreeWalker.eSibling;return _abn;}_aal=_aal.nextSibling;}var parentNode=this._g4.parentNode;if(parentNode){if(this._g4==this._tI||parentNode.firstChild==this._tI){this._g4=null;}var _auJ=false;while((!_auJ)&&(this._g4!=null)){this._g4=this._g4.parentNode;if(this._g4==this._tI){this._g4=null;}if(this._g4){var _as6=this._g4.nextSibling;while(_as6){if(_as6.nodeName==_Ik){this._g4=_as6;_auJ=true;_abn=DomTreeWalker.eOtherBranch;break;}else{_as6=_as6.nextSibling;}}}}}else{this._g4=null;}return _abn;};function COTValidation(){};COTValidation.BlockTypeSubtotalRules=new Array();COTValidation.BlockTypeToFeatureRules=new Array();COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeChildren]=new Object();COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeChildren]=new Object();COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeChildren][ExpAPIXml.eCalcRemainder]=true;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeChildren][ExpAPIXml.eCalcSubtotalVisibleItems]=true;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeChildren][ExpAPIXml.eCalcSummary]=true;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeChildren][ExpAPIXml.eCalcFLAggregate]=true;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeChildren][ExpAPIXml.eCalcPassedFLAggregate]=true;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeChildren][ExpAPIXml.kShowSubtotalsOnly]=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeChildren]['topbottom']=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeChildren]['measureattribute']=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeChildren]['exclude']=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeChildren]['hide']=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeChildren]['sort']=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeChildren][ExpAPIXml.kEleAxisOpExprBlockSize]=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeChildren]['lock']=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeChildren]['showattributes']=true;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeMemberSet]=new Object();COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeMemberSet]=new Object();COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeMemberSet][ExpAPIXml.eCalcRemainder]=false;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeMemberSet][ExpAPIXml.eCalcSubtotalVisibleItems]=false;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeMemberSet][ExpAPIXml.eCalcSummary]=true;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeMemberSet][ExpAPIXml.eCalcFLAggregate]=true;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeMemberSet][ExpAPIXml.eCalcPassedFLAggregate]=true;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeMemberSet][ExpAPIXml.kShowSubtotalsOnly]=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeMemberSet]['topbottom']=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeMemberSet]['measureattribute']=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeMemberSet]['exclude']=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeMemberSet]['hide']=false;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeMemberSet]['sort']=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeMemberSet][ExpAPIXml.kEleAxisOpExprBlockSize]=false;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeMemberSet]['lock']=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeMemberSet]['showattributes']=true;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeLevelMembers]=new Object();COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeLevelMembers]=new Object();COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeLevelMembers][ExpAPIXml.eCalcRemainder]=true;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeLevelMembers][ExpAPIXml.eCalcSubtotalVisibleItems]=true;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeLevelMembers][ExpAPIXml.eCalcSummary]=true;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeLevelMembers][ExpAPIXml.eCalcFLAggregate]=true;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeLevelMembers][ExpAPIXml.eCalcPassedFLAggregate]=true;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeLevelMembers][ExpAPIXml.kShowSubtotalsOnly]=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeLevelMembers]['topbottom']=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeLevelMembers]['measureattribute']=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeLevelMembers]['exclude']=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeLevelMembers]['hide']=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeLevelMembers]['sort']=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeLevelMembers][ExpAPIXml.kEleAxisOpExprBlockSize]=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeLevelMembers]['lock']=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeLevelMembers]['showattributes']=true;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeMeasure]=new Object();COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeMeasure]=new Object();COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeMeasure][ExpAPIXml.eCalcRemainder]=false;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeMeasure][ExpAPIXml.eCalcSubtotalVisibleItems]=false;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeMeasure][ExpAPIXml.eCalcSummary]=false;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeMeasure][ExpAPIXml.eCalcFLAggregate]=false;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeMeasure][ExpAPIXml.eCalcPassedFLAggregate]=false;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeMeasure][ExpAPIXml.kShowSubtotalsOnly]=false;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeMeasure]['topbottom']=false;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeMeasure]['measureattribute']=false;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeMeasure]['exclude']=false;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeMeasure]['hide']=false;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeMeasure]['sort']=false;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeMeasure][ExpAPIXml.kEleAxisOpExprBlockSize]=false;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeMeasure]['lock']=false;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeMeasure]['showattributes']=false;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeMeasureChildren]=new Object();COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeMeasureChildren]=new Object();COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeMeasureChildren][ExpAPIXml.eCalcRemainder]=true;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeMeasureChildren][ExpAPIXml.eCalcSubtotalVisibleItems]=true;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeMeasureChildren][ExpAPIXml.eCalcSummary]=true;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeMeasureChildren][ExpAPIXml.eCalcFLAggregate]=false;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeMeasureChildren][ExpAPIXml.eCalcPassedFLAggregate]=false;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeMeasureChildren][ExpAPIXml.kShowSubtotalsOnly]=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeMeasureChildren]['topbottom']=false;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeMeasureChildren]['measureattribute']=false;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeMeasureChildren]['exclude']=false;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeMeasureChildren]['hide']=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeMeasureChildren]['sort']=false;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeMeasureChildren][ExpAPIXml.kEleAxisOpExprBlockSize]=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeMeasureChildren]['lock']=false;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeMeasureChildren]['showattributes']=false;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeDescendants]=new Object();COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeDescendants]=new Object();COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeDescendants][ExpAPIXml.eCalcRemainder]=true;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeDescendants][ExpAPIXml.eCalcSubtotalVisibleItems]=true;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeDescendants][ExpAPIXml.eCalcSummary]=true;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeDescendants][ExpAPIXml.eCalcFLAggregate]=true;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeDescendants][ExpAPIXml.eCalcPassedFLAggregate]=true;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeDescendants][ExpAPIXml.kShowSubtotalsOnly]=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeDescendants]['topbottom']=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeDescendants]['measureattribute']=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeDescendants]['exclude']=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeDescendants]['hide']=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeDescendants]['sort']=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeDescendants][ExpAPIXml.kEleAxisOpExprBlockSize]=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeDescendants]['lock']=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeDescendants]['showattributes']=true;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeNamedSet]=new Object();COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeNamedSet]=new Object();COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeNamedSet][ExpAPIXml.eCalcRemainder]=true;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeNamedSet][ExpAPIXml.eCalcSubtotalVisibleItems]=true;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeNamedSet][ExpAPIXml.eCalcSummary]=true;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeNamedSet][ExpAPIXml.eCalcFLAggregate]=true;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeNamedSet][ExpAPIXml.eCalcPassedFLAggregate]=true;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeNamedSet][ExpAPIXml.kShowSubtotalsOnly]=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeNamedSet]['topbottom']=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeNamedSet]['measureattribute']=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeNamedSet]['exclude']=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeNamedSet]['hide']=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeNamedSet]['sort']=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeNamedSet][ExpAPIXml.kEleAxisOpExprBlockSize]=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeNamedSet]['lock']=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeNamedSet]['showattributes']=true;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeNested]=new Object();COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeNested]=new Object();COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeNested][ExpAPIXml.eCalcRemainder]=true;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeNested][ExpAPIXml.eCalcSubtotalVisibleItems]=true;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeNested][ExpAPIXml.eCalcSummary]=true;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeNested][ExpAPIXml.eCalcFLAggregate]=true;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeNested][ExpAPIXml.eCalcPassedFLAggregate]=true;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeNested][ExpAPIXml.kShowSubtotalsOnly]=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeNested]['topbottom']=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeNested]['measureattribute']=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeNested]['exclude']=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeNested]['hide']=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeNested]['sort']=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeNested][ExpAPIXml.kEleAxisOpExprBlockSize]=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeNested]['lock']=false;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeNested]['showattributes']=true;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeV5]=new Object();COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeV5]=new Object();COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeV5][ExpAPIXml.eCalcRemainder]=true;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeV5][ExpAPIXml.eCalcSubtotalVisibleItems]=true;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeV5][ExpAPIXml.eCalcSummary]=true;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeV5][ExpAPIXml.eCalcFLAggregate]=true;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeV5][ExpAPIXml.eCalcPassedFLAggregate]=true;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeV5][ExpAPIXml.kShowSubtotalsOnly]=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeV5]['topbottom']=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeV5]['measureattribute']=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeV5]['exclude']=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeV5]['hide']=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeV5]['sort']=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeV5][ExpAPIXml.kEleAxisOpExprBlockSize]=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeV5]['lock']=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeV5]['showattributes']=true;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeSegmtQuadrant]=new Object();COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeSegmtQuadrant]=new Object();COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeSegmtQuadrant][ExpAPIXml.eCalcRemainder]=false;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeSegmtQuadrant][ExpAPIXml.eCalcSubtotalVisibleItems]=false;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeSegmtQuadrant][ExpAPIXml.eCalcSummary]=false;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeSegmtQuadrant][ExpAPIXml.eCalcFLAggregate]=true;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeSegmtQuadrant][ExpAPIXml.eCalcPassedFLAggregate]=true;COTValidation.BlockTypeSubtotalRules[CDLAbsBlock.eTypeSegmtQuadrant][ExpAPIXml.kShowSubtotalsOnly]=false;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeSegmtQuadrant]['topbottom']=false;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeSegmtQuadrant]['measureattribute']=false;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeSegmtQuadrant]['exclude']=true;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeSegmtQuadrant]['hide']=false;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeSegmtQuadrant]['sort']=false;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeSegmtQuadrant][ExpAPIXml.kEleAxisOpExprBlockSize]=false;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeSegmtQuadrant]['lock']=false;COTValidation.BlockTypeToFeatureRules[CDLAbsBlock.eTypeSegmtQuadrant]['showattributes']=false;COTValidation.MetaDataSelectValidation=function(_TS,_TU,_O7){if((_TS==null)||(_TS==null)){return false;}Debug.Assert(_TS._lW&&_TU._lW);var _alW=false;if((_TS._lW==ExpAPIXml.eDimRoot&&_TU._lW==ExpAPIXml.eMember)||(_TU._lW==ExpAPIXml.eDimRoot&&_TS._lW==ExpAPIXml.eMember)||(_TS._lW==CUIMeasure.kNonAggreMeasure&&_TU._lW==ExpAPIXml.eMeasure)||(_TU._lW==CUIMeasure.kNonAggreMeasure&&_TS._lW==ExpAPIXml.eMeasure)){_alW=true;}if(!_alW&&_TS._lW!=_TU._lW){return false;}var _aHy,_0q;switch(_TS._lW){case ExpAPIXml.eNamedSet:case ExpAPIXml.eCustomSet:return false;case ExpAPIXml.eMember:case ExpAPIXml.eDimRoot:case ExpAPIXml.eMeasure:case CUIMeasure.kNonAggreMeasure:_aHy=_O7._ob.GetData(_TS._ks);_0q=_O7._ob.GetData(_TU._ks);break;default:return false;}if(_aHy.GetDimId&&_0q.GetDimId){if(_aHy.GetDimId()==_0q.GetDimId()){if(_aHy.GetHierId()==_0q.GetHierId()){return true;}else{return false;}}else{return false;}}return false;};COTValidation.SameDimValidation=function(_zB,_Eg,_AR){var _aHy,_0q;_aHy=_AR.GetData(_zB);_0q=_AR.GetData(_Eg);if(_aHy&&_0q&&_aHy.GetDimId&&_0q.GetDimId){if(_aHy.GetDimId()==_0q.GetDimId()){return true;}else{return false;}}return false;};COTValidation.IsSameDimAsMember=function(_U6,_Qk,_RJ){var oMem=_RJ.GetData(_U6);if(oMem&&oMem.GetDimId()==_Qk){return true;}return false;};COTValidation.IsHAMCDrop=function(_RJ,_FK,_Lv){if(_Lv&&(_Lv.sLevId||_Lv instanceof CUIDragDropCustomSet||_Lv instanceof CUIDragDropNamedSet||_Lv.bDelete)||_FK.IsNamedSet()){return false;}else{var _3E=_FK.GetHierarchyOrDimId()==_Lv.GetHierOrDimId(_RJ,_FK.oAxis._rk);return _3E&&(_FK.IsHAMC());}};COTValidation.IsDropFromSameBlock=function(_Lv,_FK){if(_Lv.sBlockId&&_Lv.sBlockId==_FK.GetId()){return true;}return false;};COTValidation.IsDropWithNewMembers=function(_Lv,_FK){if(_Lv.sMemId&&!_FK.IsInBlock(_Lv.sMemId)){return true;}if(_Lv.aOtherMemIds){for(var i=0;i<_Lv.aOtherMemIds.length;i++){if(!_FK.IsInBlock(_Lv.aOtherMemIds[i])){return true;}}}return false;};COTValidation.isValidReplaceDrop=function(_Qp){if(_Qp&&_Qp.IsGroupedDescendantsAtDepth()&&!_Qp.IsInnerNestedBlock()){return false;}return true;};COTValidation.isValidBlockXjoinDrop=function(_Qp,_Oy){if(!_Qp){return false;}if(_Oy==ExpAPIXml.kEleOuter){if(_Qp.IsGroupedDescendantsAtDepth()){return false;}return true;}else if(_Oy==ExpAPIXml.kEleInner){if(_Qp.IsOuterNestedBlock()){return false;}if(_Qp.IsGroupedDescendantsAtDepth()&&!_Qp.IsInnerNestedBlock()){return false;}return true;}};COTValidation.isValidBlockUnionDrop=function(_Qp,_Oy){if(!_Qp){return false;}if(_Qp.IsOuterNestedBlock()||_Qp.IsGroupedDescendantsAtDepth()){return false;}return true;};COTValidation.IsValidDrop=function(_O0,_Lv,_RJ,_Pv,_Qp,_Oy){var _afA=_Lv.bDelete&&_O0.GetBlock(_Lv.sBlockId);var _atr=true;if(!_afA){_atr=_O0.IsValidMetadataDrop(_Pv,_Qp,_Lv);}if(_atr&&_Qp){if(_Pv==ExpAPIXml.kActionReplace&&!COTValidation.isValidReplaceDrop(_Qp)){_atr=false;}else if(_Pv==ExpAPIXml.kAxisOpXjoin&&!COTValidation.isValidBlockXjoinDrop(_Qp,_Oy)){_atr=false;}else if(_Pv==ExpAPIXml.kAxisOpUnion&&!COTValidation.isValidBlockUnionDrop(_Qp,_Oy)){_atr=false;}}if(!_atr&&_Qp&&(ExpAPIXml.kEleInner==_Oy)&&(_Pv==ExpAPIXml.kAxisOpXjoin)){_atr=_Qp.AllowSDNDrop(_Lv);}return _atr;};function PerfMonitor(){this._vf=0;this.aTimers=new Array();this.oTotalTime=null;};var _d=null;var _n=null;var _l=null;var _r=null;var _k=null;var _q=null;PerfMonitor.DoTimerSetup=function(){/*@if(@bering_debug)@*/if(Debug.IsEnabled()){_d=new PerfMonitor();_n=_d.CreateTimer('refresh crosstab');g_oSizing=_d.CreateTimer('sizing crosstab + test cell size');g_oTestCellSize=_d.CreateTimer('test cell size');g_oCustomScroll=_d.CreateTimer('updating scrollbars');g_oCreateRowCol=_d.CreateTimer('creating row & column headers');g_oCreateDataCell=_d.CreateTimer('create data cell');g_oAppendingCells=_d.CreateTimer('appending cells');g_oAppendingRows=_d.CreateTimer('appending rows');g_oAppendingTable=_d.CreateTimer('appending table');_d.StartGlobalTimer("Time since init");g_oDataCell=new PerfMonitor('create data cell');g_oGetCell=g_oDataCell.CreateTimer("Get cell");g_oCloneNode=g_oDataCell.CreateTimer("Clone data cell node");g_oSetProps=g_oDataCell.CreateTimer("SetProps on data cell");g_oAppendTextNode=g_oDataCell.CreateTimer("Append text node");g_oDataCell.StartGlobalTimer("Time since init");g_oDataLayer=new PerfMonitor("Data layer processing");g_oClearData=g_oDataLayer.CreateTimer("Clear old nodes");g_oProcessData=g_oDataLayer.CreateTimer("Process nodes");g_oDMCreate=g_oDataLayer.CreateTimer("DM Create");g_oProcessCells=g_oDataLayer.CreateTimer("Process cells");g_oMergeMeta=g_oDataLayer.CreateTimer("Merge metadata");g_oAnalysisReplace=g_oDataLayer.CreateTimer("Analysis replace");g_oPreProcessCommands=g_oDataLayer.CreateTimer("Preprocess commands");g_oWSUpdate=new PerfMonitor("updating worksheet status");g_oWSDraw=g_oWSUpdate.CreateTimer("Update ws status & options");g_oRefresh=new PerfMonitor();g_oAxis=g_oRefresh.CreateTimer('refresh ui axes & cell map');g_oGetData=g_oRefresh.CreateTimer('GetCrosstabData');g_oDrawCrosstab=g_oRefresh.CreateTimer('DrawCrostab');g_oPopulateAxisCellMap=new PerfMonitor();g_oColAxis=g_oPopulateAxisCellMap.CreateTimer('populate col axis');g_oRowAxis=g_oPopulateAxisCellMap.CreateTimer('populate row axis');g_oCellMap=g_oPopulateAxisCellMap.CreateTimer('refresh cell map');g_oGetXtabData=new PerfMonitor();g_oGetColData=g_oGetXtabData.CreateTimer('get column data');g_oTestColDataSize=g_oGetXtabData.CreateTimer('Test Column data size');g_oGetRowData=g_oGetXtabData.CreateTimer('get row data');g_oTestRowDataSize=g_oGetXtabData.CreateTimer('Test row data size');g_oGetDataCellData=g_oGetXtabData.CreateTimer('get data cells');g_oTestDataCellSize=g_oGetXtabData.CreateTimer('Test data cell size');_l=new PerfMonitor();g_oCreateXMLDoc=_l.CreateTimer('Creating XML doc object');g_oHTMLEncoding=_l.CreateTimer('Server state HTML Encoding');g_oObjRefPerfMon=new PerfMonitor();g_oClearRefs=g_oObjRefPerfMon.CreateTimer("Clearing object references");g_oObjRefPerfMon.StartGlobalTimer("Time since init");}/*@end@*/};PerfMonitor.GetResults=function(){/*@if(@bering_debug)@*/_d.StopGlobalTimer();var _azp=Utilities.GenerateId();_Vp="directories=no,location=no,status=no,toolbar=no,resizable=yes,scrollbars=yes,top=100,left=100,height=480,width=640";var _aa5=window.open("",_azp,_Vp);var _BA=_aa5.document;_BA.title='Results';_aa5.focus();_d.ShowResult(_BA.body,_BA);g_oRefresh.ShowResult(_BA.body,_BA);g_oPopulateAxisCellMap.ShowResult(_BA.body,_BA);g_oGetXtabData.ShowResult(_BA.body,_BA);g_oDataCell.ShowResult(_BA.body,_BA);g_oWSUpdate.ShowResult(_BA.body,_BA);_l.ShowResult(_BA.body,_BA);g_oObjRefPerfMon.ShowResult(_BA.body,_BA);g_oDataLayer.ShowResult(_BA.body,_BA);/*@end@*/};PerfMonitor.GetSearchPerfResults=function(){/*@if(@bering_debug)@*/_d.StopGlobalTimer();var _azp=Utilities.GenerateId();var _Vp="directories=no,location=no,status=no,toolbar=no,resizable=yes,scrollbars=yes,top=100,left=100,height=480,width=640";var _aa5=window.open("",_azp,_Vp);var _BA=_aa5.document;_BA.title='Search Perf Results';_aa5.focus();if(_r){_r.ShowResult(_BA.body,_BA);}else{}if(_k){_k.ShowResult(_BA.body,_BA);}else{}/*@end@*/};PerfMonitor.prototype.Unload=function(){for(var i=0;i<this.aTimers.length;i++){Utilities.RemoveAllChildObjects(this.aTimers);}this.aTimers.length=0;};PerfMonitor.prototype.StartNewTimer=function(_Ji){this.aTimers.push(new Timer(_Ji,this));this.aTimers[this.aTimers.length-1].StartTimer();return(this.aTimers.length-1);};PerfMonitor.prototype.CreateTimer=function(_Ji){this.aTimers.push(new Timer(_Ji,this));return this.aTimers[this.aTimers.length-1];};PerfMonitor.prototype.StartTimer=function(_PQ,_IN){this.aTimers[_PQ].StartTimer(_IN);};PerfMonitor.prototype.StopTimer=function(_Jx){this.aTimers[_Jx].StopTimer();};PerfMonitor.prototype.StartGlobalTimer=function(_Ji){this.oTotalTime=new Timer(_Ji,this);this.oTotalTime.StartTimer();};PerfMonitor.prototype.ClearTimers=function(){for(var i=0;i<this.aTimers.length;i++){this.aTimers[i].ClearTimer();}};PerfMonitor.prototype.StopGlobalTimer=function(){if(this.oTotalTime){this.oTotalTime.StopTimer();}};PerfMonitor.prototype.ShowResult=function(_Ij,_BA){this.doc=_BA;this.elTable=_Ij.appendChild(_BA.createElement('TABLE'));this.elTBody=this.elTable.appendChild(_BA.createElement('TBODY'));var _aeS=this.drawResult('Timer description','Time elapsed in milliseconds','Percentage of operation','# of Calls');_aeS.style.fontStyle='italic';var _8d=this.oTotalTime.GetElapsedTime();var _0a=this.drawResult(this.oTotalTime.sDescription,_8d,100);_0a.style.fontWeight='bold';var _akJ=0;for(var i=0;i<this.aTimers.length;i++){var _Pb=this.aTimers[i].GetElapsedTime();_akJ+=_Pb;this.drawResult(this.aTimers[i].sDescription,_Pb,_Pb/_8d*100,this.aTimers[i].iTotalCalls);if(this.aTimers[i].sComment!=""){var _FW=this.elTBody.appendChild(this.doc.createElement('TR'));var _aFG=_FW.appendChild(this.doc.createElement('TD'));_aFG.appendChild(this.doc.createTextNode(this.aTimers[i].sComment));_aFG.colSpan=4;}}this.drawResult('Remainder',_8d-_akJ,((_8d-_akJ)/_8d*100));};PerfMonitor.prototype.drawResult=function(_Ji,_Pb,_H5,_VD){var _FW=this.elTBody.appendChild(this.doc.createElement('TR'));var _aFG=_FW.appendChild(this.doc.createElement('TD'));_aFG.appendChild(this.doc.createTextNode(_Ji));var _azi=_FW.appendChild(this.doc.createElement('TD'));_azi.appendChild(this.doc.createTextNode(_Pb));var _aGz=_FW.appendChild(this.doc.createElement('TD'));_aGz.appendChild(this.doc.createTextNode(_H5));if(_VD!=null){var _amu=_FW.appendChild(this.doc.createElement('TD'));_amu.appendChild(this.doc.createTextNode(_VD));}return _FW;};PerfMonitor.EnablePerceivedUserTime=function(){if(!_q){_q=new PerfMonitor();_q.CreateTimer('Perceived User Time');}};PerfMonitor.DisablePerceivedUserTime=function(){_q=null;};PerfMonitor.StartPerceivedUserTime=function(){_q.StartTimer(0);};PerfMonitor.StopPerceivedUserTime=function(){_q.StopTimer(0);alert("Total Time: "+_q.aTimers[0].GetElapsedTime()+" ms");_q.ClearTimers();};function Timer(_Ji,_H2){this._vf=0;this.sDescription=_Ji;this.oMonitor=_H2;this.iTotalCalls=0;this.bStarted=false;this.sComment="";};Timer.prototype.StartTimer=function(_EI){this._qV=new Date();this.bStarted=true;if(_EI&&this.oMonitor.oTotalTime){this.iTotalCalls++;}};Timer.prototype.SetComment=function(_UJ){this.sComment=_UJ;};Timer.prototype.StopTimer=function(){if(this.bStarted){this._dc=new Date();this._vf+=this._dc.valueOf()-this._qV.valueOf();this.bStarted=false;}};Timer.prototype.ClearTimer=function(){this._qV=null;this._vf=0;};Timer.prototype.StopSingleTime=function(){if(this.bStarted){this._dc=new Date();this._vf=this._dc.valueOf()-this._qV.valueOf();this.bStarted=false;}};Timer.prototype.GetElapsedTime=function(){return this._vf;};var _p=new RegressionTest();function RegressionTest(){this._cg=false;this._cO="seq-regression-test";this._xN="Enter a Description";this._wN="S:\\cr1\\win32\\testing\\";this._tN=1;this._qf='';};RegressionTest.StartRecording=function(){_p._cg=true;var _auy="Enter the path to your testing directory \n If you have a user install it will likely be 'S:\\crn\\' ";var _aBl=prompt(_auy,_p._wN);if(_aBl!=null){_p._wN=_aBl;}var _auy="Enter the name for your regression test";var _aBl=prompt(_auy,_p._cO);if(_aBl!=null){_p._cO=_aBl;}_auy="Enter a description for your regression test";_aBl=prompt(_auy,_p._xN);if(_aBl!=null){_p._xN=_aBl;}};RegressionTest.StopRecording=function(){if(_p){_p._cg=false;}};RegressionTest.IsRecordingEnabled=function(){if(_p){return _p._cg;}return false;};RegressionTest.RecordActions=function(_NB){if(_NB.indexOf("<action><type>init</type>")!=-1){_p._qf=_NB;}if(RegressionTest.IsRecordingEnabled()){var _azV="";if(_p._tN<10){_azV="0";}var _avf="act"+_azV+_p._tN+"-action.xml";var _QB=_p._cO;var _amX=_p._wN+"ExplorationStudio\\bqm\\";var _axk=new ActiveXObject("Scripting.FileSystemObject");if(!_axk.FolderExists(_amX)){alert("Regression Test Recorder Error: Path "+_amX+" does not exist. Could not record test");return;}var _Az=_amX+_QB;if(!_axk.FolderExists(_Az)){_axk.CreateFolder(_Az);}var _aA7=_axk.CreateTextFile(_Az+"\\"+_avf,true);_aA7.WriteLine(_NB);_aA7.Close();if(!_axk.FileExists(_Az+"\\desc.txt")){var _aIY=_axk.CreateTextFile(_Az+"\\desc.txt",true);_aIY.WriteLine(_p._xN);_aIY.Close();}if(_p._tN==1){if(!_p._qf){alert("Regression Test Recorder Error: Did not receive an init command. Please try to refresh your browser");}_avf="act"+"00"+"-action.xml";_aA7=_axk.CreateTextFile(_Az+"\\"+_avf,true);_aA7.WriteLine(_p._qf);_aA7.Close();}++_p._tN;}};function CopyPasteHLS(){this.datamanager=null;this._m0=false;};CopyPasteHLS.GetHLSFromServer=function(){var _4d=window.oUIManager.dataManager.GetCurrentWorkSheet();var _Ho;var _aI8=window.oUIManager.GetCurrentWorkSheet().GetUICrosstab();if(_aI8&&_4d._sl){_Ho=_aI8._x2.WriteToXml(_4d._b7);}var _AE=new Array();var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionGetHLS;if(_Ho){var _Gh=new CDLParameter(ExpAPIXml.kEleWidthData,_Ho,CDLParameter.XMLType());_Jj.AddParameter(_Gh);}_AE.push(_Jj);var _aBj=window.oUIManager.dataManager.commManager.CreateExploreRequest(_AE);_aBj.Send();};CopyPasteHLS.GetV5SpecFromServer=function(){var _Jj=new CDLAction();_Jj.type=ExpAPIXml.kActionGetReport;_Jj._eW(ExpAPIXml.kReportCmdType,"copytoclipboard");var _AE=new Array();_AE[0]=_Jj;var _aBj=window.oUIManager.dataManager.commManager.CreateExploreRequest(_AE);_aBj.Send();};CopyPasteHLS.CopyHLSToClipboard=function(_SD){var _avH=_c.ToString(_SD);CopyToClipboard('text',_avH);alert("HLS Copied to Clipboard");};CopyPasteHLS.PasteHLSFromClipboard=function(){var _agO=PasteFromClipboard("text");window.oUIManager.appobj.doPasteHLS(_agO);};CopyPasteHLS.CopyV5SpecToClipboard=function(_BH){CopyToClipboard('text',_BH);alert("Copied V5 Specification to Clipboard");};function decode64(_Pp){var _aGW="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";var _aiv="";var _az1,_XF,_azZ;var _afL,_afM,_agb,_aaI;var i=0;_Pp=_Pp.replace(/[^A-Za-z0-9\+\/\=]/g,"");do{_afL=_aGW.indexOf(_Pp.charAt(i++));_afM=_aGW.indexOf(_Pp.charAt(i++));_agb=_aGW.indexOf(_Pp.charAt(i++));_aaI=_aGW.indexOf(_Pp.charAt(i++));_az1=(_afL<<2)|(_afM>>4);_XF=((_afM&15)<<4)|(_agb>>2);_azZ=((_agb&3)<<6)|_aaI;_aiv=_aiv+String.fromCharCode(_az1);if(_agb!=64){_aiv=_aiv+String.fromCharCode(_XF);}if(_aaI!=64){_aiv=_aiv+String.fromCharCode(_azZ);}}while(i<_Pp.length);return _aiv;};CopyPasteHLS.CopyUndoStackToClipboard=function(){var _ann="";if(window.oUIManager.dataManager.commManager.CanUndo()){var _ajy=window.oUIManager.dataManager.commManager._sz._oG;_ann="<internalStateList>";for(var i=_ajy.length-1;i>=0;i--){var _avE=_ajy[i];var _ay5='<serverstate>';var _af8='</serverstate>';_avE=_avE.replace(Utilities.HtmlEncode(_ay5),'');_avE=_avE.replace(Utilities.HtmlEncode(_af8),'');var _2Z=decode64(_avE);_2Z=_2Z.substring(0,_2Z.length-1);_ann+='<internalState position="'+String(i)+'">'+_2Z+'</internalState>';}_ann+="</internalStateList>";}CopyToClipboard('text',_ann);alert("Copied Undo Stack to Clipboard");};function PlaybackRegressionTestResponses(){this._mE=false;this._tk=new Array();this._lI=new Array();this._g9=0;this._c7=true;};PlaybackRegressionTestResponses.prototype.GetCurrentResp=function(){return this._tk[this._g9];};PlaybackRegressionTestResponses.prototype.AddResponse=function(_Op){serverResponseEl=Dom.GetImmediateChildByName(_Op,"serverresponse");this._tk.push(_c.LoadString(serverResponseEl.xml,true,false));var _amm=Dom.GetImmediateChildByName(_Op,"actiondesc");if(_amm){var _anP=Dom.GetNodeText(_amm);var _axW=Utilities.GetReplaceToken('@NEWLINE@');_anP=_anP.replace(_axW,"\n");this._lI.push(_anP);}};PlaybackRegressionTestResponses.PlaybackNextResponse=function(_Ke){var _auf=FindApp(_Ke);var self=_auf._wJ;if(!self._mE){alert("You are not currently in Playback Mode. Cannot Playback next response");return;}if(self.HasAnotherResponse()){_auf.RenderNextRegressionTestResponse();if(self._lI.length>0){self.Alert(self._lI[self._g9]);}self._g9++;}else{self.Alert("There are no more responses to render");}};PlaybackRegressionTestResponses.EnterInteractiveMode=function(_Ke){var _auf=FindApp(_Ke);if(!_auf._wJ._mE){this.Alert("You are already in the regular client/server mode.");return;}_auf._wJ._mE=false;_c.CreateHTTPObject=_c.CreateHTTPObjectImpl;};PlaybackRegressionTestResponses.prototype.HasAnotherResponse=function(){return(this._g9<this._tk.length);};PlaybackRegressionTestResponses.prototype.RemoveAllResponses=function(){Utilities.DeleteAllFromArray(this._tk);Utilities.DeleteAllFromArray(this._lI);};PlaybackRegressionTestResponses.prototype.Alert=function(_Np){if(this._c7){alert(_Np);}};
|