//var myMenu2 = new ypSlideOutMenu("menu2", "down", 0, 41, 200, 529) // ypSlideOutMenu("menu1", "right", left, top, width, height)		

/*
myMenu2.onactivate = function() {	// dla każdego obiektu ustawiamy pozycję
	repositionMenu(myMenu2, -316);
}*/


function repositionMenu(menu, offset) // ustawienia przesunięcia
{
	var newLeft = getWindowWidth() / 2 + offset; // dla IE lewa pozycja to środek plus przesuniecie

	menu.container.style ? menu.container.style.left = newLeft + "px" : menu.container.left = newLeft; // dla innych przeglądarek niż IE
}


function getWindowWidth()	// obliczanie szerokości okna
{
	return window.innerWidth ? window.innerWidth : document.body.offsetWidth;
}	


ypSlideOutMenu.writeCSS();
