window.addEvent('domready', function() {
var customTips = $$('.tooltip');

var toolTips = new Tips(customTips, {
	//this will set how long before 
	//the tooltip will wait to show up
	//when you mouseover the element
	//in milliseconds
	showDelay: 50,    //default is 100
	
	//this is how long the tooltip
	//will delay bofore hiding
	//when you leave
	hideDelay: 50,   //default is 100
	
	//this will add a wrapper div 
	//with the following class to your tooltips
	//this lets you have different styles of tooltips
	//on the same page
	className: 'bocata', //default is null
	
	//this sets the x and y offets
	offsets: {
		'x': 16,       //default is 16
		'y': 16        //default is 16
	},
	
	//this determines whether the tooltip
	//remains staitionary or follows your cursor
	//true makes it stationary
 	fixed: false,      //default is false
	
	//if you call the functions outside of the options
	//then it may "flash" a bit on transitions
	//much smoother if you leave them in here
	onShow: function(toolTipElement){
	    //passes the tooltip element
		//you can fade in to full opacity
		//or leave them a little transparent
    	toolTipElement.fade(.9);
		if ($('show')) {
		$('show').highlight('#FFF504');
		}
	},
	onHide: function(toolTipElement){
    	toolTipElement.fade(0);
		if ($('hide')) {
		$('hide').highlight('#FFF504');
		}
	}
});





if ($('visorcontennoticias')) {

			var Noticias = new noobSlide({

				box: $('visorcontennoticias'),

				items: $$('#visorcontennoticias div.bloqueinfor'),

				size: 960,

				handles: $$('#menusecundario li'),

				onWalk: function(currentItem,currentHandle){

				//	$('info4').set('html',currentItem.getFirst().innerHTML);

					this.handles.removeClass('subactiv');

					currentHandle.addClass('subactiv');

				}

			});

		}



	});

function amplia(id) {
	var Interior = $('F'+id);
	var Contenedor = $('B'+id);
	var Enlace = $('L'+id);
	
	if (id == "00") {
		limitalto=450
	} else {
		limitalto=270	
	}
	
//	var fx = new Fx.Styles(Contenedor, {wait: false, duration: 500, transition: Fx.Transitions.Cubic.easeOut});

var altura= Interior.getSize().y;
var alturac= Contenedor.getSize().y;

var morph = new Fx.Morph('L'+id);
var morphf = new Fx.Morph('F'+id);
limite=limitalto+18

//alert(limitalto+' '+altura+' '+alturac+' '+limite);


	
	if (alturac>limite) {
		
		Contenedor.setStyles({
			height:limitalto
		});
		
		Enlace.morph('.mas');
		Interior.morph('.fuelle');
		
	} else {
		
	
		Contenedor.setStyles({
			height:altura+40
		});
		
		Enlace.morph('.menos');
		Interior.morph('.fuelleOK');
	}
};