?? functions.js
字號:
var PreiorSel="";
var isDel=false;
function init()
{
if (parent.frames("AddFunction").window.document.all.tags("TABLE").length>0)
{
if (parent.frames("SelBut").window.document.all.tags("BUTTON").length>0)
parent.frames("SelBut").document.all.item("btnLeftAll").disabled=(Tb.rows.length>1?0:1);
}
if (parent.frames("Buttons").window.document.all.tags("BUTTON").length>0)
parent.frames("Buttons").enabledBtns(1);
}
function thisClick()
{
var RowID,Row;
if (event.button==0 && (event.srcElement.tagName=="TD" || event.srcElement.tagName=="SELECT" ))
{
if (event.srcElement.tagName=="TD")
Row=event.srcElement.parentElement;
else
Row=event.srcElement.parentElement.parentElement;
if (Row.rowIndex>=1)
selectThis(Row);
}
}
function selectThis(ROWID)
{
var theIndex;
if (isDel)
PreiorSel="";
isDel=false;
if (PreiorSel!="")
parent.frames("AddFunction").document.all.item("Tb").rows(PreiorSel).className="Normal";
ROWID.className="Selected";
theIndex=parent.frames("FunctionList").document.all.item("FunctionList").selectedIndex;
if (theIndex>=0)
{
parent.frames("FunctionList").document.all.item("FunctionList").options(theIndex).selected=false;
parent.frames("SelBut").document.all.item("btnRight").disabled=1;
}
PreiorSel=ROWID.id;
setData(ROWID.id);
}
function setData(RowIDSelected)
{
parent.frames.item("SelBut").document.all.item("RowID").value=RowIDSelected;
parent.frames.item("SelBut").document.all.item("btnLeft").disabled=0;
}
function removeFunction()
{
var index,FunCode,FunName,Len
index=AddFunForm.SelectedList.selectedIndex;
if (index>=0)
{
FunCode=AddFunForm.SelectedList.options(index).value;
FunName=AddFunForm.SelectedList.options(index).text;
Len=parent.frames.item("FunctionList").FunctionList.length;
parent.frames.item("FunctionList").FunctionList.length=Len+1;
parent.frames.item("FunctionList").FunctionList.options(Len).text=FunName;
parent.frames.item("FunctionList").FunctionList.options(Len).value=FunCode;
AddFunForm.SelectedList.remove(index);
}
}
function thisClickdbl()
{
if (event.button==0 && event.srcElement.tagName=="TD")
{
isDel=true;
if (event.srcElement.parentElement.rowIndex>0)
{
setData(event.srcElement.parentElement.id);
parent.frames.item("SelBut").deleteThis();
}
}
}
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -