	$(document).ready(function() {  
		if (jQuery.browser.msie && jQuery.browser.version<7){
		}else{
		  $("#location-select").jLook({selectHeight: '128'}); 
		  $("#search-select").jLook({selectHeight: '128'});  
		  $(".welcome-page h2").jLook();  
		  $(".product-selector").jLook({});
		  $(".product-select").jLook({}); 
		  $(".mem-select").jLook({});
		  $(".regist-select").jLook({});
		  $(".dlagreement-select").jLook({});
			$(".select192 ul").each(function(i){										 
			   if($(".select192 ul:eq("+i+") > li").size() <10)
				{
					$(".select192 .optionsWrapper:eq("+i+")").height($(".select192 ul:eq("+i+") > li").size()*20+10);
			 	$(".select192 .optionsWrapper:eq("+i+") > ul ").height($(".select192 ul:eq("+i+") > li").size()*20);
				}
 			});
			
		}
	});
	
	$(function(){
	$(".butterfly-btn").toggle(
		function() {
			$(".choose-bg").css("visibility","visible");
			$(".choose-bg-wrapper").css("visibility","visible");
	  	},
		function() {
			$(".choose-bg").css("visibility","hidden");
			$(".choose-bg-wrapper").css("visibility","hidden");
	});
	
	$("#graybg-btn").click(function(){
		$("body").removeClass('purple-bg');
		$("body").addClass('gray-bg');
	});
	$("#purplebg-btn").click(function(){
		$("body").removeClass('gray-bg');
		$("body").addClass('purple-bg');
	});

	$("#recently-viewed .recently-viewed-close").click(function(){
		$("#recently-viewed .recently-viewed-close").hide();
		$("#recently-viewed .recently-viewed-open").show();
		$("#recently-viewed").css({'z-index':'20'});
	});
	$("#recently-viewed .recently-viewed-open .title").click(function(){
		$("#recently-viewed .recently-viewed-open").hide()
		$("#recently-viewed .recently-viewed-close").show();
		$("#recently-viewed").css({'z-index':''});
	});
	});

	$(function(){
	$("#sidenav .boxtitle").hover(function(){
		$(this).find(".boxtitle-top-bg").addClass("boxtitle-top-bg-over");
		$(this).removeClass("boxtitle-top-bg");
		$(this).find(".boxtitle-body-bg").addClass("boxtitle-body-bg-over");
		$(this).removeClass("boxtitle-body-bg");
		$(this).find(".boxtitle-btm-bg").addClass("boxtitle-btm-bg-over");
		$(this).removeClass("boxtitle-btm-bg");
	},
	function(){
		$(this).find(".boxtitle-top-bg-over").addClass("boxtitle-top-bg");
		$(this).removeClass("boxtitle-top-bg-over");
		$(this).find(".boxtitle-body-bg-over").addClass("boxtitle-body-bg");
		$(this).removeClass("boxtitle-body-bg-over");
		$(this).find(".boxtitle-btm-bg-over").addClass("boxtitle-btm-bg");
		$(this).removeClass("boxtitle-btm-bg-over");
	});
	
	$("#detail-nav li").each(function(i){
		$(this).click(function(e){
			if ($(this).hasClass("select")){
			}else{
				$("#detail-nav .select").removeClass("select");
				$(this).addClass("select");
				$("#detail-content .contentblock").hide();
				$("#detail-content .contentblock").eq(i).fadeIn('fast');
			}
		})
	});

	$("#list ul .list-pic,.list-name,.list-descibe").click(function(){								 		
		window.location=$(this).parent().find("a").attr("href"); 
		return false;
	});		
	
	$("#list ul .list-select").find("select").change(function()
	{
		window.location=$(this).find("option:selected").attr("id");
		return false;
	});

	});

	$(function(){
	setTimeout(function(){
		$(".selector-content-close").slideDown();
		$(".selector-content-open").slideUp();
		$("#close-selector").css({display:"none"});
		$("#expand-selector").css({display:""});
		$(".intro-content-close").slideDown();
		$(".intro-content-open").slideUp();
		$("#close-intro").css({display:"none"});
		$("#expand-intro").css({display:""});
	}, 3000);	
	
	$("#expand-selector").click(function(){
		$(".selector-content-open").css({display:""});
		$(".selector-content-close").css({display:"none"});
		$("#expand-selector").css({display:"none"});
		$("#close-selector").css({display:""});
	});
	$("#close-selector").click(function(){
		$(".selector-content-close").css({display:""});
		$(".selector-content-open").css({display:"none"});
		$("#close-selector").css({display:"none"});
		$("#expand-selector").css({display:""});
	});
	
	$("#expand-intro").click(function(){
		$(".intro-content-open").css({display:""});
		$(".intro-content-close").css({display:"none"});
		$("#expand-intro").css({display:"none"});
		$("#close-intro").css({display:""});
	});
	$("#close-intro").click(function(){
		$(".intro-content-close").css({display:""});
		$(".intro-content-open").css({display:"none"});
		$("#close-intro").css({display:"none"});
		$("#expand-intro").css({display:""});
	});

		$(".selector-nav-container li a").each(function(i){
			$(this).click(function(e){
				if ($(".selector-nav-container li ").eq(i).hasClass("select")){
				}else{
					$(".selector-nav-container li ").removeClass("select");
					$(".selector-nav-container li ").eq(i).addClass("select");
					$(".selector-content-item p").hide();
					$(".selector-content-item p").eq(i).fadeIn("fast");
				}
			})
		});
	
	$("#article .product-list .product-select a").each(function(){
		$(this).click(function(){
			if($(this).parent().hasClass('add-to-compare')){
				$(this).parent().removeClass('add-to-compare');			
			}else{
				$(this).parent().addClass('add-to-compare');			
			}
		});
	});
	
	$(".product-list .product-pic").each(function(){
		var _this = $(this);
		var _thisdetail = $(this).parent().parent().parent().parent().find(".float-product-detail");
		_this.hover(function(){
			_thisdetail.css("display","block");
		}, function(){
			_thisdetail.css("display","none");
		});
		_thisdetail.hover(function(){
			_thisdetail.css("display","block");
		}, function(){
			_thisdetail.css("display","none");
		});
	});
	
	
	});
	
	function MM_goToURL() { //v3.0
	   var i, args=MM_goToURL.arguments; document.MM_returnValue = false;
	   for (i=0; i<(args.length-1); i+=2) eval(args[i]+".location='"+args[i+1]+"'");
	}

	$(function(){
	$(".vediodemo-closebtn").click(function(){
		$(".vediodemo-closebtn").css({display:"none"});
		$(".vediodemo-openbtn").css({display:""});
		$(".vediodemo-flv").fadeOut();
	});
	$(".vediodemo-openbtn").click(function(){
		$(".vediodemo-closebtn").css({display:""});
		$(".vediodemo-openbtn").css({display:"none"});
		$(".vediodemo-flv").fadeIn();
	});
	});


	$(function(){	   
	$(".job .openbox").each(function(){
		var _thisdetail = $(this).parent().parent().parent().parent().parent().parent().find(".hr-jobdetail");
		$(this).click(function(){
			_thisdetail.css("display","block");
		});	
	});
	$(".job .closebox").each(function(){
		var _thisdetail = $(this).parent().parent().parent().parent().parent().parent().find(".hr-jobdetail");
		$(this).click(function(){
			_thisdetail.css("display","none");
		});	
	});
	});
	
	$(function(){
	equalHeight($(".compare-list .product-pic"));
	equalHeight($(".compare-list .product-name"));
	equalHeight($(".compare-list .platform"));
	equalHeight($(".compare-list .operating-sys"));
	equalHeight($(".compare-list .chipset"));
	equalHeight($(".compare-list .graphics"));
	equalHeight($(".compare-list .memory"));
	equalHeight($(".compare-list .hdd"));
	equalHeight($(".compare-list .drive"));
	equalHeight($(".compare-list .display"));
	equalHeight($(".compare-list .webcam"));
	equalHeight($(".compare-list .battery"));

$(".compare-del-btn").click(function(){
		$(this).parents(".compare-product").animate({ opacity: 'hide' }, "slow");
	});
	});

	function wbSlide (targetBox, showAtOnce, animateSpeed){
	$(document).ready(function(){
		var _this = $(targetBox);
		var itemNum = $('.sidenav2-Item>div', _this).length;
		var itemWidth = $('.sidenav2-Item>div', _this).width();
		var slideWidth = itemNum * (itemWidth + 56);
		var maxId =-( Math.ceil(itemNum / showAtOnce)) + 1;
		var rowSlide = $('.sidenav2-Panel').outerWidth(true);
		$('.sidenav2-Item', _this).css({width : slideWidth + "px"});
		var cId = 0;
		$('.sidenav2-Left>a', _this).click(function () {
			cId ++;
			sliding (cId);
		});
		$('.sidenav2-Right>a', _this).click(function () {
			cId --;
			sliding (cId);
		});
		function sliding (cId){
			if(cId == maxId) {$('.sidenav2-Right>a', _this).hide();};
			if(cId == 0) {$('.sidenav2-Left>a', _this).hide();};
			var marginNum = rowSlide * cId;
			$(".sidenav2-Item", _this).animate( { marginLeft: marginNum + "px" }, {duration:animateSpeed} );
			if(cId > maxId) {$('.sidenav2-Right>a', _this).show();};
			if(cId < 0) {$('.sidenav2-Left>a', _this).show();}
		};
		if (itemNum <= showAtOnce){
			$('.sidenav2-Left>a', _this).hide();
			$('.sidenav2-Right>a', _this).hide();
			$('.sidenav2-Item').css({margin:'0 auto'});
		} else {
			$('.sidenav2-Left>a', _this).hide();
		};
	});
	};
	wbSlide('.sidenav2', 6, 1000);
	
	function picHover (picBox){
	$(document).ready(function(){
		var _thisPic=$('a',picBox);
		$('img',_thisPic).css('opacity',1.00);
		_thisPic.each(function(){
			$(this).hover(function(){
			$(this).parent('div').css('position','relative');
			$('img',this).css('opacity',1);
				}, function(){
			$(this).parent('div').css('position','');
			$('img',this).css('opacity',1.00);
		});
	});
	});
	};
	picHover('.sidenav2-Item');

