// WebHelp 5.10.005 var gaProj=new Array(); var gnChecked=0; var gsProjName=""; var gbReady=false; var goMan=null; var gbXML=false; var gsFirstPane=""; var gServerEnabled=false; var gsPath=""; var gbWhPHost=false; var goDiv = null; var gsHTML = ""; if (navigator.currentNavPen) gsFirstPane = navigator.currentNavPen; function delayLoad() { if (goDiv&&gsHTML) { goDiv.innerHTML=gsHTML; goDiv=null; gsHTML=""; } } function whCom(sName,sComFile) { this.msName=sName; this.msDivId=sName+"Div"; this.msIFrameId=sName+"IFrame"; this.msComFile=sComFile; this.mbloaded=false; this.mbShow=false; this.show=function(bShow) { if(this.mbShow!=bShow) { if(bShow&&!this.mbloaded) { this.load(); } var oDiv=getElement(this.msDivId); if(oDiv) { if(gbIE55||(gbIE5&&gbMac)) { var oIframe=getElement(this.msIFrameId); if(oIframe) { if(bShow) { oDiv.style.zIndex=3; if(oIframe!=null) { oIframe.style.zIndex=3; if (!gbIE55) oIframe.style.visibility="visible"; } } else { oDiv.style.zIndex=2; if(oIframe!=null) { oIframe.style.zIndex=2; if (!gbIE55) oIframe.style.visibility="hidden"; } } } } if (!gbIE55) oDiv.style.visibility=(bShow==true)?'visible':'hidden'; this.mbShow=bShow; } } } this.load=function() { if(!this.mbloaded) { if(this.msComFile.length>0){ var strFile= _getFullPath(getPath(), this.msComFile); var oDiv=getElement(this.msDivId); if(oDiv){ if(gbIE4||gbOpera7){ var nIFrameHeight=oDiv.style.pixelHeight; var nIFrameWidth=oDiv.style.pixelWidth; var sHTML=""; }else{ sHTML+="100%; height:100%;\">"; } oDiv.innerHTML=sHTML; }else if(gbNav6){ gsHTML=""; goDiv = oDiv; setTimeout("delayLoad()", 100); } this.mbloaded=true; } } } } this.unload=function() { var oDiv=getElement(this.msDivId); if(oDiv) oDiv.innerHTML=""; } this.getDivHTML=function() { var sHTML=""; if(gbMac&&gbIE4) sHTML+="
"; else if(gbIE5) sHTML+="
"; else if(gbIE4||gbWindows) sHTML+="
"; else sHTML+="
"; sHTML+="
"; return sHTML; } } function whComMan() { this.sName=""; this.maCom=new Array(); this.addCom=function(sName,sComFile) { var owhCom=new whCom(sName,sComFile); this.maCom[this.maCom.length]=owhCom; } this.init=function() { var sHTML=""; for(var i=0;i0) { if(oMsg.oParam==1) gsFirstPane="toc"; else if(oMsg.oParam==2) gsFirstPane="idx"; else if(oMsg.oParam==3) gsFirstPane="fts"; else if(oMsg.oParam==4) gsFirstPane="glo"; } else if(oMsg.oParam==0) { bHidePane=true; } } goMan.init(); if(gsProjName!="") loadData2(gsProjName); if (bHidePane) { gsFirstPane=""; var oMsg1=new whMessage(WH_MSG_HIDEPANE, this, 1, null) SendMessage(oMsg1); } else { if(gsFirstPane!="") goMan.show(gsFirstPane); else goMan.showById(0); } } function setServerEnabled() { gServerEnabled = true; } function loadData2(strFile) { if(gbXML) loadDataXML(strFile); else loadData(strFile); } function addProject(bPreferXML,sXMLName,sHTMLName) { var bLoadXML=bPreferXML; if(!gbIE4&&!gbNav6&&!gbOpera7) return; if(gbIE4&&!gbIE5) bLoadXML=false; if (gbIE5&&!gbMac) bLoadXML=true; if(gbIE55||gbNav6) bLoadXML=true; if(gbOpera7) bLoadXML=false; if(bLoadXML) addProjectXML(sXMLName); else addProjectHTML(sHTMLName); } function addProjectHTML(sName) { gbXML=false; gsProjName=sName; } function addProjectXML(sName) { gbXML=true; gsProjName=sName; } function window_MyBunload() { goMan.unload(); window_BUnload(); } function putDataXML(xmlDoc,sdocPath) { if(xmlDoc!=null) { var projectNode=xmlDoc.getElementsByTagName("project")[0]; if(projectNode) { var aRProj=new Array(); aRProj[0]=new Object(); aRProj[0].sPPath=_getPath(sdocPath); var sLangId=projectNode.getAttribute("langid"); if(sLangId) { aRProj[0].sLangId=sLangId; } var sDPath=projectNode.getAttribute("datapath"); if(sDPath) { if(sDPath.lastIndexOf("/")!=sDPath.length-1) sDPath+="/"; aRProj[0].sDPath=sDPath; } else aRProj[0].sDPath=""; aRProj[0].sToc=projectNode.getAttribute("toc"); aRProj[0].sIdx=projectNode.getAttribute("index"); aRProj[0].sFts=projectNode.getAttribute("fts"); aRProj[0].sGlo=projectNode.getAttribute("glossary"); var RmtProject=projectNode.getElementsByTagName("remote"); var nCount=1; for (var i=0;i 1 && document.body.clientHeight>1) { var oMsg = new whMessage(WH_MSG_RESIZEPANE, this, 1, null); SendMessage(oMsg); } } } function window_unload() { UnRegisterListener2(this,WH_MSG_GETPROJINFO); UnRegisterListener2(this,WH_MSG_SHOWTOC); UnRegisterListener2(this,WH_MSG_SHOWIDX); UnRegisterListener2(this,WH_MSG_SHOWFTS); UnRegisterListener2(this,WH_MSG_SHOWGLO); UnRegisterListener2(this,WH_MSG_GETPANEINFO); } function onSendMessage(oMsg) { if(oMsg) { var nMsgId=oMsg.nMessageId; if(nMsgId==WH_MSG_GETPROJINFO) { if(gbReady) { var oProj=new Object(); oProj.aProj=gaProj; oProj.bXML=gbXML; oMsg.oParam=oProj; } else return false; } else if(nMsgId==WH_MSG_SHOWTOC) { if(goMan) goMan.show("toc"); var onMsg=new whMessage(WH_MSG_PANEINFO, this, 1, "toc"); SendMessage(onMsg); onMsg = new whMessage(WH_MSG_SHOWPANE, this, 1, null); SendMessage(onMsg); } else if(nMsgId==WH_MSG_SHOWIDX) { if(goMan) goMan.show("idx"); var onMsg=new whMessage(WH_MSG_PANEINFO, this, 1, "idx"); SendMessage(onMsg); onMsg = new whMessage(WH_MSG_SHOWPANE, this, 1, null); SendMessage(onMsg); } else if(nMsgId==WH_MSG_SHOWFTS) { if(goMan) goMan.show("fts"); var onMsg=new whMessage(WH_MSG_PANEINFO, this, 1, "fts"); SendMessage(onMsg); onMsg = new whMessage(WH_MSG_SHOWPANE, this, 1, null); SendMessage(onMsg); } else if(nMsgId==WH_MSG_SHOWGLO) { if(goMan) goMan.show("glo"); var onMsg=new whMessage(WH_MSG_PANEINFO, this, 1, "glo"); SendMessage(onMsg); onMsg = new whMessage(WH_MSG_SHOWPANE, this, 1, null); SendMessage(onMsg); } else if(nMsgId==WH_MSG_GETPANEINFO) { oMsg.oParam=goMan.getCurrent(); return false; } } return true; } if(window.gbWhUtil&&window.gbWhMsg&&window.gbWhVer&&window.gbWhProxy) { RegisterListener2(this,WH_MSG_GETPROJINFO); RegisterListener2(this,WH_MSG_SHOWTOC); RegisterListener2(this,WH_MSG_SHOWIDX); RegisterListener2(this,WH_MSG_SHOWFTS); RegisterListener2(this,WH_MSG_SHOWGLO); RegisterListener2(this,WH_MSG_GETPANEINFO); if((gbMac&&gbIE4)||(gbSunOS&&gbIE5)||gbOpera7) { window.onresize=window_resize; } else if(gbIE4) { window.onresize=window_resize2; } window.onload=window_OnLoad; window.onbeforeunload=window_MyBunload; window.onunload=window_unload; gbWhPHost=true; } else document.location.reload();