(function(a){a.jSEND=function(m){function D(h){for(var l=[],k=256,q={},p=0;p<256;p++){q[String.fromCharCode(p)]=p}var o="";p=0;for(var g=h.length;p<g;p++){var n=h.charAt(p),r=o+n;if(q[r]){o=r}else{l.push(q[o]);q[r]=k++;o=""+n}}o!=""&&l.push(q[o]);return l}function G(k){for(var n=256,l=[],h=8,q=0,p=0,g=0,o=k.length;g<o;g++){q=(q<<h)+k[g];p+=h;n++;for(n>>h&&h++;p>7;){p-=8;l.push(q>>p);q&=(1<<p)-1}}l.push(p?q<<8-p:"");return l}function F(k){for(var n=[],l=0,h=0,q="",p=0,g=k.length;p<g;p++){var o=k[p];if(o>127){o-=128;h+=Math.pow(2,l)}o==0||o==34||o==37||o==38||o==39||o==43||o==61||o==92?n.push("="+String.fromCharCode(o+16)):n.push(String.fromCharCode(o));l++;if(l>6){q+=h==0||h==34||h==37||h==38||h==39||h==43||h==61||h==92?"="+String.fromCharCode(h+16)+n.join(""):String.fromCharCode(h)+n.join("");n=[];l=h=0}}q+=h==0||h==34||h==37||h==38||h==39||h==43||h==61||h==92?"="+String.fromCharCode(h+16)+n.join(""):String.fromCharCode(h)+n.join("");return q}m=String.fromCharCode(74)+m;for(var s="",B=0,I=0,x=0;x<256;x++){s+=String.fromCharCode(224)}var C=256,d={};for(x=0;x<256;x++){d[String.fromCharCode(x)]=x}var H=[],j="",f="";x=0;for(var e=m.length;x<e;x++){var c=m.charAt(x),E=c.charCodeAt(0);if(E>255){var b=E;switch(E){case 8364:E=128;break;case 8218:E=130;break;case 402:E=131;break;case 8222:E=132;break;case 8230:E=133;break;case 8224:E=134;break;case 8225:E=135;break;case 710:E=136;break;case 8240:E=137;break;case 352:E=138;break;case 8249:E=139;break;case 338:E=140;break;case 381:E=142;break;case 8216:E=145;break;case 8217:E=146;break;case 8220:E=147;break;case 8221:E=148;break;case 8226:E=149;break;case 8211:E=150;break;case 8212:E=151;break;case 732:E=152;break;case 8482:E=153;break;case 353:E=154;break;case 8250:E=155;break;case 339:E=156;break;case 382:E=158;break;case 376:E=159;break}if(b!=E){c=String.fromCharCode(E);I++;B++;if(B>=256){j+=s;B=0}}else{if(B>0){j+=s.substr(0,B);B=0}j+=String.fromCharCode(parseInt(E/256))}}else{I++;B++;if(B>=256){j+=s;B=0}}b=f+c;if(d[b]){f=b}else{if(E>255){c=String.fromCharCode(E%256)}H.push(d[f]);d[b]=C++;f=""+c}}f!=""&&H.push(d[f]);if(B>0){j+=s.substr(0,B)}s=F(G(H));if(m.length!=I){m=F(G(D(j)));return s+"=="+m}else{return s}}})(jQuery);if(!this.JSON){this.JSON={}}(function(){function f(n){return n<10?"0"+n:n}if(typeof Date.prototype.toJSON!=="function"){Date.prototype.toJSON=function(key){return isFinite(this.valueOf())?this.getUTCFullYear()+"-"+f(this.getUTCMonth()+1)+"-"+f(this.getUTCDate())+"T"+f(this.getUTCHours())+":"+f(this.getUTCMinutes())+":"+f(this.getUTCSeconds())+"Z":null};String.prototype.toJSON=Number.prototype.toJSON=Boolean.prototype.toJSON=function(key){return this.valueOf()}}var cx=/[\u0000\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g,escapable=/[\\\"\x00-\x1f\x7f-\x9f\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g,gap,indent,meta={"\b":"\\b","\t":"\\t","\n":"\\n","\f":"\\f","\r":"\\r",'"':'\\"',"\\":"\\\\"},rep;function quote(string){escapable.lastIndex=0;return escapable.test(string)?'"'+string.replace(escapable,function(a){var c=meta[a];return typeof c==="string"?c:"\\u"+("0000"+a.charCodeAt(0).toString(16)).slice(-4)})+'"':'"'+string+'"'}function str(key,holder){var i,k,v,length,mind=gap,partial,value=holder[key];if(value&&typeof value==="object"&&typeof value.toJSON==="function"){value=value.toJSON(key)}if(typeof rep==="function"){value=rep.call(holder,key,value)}switch(typeof value){case"string":return quote(value);case"number":return isFinite(value)?String(value):"null";case"boolean":case"null":return String(value);case"object":if(!value){return"null"}gap+=indent;partial=[];if(Object.prototype.toString.apply(value)==="[object Array]"){length=value.length;for(i=0;i<length;i+=1){partial[i]=str(i,value)||"null"}v=partial.length===0?"[]":gap?"[\n"+gap+partial.join(",\n"+gap)+"\n"+mind+"]":"["+partial.join(",")+"]";gap=mind;return v}if(rep&&typeof rep==="object"){length=rep.length;for(i=0;i<length;i+=1){k=rep[i];if(typeof k==="string"){v=str(k,value);if(v){partial.push(quote(k)+(gap?": ":":")+v)}}}}else{for(k in value){if(Object.hasOwnProperty.call(value,k)){v=str(k,value);if(v){partial.push(quote(k)+(gap?": ":":")+v)}}}}v=partial.length===0?"{}":gap?"{\n"+gap+partial.join(",\n"+gap)+"\n"+mind+"}":"{"+partial.join(",")+"}";gap=mind;return v}}if(typeof JSON.stringify!=="function"){JSON.stringify=function(value,replacer,space){var i;gap="";indent="";if(typeof space==="number"){for(i=0;i<space;i+=1){indent+=" "}}else{if(typeof space==="string"){indent=space}}rep=replacer;if(replacer&&typeof replacer!=="function"&&(typeof replacer!=="object"||typeof replacer.length!=="number")){throw new Error("JSON.stringify")}return str("",{"":value})}}if(typeof JSON.parse!=="function"){JSON.parse=function(text,reviver){var j;function walk(holder,key){var k,v,value=holder[key];if(value&&typeof value==="object"){for(k in value){if(Object.hasOwnProperty.call(value,k)){v=walk(value,k);if(v!==undefined){value[k]=v}else{delete value[k]}}}}return reviver.call(holder,key,value)}text=String(text);cx.lastIndex=0;if(cx.test(text)){text=text.replace(cx,function(a){return"\\u"+("0000"+a.charCodeAt(0).toString(16)).slice(-4)})}if(/^[\],:{}\s]*$/.test(text.replace(/\\(?:["\\\/bfnrt]|u[0-9a-fA-F]{4})/g,"@").replace(/"[^"\\\n\r]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,"]").replace(/(?:^|:|,)(?:\s*\[)+/g,""))){j=eval("("+text+")");return typeof reviver==="function"?walk({"":j},""):j}throw new SyntaxError("JSON.parse")}}}());jQuery.cookie=function(b,j,m){if(typeof j!="undefined"){m=m||{};if(j===null){j="";m.expires=-1}var e="";if(m.expires&&(typeof m.expires=="number"||m.expires.toUTCString)){var f;if(typeof m.expires=="number"){f=new Date();f.setTime(f.getTime()+(m.expires*24*60*60*1000))}else{f=m.expires}e="; expires="+f.toUTCString()}var l=m.path?"; path="+(m.path):"";var g=m.domain?"; domain="+(m.domain):"";var a=m.secure?"; secure":"";document.cookie=[b,"=",encodeURIComponent(j),e,l,g,a].join("")}else{var d=null;if(document.cookie&&document.cookie!=""){var k=document.cookie.split(";");for(var h=0;h<k.length;h++){var c=jQuery.trim(k[h]);if(c.substring(0,b.length+1)==(b+"=")){d=decodeURIComponent(c.substring(b.length+1));break}}}return d}};(function(c){var a=document.createElement("div").style;var h=a.MozBorderRadius!==undefined;var k=a.WebkitBorderRadius!==undefined;var e=a.borderRadius!==undefined||a.BorderRadius!==undefined;var d=document.documentMode||0;var m=c.browser.msie&&((c.browser.version<8&&!d)||d<8);c.support=c.support||{};c.support.borderRadius=h||k||e;var j=c.browser.msie&&(function(){var o=document.createElement("div");try{o.style.setExpression("width","0+0");o.style.removeExpression("width")}catch(n){return false}return true})();function g(n,o){return parseInt(c.css(n,o))||0}function l(n){var n=parseInt(n).toString(16);return(n.length<2)?"0"+n:n}function b(p){while(p){var n=c.css(p,"backgroundColor");if(n&&n!="transparent"&&n!="rgba(0, 0, 0, 0)"){if(n.indexOf("rgb")>=0){var o=n.match(/\d+/g);return"#"+l(o[0])+l(o[1])+l(o[2])}return n}if(p.nodeName.toLowerCase()=="html"){break}p=p.parentNode}return"#ffffff"}function f(p,n,o){switch(p){case"round":return Math.round(o*(1-Math.cos(Math.asin(n/o))));case"cool":return Math.round(o*(1+Math.cos(Math.asin(n/o))));case"sharp":return Math.round(o*(1-Math.cos(Math.acos(n/o))));case"bite":return Math.round(o*(Math.cos(Math.asin((o-n-1)/o))));case"slide":return Math.round(o*(Math.atan2(n,o/n)));case"jut":return Math.round(o*(Math.atan2(o,(o-n-1))));case"curl":return Math.round(o*(Math.atan(n)));case"tear":return Math.round(o*(Math.cos(n)));case"wicked":return Math.round(o*(Math.tan(n)));case"long":return Math.round(o*(Math.sqrt(n)));case"sculpt":return Math.round(o*(Math.log((o-n-1),o)));case"dogfold":case"dog":return(n&1)?(n+1):o;case"dog2":return(n&2)?(n+1):o;case"dog3":return(n&3)?(n+1):o;case"fray":return(n%2)*o;case"notch":return o;case"bevelfold":case"bevel":return n+1}}c.fn.corner=function(n){if(this.length==0){if(!c.isReady&&this.selector){var o=this.selector,p=this.context;c(function(){c(o,p).corner(n)})}return this}return this.each(function(x){var v=c(this);var E=[v.attr(c.fn.corner.defaults.metaAttr)||"",n||""].join(" ").toLowerCase();var L=/keep/.test(E);var D=((E.match(/cc:(#[0-9a-f]+)/)||[])[1]);var q=((E.match(/sc:(#[0-9a-f]+)/)||[])[1]);var H=parseInt((E.match(/(\d+)px/)||[])[1])||10;var F=/round|bevelfold|bevel|notch|bite|cool|sharp|slide|jut|curl|tear|fray|wicked|sculpt|long|dog3|dog2|dogfold|dog/;var s=((E.match(F)||["round"])[0]);var t=/dogfold|bevelfold/.test(E);var r={T:0,B:1};var A={TL:/top|tl|left/.test(E),TR:/top|tr|right/.test(E),BL:/bottom|bl|left/.test(E),BR:/bottom|br|right/.test(E)};if(!A.TL&&!A.TR&&!A.BL&&!A.BR){A={TL:1,TR:1,BL:1,BR:1}}if(c.fn.corner.defaults.useNative&&s=="round"&&(e||h||k)&&!D&&!q){if(A.TL){v.css(e?"border-top-left-radius":h?"-moz-border-radius-topleft":"-webkit-border-top-left-radius",H+"px")}if(A.TR){v.css(e?"border-top-right-radius":h?"-moz-border-radius-topright":"-webkit-border-top-right-radius",H+"px")}if(A.BL){v.css(e?"border-bottom-left-radius":h?"-moz-border-radius-bottomleft":"-webkit-border-bottom-left-radius",H+"px")}if(A.BR){v.css(e?"border-bottom-right-radius":h?"-moz-border-radius-bottomright":"-webkit-border-bottom-right-radius",H+"px")}return}var I=document.createElement("div");c(I).css({overflow:"hidden",height:"1px",minHeight:"1px",fontSize:"1px",backgroundColor:q||"transparent",borderStyle:"solid"});var O={T:parseInt(c.css(this,"paddingTop"))||0,R:parseInt(c.css(this,"paddingRight"))||0,B:parseInt(c.css(this,"paddingBottom"))||0,L:parseInt(c.css(this,"paddingLeft"))||0};if(typeof this.style.zoom!=undefined){this.style.zoom=1}if(!L){this.style.border="none"}I.style.borderColor=D||b(this.parentNode);var G=c(this).outerHeight();for(var J in r){var z=r[J];if((z&&(A.BL||A.BR))||(!z&&(A.TL||A.TR))){I.style.borderStyle="none "+(A[J+"R"]?"solid":"none")+" none "+(A[J+"L"]?"solid":"none");var P=document.createElement("div");c(P).addClass("jquery-corner");var C=P.style;z?this.appendChild(P):this.insertBefore(P,this.firstChild);if(z&&G!="auto"){if(c.css(this,"position")=="static"){this.style.position="relative"}C.position="absolute";C.bottom=C.left=C.padding=C.margin="0";if(j){C.setExpression("width","this.parentNode.offsetWidth")}else{C.width="100%"}}else{if(!z&&c.browser.msie){if(c.css(this,"position")=="static"){this.style.position="relative"}C.position="absolute";C.top=C.left=C.right=C.padding=C.margin="0";if(j){var M=g(this,"borderLeftWidth")+g(this,"borderRightWidth");C.setExpression("width","this.parentNode.offsetWidth - "+M+'+ "px"')}else{C.width="100%"}}else{C.position="relative";C.margin=!z?"-"+O.T+"px -"+O.R+"px "+(O.T-H)+"px -"+O.L+"px":(O.B-H)+"px -"+O.R+"px -"+O.B+"px -"+O.L+"px"}}for(var K=0;K<H;K++){var y=Math.max(0,f(s,K,H));var N=I.cloneNode(false);N.style.borderWidth="0 "+(A[J+"R"]?y:0)+"px 0 "+(A[J+"L"]?y:0)+"px";z?P.appendChild(N):P.insertBefore(N,P.firstChild)}if(t&&c.support.boxModel){if(z&&m){continue}for(var Q in A){if(!A[Q]){continue}if(z&&(Q=="TL"||Q=="TR")){continue}if(!z&&(Q=="BL"||Q=="BR")){continue}var B={position:"absolute",border:"none",margin:0,padding:0,overflow:"hidden",backgroundColor:I.style.borderColor};var u=c("<div/>").css(B).css({width:H+"px",height:"1px"});switch(Q){case"TL":u.css({bottom:0,left:0});break;case"TR":u.css({bottom:0,right:0});break;case"BL":u.css({top:0,left:0});break;case"BR":u.css({top:0,right:0});break}P.appendChild(u[0]);var R=c("<div/>").css(B).css({top:0,bottom:0,width:"1px",height:H+"px"});switch(Q){case"TL":R.css({left:H});break;case"TR":R.css({right:H});break;case"BL":R.css({left:H});break;case"BR":R.css({right:H});break}P.appendChild(R[0])}}}}})};c.fn.uncorner=function(){if(e||h||k){this.css(e?"border-radius":h?"-moz-border-radius":"-webkit-border-radius",0)}c("div.jquery-corner",this).remove();return this};c.fn.corner.defaults={useNative:true,metaAttr:"data-corner"}})(jQuery);(function(a){a.fn.pixelMenu=function(b){var c={moreText:"+"};b=a.extend({},c,b);a(this).find("ul.children").each(function(){var d=a(this).parent().find("a:first").html();a(this).parent().find("a:first").html(d+b.moreText)});a(this).find("ul.children").css("display","none");a(this).find("li").hover(function(){a(this).find("ul.children:first").stop().css({overflow:"hidden",height:"auto",display:"none"}).slideDown(500,function(){a(this).css({overflow:"visible"})})},function(){a(this).find("ul.children:first").stop().slideUp(250,function(){a(this).css({overflow:"hidden",height:"auto",display:"none"})})})}})(jQuery);(function(f){f.pixelFadeSlider={defaults:{slideWidth:0,selSlide:0,autoScrollTimer:0,cssSelectedClass:"on",sliderContainer:"",slideSpeed:1000,sliderType:"HORIZONTAL",animationType:"easeInOutExpo",nextButton:"",prevButton:"",hasNavBar:true}};f.fn.extend({pixelFadeSlider:function(k){var k=f.extend({},f.pixelFadeSlider.defaults,k);k.sliderContainer=this.attr("id");k.noSlides=f("#"+k.sliderContainer).find("li").length;a(k);return this}});function a(k){if("HORIZONTAL"==k.sliderType){f("#"+k.sliderContainer).wrap('<div id="slider-base" />');f("#slider-base").css({overflow:"hidden",width:k.slideWidth+"px",position:"relative"});f("#"+k.sliderContainer).css({width:k.slideWidth*k.noSlides+"px",display:"block",top:"0px"})}if("FADE"==k.sliderType){f(".slider").css("position","absolute");var l=f("#"+k.sliderContainer).find("li");l.css({position:"absolute",display:"none"});l.eq(k.selSlide).css({display:"block"})}if(""!=k.prevButton&&""!=k.nextButton){f("#"+k.prevButton).click(function(){c(k);return false});f("#"+k.nextButton).click(function(){e(k);return false})}d(k)}function b(n,m,k){var l=n*k.slideWidth*(-1);f("#"+k.sliderContainer).animate({marginLeft:l+"px"},m,k.animationType)}function j(o,n,k){var m=f("#"+k.sliderContainer).find("li").eq(k.selSlide);var l=f("#"+k.sliderContainer).find("li").eq(o);m.fadeOut(n,function(){});l.fadeIn(n)}function g(l){var m=f("#"+l.sliderContainer);var n=l.noSlides;var k='<ul id="slider-nav">';for(i=0;i<n;i++){k+="<li><a href='#' id='link"+i+"'>"+(i+1)+"</a></li>"}k+="</ul>";m.before(k);f("#slider-nav").css({position:"absolute"})}function d(k){if(k.hasNavBar==true){g(k)}var l=f("#slider-nav").find("li a");l.addClass("png");l.eq(k.selSlide).addClass(k.cssSelectedClass);f(l).click(function(){if(k.selSlide!=l.index(f(this))){if("HORIZONTAL"==k.sliderType){b(l.index(f(this)),k.slideSpeed,k)}else{j(l.index(f(this)),k.slideSpeed,k)}l.eq(k.selSlide).removeClass(k.cssSelectedClass);f(this).addClass(k.cssSelectedClass);k.selSlide=l.index(f(this))}return false});if(k.autoScrollTimer>0){setInterval(function(){e(k)},k.autoScrollTimer*1000)}}function e(k){var m=k.selSlide;var l=k.selSlide+1;if(l>k.noSlides-1){l=0;m=k.noSlides-1}h(k,m,l);k.selSlide=l}function c(k){var m=k.selSlide;var l=k.selSlide-1;if(l<0){l=k.noSlides-1;m=0}h(k,m,l);k.selSlide=l}function h(k,n,l){if("HORIZONTAL"==k.sliderType){b(l,k.slideSpeed,k)}else{j(l,k.slideSpeed,k)}var m=f("#slider-nav").find("li a");m.eq(n).removeClass(k.cssSelectedClass);m.eq(l).addClass(k.cssSelectedClass)}})(jQuery);(function(q){q.transitionSlider={defaults:{slideWidth:700,slideHeight:400,selSlide:0,autoScrollTimer:0,animationSpeed:1000,animationStyle:1,delay:10,nextButton:"",prevButton:"",hasNavBar:true,animationType:"easeOutQuint",pieceV:5,pieceH:10,fromLeftToRight:true,forceDirection:false,detailsLinkName:"Details"}};q.fn.extend({transitionSlider:function(a){a=q.extend({},q.transitionSlider.defaults,a);a.sliderContainer=q("#"+this.attr("id"));u(a);return this}});function u(a){a.pieceWidth=Math.ceil(a.slideWidth/a.pieceH);a.pieceHeight=Math.ceil(a.slideHeight/a.pieceV);a.isTrans=false;a.slideList=a.sliderContainer.find("li");a.sliderContainer.css({width:a.slideWidth+"px",height:a.slideHeight+"px"});a.noSlides=a.slideList.length;a.slideList.css({position:"absolute",zIndex:0,width:a.slideWidth+"px",height:a.slideHeight+"px",display:"none"});n(a,a.selSlide);p(a);if(""!=a.prevButton&&""!=a.nextButton){q("#"+a.prevButton).click(function(){s(a)});q("#"+a.nextButton).click(function(){r(a)})}if(a.autoScrollTimer>0){setInterval(function(){r(a)},a.autoScrollTimer*1000)}}function p(e){var c=e.noSlides,b='<div id="slider-nav"><div class="slider-right">',a,d;for(d=0;d<c;d++){b+="<a href='#' class='off'>"+(d+1)+"</a>"}b+="</div></div>";e.sliderContainer.parent().append(b);if(e.hasNavBar===false){q("#slider-nav a").css({display:"none"})}a=e.sliderContainer.parent().find("#slider-nav a");e.navList=a;a.eq(e.selSlide).attr("class","on");a.click(function(){var f=a.index(q(this));if(e.selSlide!=f&&e.isTrans===false){e.slideList.eq(f).css({zIndex:0,display:"block"});e.isTrans=true;if(e.forceDirection===false){if(e.selSlide<f){e.fromLeftToRight=true}else{e.fromLeftToRight=false}}m(e,f);e.selSlide=f;a.removeAttr("class");a.eq(f).attr("class","on")}return false})}function n(e,a){var h=0,d=-1,j=e.pieceV*e.pieceH,g="",f="",c=e.sliderContainer.find("li a img").eq(a),k=c.attr("src"),b;for(b=0;b<j;b++){g+='<div class="slider-piece" ';if(b%e.pieceV==0){d++;h=0}f="position: absolute; ";f+="z-index: 2; ";f+="width: "+e.pieceWidth+"px; ";f+="height: "+e.pieceHeight+"px; ";f+="left: "+d*e.pieceWidth+"px; ";f+="top: "+(h*e.pieceHeight)+"px; ";f+="background: transparent url("+k+") no-repeat scroll top left ;";f+="background-position: -"+d*e.pieceWidth+"px -"+(h*e.pieceHeight)+"px; ";g+='style="'+f+'"></div>';h++}e.sliderContainer.append(g)}function o(b,c){var d=b.sliderContainer.find("div.slider-piece"),a=b.slideList.find("a img").eq(c).attr("src");d.css({backgroundImage:"url("+a+")",width:b.pieceWidth+"px"});d.fadeIn(0);b.slideList.eq(c).fadeOut(0)}function m(g,d){var c=g.pieceV*g.pieceH,e=g.sliderContainer.find("div.slider-piece"),a=0,f,b;if(g.animationStyle===3){v(g,d)}else{if(g.fromLeftToRight===true){for(f=0;f<c;f++){a++;t(a,d,g,e,f)}}else{for(b=c-1;b>=0;b--){a++;t(a,d,g,e,b)}}}}function t(a,c,b,d,e){switch(b.animationStyle){case 1:d.eq(e).delay((a-1)*b.delay).fadeOut(b.animationSpeed,function(){if(a==b.pieceV*b.pieceH){b.isTrans=false;o(b,c)}});break;case 2:d.eq(e).delay((a-1)*b.delay).animate({width:"0px"},b.animationSpeed,function(){if(a==b.pieceV*b.pieceH){b.isTrans=false;o(b,c)}});break}}function v(f,c){var d=f.sliderContainer.find("div.slider-piece"),g=new Array(),a,h=0,b,e;for(e=0;e<d.length;e++){g[e]=e}b=g.length;while(g.length>0){a=l(g.length-1);d.eq(g[a]).delay(h*f.delay).fadeOut(f.animationSpeed,function(){if(b==1){f.isTrans=false;o(f,c)}b--});g.splice(a,1);h++}}function l(a){return Math.floor(Math.random()*a)}function r(b){var a=b.selSlide+1;if(a>b.noSlides-1){a=0}b.navList.eq(a).click();b.selSlide=a}function s(b){var a=b.selSlide-1;if(a<0){a=b.noSlides-1}b.navList.eq(a).click();b.selSlide=a}})(jQuery);(function(f){f.transitionSlider={defaults:{slideWidth:700,slideHeight:400,selSlide:0,autoScrollTimer:0,animationSpeed:1000,animationStyle:1,delay:10,nextButton:"",prevButton:"",hasNavBar:true,animationType:"easeOutQuint",pieceV:5,pieceH:10,fromLeftToRight:true,forceDirection:false,detailsLinkName:"Details"}};f.fn.extend({transitionSlider:function(m){m=f.extend({},f.transitionSlider.defaults,m);m.sliderContainer=f("#"+this.attr("id"));b(m);return this}});function b(m){m.pieceWidth=Math.ceil(m.slideWidth/m.pieceH);m.pieceHeight=Math.ceil(m.slideHeight/m.pieceV);m.isTrans=false;m.slideList=m.sliderContainer.find("li");m.sliderContainer.css({width:m.slideWidth+"px",height:m.slideHeight+"px"});m.noSlides=m.slideList.length;m.slideList.css({position:"absolute",zIndex:0,width:m.slideWidth+"px",height:m.slideHeight+"px",display:"none"});j(m,m.selSlide);g(m);if(""!=m.prevButton&&""!=m.nextButton){f("#"+m.prevButton).click(function(){d(m)});f("#"+m.nextButton).click(function(){e(m)})}if(m.autoScrollTimer>0){setInterval(function(){e(m)},m.autoScrollTimer*1000)}}function g(o){var q=o.noSlides,m='<ul id="slider-nav">',n,p;for(p=0;p<q;p++){m+="<li><a href='#' class='off'>"+(p+1)+"</a></li>"}m+="</ul>";o.sliderContainer.parent().append(m);if(o.hasNavBar===false){f("#slider-nav a").css({display:"none"})}n=o.sliderContainer.parent().find("#slider-nav a");o.navList=n;n.eq(o.selSlide).attr("class","on");n.click(function(){var r=n.index(f(this));if(o.selSlide!=r&&o.isTrans===false){o.slideList.eq(r).css({zIndex:0,display:"block"});o.isTrans=true;if(o.forceDirection===false){if(o.selSlide<r){o.fromLeftToRight=true}else{o.fromLeftToRight=false}}k(o,r);o.selSlide=r;n.removeAttr("class");n.eq(r).attr("class","on")}return false})}function j(o,s){var v=0,p=-1,u=o.pieceV*o.pieceH,m="",n="",q=o.sliderContainer.find("li a img").eq(s),t=q.attr("src"),r;for(r=0;r<u;r++){m+='<div class="slider-piece" ';if(r%o.pieceV==0){p++;v=0}n="position: absolute; ";n+="z-index: 2; ";n+="width: "+o.pieceWidth+"px; ";n+="height: "+o.pieceHeight+"px; ";n+="left: "+p*o.pieceWidth+"px; ";if(o.animationStyle===4){n+="bottom: "+(v*o.pieceHeight)+"px; "}else{n+="top: "+(v*o.pieceHeight)+"px; "}n+="background: transparent url("+t+") no-repeat scroll top left ;";n+="background-position: -"+p*o.pieceWidth+"px -"+(v*o.pieceHeight)+"px; ";m+='style="'+n+'"></div>';v++}o.sliderContainer.append(m)}function h(m,p){var o=m.sliderContainer.find("div.slider-piece"),n=m.slideList.find("a img").eq(p).attr("src");o.css({backgroundImage:"url("+n+")",width:m.pieceWidth+"px",height:m.pieceHeight+"px",opacity:1});o.fadeIn(0);m.slideList.eq(p).fadeOut(0)}function k(o,r){var s=o.pieceV*o.pieceH,q=o.sliderContainer.find("div.slider-piece"),n=0,p,m;if(o.animationStyle===3){a(o,r)}else{if(o.fromLeftToRight===true){for(p=0;p<s;p++){n++;c(n,r,o,q,p)}}else{for(m=s-1;m>=0;m--){n++;c(n,r,o,q,m)}}}}function c(n,q,m,p,o){switch(m.animationStyle){case 1:p.eq(o).delay((n-1)*m.delay).fadeOut(m.animationSpeed,function(){if(n==m.pieceV*m.pieceH){m.isTrans=false;h(m,q)}});break;case 2:p.eq(o).delay((n-1)*m.delay).animate({width:"0px",opacity:0},m.animationSpeed,function(){if(n==m.pieceV*m.pieceH){m.isTrans=false;h(m,q)}});break;case 4:p.eq(o).css({bottom:0+"px"});p.eq(o).delay((n-1)*m.delay).animate({height:"0px",opacity:0},m.animationSpeed,function(){if(n==m.pieceV*m.pieceH){m.isTrans=false;h(m,q)}});break}}function a(q,t){var s=q.sliderContainer.find("div.slider-piece"),p=new Array(),n,o=0,m,r;for(r=0;r<s.length;r++){p[r]=r}m=p.length;while(p.length>0){n=l(p.length-1);s.eq(p[n]).delay(o*q.delay).fadeOut(q.animationSpeed,function(){if(m==1){q.isTrans=false;h(q,t)}m--});p.splice(n,1);o++}}function l(m){return Math.floor(Math.random()*m)}function e(m){var n=m.selSlide+1;if(n>m.noSlides-1){n=0}m.navList.eq(n).click();m.selSlide=n}function d(m){var n=m.selSlide-1;if(n<0){n=m.noSlides-1}m.navList.eq(n).click();m.selSlide=n}})(jQuery);
