var HOME = {
	init : function()
	{
		if (document.getElementById('menuhome'))
		{
			var opcmenu = document.getElementById('menuhome').getElementsByTagName('img');
			for (cont = 0; cont < opcmenu.length; ++cont)
			{
				document.getElementById(opcmenu[cont].id).onmouseover = function()
				{
					document.getElementById(this.id).src = document.getElementById(this.id).src.replace('_off_','_on_');
				}
				
				document.getElementById(opcmenu[cont].id).onmouseout = function()
				{
					document.getElementById(this.id).src = document.getElementById(this.id).src.replace('_on_','_off_');
				}
			}
		}
		if (document.getElementById('flashhome'))
		{
			var so = new SWFObject("../flash/anima.swf", "home", "488", "90", "8", "#FFF");
			so.addParam("quality", "hight");
			so.addParam("wmode", "transparent");
			so.write("flashhome");
		}
	}
}


/* LOAD */

function addLoadEvent(fn)
 {
	var old = window.onload;
	if(typeof window.onload != 'function')
		window.onload = fn;
	else
		window.onload = function()
		 {
			old();
			fn();
		 }
 }

addLoadEvent( function() { HOME.init(); } );
