/*
Author:
	Benoit Rat

*/
	window.addEvent('domready',function(){
	
		
		var startIt=$random(0, 4);
		var handles_more = $$('#handles_img div');
		
		//SAMPLE 4 (walk to item)
		var nS4 = new noobSlide({
			items: [0,1,2,3,4,5],
			box: $('box4'),
			items: $$('#box4 div.item'),
			size: 900,
			interval: 10000,
			startItem: startIt,
			handles: $$('#handles span'),
			autoPlay: true,
			addButtons: {
				previous: $('prev'),
				next: $('next'),
				pause: $('pause')
			},
			onWalk: function(currentItem,currentHandle){
				this.handles.removeClass('active');
				currentHandle.addClass('active');
				$$(this.handles,handles_more).removeClass('active');
				$$(currentHandle,handles_more[this.currentIndex]).addClass('active');
				
			}
		});
		
		nS4.addHandleButtons(handles_more);
		

		//END OF SAMPLES
	});
