var hs={lang:{cssDirection:"ltr",loadingText:"Loading...",loadingTitle:"Click to cancel",focusTitle:"Click to bring to front",fullExpandTitle:"Expand to actual size (f)",creditsText:"Powered by <i>Highslide JS</i>",creditsTitle:"Go to the Highslide JS homepage",previousText:"Previous",nextText:"Next",moveText:"Move",closeText:"Close",closeTitle:"Close (esc)",resizeTitle:"Resize",playText:"Play",playTitle:"Play slideshow (spacebar)",pauseText:"Pause",pauseTitle:"Pause slideshow (spacebar)",previousTitle:"Previous (arrow left)",nextTitle:"Next (arrow right)",moveTitle:"Move",fullExpandText:"1:1",number:"Image %1 of %2",restoreTitle:"Click to close image, click and drag to move. Use arrow keys for next and previous."},graphicsDir:"highslide/graphics/",expandCursor:"zoomin.cur",restoreCursor:"zoomout.cur",expandDuration:250,restoreDuration:250,marginLeft:15,marginRight:15,marginTop:15,marginBottom:15,zIndexCounter:1001,loadingOpacity:.75,allowMultipleInstances:true,numberOfImagesToPreload:5,outlineWhileAnimating:2,outlineStartOffset:3,padToMinWidth:false,fullExpandPosition:"bottom right",fullExpandOpacity:1,showCredits:true,creditsHref:"http://highslide.com/",enableKeyListener:true,openerTagNames:["a","area"],transitions:[],transitionDuration:250,dimmingOpacity:0,dimmingDuration:50,allowWidthReduction:false,allowHeightReduction:true,preserveContent:true,objectLoadTime:"before",cacheAjax:true,anchor:"auto",align:"auto",targetX:null,targetY:null,dragByHeading:true,minWidth:200,minHeight:200,allowSizeReduction:true,outlineType:"drop-shadow",wrapperClassName:"highslide-wrapper",skin:{controls:'<div class="highslide-controls"><ul>'+'<li class="highslide-previous">'+'<a href="#" title="{hs.lang.previousTitle}">'+"<span>{hs.lang.previousText}</span></a>"+"</li>"+'<li class="highslide-play">'+'<a href="#" title="{hs.lang.playTitle}">'+"<span>{hs.lang.playText}</span></a>"+"</li>"+'<li class="highslide-pause">'+'<a href="#" title="{hs.lang.pauseTitle}">'+"<span>{hs.lang.pauseText}</span></a>"+"</li>"+'<li class="highslide-next">'+'<a href="#" title="{hs.lang.nextTitle}">'+"<span>{hs.lang.nextText}</span></a>"+"</li>"+'<li class="highslide-move">'+'<a href="#" title="{hs.lang.moveTitle}">'+"<span>{hs.lang.moveText}</span></a>"+"</li>"+'<li class="highslide-full-expand">'+'<a href="#" title="{hs.lang.fullExpandTitle}">'+"<span>{hs.lang.fullExpandText}</span></a>"+"</li>"+'<li class="highslide-close">'+'<a href="#" title="{hs.lang.closeTitle}" >'+"<span>{hs.lang.closeText}</span></a>"+"</li>"+"</ul></div>",contentWrapper:'<div class="highslide-header"><ul>'+'<li class="highslide-previous">'+'<a href="#" title="{hs.lang.previousTitle}" onclick="return hs.previous(this)">'+"<span>{hs.lang.previousText}</span></a>"+"</li>"+'<li class="highslide-next">'+'<a href="#" title="{hs.lang.nextTitle}" onclick="return hs.next(this)">'+"<span>{hs.lang.nextText}</span></a>"+"</li>"+'<li class="highslide-move">'+'<a href="#" title="{hs.lang.moveTitle}" onclick="return false">'+"<span>{hs.lang.moveText}</span></a>"+"</li>"+'<li class="highslide-close">'+'<a href="#" title="{hs.lang.closeTitle}" onclick="return hs.close(this)">'+"<span>{hs.lang.closeText}</span></a>"+"</li>"+"</ul></div>"+'<div class="highslide-body"></div>'+'<div class="highslide-footer"><div>'+'<span class="highslide-resize" title="{hs.lang.resizeTitle}"><span></span></span>'+"</div></div>"},preloadTheseImages:[],continuePreloading:true,expanders:[],overrides:["allowSizeReduction","useBox","anchor","align","targetX","targetY","outlineType","outlineWhileAnimating","captionId","captionText","captionEval","captionOverlay","headingId","headingText","headingEval","headingOverlay","creditsPosition","dragByHeading","autoplay","numberPosition","transitions","dimmingOpacity","width","height","contentId","allowWidthReduction","allowHeightReduction","preserveContent","maincontentId","maincontentText","maincontentEval","objectType","cacheAjax","objectWidth","objectHeight","objectLoadTime","swfOptions","wrapperClassName","minWidth","minHeight","maxWidth","maxHeight","slideshowGroup","easing","easingClose","fadeInOut","src"],overlays:[],idCounter:0,oPos:{x:["leftpanel","left","center","right","rightpanel"],y:["above","top","middle","bottom","below"]},mouse:{},headingOverlay:{},captionOverlay:{},swfOptions:{flashvars:{},params:{},attributes:{}},timers:[],slideshows:[],pendingOutlines:{},sleeping:[],preloadTheseAjax:[],cacheBindings:[],cachedGets:{},clones:{},onReady:[],uaVersion:parseFloat((navigator.userAgent.toLowerCase().match(/.+(?:rv|it|ra|ie)[\/: ]([\d.]+)/)||[0,"0"])[1]),ie:document.all&&!window.opera,safari:/Safari/.test(navigator.userAgent),geckoMac:/Macintosh.+rv:1\.[0-8].+Gecko/.test(navigator.userAgent),$:function(a){if(a)return document.getElementById(a)},push:function(a,b){a[a.length]=b},createElement:function(a,b,c,d,e){var f=document.createElement(a);if(b)hs.extend(f,b);if(e)hs.setStyles(f,{padding:0,border:"none",margin:0});if(c)hs.setStyles(f,c);if(d)d.appendChild(f);return f},extend:function(a,b){for(var c in b)a[c]=b[c];return a},setStyles:function(a,b){for(var c in b){if(hs.ie&&c=="opacity"){if(b[c]>.99)a.style.removeAttribute("filter");else a.style.filter="alpha(opacity="+b[c]*100+")"}else a.style[c]=b[c]}},animate:function(a,b,c){var d,e,f;if(typeof c!="object"||c===null){var g=arguments;c={duration:g[2],easing:g[3],complete:g[4]}}if(typeof c.duration!="number")c.duration=250;c.easing=Math[c.easing]||Math.easeInQuad;c.curAnim=hs.extend({},b);for(var h in b){var i=new hs.fx(a,c,h);d=parseFloat(hs.css(a,h))||0;e=parseFloat(b[h]);f=h!="opacity"?"px":"";i.custom(d,e,f)}},css:function(a,b){if(document.defaultView){return document.defaultView.getComputedStyle(a,null).getPropertyValue(b)}else{if(b=="opacity")b="filter";var c=a.currentStyle[b.replace(/\-(\w)/g,function(a,b){return b.toUpperCase()})];if(b=="filter")c=c.replace(/alpha\(opacity=([0-9]+)\)/,function(a,b){return b/100});return c===""?1:c}},getPageSize:function(){var a=document,b=window,c=a.compatMode&&a.compatMode!="BackCompat"?a.documentElement:a.body;var d=a.body;var e=b.innerWidth&&b.scrollMaxX?b.innerWidth+b.scrollMaxX:Math.max(d.scrollWidth,d.offsetWidth),f=b.innerHeight&&window.scrollMaxY?b.innerHeight+b.scrollMaxY:Math.max(d.scrollHeight,d.offsetHeight),g=hs.ie?c.scrollWidth:a.documentElement.clientWidth||self.innerWidth,h=hs.ie?Math.max(c.scrollHeight,c.clientHeight):a.documentElement.clientHeight||self.innerHeight;var i=hs.ie?c.clientWidth:a.documentElement.clientWidth||self.innerWidth,j=hs.ie?c.clientHeight:self.innerHeight;return{pageWidth:Math.max(g,e),pageHeight:Math.max(h,f),width:i,height:j,scrollLeft:hs.ie?c.scrollLeft:pageXOffset,scrollTop:hs.ie?c.scrollTop:pageYOffset}},getPosition:function(a){if(/area/i.test(a.tagName)){var b=document.getElementsByTagName("img");for(var c=0;c<b.length;c++){var d=b[c].useMap;if(d&&d.replace(/^.*?#/,"")==a.parentNode.name){a=b[c];break}}}var e={x:a.offsetLeft,y:a.offsetTop};while(a.offsetParent){a=a.offsetParent;e.x+=a.offsetLeft;e.y+=a.offsetTop;if(a!=document.body&&a!=document.documentElement){e.x-=a.scrollLeft;e.y-=a.scrollTop}}return e},expand:function(a,b,c,d){if(!a)a=hs.createElement("a",null,{display:"none"},hs.container);if(typeof a.getParams=="function")return b;if(d=="html"){for(var e=0;e<hs.sleeping.length;e++){if(hs.sleeping[e]&&hs.sleeping[e].a==a){hs.sleeping[e].awake();hs.sleeping[e]=null;return false}}hs.hasHtmlExpanders=true}try{new hs.Expander(a,b,c,d);return false}catch(f){return true}},htmlExpand:function(a,b,c){return hs.expand(a,b,c,"html")},getSelfRendered:function(){return hs.createElement("div",{className:"highslide-html-content",innerHTML:hs.replaceLang(hs.skin.contentWrapper)})},getElementByClass:function(a,b,c){var d=a.getElementsByTagName(b);for(var e=0;e<d.length;e++){if((new RegExp(c)).test(d[e].className)){return d[e]}}return null},replaceLang:function(a){a=a.replace(/\s/g," ");var b=/{hs\.lang\.([^}]+)\}/g,c=a.match(b),d;if(c)for(var e=0;e<c.length;e++){d=c[e].replace(b,"$1");if(typeof hs.lang[d]!="undefined")a=a.replace(c[e],hs.lang[d])}return a},setClickEvents:function(){var a=document.getElementsByTagName("a");for(var b=0;b<a.length;b++){var c=hs.isUnobtrusiveAnchor(a[b]);if(c&&!a[b].hsHasSetClick){(function(){var d=c;if(hs.fireEvent(hs,"onSetClickEvent",{element:a[b],type:d})){a[b].onclick=c=="image"?function(){return hs.expand(this)}:function(){return hs.htmlExpand(this,{objectType:d})}}})();a[b].hsHasSetClick=true}}hs.getAnchors()},isUnobtrusiveAnchor:function(a){if(a.rel=="highslide")return"image";else if(a.rel=="highslide-ajax")return"ajax";else if(a.rel=="highslide-iframe")return"iframe";else if(a.rel=="highslide-swf")return"swf"},getCacheBinding:function(a){for(var b=0;b<hs.cacheBindings.length;b++){if(hs.cacheBindings[b][0]==a){var c=hs.cacheBindings[b][1];hs.cacheBindings[b][1]=c.cloneNode(1);return c}}return null},preloadAjax:function(a){var b=hs.getAnchors();for(var c=0;c<b.htmls.length;c++){var d=b.htmls[c];if(hs.getParam(d,"objectType")=="ajax"&&hs.getParam(d,"cacheAjax"))hs.push(hs.preloadTheseAjax,d)}hs.preloadAjaxElement(0)},preloadAjaxElement:function(a){if(!hs.preloadTheseAjax[a])return;var b=hs.preloadTheseAjax[a];var c=hs.getNode(hs.getParam(b,"contentId"));if(!c)c=hs.getSelfRendered();var d=new hs.Ajax(b,c,1);d.onError=function(){};d.onLoad=function(){hs.push(hs.cacheBindings,[b,c]);hs.preloadAjaxElement(a+1)};d.run()},focusTopmost:function(){var a=0,b=-1,c=hs.expanders,d,e;for(var f=0;f<c.length;f++){d=c[f];if(d){e=d.wrapper.style.zIndex;if(e&&e>a){a=e;b=f}}}if(b==-1)hs.focusKey=-1;else c[b].focus()},getParam:function(a,b){a.getParams=a.onclick;var c=a.getParams?a.getParams():null;a.getParams=null;return c&&typeof c[b]!="undefined"?c[b]:typeof hs[b]!="undefined"?hs[b]:null},getSrc:function(a){var b=hs.getParam(a,"src");if(b)return b;return a.href},getNode:function(a){var b=hs.$(a),c=hs.clones[a],d={};if(!b&&!c)return null;if(!c){c=b.cloneNode(true);c.id="";hs.clones[a]=c;return b}else{return c.cloneNode(true)}},discardElement:function(a){hs.garbageBin.appendChild(a);hs.garbageBin.innerHTML=""},dim:function(a){if(!hs.dimmer){hs.dimmer=hs.createElement("div",{className:"highslide-dimming",owner:"",onclick:function(){if(hs.fireEvent(hs,"onDimmerClick"))hs.close()}},{position:"absolute",visibility:"visible",left:0,opacity:0},hs.container,true);hs.addEventListener(window,"resize",hs.setDimmerSize)}hs.dimmer.style.display="";hs.setDimmerSize();hs.dimmer.owner+="|"+a.key;if(hs.geckoMac&&hs.dimmingGeckoFix)hs.setStyles(hs.dimmer,{background:"url("+hs.graphicsDir+"geckodimmer.png)",opacity:1});else hs.animate(hs.dimmer,{opacity:a.dimmingOpacity},hs.dimmingDuration)},undim:function(a){if(!hs.dimmer)return;if(typeof a!="undefined")hs.dimmer.owner=hs.dimmer.owner.replace("|"+a,"");if(typeof a!="undefined"&&hs.dimmer.owner!=""||hs.upcoming&&hs.getParam(hs.upcoming,"dimmingOpacity"))return;if(hs.geckoMac&&hs.dimmingGeckoFix)hs.setStyles(hs.dimmer,{background:"none",width:0,height:0});else hs.animate(hs.dimmer,{opacity:0},hs.dimmingDuration,null,function(){hs.setStyles(hs.dimmer,{display:"none",width:0,height:0})})},setDimmerSize:function(a){if(!hs.dimmer)return;var b=hs.ie&&a&&a.wrapper?parseInt(a.wrapper.style.top)+parseInt(a.wrapper.style.height)+(a.outline?a.outline.offset:0):0;hs.setStyles(hs.dimmer,{width:hs.page.pageWidth+"px",height:Math.max(hs.page.pageHeight,b)+"px"})},transit:function(a,b){var c=b=b||hs.getExpander();if(hs.upcoming)return false;else hs.last=c;try{hs.upcoming=a;a.onclick()}catch(d){hs.last=hs.upcoming=null}try{if(!a||b.transitions[1]!="crossfade")b.close()}catch(d){}return false},previousOrNext:function(a,b){var c=hs.getExpander(a);if(c){adj=c.getAdjacentAnchor(b);return hs.transit(adj,c)}else return false},previous:function(a){return hs.previousOrNext(a,-1)},next:function(a){return hs.previousOrNext(a,1)},keyHandler:function(a){if(!a)a=window.event;if(!a.target)a.target=a.srcElement;if(typeof a.target.form!="undefined")return true;if(!hs.fireEvent(hs,"onKeyDown",a))return true;var b=hs.getExpander();var c=null;switch(a.keyCode){case 70:if(b)b.doFullExpand();return true;case 32:c=2;break;case 34:case 39:case 40:c=1;break;case 8:case 33:case 37:case 38:c=-1;break;case 27:case 13:c=0}if(c!==null){if(c!=2)hs.removeEventListener(document,window.opera?"keypress":"keydown",hs.keyHandler);if(!hs.enableKeyListener)return true;if(a.preventDefault)a.preventDefault();else a.returnValue=false;if(b){if(c==0){b.close()}else if(c==2){if(b.slideshow)b.slideshow.hitSpace()}else{if(b.slideshow)b.slideshow.pause();hs.previousOrNext(b.key,c)}return false}}return true},registerOverlay:function(a){hs.push(hs.overlays,hs.extend(a,{hsId:"hsId"+hs.idCounter++}))},addSlideshow:function(a){var b=a.slideshowGroup;if(typeof b=="object"){for(var c=0;c<b.length;c++){var d={};for(var e in a)d[e]=a[e];d.slideshowGroup=b[c];hs.push(hs.slideshows,d)}}else{hs.push(hs.slideshows,a)}},getWrapperKey:function(a,b){var c,d=/^highslide-wrapper-([0-9]+)$/;c=a;while(c.parentNode){if(c.hsKey!==undefined)return c.hsKey;if(c.id&&d.test(c.id))return c.id.replace(d,"$1");c=c.parentNode}if(!b){c=a;while(c.parentNode){if(c.tagName&&hs.isHsAnchor(c)){for(var e=0;e<hs.expanders.length;e++){var f=hs.expanders[e];if(f&&f.a==c)return e}}c=c.parentNode}}return null},getExpander:function(a,b){if(typeof a=="undefined")return hs.expanders[hs.focusKey]||null;if(typeof a=="number")return hs.expanders[a]||null;if(typeof a=="string")a=hs.$(a);return hs.expanders[hs.getWrapperKey(a,b)]||null},isHsAnchor:function(a){return a.onclick&&a.onclick.toString().replace(/\s/g," ").match(/hs.(htmlE|e)xpand/)},reOrder:function(){for(var a=0;a<hs.expanders.length;a++)if(hs.expanders[a]&&hs.expanders[a].isExpanded)hs.focusTopmost()},fireEvent:function(a,b,c){return a&&a[b]?a[b](a,c)!==false:true},mouseClickHandler:function(a){if(!a)a=window.event;if(a.button>1)return true;if(!a.target)a.target=a.srcElement;var b=a.target;while(b.parentNode&&!/highslide-(image|move|html|resize)/.test(b.className)){b=b.parentNode}var c=hs.getExpander(b);if(c&&(c.isClosing||!c.isExpanded))return true;if(c&&a.type=="mousedown"){if(a.target.form)return true;var d=b.className.match(/highslide-(image|move|resize)/);if(d){hs.dragArgs={exp:c,type:d[1],left:c.x.pos,width:c.x.size,top:c.y.pos,height:c.y.size,clickX:a.clientX,clickY:a.clientY};hs.addEventListener(document,"mousemove",hs.dragHandler);if(a.preventDefault)a.preventDefault();if(/highslide-(image|html)-blur/.test(c.content.className)){c.focus();hs.hasFocused=true}return false}else if(/highslide-html/.test(b.className)&&hs.focusKey!=c.key){c.focus();c.doShowHide("hidden")}}else if(a.type=="mouseup"){hs.removeEventListener(document,"mousemove",hs.dragHandler);if(hs.dragArgs){if(hs.styleRestoreCursor&&hs.dragArgs.type=="image")hs.dragArgs.exp.content.style.cursor=hs.styleRestoreCursor;var e=hs.dragArgs.hasDragged;if(!e&&!hs.hasFocused&&!/(move|resize)/.test(hs.dragArgs.type)){if(hs.fireEvent(c,"onImageClick"))c.close()}else if(e||!e&&hs.hasHtmlExpanders){hs.dragArgs.exp.doShowHide("hidden")}if(hs.dragArgs.exp.releaseMask)hs.dragArgs.exp.releaseMask.style.display="none";if(e)hs.fireEvent(hs.dragArgs.exp,"onDrop",hs.dragArgs);if(e)hs.setDimmerSize(c);hs.hasFocused=false;hs.dragArgs=null}else if(/highslide-image-blur/.test(b.className)){b.style.cursor=hs.styleRestoreCursor}}return false},dragHandler:function(a){if(!hs.dragArgs)return true;if(!a)a=window.event;var b=hs.dragArgs,c=b.exp;if(c.iframe){if(!c.releaseMask)c.releaseMask=hs.createElement("div",null,{position:"absolute",width:c.x.size+"px",height:c.y.size+"px",left:c.x.cb+"px",top:c.y.cb+"px",zIndex:4,background:hs.ie?"white":"none",opacity:.01},c.wrapper,true);if(c.releaseMask.style.display=="none")c.releaseMask.style.display=""}b.dX=a.clientX-b.clickX;b.dY=a.clientY-b.clickY;var d=Math.sqrt(Math.pow(b.dX,2)+Math.pow(b.dY,2));if(!b.hasDragged)b.hasDragged=b.type!="image"&&d>0||d>(hs.dragSensitivity||5);if(b.hasDragged&&a.clientX>5&&a.clientY>5){if(!hs.fireEvent(c,"onDrag",b))return false;if(b.type=="resize")c.resize(b);else{c.moveTo(b.left+b.dX,b.top+b.dY);if(b.type=="image")c.content.style.cursor="move"}}return false},wrapperMouseHandler:function(a){try{if(!a)a=window.event;var b=/mouseover/i.test(a.type);if(!a.target)a.target=a.srcElement;if(hs.ie)a.relatedTarget=b?a.fromElement:a.toElement;var c=hs.getExpander(a.target);if(!c.isExpanded)return;if(!c||!a.relatedTarget||hs.getExpander(a.relatedTarget,true)==c||hs.dragArgs)return;hs.fireEvent(c,b?"onMouseOver":"onMouseOut",a);for(var d=0;d<c.overlays.length;d++)(function(){var a=hs.$("hsId"+c.overlays[d]);if(a&&a.hideOnMouseOut){if(b)hs.setStyles(a,{visibility:"visible"});hs.animate(a,{opacity:b?a.opacity:0},a.dur)}})()}catch(a){}},addEventListener:function(a,b,c){if(a==document&&b=="ready")hs.push(hs.onReady,c);try{a.addEventListener(b,c,false)}catch(d){try{a.detachEvent("on"+b,c);a.attachEvent("on"+b,c)}catch(d){a["on"+b]=c}}},removeEventListener:function(a,b,c){try{a.removeEventListener(b,c,false)}catch(d){try{a.detachEvent("on"+b,c)}catch(d){a["on"+b]=null}}},preloadFullImage:function(a){if(hs.continuePreloading&&hs.preloadTheseImages[a]&&hs.preloadTheseImages[a]!="undefined"){var b=document.createElement("img");b.onload=function(){b=null;hs.preloadFullImage(a+1)};b.src=hs.preloadTheseImages[a]}},preloadImages:function(a){if(a&&typeof a!="object")hs.numberOfImagesToPreload=a;var b=hs.getAnchors();for(var c=0;c<b.images.length&&c<hs.numberOfImagesToPreload;c++){hs.push(hs.preloadTheseImages,hs.getSrc(b.images[c]))}if(hs.outlineType)new hs.Outline(hs.outlineType,function(){hs.preloadFullImage(0)});else hs.preloadFullImage(0);if(hs.restoreCursor)var d=hs.createElement("img",{src:hs.graphicsDir+hs.restoreCursor})},init:function(){if(!hs.container){hs.page=hs.getPageSize();hs.ieLt7=hs.ie&&hs.uaVersion<7;hs.ie6SSL=hs.ieLt7&&location.protocol=="https:";for(var a in hs.langDefaults){if(typeof hs[a]!="undefined")hs.lang[a]=hs[a];else if(typeof hs.lang[a]=="undefined"&&typeof hs.langDefaults[a]!="undefined")hs.lang[a]=hs.langDefaults[a]}hs.container=hs.createElement("div",{className:"highslide-container"},{position:"absolute",left:0,top:0,width:"100%",zIndex:hs.zIndexCounter,direction:"ltr"},document.body,true);hs.loading=hs.createElement("a",{className:"highslide-loading",title:hs.lang.loadingTitle,innerHTML:hs.lang.loadingText,href:"javascript:;"},{position:"absolute",top:"-9999px",opacity:hs.loadingOpacity,zIndex:1},hs.container);hs.garbageBin=hs.createElement("div",null,{display:"none"},hs.container);hs.viewport=hs.createElement("div",{className:"highslide-viewport"},null,hs.container,1);hs.clearing=hs.createElement("div",null,{clear:"both",paddingTop:"1px"},null,true);Math.linearTween=function(a,b,c,d){return c*a/d+b};Math.easeInQuad=function(a,b,c,d){return c*(a/=d)*a+b};Math.easeOutQuad=function(a,b,c,d){return-c*(a/=d)*(a-2)+b};hs.hideSelects=hs.ieLt7;hs.hideIframes=window.opera&&hs.uaVersion<9||navigator.vendor=="KDE"||hs.ie&&hs.uaVersion<5.5;hs.fireEvent(this,"onActivate")}},ready:function(){if(hs.isReady)return;hs.isReady=true;for(var a=0;a<hs.onReady.length;a++)hs.onReady[a]()},updateAnchors:function(){var a,b,c=[],d=[],e=[],f={},g;for(var h=0;h<hs.openerTagNames.length;h++){b=document.getElementsByTagName(hs.openerTagNames[h]);for(var i=0;i<b.length;i++){a=b[i];g=hs.isHsAnchor(a);if(g){hs.push(c,a);if(g[0]=="hs.expand")hs.push(d,a);else if(g[0]=="hs.htmlExpand")hs.push(e,a);var j=hs.getParam(a,"slideshowGroup")||"none";if(!f[j])f[j]=[];hs.push(f[j],a)}}}hs.anchors={all:c,groups:f,images:d,htmls:e};return hs.anchors},getAnchors:function(){return hs.anchors||hs.updateAnchors()},close:function(a){var b=hs.getExpander(a);if(b)b.close();return false}};hs.fx=function(a,b,c){this.options=b;this.elem=a;this.prop=c;if(!b.orig)b.orig={}};hs.fx.prototype={update:function(){(hs.fx.step[this.prop]||hs.fx.step._default)(this);if(this.options.step)this.options.step.call(this.elem,this.now,this)},custom:function(a,b,c){function e(a){return d.step(a)}this.startTime=(new Date).getTime();this.start=a;this.end=b;this.unit=c;this.now=this.start;this.pos=this.state=0;var d=this;e.elem=this.elem;if(e()&&hs.timers.push(e)==1){hs.timerId=setInterval(function(){var a=hs.timers;for(var b=0;b<a.length;b++)if(!a[b]())a.splice(b--,1);if(!a.length){clearInterval(hs.timerId)}},13)}},step:function(a){var b=(new Date).getTime();if(a||b>=this.options.duration+this.startTime){this.now=this.end;this.pos=this.state=1;this.update();this.options.curAnim[this.prop]=true;var c=true;for(var d in this.options.curAnim)if(this.options.curAnim[d]!==true)c=false;if(c){if(this.options.complete)this.options.complete.call(this.elem)}return false}else{var e=b-this.startTime;this.state=e/this.options.duration;this.pos=this.options.easing(e,0,1,this.options.duration);this.now=this.start+(this.end-this.start)*this.pos;this.update()}return true}};hs.extend(hs.fx,{step:{opacity:function(a){hs.setStyles(a.elem,{opacity:a.now})},_default:function(a){if(a.elem.style&&a.elem.style[a.prop]!=null)a.elem.style[a.prop]=a.now+a.unit;else a.elem[a.prop]=a.now}}});hs.Outline=function(a,b){this.onLoad=b;this.outlineType=a;var c=hs.uaVersion,d;this.hasAlphaImageLoader=hs.ie&&c>=5.5&&c<7;if(!a){if(b)b();return}hs.init();this.table=hs.createElement("table",{cellSpacing:0},{visibility:"hidden",position:"absolute",borderCollapse:"collapse",width:0},hs.container,true);var e=hs.createElement("tbody",null,null,this.table,1);this.td=[];for(var f=0;f<=8;f++){if(f%3==0)d=hs.createElement("tr",null,{height:"auto"},e,true);this.td[f]=hs.createElement("td",null,null,d,true);var g=f!=4?{lineHeight:0,fontSize:0}:{position:"relative"};hs.setStyles(this.td[f],g)}this.td[4].className=a+" highslide-outline";this.preloadGraphic()};hs.Outline.prototype={preloadGraphic:function(){var a=hs.graphicsDir+(hs.outlinesDir||"outlines/")+this.outlineType+".png";var b=hs.safari?hs.container:null;this.graphic=hs.createElement("img",null,{position:"absolute",top:"-9999px"},b,true);var c=this;this.graphic.onload=function(){c.onGraphicLoad()};this.graphic.src=a},onGraphicLoad:function(){var a=this.offset=this.graphic.width/4,b=[[0,0],[0,-4],[-2,0],[0,-8],0,[-2,-8],[0,-2],[0,-6],[-2,-2]],c={height:2*a+"px",width:2*a+"px"};for(var d=0;d<=8;d++){if(b[d]){if(this.hasAlphaImageLoader){var e=d==1||d==7?"100%":this.graphic.width+"px";var f=hs.createElement("div",null,{width:"100%",height:"100%",position:"relative",overflow:"hidden"},this.td[d],true);hs.createElement("div",null,{filter:"progid:DXImageTransform.Microsoft.AlphaImageLoader(sizingMethod=scale, src='"+this.graphic.src+"')",position:"absolute",width:e,height:this.graphic.height+"px",left:b[d][0]*a+"px",top:b[d][1]*a+"px"},f,true)}else{hs.setStyles(this.td[d],{background:"url("+this.graphic.src+") "+b[d][0]*a+"px "+b[d][1]*a+"px"})}if(window.opera&&(d==3||d==5))hs.createElement("div",null,c,this.td[d],true);hs.setStyles(this.td[d],c)}}this.graphic=null;if(hs.pendingOutlines[this.outlineType])hs.pendingOutlines[this.outlineType].destroy();hs.pendingOutlines[this.outlineType]=this;if(this.onLoad)this.onLoad()},setPosition:function(a,b,c,d,e){var f=this.exp,g=f.wrapper.style,b=b||0,a=a||{x:f.x.pos+b,y:f.y.pos+b,w:f.x.get("wsize")-2*b,h:f.y.get("wsize")-2*b};if(c)this.table.style.visibility=a.h>=4*this.offset?"visible":"hidden";hs.setStyles(this.table,{left:a.x-this.offset+"px",top:a.y-this.offset+"px",width:a.w+2*this.offset+"px"});a.w-=2*this.offset;a.h-=2*this.offset;hs.setStyles(this.td[4],{width:a.w>=0?a.w+"px":0,height:a.h>=0?a.h+"px":0});if(this.hasAlphaImageLoader)this.td[3].style.height=this.td[5].style.height=this.td[4].style.height},destroy:function(a){if(a)this.table.style.visibility="hidden";else hs.discardElement(this.table)}};hs.Dimension=function(a,b){this.exp=a;this.dim=b;this.ucwh=b=="x"?"Width":"Height";this.wh=this.ucwh.toLowerCase();this.uclt=b=="x"?"Left":"Top";this.lt=this.uclt.toLowerCase();this.ucrb=b=="x"?"Right":"Bottom";this.rb=this.ucrb.toLowerCase();this.p1=this.p2=0};hs.Dimension.prototype={get:function(a){switch(a){case"loadingPos":return this.tpos+this.tb+(this.t-hs.loading["offset"+this.ucwh])/2;case"loadingPosXfade":return this.pos+this.cb+this.p1+(this.size-hs.loading["offset"+this.ucwh])/2;case"wsize":return this.size+2*this.cb+this.p1+this.p2;case"fitsize":return this.clientSize-this.marginMin-this.marginMax;case"maxsize":return this.get("fitsize")-2*this.cb-this.p1-this.p2;case"opos":return this.pos-(this.exp.outline?this.exp.outline.offset:0);case"osize":return this.get("wsize")+(this.exp.outline?2*this.exp.outline.offset:0);case"imgPad":return this.imgSize?Math.round((this.size-this.imgSize)/2):0}},calcBorders:function(){this.cb=(this.exp.content["offset"+this.ucwh]-this.t)/2;this.marginMax=hs["margin"+this.ucrb]+2*this.cb},calcThumb:function(){this.t=this.exp.el[this.wh]?parseInt(this.exp.el[this.wh]):this.exp.el["offset"+this.ucwh];this.tpos=this.exp.tpos[this.dim];this.tb=(this.exp.el["offset"+this.ucwh]-this.t)/2;if(this.tpos==0){this.tpos=hs.page[this.wh]/2+hs.page["scroll"+this.uclt]}},calcExpanded:function(){var a=this.exp;this.justify="auto";if(a.align=="center")this.justify="center";else if((new RegExp(this.lt)).test(a.anchor))this.justify=null;else if((new RegExp(this.rb)).test(a.anchor))this.justify="max";this.pos=this.tpos-this.cb+this.tb;this.size=Math.min(this.full,a["max"+this.ucwh]||this.full);this.minSize=a.allowSizeReduction?Math.min(a["min"+this.ucwh],this.full):this.full;if(a.isImage&&a.useBox){this.size=a[this.wh];this.imgSize=this.full}if(this.dim=="x"&&hs.padToMinWidth)this.minSize=a.minWidth;this.target=a["target"+this.dim.toUpperCase()];this.marginMin=hs["margin"+this.uclt];this.scroll=hs.page["scroll"+this.uclt];this.clientSize=hs.page[this.wh]},setSize:function(a){var b=this.exp;if(b.isImage&&(b.useBox||hs.padToMinWidth)){this.imgSize=a;this.size=Math.max(this.size,this.imgSize);b.content.style[this.lt]=this.get("imgPad")+"px"}else this.size=a;b.content.style[this.wh]=a+"px";b.wrapper.style[this.wh]=this.get("wsize")+"px";if(b.outline)b.outline.setPosition();if(b.releaseMask)b.releaseMask.style[this.wh]=a+"px";if(b.isHtml){var c=b.scrollerDiv;if(this.sizeDiff===undefined)this.sizeDiff=b.innerContent["offset"+this.ucwh]-c["offset"+this.ucwh];c.style[this.wh]=this.size-this.sizeDiff+"px";if(this.dim=="x")b.mediumContent.style.width="auto";if(b.body)b.body.style[this.wh]="auto"}if(this.dim=="x"&&b.overlayBox)b.sizeOverlayBox(true);if(this.dim=="x"&&b.slideshow&&b.isImage){if(a==this.full)b.slideshow.disable("full-expand");else b.slideshow.enable("full-expand")}},setPos:function(a){this.pos=a;this.exp.wrapper.style[this.lt]=a+"px";if(this.exp.outline)this.exp.outline.setPosition()}};hs.Expander=function(a,b,c,d){if(document.readyState&&hs.ie&&!hs.isReady){hs.addEventListener(document,"ready",function(){new hs.Expander(a,b,c,d)});return}this.a=a;this.custom=c;this.contentType=d||"image";this.isHtml=d=="html";this.isImage=!this.isHtml;hs.continuePreloading=false;this.overlays=[];this.last=hs.last;hs.last=null;hs.init();var e=this.key=hs.expanders.length;for(var f=0;f<hs.overrides.length;f++){var g=hs.overrides[f];this[g]=b&&typeof b[g]!="undefined"?b[g]:hs[g]}if(!this.src)this.src=a.href;var h=b&&b.thumbnailId?hs.$(b.thumbnailId):a;h=this.thumb=h.getElementsByTagName("img")[0]||h;this.thumbsUserSetId=h.id||a.id;if(!hs.fireEvent(this,"onInit"))return true;for(var f=0;f<hs.expanders.length;f++){if(hs.expanders[f]&&hs.expanders[f].a==a&&!(this.last&&this.transitions[1]=="crossfade")){hs.expanders[f].focus();return false}}for(var f=0;f<hs.expanders.length;f++){if(hs.expanders[f]&&hs.expanders[f].thumb!=h&&!hs.expanders[f].onLoadStarted){hs.expanders[f].cancelLoading()}}hs.expanders[this.key]=this;if(!hs.allowMultipleInstances&&!hs.upcoming){if(hs.expanders[e-1])hs.expanders[e-1].close();if(typeof hs.focusKey!="undefined"&&hs.expanders[hs.focusKey])hs.expanders[hs.focusKey].close()}this.el=h;this.tpos=hs.getPosition(h);hs.page=hs.getPageSize();var i=this.x=new hs.Dimension(this,"x");i.calcThumb();var j=this.y=new hs.Dimension(this,"y");j.calcThumb();if(/area/i.test(h.tagName))this.getImageMapAreaCorrection(h);this.wrapper=hs.createElement("div",{id:"highslide-wrapper-"+this.key,className:this.wrapperClassName},{visibility:"hidden",position:"absolute",zIndex:hs.zIndexCounter++},null,true);this.wrapper.onmouseover=this.wrapper.onmouseout=hs.wrapperMouseHandler;if(this.contentType=="image"&&this.outlineWhileAnimating==2)this.outlineWhileAnimating=0;if(!this.outlineType||this.last&&this.isImage&&this.transitions[1]=="crossfade"){this[this.contentType+"Create"]()}else if(hs.pendingOutlines[this.outlineType]){this.connectOutline();this[this.contentType+"Create"]()}else{this.showLoading();var k=this;new hs.Outline(this.outlineType,function(){k.connectOutline();k[k.contentType+"Create"]()})}return true};hs.Expander.prototype={error:function(a){window.location.href=this.src},connectOutline:function(){var a=this.outline=hs.pendingOutlines[this.outlineType];a.exp=this;a.table.style.zIndex=this.wrapper.style.zIndex;hs.pendingOutlines[this.outlineType]=null},showLoading:function(){if(this.onLoadStarted||this.loading)return;this.loading=hs.loading;var a=this;this.loading.onclick=function(){a.cancelLoading()};if(!hs.fireEvent(this,"onShowLoading"))return;var a=this,b=this.x.get("loadingPos")+"px",c=this.y.get("loadingPos")+"px";if(!d&&this.last&&this.transitions[1]=="crossfade")var d=this.last;if(d){b=d.x.get("loadingPosXfade")+"px";c=d.y.get("loadingPosXfade")+"px";this.loading.style.zIndex=hs.zIndexCounter++}setTimeout(function(){if(a.loading)hs.setStyles(a.loading,{left:b,top:c,zIndex:hs.zIndexCounter++})},100)},imageCreate:function(){var a=this;var b=document.createElement("img");this.content=b;b.onload=function(){if(hs.expanders[a.key])a.contentLoaded()};if(hs.blockRightClick)b.oncontextmenu=function(){return false};b.className="highslide-image";hs.setStyles(b,{visibility:"hidden",display:"block",position:"absolute",maxWidth:"9999px",zIndex:3});b.title=hs.lang.restoreTitle;if(hs.safari)hs.container.appendChild(b);if(hs.ie)b.src="res://";b.src=this.src;this.showLoading()},htmlCreate:function(){if(!hs.fireEvent(this,"onBeforeGetContent"))return;this.content=hs.getCacheBinding(this.a);if(!this.content)this.content=hs.getNode(this.contentId);if(!this.content)this.content=hs.getSelfRendered();this.getInline(["maincontent"]);if(this.maincontent){var a=hs.getElementByClass(this.content,"div","highslide-body");if(a)a.appendChild(this.maincontent);this.maincontent.style.display="block"}hs.fireEvent(this,"onAfterGetContent");this.innerContent=this.content;if(/(swf|iframe)/.test(this.objectType))this.setObjContainerSize(this.innerContent);hs.container.appendChild(this.wrapper);hs.setStyles(this.wrapper,{position:"static",padding:"0 "+hs.marginRight+"px 0 "+hs.marginLeft+"px"});this.content=hs.createElement("div",{className:"highslide-html"},{position:"relative",zIndex:3,overflow:"hidden"},this.wrapper);this.mediumContent=hs.createElement("div",null,null,this.content,1);this.mediumContent.appendChild(this.innerContent);hs.setStyles(this.innerContent,{position:"relative",display:"block",direction:hs.lang.cssDirection||""});if(this.width)this.innerContent.style.width=this.width+"px";if(this.height)this.innerContent.style.height=this.height+"px";if(this.innerContent.offsetWidth<this.minWidth)this.innerContent.style.width=this.minWidth+"px";if(this.objectType=="ajax"&&!hs.getCacheBinding(this.a)){this.showLoading();var b=new hs.Ajax(this.a,this.innerContent);var c=this;b.onLoad=function(){if(hs.expanders[c.key])c.contentLoaded()};b.onError=function(){location.href=c.src};b.run()}else if(this.objectType=="iframe"&&this.objectLoadTime=="before"){this.writeExtendedContent()}else this.contentLoaded()},contentLoaded:function(){try{if(!this.content)return;this.content.onload=null;if(this.onLoadStarted)return;else this.onLoadStarted=true;var a=this.x,b=this.y;if(this.loading){hs.setStyles(this.loading,{top:"-9999px"});this.loading=null;hs.fireEvent(this,"onHideLoading")}if(this.isImage){a.full=this.content.width;b.full=this.content.height;hs.setStyles(this.content,{width:a.t+"px",height:b.t+"px"});this.wrapper.appendChild(this.content);hs.container.appendChild(this.wrapper)}else if(this.htmlGetSize)this.htmlGetSize();a.calcBorders();b.calcBorders();hs.setStyles(this.wrapper,{left:a.tpos+a.tb-a.cb+"px",top:b.tpos+a.tb-b.cb+"px"});this.initSlideshow();this.getOverlays();var c=a.full/b.full;a.calcExpanded();this.justify(a);b.calcExpanded();this.justify(b);if(this.isHtml)this.htmlSizeOperations();if(this.overlayBox)this.sizeOverlayBox(0,1);if(this.allowSizeReduction){if(this.isImage)this.correctRatio(c);else this.fitOverlayBox();var d=this.slideshow;if(d&&this.last&&d.controls&&d.fixedControls){var e=d.overlayOptions.position||"",f;for(var g in hs.oPos)for(var h=0;h<5;h++){f=this[g];if(e.match(hs.oPos[g][h])){f.pos=this.last[g].pos+(this.last[g].p1-f.p1)+(this.last[g].size-f.size)*[0,0,.5,1,1][h];if(d.fixedControls=="fit"){if(f.pos+f.size+f.p1+f.p2>f.scroll+f.clientSize-f.marginMax)f.pos=f.scroll+f.clientSize-f.size-f.marginMin-f.marginMax-f.p1-f.p2;if(f.pos<f.scroll+f.marginMin)f.pos=f.scroll+f.marginMin}}}}if(this.isImage&&this.x.full>(this.x.imgSize||this.x.size)){this.createFullExpand();if(this.overlays.length==1)this.sizeOverlayBox()}}this.show()}catch(i){this.error(i)}},setObjContainerSize:function(a,b){var c=hs.getElementByClass(a,"DIV","highslide-body");if(/(iframe|swf)/.test(this.objectType)){if(this.objectWidth)c.style.width=this.objectWidth+"px";if(this.objectHeight)c.style.height=this.objectHeight+"px"}},writeExtendedContent:function(){if(this.hasExtendedContent)return;var a=this;this.body=hs.getElementByClass(this.innerContent,"DIV","highslide-body");if(this.objectType=="iframe"){this.showLoading();var b=hs.clearing.cloneNode(1);this.body.appendChild(b);this.newWidth=this.innerContent.offsetWidth;if(!this.objectWidth)this.objectWidth=b.offsetWidth;var c=this.innerContent.offsetHeight-this.body.offsetHeight,d=this.objectHeight||hs.page.height-c-hs.marginTop-hs.marginBottom,e=this.objectLoadTime=="before"?' onload="if (hs.expanders['+this.key+"]) hs.expanders["+this.key+'].contentLoaded()" ':"";this.body.innerHTML+='<iframe name="hs'+(new Date).getTime()+'" frameborder="0" key="'+this.key+'" '+' allowtransparency="true" style="width:'+this.objectWidth+"px; height:"+d+'px" '+e+' src="'+this.src+'"></iframe>';this.ruler=this.body.getElementsByTagName("div")[0];this.iframe=this.body.getElementsByTagName("iframe")[0];if(this.objectLoadTime=="after")this.correctIframeSize()}if(this.objectType=="swf"){this.body.id=this.body.id||"hs-flash-id-"+this.key;var f=this.swfOptions;if(typeof f.params.wmode=="undefined")f.params.wmode="transparent";if(swfobject)swfobject.embedSWF(this.src,this.body.id,this.objectWidth,this.objectHeight,f.version||"7",f.expressInstallSwfurl,f.flashvars,f.params,f.attributes)}this.hasExtendedContent=true},htmlGetSize:function(){if(this.iframe&&!this.objectHeight){this.iframe.style.height=this.body.style.height=this.getIframePageHeight()+"px"}this.innerContent.appendChild(hs.clearing);if(!this.x.full)this.x.full=this.innerContent.offsetWidth;this.y.full=this.innerContent.offsetHeight;this.innerContent.removeChild(hs.clearing);if(hs.ie&&this.newHeight>parseInt(this.innerContent.currentStyle.height)){this.newHeight=parseInt(this.innerContent.currentStyle.height)}hs.setStyles(this.wrapper,{position:"absolute",padding:"0"});hs.setStyles(this.content,{width:this.x.t+"px",height:this.y.t+"px"})},getIframePageHeight:function(){var a;try{var b=this.iframe.contentDocument||this.iframe.contentWindow.document;var c=b.createElement("div");c.style.clear="both";b.body.appendChild(c);a=c.offsetTop;if(hs.ie)a+=parseInt(b.body.currentStyle.marginTop)+parseInt(b.body.currentStyle.marginBottom)-1}catch(d){a=300}return a},correctIframeSize:function(){var a=this.innerContent.offsetWidth-this.ruler.offsetWidth;if(a<0)a=0;var b=this.innerContent.offsetHeight-this.iframe.offsetHeight;hs.setStyles(this.iframe,{width:Math.abs(this.x.size-a)+"px",height:Math.abs(this.y.size-b)+"px"});hs.setStyles(this.body,{width:this.iframe.style.width,height:this.iframe.style.height});this.scrollingContent=this.iframe;this.scrollerDiv=this.scrollingContent},htmlSizeOperations:function(){this.setObjContainerSize(this.innerContent);if(this.objectType=="swf"&&this.objectLoadTime=="before")this.writeExtendedContent();if(this.x.size<this.x.full&&!this.allowWidthReduction)this.x.size=this.x.full;if(this.y.size<this.y.full&&!this.allowHeightReduction)this.y.size=this.y.full;this.scrollerDiv=this.innerContent;hs.setStyles(this.mediumContent,{position:"relative",width:this.x.size+"px"});hs.setStyles(this.innerContent,{border:"none",width:"auto",height:"auto"});var a=hs.getElementByClass(this.innerContent,"DIV","highslide-body");if(a&&!/(iframe|swf)/.test(this.objectType)){var b=a;a=hs.createElement(b.nodeName,null,{overflow:"hidden"},null,true);b.parentNode.insertBefore(a,b);a.appendChild(hs.clearing);a.appendChild(b);var c=this.innerContent.offsetWidth-a.offsetWidth;var d=this.innerContent.offsetHeight-a.offsetHeight;a.removeChild(hs.clearing);var e=hs.safari||navigator.vendor=="KDE"?1:0;hs.setStyles(a,{width:this.x.size-c-e+"px",height:this.y.size-d+"px",overflow:"auto",position:"relative"});if(e&&b.offsetHeight>a.offsetHeight){a.style.width=parseInt(a.style.width)+e+"px"}this.scrollingContent=a;this.scrollerDiv=this.scrollingContent}if(this.iframe&&this.objectLoadTime=="before")this.correctIframeSize();if(!this.scrollingContent&&this.y.size<this.mediumContent.offsetHeight)this.scrollerDiv=this.content;if(this.scrollerDiv==this.content&&!this.allowWidthReduction&&!/(iframe|swf)/.test(this.objectType)){this.x.size+=17}if(this.scrollerDiv&&this.scrollerDiv.offsetHeight>this.scrollerDiv.parentNode.offsetHeight){setTimeout("try { hs.expanders["+this.key+"].scrollerDiv.style.overflow = 'auto'; } catch(e) {}",hs.expandDuration)}},getImageMapAreaCorrection:function(a){var b=a.coords.split(",");for(var c=0;c<b.length;c++)b[c]=parseInt(b[c]);if(a.shape.toLowerCase()=="circle"){this.x.tpos+=b[0]-b[2];this.y.tpos+=b[1]-b[2];this.x.t=this.y.t=2*b[2]}else{var d,e,f=d=b[0],g=e=b[1];for(var c=0;c<b.length;c++){if(c%2==0){f=Math.min(f,b[c]);d=Math.max(d,b[c])}else{g=Math.min(g,b[c]);e=Math.max(e,b[c])}}this.x.tpos+=f;this.x.t=d-f;this.y.tpos+=g;this.y.t=e-g}},justify:function(a,b){var c,d=a.target,e=a==this.x?"x":"y";if(d&&d.match(/ /)){c=d.split(" ");d=c[0]}if(d&&hs.$(d)){a.pos=hs.getPosition(hs.$(d))[e];if(c&&c[1]&&c[1].match(/^[-]?[0-9]+px$/))a.pos+=parseInt(c[1]);if(a.size<a.minSize)a.size=a.minSize}else if(a.justify=="auto"||a.justify=="center"){var f=false;var g=a.exp.allowSizeReduction;if(a.justify=="center")a.pos=Math.round(a.scroll+(a.clientSize+a.marginMin-a.marginMax-a.get("wsize"))/2);else a.pos=Math.round(a.pos-(a.get("wsize")-a.t)/2);if(a.pos<a.scroll+a.marginMin){a.pos=a.scroll+a.marginMin;f=true}if(!b&&a.size<a.minSize){a.size=a.minSize;g=false}if(a.pos+a.get("wsize")>a.scroll+a.clientSize-a.marginMax){if(!b&&f&&g){a.size=a.get("maxsize")}else if(a.get("wsize")<a.get("fitsize")){a.pos=a.scroll+a.clientSize-a.marginMax-a.get("wsize")}else{a.pos=a.scroll+a.marginMin;if(!b&&g)a.size=a.get("maxsize")}}if(!b&&a.size<a.minSize){a.size=a.minSize;g=false}}else if(a.justify=="max"){a.pos=Math.floor(a.pos-a.size+a.t)}if(a.pos<a.marginMin){var h=a.pos;a.pos=a.marginMin;if(g&&!b)a.size=a.size-(a.pos-h)}},correctRatio:function(a){var b=this.x,c=this.y,d=false,e=Math.min(b.full,b.size),f=Math.min(c.full,c.size),g=this.useBox||hs.padToMinWidth;if(e/f>a){e=f*a;if(e<b.minSize){e=b.minSize;f=e/a}d=true}else if(e/f<a){f=e/a;d=true}if(hs.padToMinWidth&&b.full<b.minSize){b.imgSize=b.full;c.size=c.imgSize=c.full}else if(this.useBox){b.imgSize=e;c.imgSize=f}else{b.size=e;c.size=f}this.fitOverlayBox(g?null:a);if(g&&c.size<c.imgSize){c.imgSize=c.size;b.imgSize=c.size*a}if(d||g){b.pos=b.tpos-b.cb+b.tb;b.minSize=b.size;this.justify(b,true);c.pos=c.tpos-c.cb+c.tb;c.minSize=c.size;this.justify(c,true);if(this.overlayBox)this.sizeOverlayBox()}},fitOverlayBox:function(a){var b=this.x,c=this.y;if(this.overlayBox){while(c.size>this.minHeight&&b.size>this.minWidth&&c.get("wsize")>c.get("fitsize")){c.size-=10;if(a)b.size=c.size*a;this.sizeOverlayBox(0,1)}}},reflow:function(){if(this.scrollerDiv){var a=/iframe/i.test(this.scrollerDiv.tagName)?this.getIframePageHeight()+1+"px":"auto";if(this.body)this.body.style.height=a;this.scrollerDiv.style.height=a;this.y.setSize(this.innerContent.offsetHeight);hs.setDimmerSize(this)}},show:function(){var a=this.x,b=this.y;this.doShowHide("hidden");hs.fireEvent(this,"onBeforeExpand");if(this.slideshow&&this.slideshow.thumbstrip)this.slideshow.thumbstrip.selectThumb();this.changeSize(1,{wrapper:{width:a.get("wsize"),height:b.get("wsize"),left:a.pos,top:b.pos},content:{left:a.p1+a.get("imgPad"),top:b.p1+b.get("imgPad"),width:a.imgSize||a.size,height:b.imgSize||b.size}},hs.expandDuration)},changeSize:function(a,b,c){var d=this.transitions,e=a?this.last?this.last.a:null:hs.upcoming,f=d[1]&&e&&hs.getParam(e,"transitions")[1]==d[1]?d[1]:d[0];if(this[f]&&f!="expand"){this[f](a,b);return}if(this.outline&&!this.outlineWhileAnimating){if(a)this.outline.setPosition();else this.outline.destroy(this.isHtml&&this.preserveContent)}if(!a)this.destroyOverlays();var g=this,h=g.x,i=g.y,j=this.easing;if(!a)j=this.easingClose||j;var k=a?function(){if(g.outline)g.outline.table.style.visibility="visible";setTimeout(function(){g.afterExpand()},50)}:function(){g.afterClose()};if(a)hs.setStyles(this.wrapper,{width:h.t+"px",height:i.t+"px"});if(a&&this.isHtml){hs.setStyles(this.wrapper,{left:h.tpos-h.cb+h.tb+"px",top:i.tpos-i.cb+i.tb+"px"})}if(this.fadeInOut){hs.setStyles(this.wrapper,{opacity:a?0:1});hs.extend(b.wrapper,{opacity:a})}hs.animate(this.wrapper,b.wrapper,{duration:c,easing:j,step:function(b,c){if(g.outline&&g.outlineWhileAnimating&&c.prop=="top"){var d=a?c.pos:1-c.pos;var e={w:h.t+(h.get("wsize")-h.t)*d,h:i.t+(i.get("wsize")-i.t)*d,x:h.tpos+(h.pos-h.tpos)*d,y:i.tpos+(i.pos-i.tpos)*d};g.outline.setPosition(e,0,1)}if(g.isHtml){if(c.prop=="left")g.mediumContent.style.left=h.pos-b+"px";if(c.prop=="top")g.mediumContent.style.top=i.pos-b+"px"}}});hs.animate(this.content,b.content,c,j,k);if(a){this.wrapper.style.visibility="visible";this.content.style.visibility="visible";if(this.isHtml)this.innerContent.style.visibility="visible";this.a.className+=" highslide-active-anchor"}},fade:function(a,b){this.outlineWhileAnimating=false;var c=this,d=a?hs.expandDuration:0;if(a){hs.animate(this.wrapper,b.wrapper,0);hs.setStyles(this.wrapper,{opacity:0,visibility:"visible"});hs.animate(this.content,b.content,0);this.content.style.visibility="visible";hs.animate(this.wrapper,{opacity:1},d,null,function(){c.afterExpand()})}if(this.outline){this.outline.table.style.zIndex=this.wrapper.style.zIndex;var e=a||-1,f=this.outline.offset,g=a?3:f,h=a?f:3;for(var i=g;e*i<=e*h;i+=e,d+=25){(function(){var b=a?h-i:g-i;setTimeout(function(){c.outline.setPosition(0,b,1)},d)})()}}if(a){}else{setTimeout(function(){if(c.outline)c.outline.destroy(c.preserveContent);c.destroyOverlays();hs.animate(c.wrapper,{opacity:0},null,null,function(){c.afterClose()})},d)}},crossfade:function(a,b){function s(){k.style.visibility=l.style.visibility="visible";l.style.display="block";m.style.display="none";c.a.className+=" highslide-active-anchor";c.afterExpand();e.afterClose();c.last=null}if(!a)return;var c=this,d=hs.transitionDuration,e=c.last,f=c.x,g=c.y,h=e.x,i=e.y,j=c.overlayBox,k=this.wrapper,l=this.content;hs.removeEventListener(document,"mousemove",hs.dragHandler);this.outline=e.outline;if(this.outline)this.outline.exp=c;e.outline=null;e.wrapper.style.overflow="hidden";hs.setStyles(k,{left:h.pos+"px",top:i.pos+"px",width:h.get("wsize")+"px",height:i.get("wsize")+"px"});hs.setStyles(l,{display:"none",width:(f.imgSize||f.size)+"px",height:(g.imgSize||g.size)+"px",left:f.p1+f.get("imgPad")+"px",top:g.p1+g.get("imgPad")+"px"});var m=hs.createElement("div",{className:"highslide-image"},{position:"absolute",zIndex:4,overflow:"hidden",display:"none",left:h.p1+h.get("imgPad")+"px",top:i.p1+i.get("imgPad")+"px",width:(h.imgSize||h.size)+"px",height:(i.imgSize||i.size)+"px"});if(this.isHtml)hs.setStyles(this.mediumContent,{left:0,top:0});for(var n=0;n<this.overlays.length;n++){var o=hs.$("hsId"+this.overlays[n]);if(o.style.visibility=="hidden")o.style.display="none"}if(j)hs.setStyles(j,{overflow:"visible",left:h.p1+h.cb+"px",top:i.p1+i.cb+"px",width:h.size+"px",height:i.size+"px"});var p={oldImg:e,newImg:this};for(var q in p){this[q]=p[q].content.cloneNode(1);hs.setStyles(this[q],{position:"absolute",border:0,visibility:"visible"});m.appendChild(this[q])}hs.setStyles(this.oldImg,{left:0,top:0});hs.setStyles(this.newImg,{display:"block",opacity:0,left:f.pos-h.pos+f.p1-h.p1+f.get("imgPad")-h.get("imgPad")+"px",top:g.pos-i.pos+g.p1-i.p1+g.get("imgPad")-i.get("imgPad")+"px"});k.appendChild(m);if(j){j.className="";k.appendChild(j)}m.style.display="";e.content.style.display="none";if(hs.safari){var r=navigator.userAgent.match(/Safari\/([0-9]{3})/);if(r&&parseInt(r[1])<525)k.style.visibility="visible"}hs.animate(e.wrapper,{left:f.pos,top:g.pos,width:f.get("wsize"),height:g.get("wsize")},d);hs.animate(m,{width:f.imgSize||f.size,height:g.imgSize||g.size,left:f.p1+f.get("imgPad"),top:g.p1+g.get("imgPad")},d);hs.animate(this.oldImg,{left:h.pos-f.pos+h.p1-f.p1+h.get("imgPad")-f.get("imgPad"),top:i.pos-g.pos+i.p1-g.p1+i.get("imgPad")-g.get("imgPad")},d);hs.animate(this.newImg,{opacity:1,left:0,top:0},d);if(j)hs.animate(j,{left:f.p1+f.cb,top:g.p1+g.cb,width:f.size,height:g.size},d);if(this.outline)var t=function(a,b){if(b.prop=="top"){var d=c.wrapper.style;var e={w:parseInt(d.width),h:parseInt(d.height),x:parseInt(d.left),y:parseInt(d.top)};c.outline.setPosition(e)}};hs.animate(k,b.wrapper,{duration:d,complete:s,step:t});m.style.visibility="visible"},reuseOverlay:function(a,b){if(!this.last)return false;for(var c=0;c<this.last.overlays.length;c++){var d=hs.$("hsId"+this.last.overlays[c]);if(d&&d.hsId==a.hsId){this.genOverlayBox();d.reuse=this.key;hs.push(this.overlays,this.last.overlays[c]);return true}}return false},afterExpand:function(){this.isExpanded=true;this.focus();if(this.isHtml&&this.objectLoadTime=="after")this.writeExtendedContent();if(this.iframe){try{var a=this,b=this.iframe.contentDocument||this.iframe.contentWindow.document;hs.addEventListener(b,"mousedown",function(){if(hs.focusKey!=a.key)a.focus()})}catch(c){}if(hs.ie&&typeof this.isClosing!="boolean")this.iframe.style.width=this.objectWidth-1+"px"}if(this.dimmingOpacity)hs.dim(this);if(hs.upcoming&&hs.upcoming==this.a)hs.upcoming=null;this.prepareNextOutline();var d=hs.page,e=hs.mouse.x+d.scrollLeft,f=hs.mouse.y+d.scrollTop;this.mouseIsOver=this.x.pos<e&&e<this.x.pos+this.x.get("wsize")&&this.y.pos<f&&f<this.y.pos+this.y.get("wsize");if(this.overlayBox)this.showOverlays();hs.fireEvent(this,"onAfterExpand")},prepareNextOutline:function(){var a=this.key;var b=this.outlineType;new hs.Outline(b,function(){try{hs.expanders[a].preloadNext()}catch(b){}})},preloadNext:function(){var a=this.getAdjacentAnchor(1);if(a&&a.onclick.toString().match(/hs\.expand/))var b=hs.createElement("img",{src:hs.getSrc(a)})},getAdjacentAnchor:function(a){var b=this.getAnchorIndex(),c=hs.anchors.groups[this.slideshowGroup||"none"];if(!c[b+a]&&this.slideshow&&this.slideshow.repeat){if(a==1)return c[0];else if(a==-1)return c[c.length-1]}return c[b+a]||null},getAnchorIndex:function(){var a=hs.getAnchors().groups[this.slideshowGroup||"none"];if(a)for(var b=0;b<a.length;b++){if(a[b]==this.a)return b}return null},getNumber:function(){if(this[this.numberPosition]){var a=hs.anchors.groups[this.slideshowGroup||"none"];if(a){var b=hs.lang.number.replace("%1",this.getAnchorIndex()+1).replace("%2",a.length);this[this.numberPosition].innerHTML='<div class="highslide-number">'+b+"</div>"+this[this.numberPosition].innerHTML}}},initSlideshow:function(){if(!this.last){for(var a=0;a<hs.slideshows.length;a++){var b=hs.slideshows[a],c=b.slideshowGroup;if(typeof c=="undefined"||c===null||c===this.slideshowGroup)this.slideshow=new hs.Slideshow(this.key,b)}}else{this.slideshow=this.last.slideshow}var b=this.slideshow;if(!b)return;var d=b.expKey=this.key;b.checkFirstAndLast();b.disable("full-expand");if(b.controls){var e=b.overlayOptions||{};e.overlayId=b.controls;e.hsId="controls";this.createOverlay(e)}if(b.thumbstrip)b.thumbstrip.add(this);if(!this.last&&this.autoplay)b.play(true);if(b.autoplay){b.autoplay=setTimeout(function(){hs.next(d)},b.interval||500)}},cancelLoading:function(){hs.expanders[this.key]=null;if(hs.upcoming==this.a)hs.upcoming=null;hs.undim(this.key);if(this.loading)hs.loading.style.left="-9999px";hs.fireEvent(this,"onHideLoading")},writeCredits:function(){if(this.credits)return;this.credits=hs.createElement("a",{href:hs.creditsHref,className:"highslide-credits",innerHTML:hs.lang.creditsText,title:hs.lang.creditsTitle});this.createOverlay({overlayId:this.credits,position:this.creditsPosition||"top left",hsId:"credits"})},getInline:function(types,addOverlay){for(var i=0;i<types.length;i++){var type=types[i],s=null;if(type=="caption"&&!hs.fireEvent(this,"onBeforeGetCaption"))return;else if(type=="heading"&&!hs.fireEvent(this,"onBeforeGetHeading"))return;if(!this[type+"Id"]&&this.thumbsUserSetId)this[type+"Id"]=type+"-for-"+this.thumbsUserSetId;if(this[type+"Id"])this[type]=hs.getNode(this[type+"Id"]);if(!this[type]&&!this[type+"Text"]&&this[type+"Eval"])try{s=eval(this[type+"Eval"])}catch(e){}if(!this[type]&&this[type+"Text"]){s=this[type+"Text"]}if(!this[type]&&!s){var next=this.a.nextSibling;while(next&&!hs.isHsAnchor(next)){if((new RegExp("highslide-"+type)).test(next.className||null)){this[type]=next.cloneNode(1);break}next=next.nextSibling}}if(!this[type]&&!s&&this.numberPosition==type)s="\n";if(!this[type]&&s)this[type]=hs.createElement("div",{className:"highslide-"+type,innerHTML:s});if(addOverlay&&this[type]){var o={position:type=="heading"?"above":"below"};for(var x in this[type+"Overlay"])o[x]=this[type+"Overlay"][x];o.overlayId=this[type];this.createOverlay(o)}}},doShowHide:function(a){if(hs.hideSelects)this.showHideElements("SELECT",a);if(hs.hideIframes)this.showHideElements("IFRAME",a);if(hs.geckoMac)this.showHideElements("*",a)},showHideElements:function(a,b){var c=document.getElementsByTagName(a);var d=a=="*"?"overflow":"visibility";for(var e=0;e<c.length;e++){if(d=="visibility"||document.defaultView.getComputedStyle(c[e],"").getPropertyValue("overflow")=="auto"||c[e].getAttribute("hidden-by")!=null){var f=c[e].getAttribute("hidden-by");if(b=="visible"&&f){f=f.replace("["+this.key+"]","");c[e].setAttribute("hidden-by",f);if(!f)c[e].style[d]=c[e].origProp}else if(b=="hidden"){var g=hs.getPosition(c[e]);g.w=c[e].offsetWidth;g.h=c[e].offsetHeight;if(!this.dimmingOpacity){var h=g.x+g.w<this.x.get("opos")||g.x>this.x.get("opos")+this.x.get("osize");var i=g.y+g.h<this.y.get("opos")||g.y>this.y.get("opos")+this.y.get("osize")}var j=hs.getWrapperKey(c[e]);if(!h&&!i&&j!=this.key){if(!f){c[e].setAttribute("hidden-by","["+this.key+"]");c[e].origProp=c[e].style[d];c[e].style[d]="hidden"}else if(f.indexOf("["+this.key+"]")==-1){c[e].setAttribute("hidden-by",f+"["+this.key+"]")}}else if((f=="["+this.key+"]"||hs.focusKey==j)&&j!=this.key){c[e].setAttribute("hidden-by","");c[e].style[d]=c[e].origProp||""}else if(f&&f.indexOf("["+this.key+"]")>-1){c[e].setAttribute("hidden-by",f.replace("["+this.key+"]",""))}}}}},focus:function(){this.wrapper.style.zIndex=hs.zIndexCounter++;for(var a=0;a<hs.expanders.length;a++){if(hs.expanders[a]&&a==hs.focusKey){var b=hs.expanders[a];b.content.className+=" highslide-"+b.contentType+"-blur";if(b.isImage){b.content.style.cursor=hs.ie?"hand":"pointer";b.content.title=hs.lang.focusTitle}hs.fireEvent(b,"onBlur")}}if(this.outline)this.outline.table.style.zIndex=this.wrapper.style.zIndex;this.content.className="highslide-"+this.contentType;if(this.isImage){this.content.title=hs.lang.restoreTitle;if(hs.restoreCursor){hs.styleRestoreCursor=window.opera?"pointer":"url("+hs.graphicsDir+hs.restoreCursor+"), pointer";if(hs.ie&&hs.uaVersion<6)hs.styleRestoreCursor="hand";this.content.style.cursor=hs.styleRestoreCursor}}hs.focusKey=this.key;hs.addEventListener(document,window.opera?"keypress":"keydown",hs.keyHandler);hs.fireEvent(this,"onFocus")},moveTo:function(a,b){this.x.setPos(a);this.y.setPos(b)},resize:function(a){var b,c,d=a.width/a.height;b=Math.max(a.width+a.dX,Math.min(this.minWidth,this.x.full));if(this.isImage&&Math.abs(b-this.x.full)<12)b=this.x.full;c=this.isHtml?a.height+a.dY:b/d;if(c<Math.min(this.minHeight,this.y.full)){c=Math.min(this.minHeight,this.y.full);if(this.isImage)b=c*d}this.resizeTo(b,c)},resizeTo:function(a,b){this.y.setSize(b);this.x.setSize(a)},close:function(){if(this.isClosing||!this.isExpanded)return;if(this.transitions[1]=="crossfade"&&hs.upcoming){hs.getExpander(hs.upcoming).cancelLoading();hs.upcoming=null}if(!hs.fireEvent(this,"onBeforeClose"))return;this.isClosing=true;if(this.slideshow&&!hs.upcoming)this.slideshow.pause();hs.removeEventListener(document,window.opera?"keypress":"keydown",hs.keyHandler);try{if(this.isHtml)this.htmlPrepareClose();this.content.style.cursor="default";this.changeSize(0,{wrapper:{width:this.x.t,height:this.y.t,left:this.x.tpos-this.x.cb+this.x.tb,top:this.y.tpos-this.y.cb+this.y.tb},content:{left:0,top:0,width:this.x.t,height:this.y.t}},hs.restoreDuration)}catch(a){this.afterClose()}},htmlPrepareClose:function(){if(hs.geckoMac){if(!hs.mask)hs.mask=hs.createElement("div",null,{position:"absolute"},hs.container);hs.setStyles(hs.mask,{width:this.x.size+"px",height:this.y.size+"px",left:this.x.pos+"px",top:this.y.pos+"px",display:"block"})}if(this.objectType=="swf")try{hs.$(this.body.id).StopPlay()}catch(a){}if(this.objectLoadTime=="after"&&!this.preserveContent)this.destroyObject();if(this.scrollerDiv&&this.scrollerDiv!=this.scrollingContent)this.scrollerDiv.style.overflow="hidden"},destroyObject:function(){if(hs.ie&&this.iframe)try{this.iframe.contentWindow.document.body.innerHTML=""}catch(a){}if(this.objectType=="swf")swfobject.removeSWF(this.body.id);this.body.innerHTML=""},sleep:function(){if(this.outline)this.outline.table.style.display="none";this.releaseMask=null;this.wrapper.style.display="none";hs.push(hs.sleeping,this)},awake:function(){try{hs.expanders[this.key]=this;if(!hs.allowMultipleInstances&&hs.focusKey!=this.key){try{hs.expanders[hs.focusKey].close()}catch(a){}}var b=hs.zIndexCounter++,c={display:"",zIndex:b};hs.setStyles(this.wrapper,c);this.isClosing=false;var d=this.outline||0;if(d){if(!this.outlineWhileAnimating)c.visibility="hidden";hs.setStyles(d.table,c)}if(this.slideshow){this.initSlideshow()}this.show()}catch(a){}},createOverlay:function(a){var b=a.overlayId,c=a.relativeTo=="viewport"&&!/panel$/.test(a.position);if(typeof b=="string")b=hs.getNode(b);if(a.html)b=hs.createElement("div",{innerHTML:a.html});if(!b||typeof b=="string")return;if(!hs.fireEvent(this,"onCreateOverlay",{overlay:b}))return;b.style.display="block";a.hsId=a.hsId||a.overlayId;if(this.transitions[1]=="crossfade"&&this.reuseOverlay(a,b))return;this.genOverlayBox();var d=a.width&&/^[0-9]+(px|%)$/.test(a.width)?a.width:"auto";if(/^(left|right)panel$/.test(a.position)&&!/^[0-9]+px$/.test(a.width))d="200px";var e=hs.createElement("div",{id:"hsId"+hs.idCounter++,hsId:a.hsId},{position:"absolute",visibility:"hidden",width:d,direction:hs.lang.cssDirection||"",opacity:0},c?hs.viewport:this.overlayBox,true);if(c)e.hsKey=this.key;e.appendChild(b);hs.extend(e,{opacity:1,offsetX:0,offsetY:0,dur:a.fade===0||a.fade===false||a.fade==2&&hs.ie?0:250});hs.extend(e,a);if(this.gotOverlays){this.positionOverlay(e);if(!e.hideOnMouseOut||this.mouseIsOver)hs.animate(e,{opacity:e.opacity},e.dur)}hs.push(this.overlays,hs.idCounter-1)},positionOverlay:function(a){var b=a.position||"middle center",c=a.relativeTo=="viewport",d=a.offsetX,e=a.offsetY;if(c){hs.viewport.style.display="block";a.hsKey=this.key;if(a.offsetWidth>a.parentNode.offsetWidth)a.style.width="100%"}else if(a.parentNode!=this.overlayBox)this.overlayBox.appendChild(a);if(/left$/.test(b))a.style.left=d+"px";if(/center$/.test(b))hs.setStyles(a,{left:"50%",marginLeft:d-Math.round(a.offsetWidth/2)+"px"});if(/right$/.test(b))a.style.right=-d+"px";if(/^leftpanel$/.test(b)){hs.setStyles(a,{right:"100%",marginRight:this.x.cb+"px",top:-this.y.cb+"px",bottom:-this.y.cb+"px",overflow:"auto"});this.x.p1=a.offsetWidth}else if(/^rightpanel$/.test(b)){hs.setStyles(a,{left:"100%",marginLeft:this.x.cb+"px",top:-this.y.cb+"px",bottom:-this.y.cb+"px",overflow:"auto"});this.x.p2=a.offsetWidth}var f=a.parentNode.offsetHeight;a.style.height="auto";if(c&&a.offsetHeight>f)a.style.height=hs.ieLt7?f+"px":"100%";if(/^top/.test(b))a.style.top=e+"px";if(/^middle/.test(b))hs.setStyles(a,{top:"50%",marginTop:e-Math.round(a.offsetHeight/2)+"px"});if(/^bottom/.test(b))a.style.bottom=-e+"px";if(/^above$/.test(b)){hs.setStyles(a,{left:-this.x.p1-this.x.cb+"px",right:-this.x.p2-this.x.cb+"px",bottom:"100%",marginBottom:this.y.cb+"px",width:"auto"});this.y.p1=a.offsetHeight}else if(/^below$/.test(b)){hs.setStyles(a,{position:"relative",left:-this.x.p1-this.x.cb+"px",right:-this.x.p2-this.x.cb+"px",top:"100%",marginTop:this.y.cb+"px",width:"auto"});this.y.p2=a.offsetHeight;a.style.position="absolute"}},getOverlays:function(){this.getInline(["heading","caption"],true);this.getNumber();if(this.caption)hs.fireEvent(this,"onAfterGetCaption");if(this.heading)hs.fireEvent(this,"onAfterGetHeading");if(this.heading&&this.dragByHeading)this.heading.className+=" highslide-move";if(hs.showCredits)this.writeCredits();for(var a=0;a<hs.overlays.length;a++){var b=hs.overlays[a],c=b.thumbnailId,d=b.slideshowGroup;if(!c&&!d||c&&c==this.thumbsUserSetId||d&&d===this.slideshowGroup){if(this.isImage||this.isHtml&&b.useOnHtml)this.createOverlay(b)}}var e=[];for(var a=0;a<this.overlays.length;a++){var b=hs.$("hsId"+this.overlays[a]);if(/panel$/.test(b.position))this.positionOverlay(b);else hs.push(e,b)}for(var a=0;a<e.length;a++)this.positionOverlay(e[a]);this.gotOverlays=true},genOverlayBox:function(){if(!this.overlayBox)this.overlayBox=hs.createElement("div",{className:this.wrapperClassName},{position:"absolute",width:(this.x.size||(this.useBox?this.width:null)||this.x.full)+"px",height:(this.y.size||this.y.full)+"px",visibility:"hidden",overflow:"hidden",zIndex:hs.ie?4:null},hs.container,true)},sizeOverlayBox:function(a,b){var c=this.overlayBox,d=this.x,e=this.y;hs.setStyles(c,{width:d.size+"px",height:e.size+"px"});if(a||b){for(var f=0;f<this.overlays.length;f++){var g=hs.$("hsId"+this.overlays[f]);var h=hs.ieLt7||document.compatMode=="BackCompat";if(g&&/^(above|below)$/.test(g.position)){if(h){g.style.width=c.offsetWidth+2*d.cb+d.p1+d.p2+"px"}e[g.position=="above"?"p1":"p2"]=g.offsetHeight}if(g&&h&&/^(left|right)panel$/.test(g.position)){g.style.height=c.offsetHeight+2*e.cb+"px"}}}if(a){hs.setStyles(this.content,{top:e.p1+"px"});hs.setStyles(c,{top:e.p1+e.cb+"px"})}},showOverlays:function(){var a=this.overlayBox;a.className="";hs.setStyles(a,{top:this.y.p1+this.y.cb+"px",left:this.x.p1+this.x.cb+"px",overflow:"visible"});if(hs.safari)a.style.visibility="visible";this.wrapper.appendChild(a);for(var b=0;b<this.overlays.length;b++){var c=hs.$("hsId"+this.overlays[b]);c.style.zIndex=c.hsId=="controls"?5:4;if(!c.hideOnMouseOut||this.mouseIsOver){c.style.visibility="visible";hs.setStyles(c,{visibility:"visible",display:""});hs.animate(c,{opacity:c.opacity},c.dur)}}},destroyOverlays:function(){if(!this.overlays.length)return;for(var a=0;a<this.overlays.length;a++){var b=hs.$("hsId"+this.overlays[a]);if(b.parentNode==hs.viewport)hs.discardElement(b)}if(this.slideshow){var c=this.slideshow.controls;if(c&&hs.getExpander(c)==this)c.parentNode.removeChild(c)}if(this.isHtml&&this.preserveContent){this.overlayBox.style.top="-9999px";hs.container.appendChild(this.overlayBox)}else hs.discardElement(this.overlayBox)},createFullExpand:function(){if(this.slideshow&&this.slideshow.controls){this.slideshow.enable("full-expand");return}this.fullExpandLabel=hs.createElement("a",{href:"javascript:hs.expanders["+this.key+"].doFullExpand();",title:hs.lang.fullExpandTitle,className:"highslide-full-expand"});if(!hs.fireEvent(this,"onCreateFullExpand"))return;this.createOverlay({overlayId:this.fullExpandLabel,position:hs.fullExpandPosition,hideOnMouseOut:true,opacity:hs.fullExpandOpacity})},doFullExpand:function(){try{if(!hs.fireEvent(this,"onDoFullExpand"))return;if(this.fullExpandLabel)hs.discardElement(this.fullExpandLabel);this.focus();var a=this.x.size;this.resizeTo(this.x.full,this.y.full);var b=this.x.pos-(this.x.size-a)/2;if(b<hs.marginLeft)b=hs.marginLeft;this.moveTo(b,this.y.pos);this.doShowHide("hidden");hs.setDimmerSize(this)}catch(c){this.error(c)}},afterClose:function(){this.a.className=this.a.className.replace("highslide-active-anchor","");this.doShowHide("visible");if(this.isHtml&&this.preserveContent&&this.transitions[1]!="crossfade"){this.sleep()}else{if(this.outline&&this.outlineWhileAnimating)this.outline.destroy();hs.discardElement(this.wrapper)}if(hs.mask)hs.mask.style.display="none";if(!hs.viewport.childNodes.length)hs.viewport.style.display="none";if(this.dimmingOpacity)hs.undim(this.key);hs.fireEvent(this,"onAfterClose");hs.expanders[this.key]=null;hs.reOrder()}};hs.Ajax=function(a,b,c){this.a=a;this.content=b;this.pre=c};hs.Ajax.prototype={run:function(){if(!this.src)this.src=hs.getSrc(this.a);if(this.src.match("#")){var a=this.src.split("#");this.src=a[0];this.id=a[1]}if(hs.cachedGets[this.src]){this.cachedGet=hs.cachedGets[this.src];if(this.id)this.getElementContent();else this.loadHTML();return}try{this.xmlHttp=new XMLHttpRequest}catch(b){try{this.xmlHttp=new ActiveXObject("Msxml2.XMLHTTP")}catch(b){try{this.xmlHttp=new ActiveXObject("Microsoft.XMLHTTP")}catch(b){this.onError()}}}var c=this;this.xmlHttp.onreadystatechange=function(){if(c.xmlHttp.readyState==4){if(c.id)c.getElementContent();else c.loadHTML()}};this.xmlHttp.open("POST",this.src,true);this.xmlHttp.setRequestHeader("X-Requested-With","XMLHttpRequest");this.xmlHttp.send("dummy=1")},getElementContent:function(){hs.init();var a=window.opera||hs.ie6SSL?{src:"about:blank"}:null;this.iframe=hs.createElement("iframe",a,{position:"absolute",top:"-9999px"},hs.container);this.loadHTML()},loadHTML:function(){var a=this.cachedGet||this.xmlHttp.responseText;if(this.pre)hs.cachedGets[this.src]=a;if(!hs.ie||hs.uaVersion>=5.5){a=a.replace(/\s/g," ").replace(new RegExp("<link[^>]*>","gi"),"").replace(new RegExp("<script[^>]*>.*?</script>","gi"),"");if(this.iframe){var b=this.iframe.contentDocument;if(!b&&this.iframe.contentWindow)b=this.iframe.contentWindow.document;if(!b){var c=this;setTimeout(function(){c.loadHTML()},25);return}b.open();b.write(a);b.close();try{a=b.getElementById(this.id).innerHTML}catch(d){try{a=this.iframe.document.getElementById(this.id).innerHTML}catch(d){}}}else{a=a.replace(new RegExp("^.*?<body[^>]*>(.*?)</body>.*?$","i"),"$1")}}hs.getElementByClass(this.content,"DIV","highslide-body").innerHTML=a;this.onLoad();for(var e in this)this[e]=null}};hs.Slideshow=function(a,b){if(hs.dynamicallyUpdateAnchors!==false)hs.updateAnchors();this.expKey=a;for(var c in b)this[c]=b[c];if(this.useControls)this.getControls();if(this.thumbstrip)this.thumbstrip=hs.Thumbstrip(this)};hs.Slideshow.prototype={getControls:function(){this.controls=hs.createElement("div",{innerHTML:hs.replaceLang(hs.skin.controls)},null,hs.container);var a=["play","pause","previous","next","move","full-expand","close"];this.btn={};var b=this;for(var c=0;c<a.length;c++){this.btn[a[c]]=hs.getElementByClass(this.controls,"li","highslide-"+a[c]);this.enable(a[c])}this.btn.pause.style.display="none"},checkFirstAndLast:function(){if(this.repeat||!this.controls)return;var a=hs.expanders[this.expKey],b=a.getAnchorIndex(),c=/disabled$/;if(b==0)this.disable("previous");else if(c.test(this.btn.previous.getElementsByTagName("a")[0].className))this.enable("previous");if(b+1==hs.anchors.groups[a.slideshowGroup||"none"].length){this.disable("next");this.disable("play")}else if(c.test(this.btn.next.getElementsByTagName("a")[0].className)){this.enable("next");this.enable("play")}},enable:function(a){if(!this.btn)return;var b=this,c=this.btn[a].getElementsByTagName("a")[0],d=/disabled$/;c.onclick=function(){b[a]();return false};if(d.test(c.className))c.className=c.className.replace(d,"")},disable:function(a){if(!this.btn)return;var b=this.btn[a].getElementsByTagName("a")[0];b.onclick=function(){return false};if(!/disabled$/.test(b.className))b.className+=" disabled"},hitSpace:function(){if(this.autoplay)this.pause();else this.play()},play:function(a){if(this.btn){this.btn.play.style.display="none";this.btn.pause.style.display=""}this.autoplay=true;if(!a)hs.next(this.expKey)},pause:function(){if(this.btn){this.btn.pause.style.display="none";this.btn.play.style.display=""}clearTimeout(this.autoplay);this.autoplay=null},previous:function(){this.pause();hs.previous(this.btn.previous)},next:function(){this.pause();hs.next(this.btn.next)},move:function(){},"full-expand":function(){hs.getExpander().doFullExpand()},close:function(){hs.close(this.btn.close)}};hs.Thumbstrip=function(a){function d(b,c){if(b===undefined)for(var d=0;d<e.length;d++){if(e[d]==hs.expanders[a.expKey].a){b=d;break}}var f=k.getElementsByTagName("a"),g=f[b],h=g.parentNode,i=j?"Left":"Top",l=j?"Right":"Bottom",r=j?"Width":"Height",s="offset"+i,t="offset"+r,u=m.parentNode.parentNode[t],v=u-q[t],w=parseInt(q.style[j?"left":"top"])||0,x=w,y=20;if(c!==undefined){x=w-c;if(x>0)x=0;if(x<v)x=v}else{for(var d=0;d<f.length;d++)f[d].className="";g.className="highslide-active-anchor";var z=b>0?f[b-1].parentNode[s]:h[s],A=h[s]+h[t]+(f[b+1]?f[b+1].parentNode[t]:0);if(A>u-w)x=u-A;else if(z<-w)x=-z}var B=h[s]+(h[t]-p[t])/2+x;hs.animate(q,j?{left:x}:{top:x},null,"easeOutQuad");hs.animate(p,j?{left:B}:{top:B},null,"easeOutQuad");n.style.display=x<0?"block":"none";o.style.display=x>v?"block":"none"}function c(a){d(undefined,Math.round(a*k[j?"offsetWidth":"offsetHeight"]*.7))}function b(a){hs.extend(f||{},{overlayId:k,hsId:"thumbstrip"});if(hs.ieLt7)f.fade=0;a.createOverlay(f);hs.setStyles(k.parentNode,{overflow:"hidden"})}var e=hs.anchors.groups[hs.expanders[a.expKey].slideshowGroup||"none"],f=a.thumbstrip,g=f.mode||"horizontal",h=g=="float",i=h?["div","ul","li","span"]:["table","tbody","tr","td"],j=g=="horizontal",k=hs.createElement("div",{className:"highslide-thumbstrip highslide-thumbstrip-"+g,innerHTML:'<div class="highslide-thumbstrip-inner">'+"<"+i[0]+"><"+i[1]+"></"+i[1]+"></"+i[0]+"></div>"+'<div class="highslide-scroll-up"><div></div></div>'+'<div class="highslide-scroll-down"><div></div></div>'+'<div class="highslide-marker"><div></div></div>'},{display:"none"},hs.container),l=k.childNodes,m=l[0],n=l[1],o=l[2],p=l[3],q=m.firstChild,r=k.getElementsByTagName(i[1])[0],s;for(var t=0;t<e.length;t++){if(t==0||!j)s=hs.createElement(i[2],null,null,r);(function(){var a=e[t],b=hs.createElement(i[3],null,null,s),c=t;hs.createElement("a",{href:a.href,onclick:function(){return hs.transit(a)},innerHTML:hs.stripItemFormatter?hs.stripItemFormatter(a):a.innerHTML},null,b)})()}if(!h){n.onclick=function(){c(-1)};o.onclick=function(){c(1)};hs.addEventListener(r,document.onmousewheel!==undefined?"mousewheel":"DOMMouseScroll",function(a){var b=0;a=a||window.event;if(a.wheelDelta){b=a.wheelDelta/120;if(hs.opera)b=-b}else if(a.detail){b=-a.detail/3}if(b)c(-b*.2);if(a.preventDefault)a.preventDefault();a.returnValue=false})}return{add:b,selectThumb:d}};if(hs.ie){(function(){try{document.documentElement.doScroll("left")}catch(a){setTimeout(arguments.callee,50);return}hs.ready()})()}hs.addEventListener(document,"DOMContentLoaded",hs.ready);hs.addEventListener(window,"load",hs.ready);hs.langDefaults=hs.lang;var HsExpander=hs.Expander;hs.addEventListener(window,"load",function(){if(hs.expandCursor){var a=".highslide img",b="cursor: url("+hs.graphicsDir+hs.expandCursor+"), pointer !important;";var c=hs.createElement("style",{type:"text/css"},null,document.getElementsByTagName("HEAD")[0]);if(!hs.ie){c.appendChild(document.createTextNode(a+" {"+b+"}"))}else{var d=document.styleSheets[document.styleSheets.length-1];if(typeof d.addRule=="object")d.addRule(a,b)}}});hs.addEventListener(window,"resize",function(){hs.page=hs.getPageSize();if(hs.viewport)for(var a=0;a<hs.viewport.childNodes.length;a++){var b=hs.viewport.childNodes[a],c=hs.getExpander(b);c.positionOverlay(b);if(b.hsId=="thumbstrip")c.slideshow.thumbstrip.selectThumb()}});hs.addEventListener(document,"mousemove",function(a){hs.mouse={x:a.clientX,y:a.clientY}});hs.addEventListener(document,"mousedown",hs.mouseClickHandler);hs.addEventListener(document,"mouseup",hs.mouseClickHandler);hs.addEventListener(document,"ready",hs.setClickEvents);hs.addEventListener(window,"load",hs.preloadImages);hs.addEventListener(window,"load",hs.preloadAjax)
