Coalesys.WebMenu source code(partial)(6)
发表于:2007-06-30来源:作者:点击数:
标签:
writer.CSF_11(cswmPI[cswmPI.length]=id;); writer.CSF_11(}); writer.CSF_11(else); writer.CSF_11({); writer.CSF_11(cswmPx[cswmPx.length]=eval(cswmOM+cswmPopup+cswmPI[cswmPI.length-1]+.clientWidth)+cswmPx[cswmPx.length-1]-4;); writer.CSF_11(va
writer.CSF_11("cswmPI[cswmPI.length]=id;");
writer.CSF_11("}");
writer.CSF_11("else");
writer.CSF_11("{");
writer.CSF_11("cswmPx[cswmPx.length]=eval(cswmOM+"cswmPopup"+cswmPI[cswmPI.length-1]+".clientWidth")+cswmPx[cswmPx.length-1]-4;");
writer.CSF_11("var szPrE="";");
writer.CSF_11("if(document.all["cswmItem"+itemid].offsetParent.offsetTop==0)");
writer.CSF_11("{");
writer.CSF_11("if(document.all["cswmItem"+itemid].offsetParent.offsetParent.offsetParent.offsetParent.className!="cswmPopupBox")");
writer.CSF_11("{");
writer.CSF_11("var szPrE="offsetParent.offsetParent.offsetParent.";");
writer.CSF_11("}");
writer.CSF_11("}");
writer.CSF_11("cswmPy[cswmPy.length]=eval(cswmOM+"cswmItem"+itemid+".offsetParent."+szPrE+"offsetTop")+cswmPy[cswmPy.length-1];");
writer.CSF_11("eval(cswmOM+"cswmPopup"+id+".style.width=1");");
writer.CSF_11("eval(cswmOM+"cswmPopup"+id+".style.height=1");");
writer.CSF_11("eval(cswmOM+"cswmPopup"+id+cswmDi+"=\"block\"");");
writer.CSF_11("cswmPW=eval(cswmOM+"cswmPopup"+id+".clientWidth");");
writer.CSF_11("cswmPH=eval(cswmOM+"cswmPopup"+id+".clientHeight");");
writer.CSF_11("var cswmPrW=eval(cswmOM+"cswmPopup"+cswmPI[cswmPI.length-1]+".clientWidth");");
writer.CSF_11("cswmAR=cswmBW-cswmPx[cswmPx.length-1]+cswmSLA;");
writer.CSF_11("cswmAB=cswmBH-cswmPy[cswmPy.length-1]+cswmSTA;");
writer.CSF_11("if(cswmPx[cswmPx.length-2]==cswmSLA){cswmDir="right";}");
writer.CSF_11("if((cswmAR<cswmPW)||(cswmDir=="left"))");
writer.CSF_11("{");
writer.CSF_11("cswmMB=(cswmPx[cswmPx.length-1]-cswmPW-cswmPrW)+8;");
writer.CSF_11("if((cswmMB>=0)&&(cswmMB>cswmSLA))");
writer.CSF_11("{");
writer.CSF_11("cswmDir="left";");
writer.CSF_11("}");
writer.CSF_11("else");
writer.CSF_11("{");
writer.CSF_11("cswmMB=cswmSLA;");
writer.CSF_11("}");
writer.CSF_11("cswmPx[cswmPx.length-1]=cswmMB;");
writer.CSF_11("}");
writer.CSF_11("if(cswmAB<cswmPH)");
writer.CSF_11("{");
writer.CSF_11("cswmMB=cswmPy[cswmPy.length-1]-(cswmPH-cswmAB);");
writer.CSF_11("if(cswmMB<0)");
writer.CSF_11("{");
writer.CSF_11("cswmMB=cswmSTA;");
writer.CSF_11("}");
writer.CSF_11("cswmPy[cswmPy.length-1]=cswmMB;");
writer.CSF_11("}");
writer.CSF_11("eval(cswmOM+"cswmPopup"+id+".style.left=cswmPx[cswmPx.length-1]");");
writer.CSF_11("eval(cswmOM+"cswmPopup"+id+".style.top=cswmPy[cswmPy.length-1]");");
writer.CSF_11("cswmPI[cswmPI.length]=id;");
writer.CSF_11("}");
writer.CSF_11("}");
writer.CSF_11("function cswmHP(level)");
writer.CSF_11("{");
writer.CSF_11("var count=level;");
writer.CSF_11("for(count=level;count<cswmPI.length;count++)");
writer.CSF_11("{");
writer.CSF_11("eval(cswmOM+"cswmPopup"+cswmPI[count]+cswmDi+"=\"none\"");");
writer.CSF_11("}");
writer.CSF_11("if(level==0&&cswmPI.length>0)");
writer.CSF_11("{");
if (!(Common.CSF_0(local32))) {
writer.CSF_11("var id = cswmPI[0];");
writer.CSF_11(local32);
writer.CSF_11(";");
}
writer.CSF_11("}");
writer.CSF_11("cswmPI.length=level;");
writer.CSF_11("cswmPx.length=level;");
writer.CSF_11("cswmPy.length=level;");
writer.CSF_11("}");
writer.CSF_11("function cswmCR()");
writer.CSF_11("{");
writer.CSF_11("cswmAR=(cswmBW+cswmSLA)-cswmPx[cswmPx.length-1];");
writer.CSF_11("if(cswmAR<cswmPW)");
writer.CSF_11("{");
writer.CSF_11("if(cswmSPnt=="below"||cswmSPnt=="above")");
writer.CSF_11("{");
writer.CSF_11("cswmMB=cswmPx[cswmPx.length-1]-(cswmPW-cswmAR);");
writer.CSF_11("if(cswmMB<0||cswmMB<cswmSLA)");
writer.CSF_11("{");
writer.CSF_11("cswmMB=cswmSLA;");
writer.CSF_11("}");
writer.CSF_11("cswmPx[cswmPx.length-1]=cswmMB;");
writer.CSF_11("}");
writer.CSF_11("else");
writer.CSF_11("{");
writer.CSF_11("cswmMB=cswmSEL-cswmPW;");
writer.CSF_11("if(cswmMB>=0)");
writer.CSF_11("{");
writer.CSF_11("cswmPx[cswmPx.length-1]=cswmMB;");
writer.CSF_11("}");
writer.CSF_11("}");
writer.CSF_11("}");
writer.CSF_11("}");
writer.CSF_11("function cswmCL()");
writer.CSF_11("{");
writer.CSF_11("if(cswmPx[cswmPx.length-1]<(cswmSLA))");
writer.CSF_11("{");
writer.CSF_11("cswmPx[cswmPx.length-1]=cswmSEL+cswmSEW;");
writer.CSF_11("cswmCR();");
writer.CSF_11("}");
writer.CSF_11("}");
writer.CSF_11("function cswmCB()");
writer.CSF_11("{");
writer.CSF_11("cswmAB=(cswmBH+cswmSTA)-cswmPy[cswmPy.length-1];");
writer.CSF_11("if(cswmAB<cswmPH)");
writer.CSF_11("{");
writer.CSF_11("if(cswmSPnt=="below")");
writer.CSF_11("{");
writer.CSF_11("cswmMB=cswmPy[cswmPy.length-1]-cswmPH-cswmSEH;");
writer.CSF_11("if(cswmMB>=0)");
writer.CSF_11("{");
writer.CSF_11("cswmPy[cswmPy.length-1]=cswmMB;");
writer.CSF_11("}");
writer.CSF_11("}");
writer.CSF_11("else");
writer.CSF_11("{");
writer.CSF_11("cswmMB=cswmPy[cswmPy.length-1]-(cswmPH-cswmAB);");
writer.CSF_11("if(cswmMB<0||cswmMB<cswmSTA)");
writer.CSF_11("{");
writer.CSF_11("cswmMB=cswmSTA;");
writer.CSF_11("}");
writer.CSF_11("cswmPy[cswmPy.length-1]=cswmMB;");
writer.CSF_11("}");
writer.CSF_11("}");
writer.CSF_11("}");
writer.CSF_11("function cswmCA()");
writer.CSF_11("{");
writer.CSF_11("if(cswmPy[cswmPy.length-1]<(cswmSTA))");
writer.CSF_11("{");
writer.CSF_11("cswmPy[cswmPy.length-1]=cswmSET+cswmSEH;");
writer.CSF_11("cswmCB();");
writer.CSF_11("}");
writer.CSF_11("}");
writer.CSF_11("function cswmHideSelectBox()");
writer.CSF_11("{");
writer.CSF_11("}");
writer.CSF_11("function cswmShowInFrame(MenuID,x,y)");
writer.CSF_11("{");
writer.CSF_11("x+=document.body.scrollLeft;");
writer.CSF_11("y+=document.body.scrollTop;");
writer.CSF_11("cswmShow(MenuID,@#@#,@#below@#,x,y,1);");
writer.CSF_11("}");
writer.CSF_11("function cswmRefresh()");
writer.CSF_11("{");
writer.CSF_11("}");
writer.CSF_11("
//-->
");
return;
}
if (type == 3) {
local41 = webmenu.OuterShadowColor;
local42 = webmenu.OuterHighlightColor;
local43 = webmenu.InnerShadowColor;
local44 = webmenu.InnerHighlightColor;
local34 = webmenu.BorderSize;
local35 = webmenu.HideTimer;
local38 = webmenu.HideOnClick;
local39 = webmenu.IgnoreHorzScroll;
local40 = webmenu.IgnoreVertScroll;
local45 = webmenu.OnShow;
local46 = webmenu.OnHide;
local33 = webmenu.ItemFont;
local36 = local33.PaddingBottom;
local37 = local33.PaddingRight;
if (local34 == 1) {
local43 = local41;
local44 = local42;
}
writer.CSF_11("
<!--
");
if (!(webmenu.CSF_8())) {
writer.CSF_11("/////////////////////////////////////////////////
");
writer.CSF_11("// Coalesys WebMenu for ASP.NET NN4 DHTML script
");
writer.CSF_11("// COPYRIGHT 2001 Coalesys, Inc.
");
writer.CSF_11("/////////////////////////////////////////////////
");
}
writer.CSF_11("var cswmP=new Object();");
writer.CSF_11("var cswmBP=");
writer.CSF_11(local36);
writer.CSF_11(";");
writer.CSF_11("var cswmRP=");
writer.CSF_11(local37);
writer.CSF_11(";");
writer.CSF_11("var cswmBS=");
writer.CSF_11(local34);
writer.CSF_11(";");
writer.CSF_11("var cswmTI="";");
writer.CSF_11("var cswmClkd=new String();");
writer.CSF_11("var cswmPI=new Array();");
writer.CSF_11("var cswmPL=new Array();");
writer.CSF_11("var cswmPT=new Array();");
writer.CSF_11("var cswmPS=new Array();");
writer.CSF_11("var cswmPW=0;");
writer.CSF_11("var cswmPH=0;");
writer.CSF_11("var cswmSPnt="";");
writer.CSF_11("var cswmDir="";");
writer.CSF_11("var cswmMB=0;");
writer.CSF_11("var cswmSI="";");
writer.CSF_11("var cswmSE=new Object();");
writer.CSF_11("var cswmSEL=0;");
writer.CSF_11("var cswmSET=0;");
writer.CSF_11("var cswmSEH=0;");
writer.CSF_11("var cswmSEW=0;");
writer.CSF_11("var cswmBW=self.innerWidth-16;");
原文转自:http://www.ltesting.net