<!--
// Google API key for http://www.ebgsystems.com:
//	ABQIAAAAXNfdx9Zeq5EDuxYIprwQ6xT_aoLc_-MVkCUsvneEej9tCKNHSxTFKNi7-BYnzUtKNATky0SDl3T5sQ

var currentIndex = "0";
var Op=100;
var Tof;
var _step = 10;
var _delay = 25;
var el;
var autoTime = 10000000;
var autoTO;

function fpbanner_autoBanner() {
	autoTO = setTimeout("fpbanner_next()",autoTime);
}

function fpbanner_next() {
	var newIndex = parseInt(currentIndex) + 1;
	if(newIndex>1) {
		newIndex = 0;
	}
	var divObj = document.getElementById("bannerButton" + newIndex);
	fpbanner_select(newIndex, divObj);
}

function fpbanner_select(index, obj) {
	clearTimeout(autoTO);
	autoTO = setTimeout("fpbanner_next()",autoTime);
	if(!(index==currentIndex)) {
		currentIndex = index;
		if(obj) {
			jQuery('.bannerButton').removeClass('selected');
			jQuery(obj).addClass('selected');
		}
		fpbanner_fadeOut(index);
	}
}

function fpbanner_fadeOut(index) {
	clearTimeout(Tof);
	if(Op > 0) {
		el = document.getElementById("fbbanner_tableWrapper");
		Op = Op - _step;
		el.style.opacity = Op/100;
		el.style.filter = "alpha(opacity=" + (Op) + ")";
		Tof = setTimeout("fpbanner_fadeOut(" + index + ")",_delay);
	} else {
		document.getElementById("fbbanner_tableWrapper").style.left = "-" + (index*931) + "px";
		Tof = setTimeout("fpbanner_fadeIn()",_delay);
	}
}

function fpbanner_fadeIn() {
	clearTimeout(Tof);
	if(Op < 100) {
		el = document.getElementById("fbbanner_tableWrapper");
		Op = Op + _step;
		el.style.opacity = Op/100;
		el.style.filter = "alpha(opacity=" + (Op) + ")";
		Tof = setTimeout("fpbanner_fadeIn()",_delay);
	}
}
-->
