
jQuery.noConflict();jQuery(document).ready(function($){jQuery('html').addClass('trim');var original_background=jQuery('html.trim').css('background-image');var trim_background=jQuery('#trim').css('background-image');jQuery('html.trim').css('background-image',trim_background+','+original_background);jQuery('html.trim').css('background-position','-12px 0px , -250px 0px');(function(jQuery){jQuery.fn.hoverIntent=function(f,g){var cfg={sensitivity:7,interval:100,timeout:0};cfg=jQuery.extend(cfg,g?{over:f,out:g}:f);var cX,cY,pX,pY;var track=function(ev){cX=ev.pageX;cY=ev.pageY};var compare=function(ev,ob){ob.hoverIntent_t=clearTimeout(ob.hoverIntent_t);if((Math.abs(pX-cX)+Math.abs(pY-cY))<cfg.sensitivity){jQuery(ob).unbind("mousemove",track);ob.hoverIntent_s=1;return cfg.over.apply(ob,[ev])}else{pX=cX;pY=cY;ob.hoverIntent_t=setTimeout(function(){compare(ev,ob)},cfg.interval)}};var delay=function(ev,ob){ob.hoverIntent_t=clearTimeout(ob.hoverIntent_t);ob.hoverIntent_s=0;return cfg.out.apply(ob,[ev])};var handleHover=function(e){var ev=jQuery.extend({},e);var ob=this;if(ob.hoverIntent_t){ob.hoverIntent_t=clearTimeout(ob.hoverIntent_t)}if(e.type=="mouseenter"){pX=ev.pageX;pY=ev.pageY;jQuery(ob).bind("mousemove",track);if(ob.hoverIntent_s!=1){ob.hoverIntent_t=setTimeout(function(){compare(ev,ob)},cfg.interval)}}else{jQuery(ob).unbind("mousemove",track);if(ob.hoverIntent_s==1){ob.hoverIntent_t=setTimeout(function(){delay(ev,ob)},cfg.timeout)}}};return this.bind('mouseenter',handleHover).bind('mouseleave',handleHover)}})(jQuery);jQuery('nav ul li').hoverIntent(function(){jQuery(this).find('> ul').not(".current + ul, .currentAncestor + ul").animate({opacity:'toggle',height:'toggle'},250);},function(){jQuery(this).find('> ul').not(".current + ul, .currentAncestor + ul").animate({opacity:'toggle',height:'toggle'},250);});jQuery(".current + ul, .currentAncestor + ul").show();f=jQuery("#fadeButtonHQ");h=jQuery("html.trim");a=jQuery("aside");f.mouseenter(function(){jQuery(this).stop(true,true).animate({opacity:'0'});}).mouseleave(function(){jQuery(this).stop(true,true).animate({opacity:'1'});});if(jQuery('ul#breadcrumb').length){jQuery("footer").css('padding-top','20px');}
if(jQuery('span.social').length){jQuery("aside").css('padding-top','0px').prepend('<div id="sLinks"></div>');}
if(jQuery('.blog-entry-comments').length){jQuery("p.blog-entry-tags").css('margin-bottom','20px');}
if(jQuery('.movie-background').length){jQuery("html").css('background-image','none');}
jQuery('.blog-entry-body').find('.imageStyle:first').not('img[alt=image]').hide().each(function(){jQuery(this).prependTo(jQuery(this).parent().parent()).wrap('<div class="imgPost"></div>');});jQuery('.imgPost img').each(function(i){jQuery(this).delay(500*i).fadeIn(500);});jQuery('section .thumbnail-wrap').hide().each(function(i){jQuery(this).delay(50*i).fadeIn(150);});jQuery('.filesharing-item, section .movie-thumbnail-frame, section .form-input-field').hide().each(function(i){jQuery(this).delay(150*i).fadeIn(300);});jQuery('.movie-thumbnail-frame a').append('<span></span>');jQuery('span.social').prependTo('#sLinks').show();jQuery('span#asideTitle:empty, .filesharing-description:empty, .blog-entry-body > br:first').remove();if(jQuery('.album-wrapper').length){RwGet={pathto:function(path,file){var rtrim=function(str,list){var charlist=!list?'s\xA0':(list+'').replace(/([\[\]\(\)\.\?\/\*\{\}\+\$\^\:])/g,'$1');var re=new RegExp('['+charlist+']+$','g');return(str+'').replace(re,'');};var jspathto=rtrim(RwSet.pathto,"javascript.js");if((path!==undefined)&&(file!==undefined)){jspathto=jspathto+path+file;}else if(path!==undefined){jspathto=jspathto+path;}return jspathto;},baseurl:function(path,file){var jsbaseurl=RwSet.baseurl;if((path!==undefined)&&(file!==undefined)){jsbaseurl=jsbaseurl+path+file;}else if(path!==undefined){jsbaseurl=jsbaseurl+path;}return jsbaseurl;}};jQuery("head").append("<link>").children(":last").attr({rel:"stylesheet",type:"text/css",href:RwGet.pathto('css/prettyPhoto.css')});jQuery.getScript(RwGet.pathto('scripts/jquery.prettyPhoto.js'),function(){if(jQuery('.album-wrapper').length){jQuery('.thumbnail-frame').each(function(){var thisAnch=jQuery('a',this);var thisImg=jQuery('a img',this);var thisCap=jQuery('.thumbnail-caption',this);thisAnch.attr({'href':thisImg.attr('src').replace(/thumb/i,'full'),'rel':'prettyPhoto[gallery]','title':thisCap.text()});});}
jQuery('a[rel^=prettyPhoto]').prettyPhoto({animation_speed:'fast',opacity:0.50,show_title:false});});};});
