// JavaScript Document
$(document).ready(function(){
	//收缩按钮的划过效果
	$(".user_show").hover(function(){
		$(this).addClass("user_show_hover");							   
	},function(){
		$(this).removeClass("user_show_hover");							   
	});
	$(".user_hide").hover(function(){
		$(this).addClass("user_hide_hover");							   
	},function(){
		$(this).removeClass("user_hide_hover");							   
	});
	//登出按钮的划过效果
	$(".logout").hover(function(){
		$(this).addClass("logout_hover");							   
	},function(){
		$(this).removeClass("logout_hover");							   
	});
	//搜索按钮的划过效果
	$(".search_but").hover(function(){
		$(this).addClass("search_but_hover");							   
	},function(){
		$(this).removeClass("search_but_hover");							   
	});
	//点击收缩按钮伸缩user效果
	$(".user_center").css({width:'0px',overflow:'hidden'});
	$(".user_show").click(function(){
		$(this).hide("fast");
		$(".user_center").stop().animate({width:'280px'},{queue:false, duration:600, easing: 'easeOutBounce'});
		$(".user_hide").show("fast");
	});
	$(".user_hide").click(function(){
		$(this).hide("fast");
		$(".user_center").stop().animate({width:'0px'},{queue:false, duration:600, easing: 'easeOutBounce'});
		$(".user_show").show("fast");
	});
	//菜单
	//When mouse rolls over
	
	//$(".user_center").mouseover(function(){
	//	$(this).stop().animate({width:'300px'},{queue:false, duration:600, easing: 'easeOutBounce'})
	//});
	//When mouse is removed
	//$(".user_center").mouseout(function(){
	//	$(this).stop().animate({width:'20px'},{queue:false, duration:600, easing: 'easeOutBounce'})
	//});	
});
