/*

UnionNets netsEditor version 0.01

*/
function netsEditor(){}
//-- ------ # ------ --
netsEditor.prototype.sName="";
netsEditor.prototype.sEditor=null;
//-- ------ # ------ --
//Initial and reset
netsEditor.prototype.Initial=function(){
	this.sEditor.document.designMode="On";
	this.sEditor.document.write(document.getElementById(this.sName).value);
}
netsEditor.prototype.ResetContent=function(){
	document.getElementById(this.sName).value=this.sEditor.document.body.innerHTML;
}
//Format
netsEditor.prototype.Format=function(pOperate){
	this.sEditor.document.execCommand(pOperate);
	this.sEditor.focus();
}
//Insert image
netsEditor.prototype.insertIMG=function(pURL){
	this.sEditor.focus();
	this.sEditor.document.execCommand('InsertImage',false,pURL);
}
//Tab image
netsEditor.prototype.tabIMG=function(pCount_Button,pCount_Img){
	var tmpFlag=0;
	var Coun0=0;
	while(tmpFlag==0){
		tmpElement=document.getElementById(this.sName+"_Button_"+pCount_Button+"_ImgBox_"+Coun0);
		if(tmpElement!=undefined){
			document.getElementById(this.sName+"_Button_"+pCount_Button+"_ImgTab_"+Coun0).className="netsEdit_Button_3_E";
			document.getElementById(this.sName+"_Button_"+pCount_Button+"_ImgBox_"+Coun0).className=tmpCommon.sysHidden;
		}else{
			tmpFlag=1;
		}
		Coun0++;
	}
	
	document.getElementById(this.sName+"_Button_"+pCount_Button+"_ImgTab_"+pCount_Img).className="netsEdit_Button_3_D";
	document.getElementById(this.sName+"_Button_"+pCount_Button+"_ImgBox_"+pCount_Img).className="netsEdit_Button_3_F";
	return 0;
}





