(function(L){if(/1\.(0|1|2)\.(0|1|2)/.test(L.fn.jquery)||/^1.1/.test(L.fn.jquery)){alert("blockUI requires jQuery v1.2.3 or later!  You are using v"+L.fn.jquery);return}L.fn._fadeIn=L.fn.fadeIn;var J=document.documentMode||0;var K=L.browser.msie&&((L.browser.version<8&&!J)||J<8);var D=L.browser.msie&&/MSIE 6.0/.test(navigator.userAgent)&&!J;L.blockUI=function(O){M(window,O)};L.unblockUI=function(O){A(window,O)};L.growlUI=function(R,S,O,Q){var P=L('<div class="growlUI"></div>');if(R){P.append("<h1>"+R+"</h1>")}if(S){P.append("<h2>"+S+"</h2>")}if(O==undefined){O=3000}L.blockUI({message:P,fadeIn:700,fadeOut:1000,centerY:false,timeout:O,showOverlay:false,onUnblock:Q,css:L.blockUI.defaults.growlCSS})};L.fn.block=function(O){return this.unblock({fadeOut:0}).each(function(){if(L.css(this,"position")=="static"){this.style.position="relative"}if(L.browser.msie){this.style.zoom=1}M(this,O)})};L.fn.unblock=function(O){return this.each(function(){A(this,O)})};L.blockUI.version=2.23;L.blockUI.defaults={message:"<h1>Please wait...</h1>",css:{padding:0,margin:0,width:"30%",top:"40%",left:"35%",textAlign:"center",color:"#000",border:"3px solid #aaa",backgroundColor:"#fff",cursor:"wait"},overlayCSS:{backgroundColor:"#000",opacity:0.6,cursor:"wait"},growlCSS:{width:"350px",top:"10px",left:"",right:"10px",border:"none",padding:"5px",opacity:0.6,cursor:null,color:"#fff",backgroundColor:"#000","-webkit-border-radius":"10px","-moz-border-radius":"10px"},iframeSrc:/^https/i.test(window.location.href||"")?"javascript:false":"about:blank",forceIframe:false,baseZ:1000,centerX:true,centerY:true,allowBodyStretch:true,bindEvents:true,constrainTabKey:true,fadeIn:200,fadeOut:400,timeout:0,showOverlay:true,focusInput:true,applyPlatformOpacityRules:true,onUnblock:null,quirksmodeOffsetHack:4};var H=null;var F=[];function M(e,a){var W=(e==window);var S=a&&a.message!==undefined?a.message:undefined;a=L.extend({},L.blockUI.defaults,a||{});a.overlayCSS=L.extend({},L.blockUI.defaults.overlayCSS,a.overlayCSS||{});var Z=L.extend({},L.blockUI.defaults.css,a.css||{});S=S===undefined?a.message:S;if(W&&H){A(window,{fadeOut:0})}if(S&&typeof S!="string"&&(S.parentNode||S.jquery)){var Y=S.jquery?S[0]:S;var c={};L(e).data("blockUI.history",c);c.el=Y;c.parent=Y.parentNode;c.display=Y.style.display;c.position=Y.style.position;if(c.parent){c.parent.removeChild(Y)}}var d=a.baseZ;var R=(L.browser.msie||a.forceIframe)?L('<iframe class="blockUI" style="z-index:'+(d++)+';display:none;border:none;margin:0;padding:0;position:absolute;width:100%;height:100%;top:0;left:0" src="'+a.iframeSrc+'"></iframe>'):L('<div class="blockUI" style="display:none"></div>');var X=L('<div class="blockUI blockOverlay" style="z-index:'+(d++)+';display:none;border:none;margin:0;padding:0;width:100%;height:100%;top:0;left:0"></div>');var O=W?L('<div class="blockUI blockMsg blockPage" style="z-index:'+d+';display:none;position:fixed"></div>'):L('<div class="blockUI blockMsg blockElement" style="z-index:'+d+';display:none;position:absolute"></div>');if(S){O.css(Z)}if(!a.applyPlatformOpacityRules||!(L.browser.mozilla&&/Linux/.test(navigator.platform))){X.css(a.overlayCSS)}X.css("position",W?"fixed":"absolute");if(L.browser.msie||a.forceIframe){R.css("opacity",0)}L([R[0],X[0],O[0]]).appendTo(W?"body":e);var b=K&&(!L.boxModel||L("object,embed",W?null:e).length>0);if(D||b){if(W&&a.allowBodyStretch&&L.boxModel){L("html,body").css("height","100%")}if((D||!L.boxModel)&&!W){var Q=B(e,"borderTopWidth"),U=B(e,"borderLeftWidth");var V=Q?"(0 - "+Q+")":0;var T=U?"(0 - "+U+")":0}L.each([R,X,O],function(f,h){var g=h[0].style;g.position="absolute";if(f<2){W?g.setExpression("height","Math.max(document.body.scrollHeight, document.body.offsetHeight) - (jQuery.boxModel?0:"+a.quirksmodeOffsetHack+') + "px"'):g.setExpression("height",'this.parentNode.offsetHeight + "px"');W?g.setExpression("width",'jQuery.boxModel && document.documentElement.clientWidth || document.body.clientWidth + "px"'):g.setExpression("width",'this.parentNode.offsetWidth + "px"');if(T){g.setExpression("left",T)}if(V){g.setExpression("top",V)}}else{if(a.centerY){if(W){g.setExpression("top",'(document.documentElement.clientHeight || document.body.clientHeight) / 2 - (this.offsetHeight / 2) + (blah = document.documentElement.scrollTop ? document.documentElement.scrollTop : document.body.scrollTop) + "px"')}g.marginTop=0}else{if(!a.centerY&&W){var j=(a.css&&a.css.top)?parseInt(a.css.top):0;var k="((document.documentElement.scrollTop ? document.documentElement.scrollTop : document.body.scrollTop) + "+j+') + "px"';g.setExpression("top",k)}}}})}if(S){O.append(S);if(S.jquery||S.nodeType){L(S).show()}}if((L.browser.msie||a.forceIframe)&&a.showOverlay){R.show()}if(a.fadeIn){if(a.showOverlay){X._fadeIn(a.fadeIn)}if(S){O.fadeIn(a.fadeIn)}}else{if(a.showOverlay){X.show()}if(S){O.show()}}C(1,e,a);if(W){H=O[0];F=L(":input:enabled:visible",H);if(a.focusInput){setTimeout(N,20)}}else{I(O[0],a.centerX,a.centerY)}if(a.timeout){var P=setTimeout(function(){W?L.unblockUI(a):L(e).unblock(a)},a.timeout);L(e).data("blockUI.timeout",P)}}function A(O,P){var T=O==window;var S=L(O);var U=S.data("blockUI.history");var Q=S.data("blockUI.timeout");if(Q){clearTimeout(Q);S.removeData("blockUI.timeout")}P=L.extend({},L.blockUI.defaults,P||{});C(0,O,P);var R=T?L("body").children().filter(".blockUI"):L(".blockUI",O);if(T){H=F=null}if(P.fadeOut){R.fadeOut(P.fadeOut);setTimeout(function(){E(R,U,P,O)},P.fadeOut)}else{E(R,U,P,O)}}function E(Q,R,P,O){Q.each(function(S,T){if(this.parentNode){this.parentNode.removeChild(this)}});if(R&&R.el){R.el.style.display=R.display;R.el.style.position=R.position;if(R.parent){R.parent.appendChild(R.el)}L(R.el).removeData("blockUI.history")}if(typeof P.onUnblock=="function"){P.onUnblock(O,P)}}function C(Q,O,P){var T=O==window,R=L(O);if(!Q&&(T&&!H||!T&&!R.data("blockUI.isBlocked"))){return}if(!T){R.data("blockUI.isBlocked",Q)}if(!P.bindEvents||(Q&&!P.showOverlay)){return}var S="mousedown mouseup keydown keypress";Q?L(document).bind(S,P,G):L(document).unbind(S,G)}function G(P){if(P.keyCode&&P.keyCode==9){if(H&&P.data.constrainTabKey){var Q=F;var R=!P.shiftKey&&P.target==Q[Q.length-1];var O=P.shiftKey&&P.target==Q[0];if(R||O){setTimeout(function(){N(O)},10);return false}}}if(L(P.target).parents("div.blockMsg").length>0){return true}return L(P.target).parents().children().filter("div.blockUI").length==0}function N(O){if(!F){return}var P=F[O===true?F.length-1:0];if(P){P.focus()}}function I(O,S,T){var Q=O.parentNode,P=O.style;var R=((Q.offsetWidth-O.offsetWidth)/2)-B(Q,"borderLeftWidth");var U=((Q.offsetHeight-O.offsetHeight)/2)-B(Q,"borderTopWidth");if(S){P.left=R>0?(R+"px"):"0"}if(T){P.top=U>0?(U+"px"):"0"}}function B(O,P){return parseInt(L.css(O,P))||0}})(jQuery);