var theWidth, theHeight; var docIdClick = '' var showMKey1 = '' var showMKey2 = '' function showMenu(docId, key1, key2) { docIdClick = docId showMKey1 = key1 //alert(key1) showMKey2 = key2 if (key2==0) return false; toggleMenu() getWindowSize() ContextElement=event.srcElement; menu1.style.leftPos+=10; x = document.body.scrollLeft + event.clientX y = document.body.scrollTop + event.clientY /*....Checks to see if user clicks in the rightmost side of the browser..........*/ //alert(event.clientY + ' - ' + document.body.scrollTop + ' - ' + ' - y:' + y) resX = parseFloat(theWidth) - parseFloat(x) menuWidth = document.all.menu1.style.width menuHeight = document.all.menu1.style.height resY = parseFloat(theHeight) - parseFloat(y) // position from right if ((parseFloat(resX) + 5 ) < parseFloat(menuWidth)) { menu1.style.posRight=5; } else menu1.style.posLeft=x; // position from bottom resY = parseFloat(theHeight) - parseFloat(y) if (parseFloat(resY) < parseFloat(menuHeight)) { menu1.style.posBottom= 5 } else { menu1.style.posTop=y; } menu1.style.display=""; menu1.setCapture(); } function toggleMenu() { el=event.srcElement; if (el.className=="menuItemRightClick") { el.className="highlightItemRightClick"; } else if (el.className=="highlightItemRightClick") { el.className="menuItemRightClick"; } } function clickMenu() { menu1.releaseCapture(); menu1.style.display="none"; el=event.srcElement; if (el.doFunction != null) { func = el.doFunction func = func.replace('$DOCID$', docIdClick) func = func.replace('$KEY1$', showMKey1) func = func.replace('$KEY2$', showMKey2) eval(func); } }  function getWindowSize() { // Window dimensions: if (window.innerWidth) { theWidth=window.innerWidth; } else if (document.documentElement && document.documentElement.clientWidth) { theWidth=document.documentElement.clientWidth; } else if (document.body) { theWidth=document.body.clientWidth; } if (window.innerHeight) { theHeight=window.innerHeight; } else if (document.documentElement && document.documentElement.clientHeight) { theHeight=document.documentElement.clientHeight+document.body.scrollTop; } else if (document.body) { // alert(document.body.scrollTop) theHeight=document.body.clientHeight; } } //-------------------------------------------------------------------------- function viewParticulars(id) { host = location.protocol+'//'+location.host+'/' vesselpath =top.fra_UserVariables.symfoniprofileArray["70"]; vesselpath = 'http://'+host+'/' + vesselpath; f1 = '&1=../pages/Commonelements_Tabbedmenu_z.pro?open%%seltabs=Particulars%%Selected_tab=1&docid='+id f2 = '&2='+vesselpath+'/vieShowParticulars/'+id +'?openDocument' urlToUse = '/Web/Basic/cms_internett.nsf/frames/VesselParticulars.html?open' + f1 +f2 parent.parent.fra_Content.location = urlToUse } //--------------------------------------------------------------------------