var IXF=function(){this.intervalSeconds=2;this.fadeSeconds=2;this.sources;this.quotes;this.slideImageId="slideImage";this.slideQuoteId="slideQuote";this.clock=null;this.count=1;this.loopCounter=1;};IXF.prototype.scrambleSequence=function(){var i=this.sources.length,j,temp;while(i){j=Math.floor((i--)*Math.random());temp=this.sources[i];this.sources[i]=this.sources[j];this.sources[j]=temp;if(this.quotes&&this.slideQuoteId){temp=this.quotes[i];this.quotes[i]=this.quotes[j];this.quotes[j]=temp;}}};IXF.prototype.cacheImages=function(){var _2=new Array();for(var i=0;i<this.sources.length;i++){_2[i]=new Image;_2[i].src=this.sources[i];}};IXF.prototype.initCrossfade=function(){if(this.clock==null){this.obj=arguments[0];this.src=arguments[1];if(typeof this.obj.style.opacity!="undefined"){this.type="w3c";}else{if(typeof this.obj.style.MozOpacity!="undefined"){this.type="moz";}else{if(typeof this.obj.style.KhtmlOpacity!="undefined"){this.type="khtml";}else{if(typeof this.obj.filters=="object"){this.type=(this.obj.filters.length>0&&typeof this.obj.filters.alpha=="object"&&typeof this.obj.filters.alpha.opacity=="number")?"ie":"none";}else{this.type="none";}}}}if(typeof arguments[3]!="undefined"&&arguments[3]!=""){this.obj.alt=arguments[3];}if(this.type!="none"){this.newimg=document.getElementsByTagName("body")[0].appendChild(document.createElement("img"));this.newimg.className="idupe";this.newimg.src=this.src;this.newimg.style.left=this.getRealPosition(this.obj,"x")+"px";this.newimg.style.top=this.getRealPosition(this.obj,"y")+"px";this.length=parseInt(arguments[2],10)*1000;this.resolution=parseInt(arguments[2],10)*20;var _4=this;this.clock=setInterval(function(){_4.crossfade();},this.length/this.resolution);}else{this.obj.src=this.src;}}};IXF.prototype.crossfade=function(){this.count-=(1/this.resolution);if(this.count<(1/this.resolution)){clearInterval(this.clock);this.clock=null;this.count=1;this.obj.src=this.src;}this.setOpacity(this.count);this.newimg.style.visibility="visible";if(!document.all){this.newimg.style.left=this.getRealPosition(this.obj,"x")+"px";this.newimg.style.top=this.getRealPosition(this.obj,"y")+"px";}if(this.count==1){this.newimg.parentNode.removeChild(this.newimg);}};IXF.prototype.setOpacity=function(_5){switch(this.type){case "ie":this.obj.filters.alpha.opacity=_5*100;this.newimg.filters.alpha.opacity=(1-_5)*100;break;case "khtml":this.obj.style.KhtmlOpacity=_5;this.newimg.style.KhtmlOpacity=(1-_5);break;case "moz":this.obj.style.MozOpacity=(_5==1?0.9999999:_5);this.newimg.style.MozOpacity=(1-_5);break;default:this.obj.style.opacity=(_5==1?0.9999999:_5);this.newimg.style.opacity=(1-_5);}};IXF.prototype.getRealPosition=function(){var _6=(arguments[1]=="x")?arguments[0].offsetLeft:arguments[0].offsetTop;var _7=arguments[0].offsetParent;while(_7!=null){_6+=(arguments[1]=="x")?_7.offsetLeft:_7.offsetTop;_7=_7.offsetParent;}return _6;};IXF.prototype.slide=function(){if(this.count==1){this.initCrossfade(document.getElementById(this.slideImageId),this.sources[this.loopCounter],this.fadeSeconds);if(this.quotes&&this.slideQuoteId){document.getElementById(this.slideQuoteId).innerHTML=this.quotes[this.loopCounter];}this.loopCounter=(this.loopCounter<this.sources.length-1)?this.loopCounter+1:0;}};IXF.prototype.play=function(){if(!this.slideshowID){var _8=this;if(this.count<1){this.clock=setInterval(function(){_8.crossfade();},this.length/this.resolution);}this.slideshowID=setInterval(function(){_8.slide();},(this.intervalSeconds+this.fadeSeconds)*1000);}};IXF.prototype.pause=function(_9){if(this.slideshowID){clearInterval(this.slideshowID);this.slideshowID=null;if(this.count<1){clearInterval(this.clock);this.clock=null;}}};IXF.prototype.stop=function(_a){if(this.slideshowID){clearInterval(this.slideshowID);this.slideshowID=null;if(this.count<1){clearInterval(this.clock);this.clock=null;this.count=1;this.setOpacity(1);this.newimg.parentNode.removeChild(this.newimg);if(!_a){this.loopCounter=(this.loopCounter==0?this.sources.length-1:this.loopCounter-1);status=this.loopCounter+", ";}}if(_a){document.getElementById(this.slideImageId).src=this.sources[0];this.loopCounter=1;}if(this.quotes&&this.slideQuoteId){document.getElementById(this.slideQuoteId).innerHTML=this.quotes[this.loopCounter==0?this.sources.length-1:this.loopCounter-1];}}};IXF.prototype.loadFirst=function(_b){if(document.getElementById(this.slideImageId)&&(!this.quotes||document.getElementById(this.slideQuoteId))){document.getElementById(this.slideImageId).src=this.sources[0];if(this.quotes&&this.slideQuoteId){document.getElementById(this.slideQuoteId).innerHTML=this.quotes[0];}if(_b){this.play();}}else{var _c=this;setTimeout(function(){_c.loadFirst(_b);},100);}};IXF.prototype.hide=function(){document.getElementById(this.slideImageId).style.display="none";if(this.count<1){this.newimg.style.display="none";}};IXF.prototype.show=function(){document.getElementById(this.slideImageId).style.display="block";if(this.count<1){this.newimg.style.display="block";}};Array.prototype.inArray=function(_d){for(i=0;i<this.length;i++){if(this[i]==_d){return true;}}return false;};