Help.Web/editor/box.htm

(开头部分) 27KB

这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。

<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<link href="style/editor.css" rel="stylesheet" type="text/css">
<script>
	var sLangDir=dialogArguments.oUtil.langDir;
	document.write("<scr"+"ipt src='language/"+sLangDir+"/box.js'></scr"+"ipt>");
</script>
<script language="JavaScript" src="color_picker.js"></script>
<script>writeTitle()</script>
<script>
function doWindowFocus()
	{	
	dialogArguments.oUtil.onSelectionChanged=new Function("realTime()");
	}
function bodyOnLoad()
	{
	window.onfocus=doWindowFocus;
	dialogArguments.oUtil.onSelectionChanged=new Function("realTime()");

	realTime();
	}
function realTime()
	{
	if(!dialogArguments.oUtil.obj.checkFocus()){return;}//Focus stuff
	var oEditor=dialogArguments.oUtil.oEditor;
	var oSel=oEditor.document.selection.createRange();
	
	var oElement;
	if(dialogArguments.oUtil.activeElement)
		{
		oElement=dialogArguments.oUtil.activeElement
		}
	else
		{
		if (oSel.parentElement)	oElement=oSel.parentElement();
		else oElement=oSel.item(0);
		}
	
	inpMarginLeft.value=oElement.style.marginLeft;
	inpMarginRight.value=oElement.style.marginRight;
	inpMarginTop.value=oElement.style.marginTop;
	inpMarginBottom.value=oElement.style.marginBottom;
	inpPaddingLeft.value=oElement.style.paddingLeft;
	inpPaddingRight.value=oElement.style.paddingRight;
	inpPaddingTop.value=oElement.style.paddingTop;
	inpPaddingBottom.value=oElement.style.paddingBottom;
	
	if(oElement.style.width == "")inpWidth.value="";
	if(oElement.style.width.substr(oElement.style.width.length-2,2)=="px")
		{		
		inpAutoFitMeasure1.value = "px";
		inpWidth.value = oElement.style.width.substr(0,oElement.style.width.length-2);
		}		
	if(oElement.style.width.substr(oElement.style.width.length-1,1)=="%")
		{
		inpAutoFitMeasure1.value = "%";
		inpWidth.value = oElement.style.width.substr(0,oElement.style.width.length-1)
		}
	if(oElement.style.height == "")inpHeight.value="";
后面还有 662 行代码,解锁后查看完整代码

24 小时内免费解锁 3 个项目,之后 1 积分/个。 规则说明

AI 解读

登录后可用,每次 10 积分,解读结果公开显示在下面。

还没有人解读过这个文件。