// Load Tabs
$(function () { 
				var tabContainers = $('div.tabs > div');
				tabContainers.hide().filter(':first').show();				
				$('div.tabs ul.tabNavigation a').mouseover(function () {
					tabContainers.hide();
					tabContainers.filter('#' + this.rel).show();
					//alert(this.rel);
					$('div.tabs ul.tabNavigation a').removeClass('selected');
					$(this).addClass('selected');
					return false;
				}).filter(':first').mouseover();				
				
				var tabContainers2 = $('div.tabs2 > div');
				tabContainers2.hide().filter(':first').show();				
				$('div.tabs2 ul.tabNavigation a').mouseover(function () {
					tabContainers2.hide();
					tabContainers2.filter('#' + this.rel).show();
					$('div.tabs2 ul.tabNavigation a').removeClass('selected');
					$(this).addClass('selected');
					return false;
				}).filter(':first').mouseover();				
				
				var tabContainers3 = $('div.tabs3 > div');
				tabContainers3.hide().filter(':first').show();				
				$('div.tabs3 ul.tabNavigation a').mouseover(function () {
					tabContainers3.hide();
					tabContainers3.filter('#' + this.rel).show();
					$('div.tabs3 ul.tabNavigation a').removeClass('selected');
					$(this).addClass('selected');
					return false;
				}).filter(':first').mouseover();				
			});
// Toolbox
$(function(){
	$('#drop_down>li>ul').hide();
	setupToolboxEvents();										 
});

function setupToolboxEvents() {
	this.toolBoxTimeoutID = 0;	
	// setup events on the toolbox:
	$('#drop_down>li').hover(function() {
		if ($('#drop_down ul:animated').length > 0) return;		
		// clear the timeout:
		clearTimeout(this.toolBoxTimeoutID);		
		// get the li that the user is hovered over:
		var hoveredLI = $(this);		
		// method for sliding the element down:
		var slideDownFn = function() {
			hoveredLI.find('ul').slideDown(200);
		};		
		// collapse currently expanded siblings:
        var expandedSiblings = hoveredLI.siblings().find('ul:visible');
		if (expandedSiblings.length > 0)
		{
			expandedSiblings.slideUp(200, slideDownFn);
		}
		else
		{
			slideDownFn();
		}		
	}, function() {
		var hoveredLI = $(this);
		this.toolBoxTimeoutID = setTimeout(function() {
			$(hoveredLI).find('ul').slideUp(200);
		}, 500);
	});	
};
