/*
 * Power by xu
 * Date: 2010.07.24 15:56
 */
 
$(function(){
	//header page arr style
	$("#nav>li").each(function(){
		var i = $("#nav>li").index($(this)[0]);
		$(this).bind("mouseover",function(){
			$("#nar_arr").css("background-position",i*62);
		})	
	})
	
	$(".banner2menucon>ul li").each(function(){
		$(this).hover(function(){
				nereidFade(this,100,100,10);changes(parseInt(this.id.replace('infoo_','')));},
			function(){
				startInterval();nereidFade(this,50,10,5);
			})	
	})
	
	//footer page guide style
/*	$("#guide_box").mouseenter(function(){
		var pos=$(this).offset();
		$("#guide").show().css({left:"0px",top:"-298px"});	
	}).mouseleave(function(){
		$("#guide").hide()		
	})
*/	 
	
	
	$(".this_map").mouseover(function(){
		$(this).find("ul").stop().animate({top:'-155px'},{queue:false,duration:500});
	}).mouseout(function() {
		$(this).find("ul").stop().animate({top:'0'},{queue:false,duration:500});
	});
	
	//show/hidden information
	$("#news_btn>img").toggle(function(){
			$("#text_box").slideUp("fast");
			$(this).attr("src","images/news_btn2.jpg");
		},
		function(){
			$('html,body').animate({scrollTop:document.body.scrollTop+document.documentElement.scrollTop+500},1200);//定位到该位置			
			$("#text_box").slideDown();
			$(this).attr("src","image/news_btn.jpg");
		})
	
	//The same height of news
	$("#text_news .text_col").height(function(){
		var h=0;
		$("#text_news .text_col").each(function(){
			if(h<$(this).height())h=$(this).height();
		})
		return h;
	})
}) 



