if(typeof(pageelements_js)=="undefined"){pageelements_js=true;var kSeparator=0;var kActive=1;var kInactive=2;var kDisabled=3;var kSingleSelect=0;var kMultipleSelect=1;var kCustomSelect=2;function NQBtnBarBtn(d,c,a,b){this.sName=d;this.bAutoUnique=(c==null?false:c);this.sImg=a;this.eStatus=b;return this}function NQBtnBar_PushButton(c,a,b,d){this.vButtons[this.vButtons.length]=new NQBtnBarBtn(c,a,b,d)}function NQBtnBar_EncodeState(g){var f="~";var a=this.vButtons;var d="";var e=0;for(var c=0;c!=a.length;++c){var b=a[c];if(b!=null){if(!g&&b.eStatus==kSeparator){continue}if(e>0){d+=f}++e;d+=b.sName+f+b.bAutoUnique+f+b.eStatus}}if(e>0){d=e+f+d}return d}function NQBtnBar_GetButton(a){return this.vButtons[a]}function NQBtnBar_NumButtons(){return this.vButtons.length}function NQBtnBar(){this.vButtons=new Array();this.EncodeState=NQBtnBar_EncodeState;this.GetButton=NQBtnBar_GetButton;this.PushButton=NQBtnBar_PushButton;this.NumButtons=NQBtnBar_NumButtons;this.sUserParam="";return this}function NQBtnBarArrayEncode(f,g){var e="~";var c="";var b=false;for(var a=0;a!=f.length;++a){var d=f[a];if(d!=null){if(b){c+=e}else{b=true}c+=d.sUserParam+e+d.EncodeState(g)}}return c}function onBtnBarClick(){var a=onBtnBarClick;var h=a.arguments[0];var e=a.arguments[1];var g=a.arguments[2];var f=3;var b=a.arguments.length-f;var c=true;if(g!=null){switch(b){case 0:c=g(h,e);break;case 1:c=g(h,e,a.arguments[f]);break;case 2:c=g(h,e,a.arguments[f],a.arguments[f+1]);break;case 3:c=g(h,e,a.arguments[f],a.arguments[f+1],a.arguments[f+2]);break;case 4:c=g(h,e,a.arguments[f],a.arguments[f+1],a.arguments[f+2],a.arguments[f+3]);break}}if((c==true)&&(h.eType!=kCustomSelect)){var j=h.GetButton(e);if(!j){return}if(j.eStatus==kActive){document.images[j.sName].src=WebScriptMapGet(j.sImg+"_off.gif");j.eStatus=kInactive}else{if(j.eStatus==kInactive){document.images[j.sName].src=WebScriptMapGet(j.sImg+".gif");j.eStatus=kActive}}if(h.eType==kSingleSelect){for(var d=0;d<h.NumButtons();++d){var j=h.GetButton(d);if((j.eStatus==kActive)&&(d!=e)){document.images[j.sName].src=WebScriptMapGet(j.sImg+"_off.gif");j.eStatus=kInactive}}}}}function ExpandCollapse(a,d){var b=document.getElementById(a);if(b.style.display=="none"){b.style.display="";var e=b.offsetTop-saw.getEventTarget(d).offsetHeight;var c=b.offsetHeight+saw.getEventTarget(d).offsetHeight;while(b.offsetParent!=null){b=b.offsetParent;e+=b.offsetTop}if(c<document.body.clientHeight){if(e+c>document.body.scrollTop+document.body.clientHeight){document.body.scrollTop=e+c-document.body.clientHeight}}else{document.body.scrollTop=e}}else{b.style.display="none"}saw.stopEventPropagation(d)}function PreloadImages(a){if(document.images){pics=new Array();for(i=0;i<PreloadImages.arguments.length;i++){pics[i]=new Image();pics[i].src=PreloadImages.arguments[i]}}}function ImgOn(a,b){if(document.images){document.images[a].src=b+"_over.gif"}}function ImgOff(a,b){if(document.images){document.images[a].src=b+".gif"}}};