(function($){$.fn.cross=function(options){return this.each(function(i){var $$=$(this);var target=$$.css('backgroundImage').replace(/^url|[\(\)'"]/g,'');$$.wrap('<span style="position: relative;"></span>').parent().prepend('<img>').find(':first-child').attr('src',target);if($.browser.msie&&$.browser.version<8){$$.css({'position':'absolute','left':0,'background':'','top':"0"})}else if($.browser.mozilla){$$.css({'position':'absolute','left':0,'background':'','top':this.offsetTop});}else if($.browser.opera&&$.browser.version<9.5){$$.css({'position':'absolute','left':0,'background':'','top':"0"});}else{$$.css({'position':'absolute','left':0,'background':''});}
$$.hover(function(){$$.stop().animate({opacity:0},1000);},function(){$$.stop().animate({opacity:1},1000);});});};})(jQuery);$(window).bind('load',function(){$('img.fade').cross();});$(function(){$('#slideshow').cycle({fx:'fade',speed:'2000',timeoutFn:calculateTimeout});});var timeouts=[2.5,4,50000000];function calculateTimeout(currElement,nextElement,opts,isForward){var index=opts.currSlide;return timeouts[index]*1000;}
$(function(){$('#splash').cycle({fx:'fade',speedIn:0,speedOut:2000,sync:1,timeoutFn:calculateSplashTimeout});});var splashtimeouts=[0.5,1,1,50000000];function calculateSplashTimeout(currElement,nextElement,opts,isForward){var index=opts.currSlide;return splashtimeouts[index]*1000;}
$(function(){$('#portfolio-slideshow').cycle({fx:'fade',speed:1500,prev:'#prev',next:'#next',nowrap:0,timeout:0});});