if($.browser.msie) var isIE = true;
else var isIE = false;
if($.browser.safari) var isWebkit = true;
else var isWebkit = false;
var browserVersion = $.browser.version;

$(document).ready(function(){
	if($("#wrapper_prize_draw form input[type=image]").attr("src")!="") {
		$("#wrapper_prize_draw form input[type=image]").mouseover(function() {
			$("#wrapper_prize_draw form input[type=image]").attr("src","/assets/prizedraw_submitbtn_hover.png");
		});
		$("#wrapper_prize_draw form input[type=image]").mouseout(function() {
			$("#wrapper_prize_draw form input[type=image]").attr("src","/assets/prizedraw_submitbtn.png");
		});
	}
	//Calculate the total width - sum of all sub-panels width  
    //Width is generated according to the width of #mask * total of sub-panels  
    $('#panel').width(parseInt($('#mask').width() * $('#panel div').length));  
       
    //Set the sub-panel width according to the #mask width (width of #mask and sub-panel must be same)  
    $('#panel div').width($('#mask').width());  
 
/*
	
*/
	if(isWebkit && $("#wrapper_prize_draw form textarea").length > 0) $("#wrapper_prize_draw form textarea").css("width","151px");
	 
    scroller();
     
}); 



function displayProductInfo(productID) {
         
         //Scroll to the correct panel, the panel id is grabbed from the href attribute of the anchor  
	$('#mask').scrollTo("#details"+productID, 800);
}


function scroller() {

	if($('.scroller').length > 0) {
		$('.scroller').jScrollPane({
		showArrows: true,
		scrollbarWidth: 17,
		scrollbarOnLeft: true
		});
	}
	
}

 

