/********************************
*function addDiv
*parameters: whichDiv - the Div that is going to be animated through a chain
*this function makes a chain of animations
*the div starts out with a width of 0, then it is added to the 'items' div
*then it's opacity is set to .3, then...after  the width goes to 150 and then the opacity to 100 again
*it then calls the tooltips function to make the tooltips
*********************************/	
	
	
	var addDiv = function(whichDiv) 
			{

			
				var fx = whichDiv.effects({duration: 1000, transition: Fx.Transitions.Quart.easeOut});
				whichDiv.style.width = "0px";
	
				whichDiv.injectTop($('items'));	
				fx.start({
				'opacity': .3
				
				
				}).chain(function(){
				
					
					this.start.delay(20,this, {
					
					'width': 150
				});
				}).chain(function() {
				
		
					this.start.delay(100, this, {
				
					'opacity': 1
				});
				}).chain(function() {
			
					addItemToItems(whichDiv);	
				
				});
			
				doToolTips(whichDiv);
}
		
		
		
		
		
		
		
		
		
/********************************
*function doToolTips
*parameters: whichItem - the Div that is going to have a tooltip
*the tooltip text is taken from the div's 'title' attribute
*********************************/		
function doToolTips(whichItem){

var Tips2 = new Tips(whichItem, {
	maxTitleChars: 500,
	initialize:function(){

	
	this.fx = new Fx.Style(this.toolTip, 'opacity', {duration: 500, wait: false}).set(0);
		
		
	},
	onShow: function(toolTip) {
		this.fx.start(1);
	},   

	onHide: function(toolTip) {
		this.fx.start(0);
	}
});
}