// JavaScript Document
window.addEvent('domready', function() {
	
	//var myVerticalSlide = new Fx.Slide('menu_azienda');
	
	var menu_azienda = $('menu_azienda');
	var menu_prodotti = $('menu_prodotti');
	/*$('azienda_').addEvent('mouseover', function(e){
		e = new Event(e);
		myVerticalSlide.slideIn();
		e.stop()
		
	});;*/
	
	/*$('azienda_').addEvents({
			'mouseenter': function() {
				myVerticalSlide.slideIn();},
		'mouseleave': function() {myVerticalSlide.slideOut();}
		
		
	});
	$('content_home').addEvent('mouseover', function(e){
		e = new Event(e);
		myVerticalSlide.slideOut();
		e.stop();
	});*/
	$('prodotti_').addEvents({
		'mouseenter': function(){
				// Always sets the duration of the tween to 1000 ms and a bouncing transition
				// And then tweens the height of the element
				menu_prodotti.set('tween', {
					duration: 900,
					transition: Fx.Transitions.Bounce.easeOut // This could have been also 'bounce:out'
				}).tween('height', '75px');
			},
			'mouseleave': function(){
				// Resets the tween and changes the element back to its original size
				menu_prodotti.set('tween', {}).tween('height', '0px');
			}
	});
	
	$('azienda_').addEvents({
		'mouseenter': function(){
				// Always sets the duration of the tween to 1000 ms and a bouncing transition
				// And then tweens the height of the element
				menu_azienda.set('tween', {
					duration: 1000,
					transition: Fx.Transitions.Bounce.easeOut // This could have been also 'bounce:out'
				}).tween('height', '137px');
			},
			'mouseleave': function(){
				// Resets the tween and changes the element back to its original size
				menu_azienda.set('tween', {}).tween('height', '0px');
			}
	});
		
	//myVerticalSlide.hide();
	
	/*$('azienda_').addEvent('click', function(e) {
		e.stop();
		myVerticalSlide.slideOut();
	});*/
	
});