/**
 * Maxx News Slider and Slide Show (PHP-Fusion v6)
 * It slide five latest news
 * @author: anderson <http://sml2008.free.fr> <joeserpa@gmail.com>
 * @version 0.1.0
 *
 * Release under the terms & conditions of v3 or higher
 * of the GNU General Public License. For details refer
 * to the included gpl.txt file or visit http://gnu.org
 *
 */

	window.addEvent('domready',function(){

		var hs = new maxxSlide({
			box: $('maxx_box'),
			startItem: 6,
			items: $ES('h2','maxx_box'),
			size: 540,
			handles: $ES('span','handles'),
			buttons: {previous: $('next'), play: $('play'), stop: $('stop'), playback: $('playback'), next: $('prev') },
			onWalk: function(currentItem,currentHandle){
				//style for handles
				this.handles.extend(handles_more).removeClass('active');
				$$(currentHandle,handles_more[this.currentIndex]).addClass('active');
				//text for "previous" and "next" default buttons
				//$('prev').setHTML('&lt;&lt; '+this.items[this.previousIndex].innerHTML);
				//$('next').setHTML(this.items[this.nextIndex].innerHTML+' &gt;&gt;');
			}
		});
		//more "previous" and "next" buttons
		hs.addActionButtons('previous',$('next'));
		hs.addActionButtons('next',$('prev'));
		//more handle buttons
		var handles_more = $ES('span','handles_more');
		hs.addHandleButtons(handles_more);
		//
		hs.walk(1);
        hs.play(0,'previous',5000);
	});

