var SlideList = new Class({
	initialize: function(manager, classname){
		this.manager = manager;
		this.classname = classname;
		this.duration = 1200;
		this.slides = new Array();
		var divs = $$('.' + this.classname);
		for(var d = 0; d < divs.length; d++){
			this.slides.push(new Slide(this.manager, this, divs[d]));
		}
		this.slide = null;
	},
	
	get: function(index){
		return this.slides[index];
	},
	
	getByPosition: function(position){
		for(var s = 0; s < this.slides.length; s++){
			if(this.get(s).position == position){
				return this.get(s); 
			}
		}
		return null;
	},
	
	hideAll: function(){
		for(var s = 0; s < this.slides.length; s++){
			this.get(s).hide();
		}
	},
	
	select: function(slide){
		if(this.slide != null){
			this.slide.disappear();
			this.slide = slide;
		}
		else{
			this.slide = slide;
			this.slide.appear();
		}
		
	},
	
	setup: function(){
		for(var s = 0; s < this.slides.length; s++){
			this.get(s).setup();
		}
	}
});
