function startHero(a,d){var c=0,b;d&&(c=650),currentHero=a,clearTimeout(heroTimeout),$("#heropager img").each(function(b){a==b?$(this).attr({src:"images/orange_dot.png",alt:"*"}):$(this).attr({src:"images/grey_dot.png",alt:"O"})}),$("[hero='true']").each(function(b){a==b?$(this).fadeIn(c):$(this).hide(0)}),b=$("[hero='true']").each.length,heroTimeout=a>b+1?setTimeout("startHero(0, true)",heropagetime):setTimeout("startHero("+(a+1)+", true)",heropagetime)}function showTab(a){$("#links a").each(function(b){a==b?($(this).attr({"class":"tabactive"}),a==0?resumeQuotes():pauseQuotes()):$(this).attr({"class":"tabinactive"})}),$("div[tab]").each(function(b){a==b?$(this).fadeIn(300):$(this).hide(0)})}function readyTabs(){$("#links a").each(function(a){$(this).click(function(){showTab(a)})}),$("div[tab]").each(function(){$(this).hide(0)}),showTab(0)}function readyQuotes(){$("[class='homequote']").each(function(){$(this).hide(0)}),showQuote(0)}function showQuote(a,c){currentQuote=a,clearTimeout(quoteTimeout),$("[class='homequote']").each(function(b){a==b?$(this).fadeIn(c):$(this).hide()});var b=$("[class='homequote']").each.length;quoteTimeout=currentQuote>b+2?setTimeout("showQuote(0, 600)",quotepagetime):setTimeout("showQuote("+(currentQuote+1)+", 600)",quotepagetime)}function pauseQuotes(){clearTimeout(quoteTimeout)}function resumeQuotes(){quoteTimeout!=""&&($("[class='homequote']").each(function(){$(this).hide(0)}),clearTimeout(quoteTimeout),showQuote(currentQuote,!1))}function showsub(a){var d=$("[menuparent='"+a+"']"),b=$("[sub='"+a+"']"),c=d.position().left;b.css({left:c+"px"}),b.show(0)}function hidesub(a){var b=$("[menuparent='"+a+"']"),c=$("[sub='"+a+"']"),d=b.position().left;c.hide(0)}var heropagetime=12000,quotepagetime=1e4,heroTimeout="",currentHero=0,quoteTimeout="",currentQuote=0;$(document).ready(function(){$("#heropager img").each(function(a){$(this).click(function(){startHero(a,!0)})})}),$(document).ready(function(){startHero(0,!1)}),$(document).ready(function(){readyTabs()}),$(document).ready(function(){readyQuotes()}),$(window).bind("blur",function(){pauseQuotes()}),$(window).bind("focus",function(){resumeQuotes()}),$(window).bind("blur",function(){clearTimeout(heroTimeout)}),$(window).bind("focus",function(){heroTimeout!=""&&($("[hero='true']").each(function(){$(this).hide(0)}),clearTimeout(heroTimeout),startHero(currentHero,!1))}),$(document).ready(function(){$("[showhiddendiv='true']").hover(function(){$(this).find("div").fadeIn(250)},function(){$(this).find("div").fadeOut(100)})}),$(document).ready(function(){var d="iphone",c="ipod",b="ipad",a=navigator.userAgent.toLowerCase();(a.search(d)>-1||a.search(c)>-1||a.search(b)>-1)&&$("#footer").attr("class","footeriphone")}),function(a){a.fn.Vendors=function(e){function h(){g();var d=a.fn.Vendors.settings[c.scrollID];d.left-=c.speed,d.left>d.shiftLeftAt*-1||(d.left=2,b.append(b.children().get(0)),d.shiftLeftAt=b.children().first().outerWidth()),b.css("left",d.left+"px"),d.runId=setTimeout(arguments.callee,c.interval),a.fn.Vendors.settings[c.scrollID]=d}function g(){var b=a.fn.Vendors.settings[c.scrollID];b.runId&&clearTimeout(b.runId),b.runId=null,a.fn.Vendors.settings[c.scrollID]=b}var c,b,i,k,d,f,j;typeof e=="undefined"&&(e={}),c=a.extend({},a.fn.Vendors.defaults,e),b=a(this),c.scrollID=b[0].id,a.fn.Vendors.settings[c.scrollID]={},i=null,b.parent().get(0).className!="vendorWrap"&&(i=b.wrap("<div class='vendorWrap' style='margin-top:-30px;'></div>")),k=null,b.parent().parent().get(0).className!="vendorContainer"&&(k=b.parent().wrap("<div class='vendorContainer' style='margin-left:412px;margin-top:2px;'></div>")),d=b[0].firstChild;while(d)f=d.nextSibling,d.NodeType==3&&b[0].removeChild(d),d=f;j=b.children().first().outerWidth(!0),a.fn.Vendors.settings[c.scrollID].shiftLeftAt=j,a.fn.Vendors.settings[c.scrollID].left=0,a.fn.Vendors.settings[c.scrollID].runid=null,b.width(2*screen.availWidth),b.hover(g,h),h()},a.fn.Vendors.settings={},a.fn.Vendors.defaults={scrollID:null,url:null,speed:1,interval:50}}(jQuery),$(function(){$("#scroll").Vendors({interval:50})}),$(document).ready(function(){$("[menuparent]").each(function(){var a=$(this).attr("menuparent");$(this).hover(function(){showsub(a)},function(){hidesub(a)}),$("[sub='"+a+"']").hover(function(){$(this).show(0)},function(){$(this).hide(0)})})})
