function opensizedwin(link, w, h)  {
	popupWinex = window.open('http://www.skull.hu/' + link,'','scrollbars=auto, width=' + (w+20) + ', height=' + (h+20) + ', left=' + ((screen.width/2)-w/2) + ', top=' + ((screen.height/2)-h/2));
}

/*************************************************/
function showSubMenu(i)  { // alert('show_lang');
	clearTimeout(this.timer);
	this.timer=setTimeout('showSubMenuDiv(' + i + ')','1');
}

function hideSubMenu(i)  { // alert('hide_lang');
	clearTimeout(this.timer);
	this.timer=setTimeout('hideSubMenuDiv(' + i + ')','600');
}

function showSubMenuDiv(i)  { // alert('show_lang');
	if ( i == 1 )
		j = 2;
	if ( i == 2 )
		j = 1;
	document.getElementById('sub_menu' + i).style.display = 'block';
	hideSubMenuDiv(j);
}

function hideSubMenuDiv(i)  { // alert('show_lang');
	document.getElementById('sub_menu' + i).style.display = 'none';
}

/*************************************************/


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


/***************************************************/
/*******************  SAJÁT  ***********************/
/***************************************************/

addLoadEvent(function(){ 
	if(!document.body.currentStyle) return;
	var subs = document.getElementsByName('submenu');
	for(var i=0; i<subs.length; i++) {
		var li = subs[i].parentNode;
		if(li && li.lastChild.style) {
				li.onmouseover = function() {
					this.lastChild.style.visibility = 'visible';
				}
				li.onmouseout = function() {
					this.lastChild.style.visibility = 'hidden';
				}
		}
	}
}) 


function show()  {
	clearTimeout(this.timer);
	this.timer=setTimeout('show2()','1');
}

function hide()  {
	clearTimeout(this.timer);
	this.timer=setTimeout('hide2()','1000');
}

function show2()  {
	document.getElementById('takaras').style.background = '#FD8910';
}

function hide2()  {
	document.getElementById('takaras').style.background = 'none';
}
function mutat(mit) {
	if (document.getElementById(mit).style.display == 'none') { document.getElementById(mit).style.display = ''; }
	else { document.getElementById(mit).style.display = 'none'; }
}
