/**
 * @author andrewkett
 */

$(document).ready(function() {
	
	var hasReqestedVersion = DetectFlashVer(9, 0, 0);
	var hasIE6 = (navigator.userAgent.toLowerCase().indexOf('msie 6') != -1) && (navigator.userAgent.toLowerCase().indexOf('msie 7') == -1) && (navigator.userAgent.toLowerCase().indexOf('msie 8') == -1)
	
	menuInit();
	
	if (hasReqestedVersion)
	{
		var params = {};
		var attrs = {};
		var flashvars = {};
		var options = {};
		
		//pass the overriden content into the flash file to be used as xml content
		options.passcontent = true;
		
		//if using multiple files params may need to be redeclared
		params = {};
		params.bgcolor = '#0000FF';
		params.quality = "high";
		params.wmode = "transparent";

		jQuery('#navigation').seoReplace('/themes/boondigga/flash/menu.swf', flashvars, params, attrs, options);
		jQuery('#navigation_container').css('overflow', 'hidden');
		jQuery('#navigation').css('display', 'block');
		jQuery('#navigation_fallback').css('display', 'none');
		//---
			jQuery("#navigation").hover(focusFlash, function(){});
		//---
	}
	else
	{
		jQuery('#navigation_fallback>ul>li').mouseover(
			function()
			{
				jQuery(this).addClass('over');
			}
		);
	    
		jQuery('#navigation_fallback>ul>li').mouseout(
			function()
			{
				jQuery(this).removeClass('over');
			}
		);
	}
});
