1 |
- var __securemail=function(b){var l=function(d){function g(a){if(!a)return alert("UI load error."),!1;var b=document.createElement("div");document.body.insertBefore(b,document.body.firstChild);b.innerHTML=a;return!0}function f(a){d.onConfirm(d.args.algorithm,d.args.data,a,d.args.decryptData)}var e=function(){var a=window.XMLHttpRequest?new window.XMLHttpRequest:new ActiveXObject("MSXML2.XMLHTTP.3.0");a.open("GET",b.ESVS.SRCPath+"unisignweb/rsrc/layout/securemail.html?version="+b.ver,!1);a.send(null);return a.responseText},h=function(){var a=window.XMLHttpRequest?new window.XMLHttpRequest:new ActiveXObject("MSXML2.XMLHTTP.3.0");a.open("GET",b.ESVS.SRCPath+"unisignweb/rsrc/lang/"+b.ESVS.Language+"/securemail_"+b.ESVS.Language+".js?version="+b.ver,!1);a.send(null);return a.responseText},k=b.ESVS.TabIndex;return function(){var a=b.CustomEval(e),c=b.CustomEval(h,!0);g(a());document.getElementById("us-secure-mail-lbl-title").appendChild(document.createTextNode(c.IDS_KEY_TYPE2[d.args.mode]+c.IDS_PASSWORD_TITLE));a=document.getElementById("us-cert-manage-logo-img");a.setAttribute("alt",c.IDS_LOGO,0);a.setAttribute("src",b.ESVS.SRCPath+"unisignweb/rsrc/img/securemail_title.jpg",0);a=document.getElementById("us-secure-mail-lock-img");a.setAttribute("alt",c.IDS_PWD_IMG,0);a.setAttribute("src",b.ESVS.SRCPath+"unisignweb/rsrc/img/passwd.png",0);a=document.getElementById("us-div-secure-mail-content");a.appendChild(document.createTextNode(c.IDS_POPUP_LETTER));a.appendChild(document.createElement("br"));a.appendChild(document.createTextNode(c.IDS_POPUP_LETTER2+c.IDS_KEY_TYPE[d.args.mode]+c.IDS_POPUP_LETTER3));a=document.getElementById("us-div-secure-mail-input-lbl");0==d.args.mode?a.appendChild(document.createTextNode(c.IDS_ENTER_CORPARATENUM)):a.appendChild(document.createTextNode(c.IDS_ENTER_SSN));a=document.getElementById("us-secure-mail-confirm-btn");a.setAttribute("value",c.IDS_BTN_OK,0);a.setAttribute("title",c.IDS_BTN_OK+c.IDS_BUTTON,0);a.setAttribute("tabindex",k+1,0);a.onclick=function(){f(c)};a=document.getElementById("us-secure-mail-cancel-btn");a.setAttribute("value",c.IDS_BTN_CANCEL,0);a.setAttribute("title",c.IDS_BTN_CANCEL+c.IDS_BUTTON,0);a.setAttribute("tabindex",k+2,0);a.onclick=function(){d.onCancel()};a=document.getElementById("us-secure-mail-cls-img-btn");a.setAttribute("alt",c.IDS_CERT_VIEW_CLOSE,0);a.setAttribute("tabindex",k+3,0);a.onclick=function(){d.onCancel()};a=document.getElementById("us-secure-mail-cls-btn-img");a.setAttribute("alt",c.IDS_CERT_VIEW_CLOSE,0);a.setAttribute("src",b.ESVS.SRCPath+"unisignweb/rsrc/img/btn_close_16x16.png",0);a=document.getElementById("us-input-secure-mail-password");a.setAttribute("tabindex",k,0);a.focus();a.onkeydown=function(a){null!=a&&"undefined"!=a&&13==a.keyCode&&f(c)};return document.getElementById("us-div-secure-mail")}()};return function(d){var g=b.uiLayerLevel,f=b.uiUtil().getOverlay(g),e=l({type:d.type,args:d.args,onConfirm:d.onConfirm,onCancel:d.onCancel});e.style.zIndex=g+1;var h=function(){b.ESVS.TargetObj?b.ESVS.TargetObj.insertBefore(f,b.ESVS.TargetObj.firstChild):setTimeout(h,300)};h();return{show:function(){draggable(e,document.getElementById("us-div-secure-mail-title"));f.style.display="block";e.style.top=b.uiUtil().getScrollTop()+(b.uiUtil().getViewportHeight()-b.uiUtil().getNumSize(b.uiUtil().getStyle(e,"height","height")))/3+"px";e.style.left=b.uiUtil().getScrollLeft()+(b.uiUtil().getViewportWidth()-b.uiUtil().getNumSize(b.uiUtil().getStyle(e,"width","width")))/2+"px";e.style.display="block";b.uiLayerLevel+=10;b.ESVS.TabIndex+=20;setTimeout(function(){var b=e.getElementsByTagName("div");if(0<b.length)for(var a=0;a<b.length;a++)"us-sw-info-lbl"==b[a].id&&b[a].focus()},10)},hide:function(){f.style.display="none";e.style.display="none"},dispose:function(){e.parentNode.parentNode.removeChild(e.parentNode);f.parentNode.removeChild(f);b.uiLayerLevel-=10;b.ESVS.TabIndex-=20}}}};
|