// JavaScript Document


// Image rollovers

function tftRollOver (el) {
	$(el + " img").after("<span class='rollover'></span>");
	$(el).find('.rollover').fadeTo(0, 0.10).fadeTo(0, 0.00);
	
	$(el).hover(
		function() {
			$(this).find('.rollover').fadeTo(250, 1.00);
		},
		function() {
			$(this).find('.rollover').fadeTo(500, 0.00);
		}
	);
}

$(document).ready(function() {
	tftRollOver("#top-rfq a");
	tftRollOver("#ftr-tech-drupal a");
	tftRollOver("#ftr-tech-magento a");
	tftRollOver("#ftr-tech-modx a");
	tftRollOver("#ftr-social-twitter a");
	tftRollOver("#ftr-social-facebook a");
	tftRollOver("#ftr-social-linkedin a");
	$('#ftr-news ul').scrollList('up', 15, 4000); 
	if (parseInt($.browser.version) <= 7 && $.browser.msie == true) { } else {
		$("#images ul").PikaChoose();
		$("#nav").droppy({ speed: 250 }); 
	}
	if($.browser.msie == false) {
		$("#services li").hover(
			function() {
				$(this).addClass("active").find(".over").fadeIn('fast');
			}, 
			function() {
				$(this).removeClass("active").find(".over").fadeOut('fast');
			}
		);	
	} else if (parseInt($.browser.version) >= 7) {
		$("#services li").hover(
			function() {
				$(this).addClass("active").find(".over").show();
			}, 
			function() {
				$(this).removeClass("active").find(".over").hide();
			}
		);	
	}
		
	$(".thumb a img").fadeTo("slow", 0.5);
	$(".thumb").hover(
		function() {
			$(this).find("img").fadeTo("fast", 1);
		}, 
		function() {
			$(this).find("img").fadeTo("slow", 0.5);
		}
	);	

});




