Dialog_Tag_Image.js
上传用户:simon2hong
上传日期:2021-11-18
资源大小:16746k
文件大小:7k
- var OxO2bb2=["inp_src","btnbrowse","AlternateText","inp_id","longDesc","Align","optNotSet","optLeft","optRight","optTexttop","optAbsMiddle","optBaseline","optAbsBottom","optBottom","optMiddle","optTop","Border","bordercolor","bordercolor_Preview","inp_width","imgLock","inp_height","constrain_prop","HSpace","VSpace","outer","img_demo","onclick","src","height","width","value","cssText","style","","src_cetemp","id","vspace","hspace","border","borderColor"," ","backgroundColor","align","alt","[[ValidNumber]]","[[ValidID]]","checked","Load.ashx?type=imagex26file=locked.gif","Load.ashx?type=imagex26file=1x1.gif","length"];var inp_src=Window_GetElement(window,OxO2bb2[0x0],true);var btnbrowse=Window_GetElement(window,OxO2bb2[0x1],true);var AlternateText=Window_GetElement(window,OxO2bb2[0x2],true);var inp_id=Window_GetElement(window,OxO2bb2[0x3],true);var longDesc=Window_GetElement(window,OxO2bb2[0x4],true);var Align=Window_GetElement(window,OxO2bb2[0x5],true);var optNotSet=Window_GetElement(window,OxO2bb2[0x6],true);var optLeft=Window_GetElement(window,OxO2bb2[0x7],true);var optRight=Window_GetElement(window,OxO2bb2[0x8],true);var optTexttop=Window_GetElement(window,OxO2bb2[0x9],true);var optAbsMiddle=Window_GetElement(window,OxO2bb2[0xa],true);var optBaseline=Window_GetElement(window,OxO2bb2[0xb],true);var optAbsBottom=Window_GetElement(window,OxO2bb2[0xc],true);var optBottom=Window_GetElement(window,OxO2bb2[0xd],true);var optMiddle=Window_GetElement(window,OxO2bb2[0xe],true);var optTop=Window_GetElement(window,OxO2bb2[0xf],true);var Border=Window_GetElement(window,OxO2bb2[0x10],true);var bordercolor=Window_GetElement(window,OxO2bb2[0x11],true);var bordercolor_Preview=Window_GetElement(window,OxO2bb2[0x12],true);var inp_width=Window_GetElement(window,OxO2bb2[0x13],true);var imgLock=Window_GetElement(window,OxO2bb2[0x14],true);var inp_height=Window_GetElement(window,OxO2bb2[0x15],true);var constrain_prop=Window_GetElement(window,OxO2bb2[0x16],true);var HSpace=Window_GetElement(window,OxO2bb2[0x17],true);var VSpace=Window_GetElement(window,OxO2bb2[0x18],true);var outer=Window_GetElement(window,OxO2bb2[0x19],true);var img_demo=Window_GetElement(window,OxO2bb2[0x1a],true); btnbrowse[OxO2bb2[0x1b]]=function btnbrowse_onclick(){ function Ox20e(Ox330){if(Ox330){ function Actualsize(){var Oxde= new Image(); Oxde[OxO2bb2[0x1c]]=Ox330 ;if(Oxde[OxO2bb2[0x1e]]>0x0&&Oxde[OxO2bb2[0x1d]]>0x0){ inp_width[OxO2bb2[0x1f]]=Oxde[OxO2bb2[0x1e]] ; inp_height[OxO2bb2[0x1f]]=Oxde[OxO2bb2[0x1d]] ; FireUIChanged() ;} else { setTimeout(Actualsize,0x190) ;} ;} ; inp_src[OxO2bb2[0x1f]]=Ox330 ; setTimeout(Actualsize,0x190) ;} ;} ; editor.SetNextDialogWindow(window) ;if(Browser_IsSafari()){ editor.ShowSelectImageDialog(Ox20e,inp_src.value,inp_src) ;} else { editor.ShowSelectImageDialog(Ox20e,inp_src.value) ;} ;} ; UpdateState=function UpdateState_Image(){ img_demo[OxO2bb2[0x21]][OxO2bb2[0x20]]=element[OxO2bb2[0x21]][OxO2bb2[0x20]] ;if(Browser_IsWinIE()){ img_demo.mergeAttributes(element) ;} ;if(element[OxO2bb2[0x1c]]){ img_demo[OxO2bb2[0x1c]]=element[OxO2bb2[0x1c]] ;} else { img_demo.removeAttribute(OxO2bb2[0x1c]) ;} ;} ; SyncToView=function SyncToView_Image(){var src; src=element.getAttribute(OxO2bb2[0x1c])+OxO2bb2[0x22] ;if(element.getAttribute(OxO2bb2[0x23])){ src=element.getAttribute(OxO2bb2[0x23])+OxO2bb2[0x22] ;} ; inp_src[OxO2bb2[0x1f]]=src ; inp_width[OxO2bb2[0x1f]]=element[OxO2bb2[0x1e]] ; inp_height[OxO2bb2[0x1f]]=element[OxO2bb2[0x1d]] ; inp_id[OxO2bb2[0x1f]]=element[OxO2bb2[0x24]] ;if(element[OxO2bb2[0x25]]<=0x0){ VSpace[OxO2bb2[0x1f]]=OxO2bb2[0x22] ;} else { VSpace[OxO2bb2[0x1f]]=element[OxO2bb2[0x25]] ;} ;if(element[OxO2bb2[0x26]]<=0x0){ HSpace[OxO2bb2[0x1f]]=OxO2bb2[0x22] ;} else { HSpace[OxO2bb2[0x1f]]=element[OxO2bb2[0x26]] ;} ; Border[OxO2bb2[0x1f]]=element[OxO2bb2[0x27]] ;if(Browser_IsWinIE()){ bordercolor[OxO2bb2[0x1f]]=element[OxO2bb2[0x21]][OxO2bb2[0x28]] ;} else {var arr=revertColor(element[OxO2bb2[0x21]].borderColor).split(OxO2bb2[0x29]); bordercolor[OxO2bb2[0x1f]]=arr[0x0] ;} ; bordercolor[OxO2bb2[0x21]][OxO2bb2[0x2a]]=bordercolor[OxO2bb2[0x1f]]||OxO2bb2[0x22] ; bordercolor[OxO2bb2[0x21]][OxO2bb2[0x2a]]=bordercolor[OxO2bb2[0x1f]] ; bordercolor_Preview[OxO2bb2[0x21]][OxO2bb2[0x2a]]=bordercolor[OxO2bb2[0x1f]] ; Align[OxO2bb2[0x1f]]=element[OxO2bb2[0x2b]] ; AlternateText[OxO2bb2[0x1f]]=element[OxO2bb2[0x2c]] ; longDesc[OxO2bb2[0x1f]]=element[OxO2bb2[0x4]] ;} ; SyncTo=function SyncTo_Image(element){ element[OxO2bb2[0x1c]]=inp_src[OxO2bb2[0x1f]] ; element.setAttribute(OxO2bb2[0x23],inp_src.value) ; element[OxO2bb2[0x27]]=Border[OxO2bb2[0x1f]] ; element[OxO2bb2[0x26]]=HSpace[OxO2bb2[0x1f]] ; element[OxO2bb2[0x25]]=VSpace[OxO2bb2[0x1f]] ;try{ element[OxO2bb2[0x1e]]=inp_width[OxO2bb2[0x1f]] ; element[OxO2bb2[0x1d]]=inp_height[OxO2bb2[0x1f]] ;} catch(er){ alert(OxO2bb2[0x2d]) ;return false;} ;if(element[OxO2bb2[0x21]][OxO2bb2[0x1e]]||element[OxO2bb2[0x21]][OxO2bb2[0x1d]]){try{ element[OxO2bb2[0x21]][OxO2bb2[0x1e]]=inp_width[OxO2bb2[0x1f]] ; element[OxO2bb2[0x21]][OxO2bb2[0x1d]]=inp_height[OxO2bb2[0x1f]] ;} catch(er){ alert(OxO2bb2[0x2d]) ;return false;} ;} ;var Ox268=/[^a-zd]/i;if(Ox268.test(inp_id.value)){ alert(OxO2bb2[0x2e]) ;return ;} ; element[OxO2bb2[0x24]]=inp_id[OxO2bb2[0x1f]] ; element[OxO2bb2[0x2b]]=Align[OxO2bb2[0x1f]] ; element[OxO2bb2[0x2c]]=AlternateText[OxO2bb2[0x1f]] ; element[OxO2bb2[0x4]]=longDesc[OxO2bb2[0x1f]] ; element[OxO2bb2[0x21]][OxO2bb2[0x28]]=bordercolor[OxO2bb2[0x1f]] ;if(element[OxO2bb2[0x4]]==OxO2bb2[0x22]){ element.removeAttribute(OxO2bb2[0x4]) ;} ;if(element[OxO2bb2[0x1e]]==0x0){ element.removeAttribute(OxO2bb2[0x1e]) ;} ;if(element[OxO2bb2[0x1d]]==0x0){ element.removeAttribute(OxO2bb2[0x1d]) ;} ;if(element[OxO2bb2[0x26]]==OxO2bb2[0x22]){ element.removeAttribute(OxO2bb2[0x26]) ;} ;if(element[OxO2bb2[0x25]]==OxO2bb2[0x22]){ element.removeAttribute(OxO2bb2[0x25]) ;} ;if(element[OxO2bb2[0x24]]==OxO2bb2[0x22]){ element.removeAttribute(OxO2bb2[0x24]) ;} ;} ; function toggleConstrains(){if(constrain_prop[OxO2bb2[0x2f]]){ imgLock[OxO2bb2[0x1c]]=OxO2bb2[0x30] ; checkConstrains(OxO2bb2[0x1e]) ;} else { imgLock[OxO2bb2[0x1c]]=OxO2bb2[0x31] ;} ;} ;var checkingConstrains=false; function checkConstrains(Oxdb){if(checkingConstrains){return ;} ; checkingConstrains=true ;try{var Oxe,Ox29;if(constrain_prop[OxO2bb2[0x2f]]){var Oxde= new Image(); Oxde[OxO2bb2[0x1c]]=inp_src[OxO2bb2[0x1f]] ;var Ox315=Oxde[OxO2bb2[0x1e]];var Ox316=Oxde[OxO2bb2[0x1d]];if((Ox315>0x0)&&(Ox316>0x0)){var Oxd5=inp_width[OxO2bb2[0x1f]];var Oxd4=inp_height[OxO2bb2[0x1f]];if(Oxdb==OxO2bb2[0x1e]){if(Oxd5[OxO2bb2[0x32]]==0x0||isNaN(Oxd5)){ inp_width[OxO2bb2[0x1f]]=OxO2bb2[0x22] ; inp_height[OxO2bb2[0x1f]]=OxO2bb2[0x22] ;} else { Oxd4=parseInt(Oxd5*Ox316/Ox315) ; inp_height[OxO2bb2[0x1f]]=Oxd4 ;} ;} ;if(Oxdb==OxO2bb2[0x1d]){if(Oxd4[OxO2bb2[0x32]]==0x0||isNaN(Oxd4)){ inp_width[OxO2bb2[0x1f]]=OxO2bb2[0x22] ; inp_height[OxO2bb2[0x1f]]=OxO2bb2[0x22] ;} else { Oxd5=parseInt(Oxd4*Ox315/Ox316) ; inp_width[OxO2bb2[0x1f]]=Oxd5 ;} ;} ;} ;} ;} finally{ checkingConstrains=false ;} ;} ;if(!Browser_IsWinIE()){ bordercolor[OxO2bb2[0x1b]]=bordercolor_Preview[OxO2bb2[0x1b]]=function bordercolor_onclick(){ SelectColor(bordercolor,bordercolor_Preview) ;} ;} ;