 var $j = jQuery.noConflict();
$j(document).ready(
	function() {
           
		var container = $j(".container");
		container.wtListRotator({
					screen_width:704,
					screen_height:275,
					item_width:250,
					item_height:75,
					item_display:4,
					list_align:"left",
					scroll_type:"mouse_move",
					auto_start:true,
					delay:7000,
					transition:"random",
					transition_speed:800,
					display_playbutton:true,
					display_number:true,
					display_timer:true,
					display_arrow:true,
					display_thumb:true,
					display_scrollbar:true,
					pause_mouseover:false,
					cpanel_mouseover:false,					
					text_mouseover:false,
					text_effect:"fade",
					text_sync:true,
					cpanel_align:"TR",
					timer_align:"bottom",
					move_one:false,
					auto_adjust:true,
					shuffle:false,
					block_size:75,
					vert_size:50,
					horz_size:50,
					block_delay:35,
					vstripe_delay:90,
					hstripe_delay:180		
				});

		var transitions =	$j("#transitions");
		var textEffects =	$j("#texteffects");
		var scrollType =	$j("#scrolltype");
		
		var thumbCB = 		$j("#thumb-cb");
		var playBtnCB = 	$j("#playbutton-cb");
		var numCB 	= 		$j("#num-cb");
		var timerCB = 		$j("#timer-cb");
		var scrollbarCB = 	$j("#scrollbar-cb");
		
		var pauseCB = 	$j("#pause-cb");
		var cpanelCB = $j("#cpanel-cb");
		var textCB = 	$j("#text-cb");
		
		transitions.val("random").change(
			function() {
				container.setTransition($j(this).val());
			}
		);
		
		textEffects.val("fade").change(
			function() {
				container.setTextEffect($j(this).val());
			}
		);
		
		scrollType.val("mouse_move").change(
			function() {
				container.setNav($j(this).val());
			}
		);
		
		$j("input#align-left").attr("checked", true);
		$j("input[name='list-align']").change(
			function() {		
				var val = $j(this).filter(":checked").val();
				container.setListAlign(val);
			}
		);
		
		thumbCB.attr("checked", "checked").change(
			function() {
				container.setThumbs($j(this).filter(":checked").val());
			}
		);		
		
		scrollbarCB.attr("checked", "checked").change(
			function() {
				var val = $j(this).filter(":checked").val();
				container.setScrollbar(val);
			}
		);
		
		playBtnCB.attr("checked", "checked").change(
			function() {
				var val = $j(this).attr("checked");
				container.setPlayButton(val);
				cpanelCB.attr("disabled", !val && !numCB.attr("checked"));
			}				
		);
		
		numCB.attr("checked", "checked").change(
			function() {
				var val = $j(this).attr("checked");
				container.setNumber(val);
				cpanelCB.attr("disabled", !val && !playBtnCB.attr("checked"));
			}				
		);		
		
		timerCB.attr("checked", "checked").change(
			function() {
				container.setTimerBar($j(this).attr("checked"));
			}				
		);						
		
		pauseCB.attr("checked", "").change(
			function() {
				container.setMouseoverPause($j(this).attr("checked"));
			}				
		);		
		
		textCB.attr("checked", "").change(
			function() {
				container.setMouseoverText($j(this).attr("checked"));
			}				
		);
		
		cpanelCB.attr("checked", "").change(
			function() {
				container.setMouseoverCP($j(this).attr("checked"));
			}				
		);				
	}
);
