
/* - nextevolution.js - */
// http://www.nextevolution.com/portal_javascripts/nextevolution.js?original=1
jq(document).ready(function(){jq("a.external-link").filter(":has(img)").css({'background-image':'none','padding':'0'});
function addMega(){jq(this).addClass("hovering");jq(this).find(".navdiv").fadeIn('fast')}
function removeMega(){jq(this).removeClass("hovering");jq(this).find(".navdiv").fadeOut('fast')}
jq("#portal-globalnav li.plain").filter(':has(a.megalink)').hoverIntent(addMega,removeMega,{});jq("#portal-globalnav li.selected").filter(':has(a.megalink)').hoverIntent(addMega,removeMega,{});var index=0;var max=jq("#bigimage .thumb img").length;var pause;var rotatedelay=4000;
function nextIndex(){index=(index+1)%max;return index}
function selectThumb(){if(jq.browser.msie&&jq.browser.version=='7.0'){jq("#bigimage .thumb img").css({'top':'3px'})}
else{jq("#bigimage .thumb img").css({'top':'0px'})}
if(jq.browser.msie&&jq.browser.version=='7.0'){jq(this).find('img').animate({'top':'-6px'},'fast')}
else{jq(this).find('img').animate({'top':'-9px'},'fast')}}
jq("#bigimage .thumb").hoverIntent(selectThumb, function(){});
function selectImage(){var mainid=jq(this).attr('id').replace('_thumbnail','_image');jq("#bigimage .mainimages img:visible").fadeOut('slow').css({'z-index':'5'});jq("#bigimage .mainimages #"+mainid).css({'z-index':'6'}).fadeIn('slow');var textid=jq(this).attr('id').replace('_thumbnail','_content');var html=jq("#"+textid).html();if(html){jq("#bigimage .maintext").hide();jq("#bigimage .maintext").html(html);jq("#bigimage .maintext").fadeIn('slow')}
else{jq("#bigimage .maintext").html('')}}
jq("#bigimage .thumb img").hoverIntent(selectImage, function(){});jq("#bigimage .thumb img").eq(0).each(selectImage);jq("#bigimage .thumb").eq(0).each(selectThumb);
function rotateImage(){var next=nextIndex();jq("#bigimage .thumb img").eq(next).each(selectImage);jq("#bigimage .thumb").eq(next).each(selectThumb);pause=setTimeout(rotateImage,rotatedelay)}
pause=setTimeout(rotateImage,rotatedelay);jq("#bigimage .thumb").hover(function(){clearTimeout(pause);var thumbs=jq("#bigimage .thumb");index=thumbs.index(this)}, function(){pause=setTimeout(rotateImage,rotatedelay)})});

