//Menu implementation	   
jQuery(document).ready(function(){
				
	jQuery("#navigation > ul").superfish({
		hoverClass:"hover",
		pathClass:"overideThisToUse",
		delay:600,
		animation:{height:"show"},
		speed:"normal",
		oldJquery:false,
		disableHI:false,
		onInit:function () {},
		onBeforeShow:function () {},
		onShow:function () {},
		onHide:function () {}
	}).find(">li:has(ul)").mouseover( function () {
		jQuery("ul", this).bgIframe({opacity:true});
	}).find("a").focus(function () {
		jQuery("ul", jQuery("#navigation > ul >li:has(ul)")).bgIframe({opacity:true});
	});
	/* remove box from links */
	jQuery("a").focus(function(){
		this.blur();
	});
	
	jQuery("#navigation > ul >li:has(ul > li)").find("a:first").attr("href", "#");
	jQuery("#navigation a[href='#']").click( function(){ return false; });
	jQuery("#navigation > ul >li > ul:empty").css({'border' : 'none', 'height' : '0', 'width' : '0'});
	
	// staff tabs 
	
	jQuery("#staffPics > ul.tabs").tabs("#staffBios > div");
	jQuery("ul.tabs li a").mouseover(function() {
		jQuery(this).addClass("hover");										  
	}).mouseout( function() {
		jQuery(this).removeClass("hover");
	});
	
	// Office Tour - jQuery CrossSlide plugin
	jQuery('#officeTour').crossSlide({
  		fade: 1
	}, [
		{
    	src:  '/Portals/0/tour/1.jpg',
    	from: '50% 50%',
    	to:   '20% 80% 1.3x',
    	time: 3
  	}, {
    	src:  '/Portals/0/tour/2.jpg',
    	from: 'center center',
    	to:   '50% 80% 1.5x',
    	time: 3
  	}, {
    	src:  '/Portals/0/tour/3.jpg',
    	from: '0% 50%',
    	to:   '100% 50% 1.2x',
    	time: 3
  	}, {
    	src:  '/Portals/0/tour/4.jpg',
    	from: 'left center 1.5x',
    	to:   'right center',
    	time: 3
  	}, {
    	src:  '/Portals/0/tour/5.jpg',
    	from: '0% 50% 1.3x',
    	to:   '100% 100%',
    	time: 3
  	}, {
    	src:  '/Portals/0/tour/6.jpg',
    	from: '0% 50%',
    	to:   '100% 50% 1.5x',
    	time: 3
  	}, {
    	src:  '/Portals/0/tour/7.jpg',
    	from: '45% 0% 1.5x',
    	to:   '40% 70% ',
    	time: 5
  	}, {
    	src:  '/Portals/0/tour/8.jpg',
    	from: '80% 80%',
    	to:   '20% 20% 1.5x',
    	time: 5
  	}, {
    	src:  '/Portals/0/tour/9.jpg',
    	from: 'left center 1.5x',
    	to:   'right center',
    	time: 4
  	}, {
    	src:  '/Portals/0/tour/10.jpg',
    	from: '0% 50%',
    	to:   '100% 50% 1.5x',
    	time: 4
  	}, {
    	src:  '/Portals/0/tour/11.jpg',
    	from: 'left center 1.5x',
    	to:   'right center',
    	time: 4
  	}, {
    	src:  '/Portals/0/tour/12.jpg',
    	from: '0% 50% 1.3x',
    	to:   '100% 100%',
    	time: 4
  	}
]);
	
});

// toggle ripped from old site
function toggleDiv(id,flagit) {
	if (flagit=="1"){
		if (document.layers) document.layers[''+id+''].display = "show"
		else if (document.all) document.all[''+id+''].style.display = "block"
		else if (document.getElementById) document.getElementById(''+id+'').style.display = "block"
	}
	else if (flagit=="0"){
		if (document.layers) document.layers[''+id+''].display = "hide"
		else if (document.all) document.all[''+id+''].style.display = "none"
		else if (document.getElementById) document.getElementById(''+id+'').style.display = "none"
	}
}



