	
function slideShow( Obj ){
	var pass = this;
	// initializing
	this.curImg = 0;
	this.slides = Obj;
	this.slides.each( function( img, index ){ 
		if( index > 0 ) img.fade(); 
		img.set('morph', { duration: 'long' });
	}, this);
	this.next = function(){
		pass.curImg++;
		this.slides.each( function( img, index ){ 
			img.morph({ opacity: 0 });
		}, this);
		if( pass.curImg == this.slides.length ) pass.curImg = 0;
		this.slides[ pass.curImg ].morph({ opacity: 1 });
	}
	this.prev = function(){
		pass.curImg--;
		this.slides.each( function( img, index ){ 
			img.morph({ opacity: 0 });
		}, this);
		if( pass.curImg < 0 ) pass.curImg = this.slides.length - 1;
		this.slides[ pass.curImg ].morph({ opacity: 1 });
	}
}

window.addEvent( 'load', function(){
   sshow = new slideShow( $$('div#home_image img') );
   sshow.next.periodical( 5000, sshow );
});