if(typeof(Control)=="undefined"){Control={}}var $proc=function(a){return typeof(a)=="function"?a:function(){return a}};var $value=function(a){return typeof(a)=="function"?a():a};Object.Event={extend:function(a){a._objectEventSetup=function(b){this._observers=this._observers||{};this._observers[b]=this._observers[b]||[]};a.observe=function(d,b){if(typeof(d)=="string"&&typeof(b)!="undefined"){this._objectEventSetup(d);if(!this._observers[d].include(b)){this._observers[d].push(b)}}else{for(var c in d){this.observe(c,d[c])}}};a.stopObserving=function(c,b){this._objectEventSetup(c);if(c&&b){this._observers[c]=this._observers[c].without(b)}else{if(c){this._observers[c]=[]}else{this._observers={}}}};a.observeOnce=function(d,c){var b=function(){c.apply(this,arguments);this.stopObserving(d,b)}.bind(this);this._objectEventSetup(d);this._observers[d].push(b)};a.notify=function(g){this._objectEventSetup(g);var d=[];var b=$A(arguments).slice(1);try{for(var c=0;c<this._observers[g].length;++c){d.push(this._observers[g][c].apply(this._observers[g][c],b)||null)}}catch(f){if(f==$break){return false}else{throw f}}return d};if(a.prototype){a.prototype._objectEventSetup=a._objectEventSetup;a.prototype.observe=a.observe;a.prototype.stopObserving=a.stopObserving;a.prototype.observeOnce=a.observeOnce;a.prototype.notify=function(g){if(a.notify){var b=$A(arguments).slice(1);b.unshift(this);b.unshift(g);a.notify.apply(a,b)}this._objectEventSetup(g);var b=$A(arguments).slice(1);var d=[];try{if(this.options&&this.options[g]&&typeof(this.options[g])=="function"){d.push(this.options[g].apply(this,b)||null)}for(var c=0;c<this._observers[g].length;++c){d.push(this._observers[g][c].apply(this._observers[g][c],b)||null)}}catch(f){if(f==$break){return false}else{throw f}}return d}}}};Element.addMethods({observeOnce:function(c,d,b){var a=function(){b.apply(this,arguments);Element.stopObserving(c,d,a)};Element.observe(c,d,a)}});Object.extend(Event,(function(){var b=Event.cache;function c(j){if(j._prototypeEventID){return j._prototypeEventID[0]}arguments.callee.id=arguments.callee.id||1;return j._prototypeEventID=[++arguments.callee.id]}function g(j){if(j&&j.include(":")){return"dataavailable"}if(!Prototype.Browser.IE){j={mouseenter:"mouseover",mouseleave:"mouseout"}[j]||j}return j}function a(j){return b[j]=b[j]||{}}function f(l,j){var k=a(l);return k[j]=k[j]||[]}function h(k,j,l){var o=c(k);var n=f(o,j);if(n.pluck("handler").include(l)){return false}var m=function(p){if(!Event||!Event.extend||(p.eventName&&p.eventName!=j)){return false}Event.extend(p);l.call(k,p)};if(!(Prototype.Browser.IE)&&["mouseenter","mouseleave"].include(j)){m=m.wrap(function(r,q){var p=q.relatedTarget;var s=q.currentTarget;if(p&&p.nodeType==Node.TEXT_NODE){p=p.parentNode}if(p&&p!=s&&!p.descendantOf(s)){return r(q)}})}m.handler=l;n.push(m);return m}function i(m,j,k){var l=f(m,j);return l.find(function(n){return n.handler==k})}function d(m,j,k){var l=a(m);if(!l[j]){return false}l[j]=l[j].without(i(m,j,k))}function e(){for(var k in b){for(var j in b[k]){b[k][j]=null}}}if(window.attachEvent){window.attachEvent("onunload",e)}return{observe:function(l,j,m){l=$(l);var k=g(j);var n=h(l,j,m);if(!n){return l}if(l.addEventListener){l.addEventListener(k,n,false)}else{l.attachEvent("on"+k,n)}return l},stopObserving:function(l,j,m){l=$(l);var o=c(l),k=g(j);if(!m&&j){f(o,j).each(function(p){l.stopObserving(j,p.handler)});return l}else{if(!j){Object.keys(a(o)).each(function(p){l.stopObserving(p)});return l}}var n=i(o,j,m);if(!n){return l}if(l.removeEventListener){l.removeEventListener(k,n,false)}else{l.detachEvent("on"+k,n)}d(o,j,m);return l},fire:function(l,k,j){l=$(l);if(l==document&&document.createEvent&&!l.dispatchEvent){l=document.documentElement}var m;if(document.createEvent){m=document.createEvent("HTMLEvents");m.initEvent("dataavailable",true,true)}else{m=document.createEventObject();m.eventType="ondataavailable"}m.eventName=k;m.memo=j||{};if(document.createEvent){l.dispatchEvent(m)}else{l.fireEvent(m.eventType,m)}return Event.extend(m)}}})());Object.extend(Event,Event.Methods);Element.addMethods({fire:Event.fire,observe:Event.observe,stopObserving:Event.stopObserving});Object.extend(document,{fire:Element.Methods.fire.methodize(),observe:Element.Methods.observe.methodize(),stopObserving:Element.Methods.stopObserving.methodize()});(function(){function a(c){var d;if(c.wheelDelta){d=c.wheelDelta/120}else{if(c.detail){d=-c.detail/3}}if(!d){return}var b=c.element().fire("mouse:wheel",{delta:d});if(b.stopped){c.stop();return false}}document.observe("mousewheel",a);document.observe("DOMMouseScroll",a)})();var IframeShim=Class.create({initialize:function(){this.element=new Element("iframe",{style:"position:absolute;filter:progid:DXImageTransform.Microsoft.Alpha(opacity=0);display:none",src:"javascript:void(0);",frameborder:0});$(document.body).insert(this.element)},hide:function(){this.element.hide();return this},show:function(){this.element.show();return this},positionUnder:function(a){var a=$(a);var c=a.cumulativeOffset();var b=a.getDimensions();this.element.setStyle({left:c[0]+"px",top:c[1]+"px",width:b.width+"px",height:b.height+"px",zIndex:a.getStyle("zIndex")-1}).show();return this},setBounds:function(a){for(prop in a){a[prop]+="px"}this.element.setStyle(a);return this},destroy:function(){if(this.element){this.element.remove()}return this}});if(typeof(Prototype)=="undefined"){throw"Control.ScrollBar requires Prototype to be loaded."}if(typeof(Control.Slider)=="undefined"){throw"Control.ScrollBar requires Control.Slider to be loaded."}if(typeof(Object.Event)=="undefined"){throw"Control.ScrollBar requires Object.Event to be loaded."}Control.ScrollBar=Class.create({initialize:function(b,a,c){this.enabled=false;this.notificationTimeout=false;this.container=$(b);this.boundMouseWheelEvent=this.onMouseWheel.bindAsEventListener(this);this.boundResizeObserver=this.onWindowResize.bind(this);this.track=$(a);this.handle=this.track.firstDescendant();this.options=Object.extend({active_class_name:"scrolling",apply_active_class_name_to:this.container,notification_timeout_length:125,handle_minimum_height:25,scroll_to_smoothing:0.01,scroll_to_steps:15,proportional:true,slider_options:{}},c||{});this.slider=new Control.Slider(this.handle,this.track,Object.extend({axis:"vertical",onSlide:this.onChange.bind(this),onChange:this.onChange.bind(this)},this.options.slider_options));this.recalculateLayout();Event.observe(window,"resize",this.boundResizeObserver);this.handle.observe("mousedown",function(){if(this.auto_sliding_executer){this.auto_sliding_executer.stop()}}.bind(this))},destroy:function(){Event.stopObserving(window,"resize",this.boundResizeObserver)},enable:function(){this.enabled=true;this.container.observe("mouse:wheel",this.boundMouseWheelEvent);this.slider.setEnabled();this.track.show();if(this.options.active_class_name){$(this.options.apply_active_class_name_to).addClassName(this.options.active_class_name)}this.notify("enabled")},disable:function(){this.enabled=false;this.container.stopObserving("mouse:wheel",this.boundMouseWheelEvent);this.slider.setDisabled();this.track.hide();if(this.options.active_class_name){$(this.options.apply_active_class_name_to).removeClassName(this.options.active_class_name)}this.notify("disabled");this.reset()},reset:function(){this.slider.setValue(0)},recalculateLayout:function(){if(this.container.scrollHeight<=this.container.offsetHeight){this.disable()}else{this.slider.trackLength=this.slider.maximumOffset()-this.slider.minimumOffset();if(this.options.proportional){this.handle.style.height=Math.max(this.container.offsetHeight*(this.container.offsetHeight/this.container.scrollHeight),this.options.handle_minimum_height)+"px";this.slider.handleLength=this.handle.style.height.replace(/px/,"")}this.enable()}},onWindowResize:function(){this.recalculateLayout();this.scrollBy(0)},onMouseWheel:function(a){if(this.auto_sliding_executer){this.auto_sliding_executer.stop()}this.slider.setValueBy(-(a.memo.delta/20));a.stop();return false},onChange:function(a){this.container.scrollTop=Math.round(a/this.slider.maximum*(this.container.scrollHeight-this.container.offsetHeight));if(this.notification_timeout){window.clearTimeout(this.notificationTimeout)}this.notificationTimeout=window.setTimeout(function(){this.notify("change",a)}.bind(this),this.options.notification_timeout_length)},getCurrentMaximumDelta:function(){return this.slider.maximum*(this.container.scrollHeight-this.container.offsetHeight)},getCurrentSliderValue:function(){return this.slider.value*this.getCurrentMaximumDelta()},getDeltaToElement:function(a){return this.slider.maximum*((a.positionedOffset().top+(a.getHeight()/2))-(this.container.getHeight()/2))},scrollTo:function(f,a){var c=this.getCurrentMaximumDelta();if(f=="top"){f=0}else{if(f=="bottom"){f=c}else{if(typeof(f)!="number"){f=this.getDeltaToElement($(f))}}}if(this.enabled){f=Math.max(0,Math.min(f,c));if(this.auto_sliding_executer){this.auto_sliding_executer.stop()}var b=f/c;var e=this.slider.value;var d=(b-e)*c;if(a){this.auto_sliding_executer=new PeriodicalExecuter(function(){if(Math.round(this.slider.value*100)/100<Math.round(b*100)/100||Math.round(this.slider.value*100)/100>Math.round(b*100)/100){this.scrollBy(d/this.options.scroll_to_steps)}else{this.auto_sliding_executer.stop();this.auto_sliding_executer=null;if(typeof(a)=="function"){a()}}}.bind(this),this.options.scroll_to_smoothing)}else{this.scrollBy(d)}}else{if(typeof(a)=="function"){a()}}},scrollBy:function(a){if(!this.enabled){return false}this.slider.setValueBy(a/this.getCurrentMaximumDelta())}});Object.Event.extend(Control.ScrollBar);var tooltip=function(){var d="tt";var r=3;var g=3;var q=300;var i=500;var e=20;var m=95;var j=0;var n,s,o,p,l;var k,f;var a=document.all?true:false;return{show:function(c,b){if(n==null){n=document.createElement("div");n.setAttribute("id",d);s=document.createElement("div");s.setAttribute("id",d+"top");o=document.createElement("div");o.setAttribute("id",d+"cont");p=document.createElement("div");p.setAttribute("id",d+"bot");n.appendChild(s);n.appendChild(o);n.appendChild(p);document.body.appendChild(n);n.style.opacity=0;n.style.filter="alpha(opacity=0)";document.onmousemove=this.pos}k=findPosX(c);f=findPosY(c);this.pos;n.style.zIndex="50";n.style.top=(f-35)+"px";n.style.left=(k+20)+"px";n.style.display="block";n.style.width="250";if(!isNaN(c.getAttribute("longDesc"))){o.innerHTML=InfoText[c.getAttribute("longDesc")]}else{o.innerHTML=c.getAttribute("longDesc")}if(!b&&a){s.style.display="none";p.style.display="none";n.style.width=n.offsetWidth;s.style.display="block";p.style.display="block"}if(n.offsetWidth>q){n.style.width=q+"px"}l=parseInt(n.offsetHeight)+r;clearInterval(n.timer);n.timer=setInterval(function(){tooltip.fade(1)},e)},pos:function(h){var c=a?event.clientY+document.documentElement.scrollTop:h.pageY;var b=a?event.clientX+document.documentElement.scrollLeft:h.pageX;if(Math.abs(b-k)>200){k=b;n.style.left=(k+20)+"px"}if(Math.abs(c-f)>200){f=c;n.style.top=(f-20)+"px"}},fade:function(h){var b=j;if((b!=m&&h==1)||(b!=0&&h==-1)){var c=i;if(m-b<i&&h==1){c=m-b}else{if(j<i&&h==-1){c=b}}j=b+(c*h);n.style.opacity=j*0.01;n.style.filter="alpha(opacity="+j+")"}else{clearInterval(n.timer);if(h==-1){n.style.display="none"}}},hide:function(){clearInterval(n.timer);n.timer=setInterval(function(){tooltip.fade(-1)},e)}}}();if(typeof(Control)=="undefined"){Control={}}var $proc=function(a){return typeof(a)=="function"?a:function(){return a}};var $value=function(a){return typeof(a)=="function"?a():a};Object.Event={extend:function(a){a._objectEventSetup=function(b){this._observers=this._observers||{};this._observers[b]=this._observers[b]||[]};a.observe=function(d,b){if(typeof(d)=="string"&&typeof(b)!="undefined"){this._objectEventSetup(d);if(!this._observers[d].include(b)){this._observers[d].push(b)}}else{for(var c in d){this.observe(c,d[c])}}};a.stopObserving=function(c,b){this._objectEventSetup(c);if(c&&b){this._observers[c]=this._observers[c].without(b)}else{if(c){this._observers[c]=[]}else{this._observers={}}}};a.observeOnce=function(d,c){var b=function(){c.apply(this,arguments);this.stopObserving(d,b)}.bind(this);this._objectEventSetup(d);this._observers[d].push(b)};a.notify=function(g){this._objectEventSetup(g);var d=[];var b=$A(arguments).slice(1);try{for(var c=0;c<this._observers[g].length;++c){d.push(this._observers[g][c].apply(this._observers[g][c],b)||null)}}catch(f){if(f==$break){return false}else{throw f}}return d};if(a.prototype){a.prototype._objectEventSetup=a._objectEventSetup;a.prototype.observe=a.observe;a.prototype.stopObserving=a.stopObserving;a.prototype.observeOnce=a.observeOnce;a.prototype.notify=function(g){if(a.notify){var b=$A(arguments).slice(1);b.unshift(this);b.unshift(g);a.notify.apply(a,b)}this._objectEventSetup(g);var b=$A(arguments).slice(1);var d=[];try{if(this.options&&this.options[g]&&typeof(this.options[g])=="function"){d.push(this.options[g].apply(this,b)||null)}for(var c=0;c<this._observers[g].length;++c){d.push(this._observers[g][c].apply(this._observers[g][c],b)||null)}}catch(f){if(f==$break){return false}else{throw f}}return d}}}};Element.addMethods({observeOnce:function(c,d,b){var a=function(){b.apply(this,arguments);Element.stopObserving(c,d,a)};Element.observe(c,d,a)}});Object.extend(Event,(function(){var b=Event.cache;function c(j){if(j._prototypeEventID){return j._prototypeEventID[0]}arguments.callee.id=arguments.callee.id||1;return j._prototypeEventID=[++arguments.callee.id]}function g(j){if(j&&j.include(":")){return"dataavailable"}if(!Prototype.Browser.IE){j={mouseenter:"mouseover",mouseleave:"mouseout"}[j]||j}return j}function a(j){return b[j]=b[j]||{}}function f(l,j){var k=a(l);return k[j]=k[j]||[]}function h(k,j,l){var o=c(k);var n=f(o,j);if(n.pluck("handler").include(l)){return false}var m=function(p){if(!Event||!Event.extend||(p.eventName&&p.eventName!=j)){return false}Event.extend(p);l.call(k,p)};if(!(Prototype.Browser.IE)&&["mouseenter","mouseleave"].include(j)){m=m.wrap(function(r,q){var p=q.relatedTarget;var s=q.currentTarget;if(p&&p.nodeType==Node.TEXT_NODE){p=p.parentNode}if(p&&p!=s&&!p.descendantOf(s)){return r(q)}})}m.handler=l;n.push(m);return m}function i(m,j,k){var l=f(m,j);return l.find(function(n){return n.handler==k})}function d(m,j,k){var l=a(m);if(!l[j]){return false}l[j]=l[j].without(i(m,j,k))}function e(){for(var k in b){for(var j in b[k]){b[k][j]=null}}}if(window.attachEvent){window.attachEvent("onunload",e)}return{observe:function(l,j,m){l=$(l);var k=g(j);var n=h(l,j,m);if(!n){return l}if(l.addEventListener){l.addEventListener(k,n,false)}else{l.attachEvent("on"+k,n)}return l},stopObserving:function(l,j,m){l=$(l);var o=c(l),k=g(j);if(!m&&j){f(o,j).each(function(p){l.stopObserving(j,p.handler)});return l}else{if(!j){Object.keys(a(o)).each(function(p){l.stopObserving(p)});return l}}var n=i(o,j,m);if(!n){return l}if(l.removeEventListener){l.removeEventListener(k,n,false)}else{l.detachEvent("on"+k,n)}d(o,j,m);return l},fire:function(l,k,j){l=$(l);if(l==document&&document.createEvent&&!l.dispatchEvent){l=document.documentElement}var m;if(document.createEvent){m=document.createEvent("HTMLEvents");m.initEvent("dataavailable",true,true)}else{m=document.createEventObject();m.eventType="ondataavailable"}m.eventName=k;m.memo=j||{};if(document.createEvent){l.dispatchEvent(m)}else{l.fireEvent(m.eventType,m)}return Event.extend(m)}}})());Object.extend(Event,Event.Methods);Element.addMethods({fire:Event.fire,observe:Event.observe,stopObserving:Event.stopObserving});Object.extend(document,{fire:Element.Methods.fire.methodize(),observe:Element.Methods.observe.methodize(),stopObserving:Element.Methods.stopObserving.methodize()});(function(){function a(c){var d;if(c.wheelDelta){d=c.wheelDelta/120}else{if(c.detail){d=-c.detail/3}}if(!d){return}var b=c.element().fire("mouse:wheel",{delta:d});if(b.stopped){c.stop();return false}}document.observe("mousewheel",a);document.observe("DOMMouseScroll",a)})();var IframeShim=Class.create({initialize:function(){this.element=new Element("iframe",{style:"position:absolute;filter:progid:DXImageTransform.Microsoft.Alpha(opacity=0);display:none",src:"javascript:void(0);",frameborder:0});$(document.body).insert(this.element)},hide:function(){this.element.hide();return this},show:function(){this.element.show();return this},positionUnder:function(a){var a=$(a);var c=a.cumulativeOffset();var b=a.getDimensions();this.element.setStyle({left:c[0]+"px",top:c[1]+"px",width:b.width+"px",height:b.height+"px",zIndex:a.getStyle("zIndex")-1}).show();return this},setBounds:function(a){for(prop in a){a[prop]+="px"}this.element.setStyle(a);return this},destroy:function(){if(this.element){this.element.remove()}return this}});var TINY={};function T$(a){return document.getElementById(a)}function T$$(b,a){return a.getElementsByTagName(b)}TINY.slider=function(){function a(c,b){this.n=c;this.init(b)}a.prototype.init=function(g){var f=T$(g.id),d=this.u=T$$("ul",f)[0],h=T$$("li",d),b=h.length,e=this.l=this.c=0;if(g.navid&&g.activeclass){this.g=T$$("li",T$(g.navid));this.s=g.activeclass}this.a=g.auto||0;this.p=g.resume||0;this.v=g.vertical||0;f.style.overflow="hidden";for(e;e<b;e++){if(h[e].parentNode==d){this.l++}}if(this.v){d.style.top=0;this.h=g.height||h[0].offsetHeight;d.style.height=(this.l*this.h)+"px"}else{d.style.left=0;this.w=g.width||h[0].offsetWidth;d.style.width=(this.l*this.w)+"px"}this.pos(g.position||0,this.a?1:0)},a.prototype.auto=function(){this.u.ai=setInterval(new Function(this.n+".move(1,1)"),this.a*1000)},a.prototype.move=function(e,b){var f=this.c+e,c=e==1?f==this.l?0:f:f<0?this.l-1:f;this.pos(c,b)},a.prototype.pos=function(f,b){clearInterval(this.u.ai);clearInterval(this.u.si);var h=this.v?parseInt(this.u.style.top):parseInt(this.u.style.left),e=this.v?f*this.h:f*this.w,g=e>Math.abs(h)?1:-1;e=e*-1;this.c=f;if(this.g){for(var c=0;c<this.l;c++){this.g[c].className=c==f?this.s:""}}this.u.si=setInterval(new Function(this.n+".slide("+e+","+g+","+b+")"),20)},a.prototype.slide=function(e,g,b){var f=this.v?parseInt(this.u.style.top):parseInt(this.u.style.left);if(f==e){clearInterval(this.u.si);if(b||(this.a&&this.p)){this.auto()}}else{var c=f-Math.ceil(Math.abs(e-f)*0.15)*g+"px";this.v?this.u.style.top=c:this.u.style.left=c}};return{slide:a}}();var TINY={};function T$(a){return document.getElementById(a)}function T$$(b,a){return a.getElementsByTagName(b)}TINY.fader=function(){function a(c,b){this.n=c;this.init(b)}a.prototype.init=function(f){var e=T$(f.id),c=this.u=T$$("li",e),b=c.length,d=this.l=this.c=this.z=0;if(f.navid&&f.activeclass){this.g=T$$("li",T$(f.navid));this.s=f.activeclass}e.style.overflow="hidden";this.a=f.auto||0;this.p=f.resume||0;for(d;d<b;d++){if(c[d].parentNode==e){c[d].style.position="absolute";this.l++;c[d].o=f.visible?100:0;c[d].style.opacity=c[d].o/100;c[d].style.filter="alpha(opacity="+c[d].o+")"}}this.pos(f.position||0,this.a?1:0,f.visible)},a.prototype.auto=function(){this.u.ai=setInterval(new Function(this.n+".move(1,1)"),this.a*1000)},a.prototype.move=function(e,b){var f=this.c+e,c=e==1?f==this.l?0:f:f<0?this.l-1:f;this.pos(c,b)},a.prototype.pos=function(e,c,d){var f=this.u[e];this.z++;f.style.zIndex=this.z;clearInterval(f.si);clearInterval(this.u.ai);this.u.ai=0;this.c=e;if(f.o>=100&&!d){f.o=0;f.style.opacity=0;f.style.filter="alpha(opacity=0)"}if(this.g){for(var b=0;b<this.l;b++){this.g[b].className=b==e?this.s:""}}f.si=setInterval(new Function(this.n+".fade("+e+","+c+")"),20)},a.prototype.fade=function(c,b){var d=this.u[c];if(d.o>=100){clearInterval(d.si);if((b||(this.a&&this.p))&&!this.u.ai){this.auto()}}else{d.o+=5;d.style.opacity=d.o/100;d.style.filter="alpha(opacity="+d.o+")"}};return{fade:a}}();
