// The following will run as soon as the page is loaded and the DOM is ready, but images might still be loading.
$(function(){	 

Cufon.replace('h1,#compName,#compNameSub, h2, h3, #introText');


//		   $("table").tablesorter({widgets: ['zebra']}); 

$("ul#mainNav")
	.superfish({
	animation : {height:"show"},
	delay : 1000
	})
	//
	$('#mainNav li li:has(ul) > a').addClass('wbg'); 
//	$('.mainSub li:even').addClass('wbg');

	
$('#opUL').innerfade({ speed: 'slow', timeout: 4000, type: 'sequence'}); 
$('#homeUL').innerfade({ speed: 'slow', timeout: 4000, type: 'sequence'}); 
$("#mid table tr:odd").addClass("alt");  
$("#tabs").tabs({ fx: { opacity: 'toggle' } }).tabs('rotate',  10000);

$('.rmv-dft-val').click(
function() {
if (this.value == this.defaultValue) {
this.value = '';
}
}
);
$('.rmv-dft-val').blur(
function() {
if (this.value == '') {
this.value = this.defaultValue;
}
}
);

function mycarousel_initCallback(carousel)
{
    // Disable autoscrolling if the user clicks the prev or next button.
    carousel.buttonNext.bind('click', function() {
        carousel.startAuto(0);
    });

    carousel.buttonPrev.bind('click', function() {
        carousel.startAuto(0);
    });

    // Pause autoscrolling if the user moves with the cursor over the clip.
    carousel.clip.hover(function() {
        carousel.stopAuto();
    }, function() {
        carousel.startAuto();
    });
};


//    jQuery('#mycarousel').jcarousel({
//       auto: 7,
//		scroll: 1,
//		animation: 'slow',
//        wrap: 'both',
//        initCallback: mycarousel_initCallback
//    });




});

