$(document).ready(function() {
	$("#top_news_float").css("top", 0);

	if(newsListType== 0) {
		//文件列表方式时
		$("#top_content").css("top", $("#top_news").position().top+43);
		
		$("#top_content_mask").css("opacity", 0.5);
	
		$("#top_content_close").css("top", 0);
		$("#top_content_close").css("left", 948);

		$(".top_news").mouseover(function(){$(this).find("div").addClass("top_news_over");$(this).find("a").addClass("black_link");});
		$(".top_news").mouseout(function(){$(this).find("div").removeClass("top_news_over");$(this).find("a").removeClass("black_link");});

		if(selectColor > 1) {
			$(".top_news > div").css({"backgroundPositionY":(selectColor-1)*(-43)});
		}

		if( selectColor== 1) {
			$("#news_url").mouseover(function() {$(this).css("background", "#ff0000")});
			for(i=0;i<$("#top_news_float").children().length;i++) {
				$("#top_news_float").children().eq(i).children().eq(0).addClass("top_news_red_"+i%10);
				$("#top_news_float").children().eq(i).children().eq(1).addClass("top_news_red_"+i%10+"_");
			}
		}
		if(selectColor == 2) {
			$("#news_url").mouseover(function() {$(this).css("background", "#0083ff")});

			for(i=0;i<$("#top_news_float").children().length;i++) {
				$("#top_news_float").children().eq(i).children().eq(0).addClass("top_news_blue_"+i%10);
				$("#top_news_float").children().eq(i).children().eq(1).addClass("top_news_blue_"+i%10+"_");
			}
		}
		if(selectColor == 3) {
			$("#news_url").mouseover(function() {$(this).css("background", "#ee00ff")});

			for(i=0;i<$("#top_news_float").children().length;i++) {
				$("#top_news_float").children().eq(i).children().eq(0).addClass("top_news_plue_"+i%10);
				$("#top_news_float").children().eq(i).children().eq(1).addClass("top_news_plue_"+i%10+"_");
			}
		}
		if(selectColor == 4) {
			$("#news_url").mouseover(function() {$(this).css("background", "#41d300")});

			for(i=0;i<$("#top_news_float").children().length;i++) {
				$("#top_news_float").children().eq(i).children().eq(0).addClass("top_news_green_"+i%10);
				$("#top_news_float").children().eq(i).children().eq(1).addClass("top_news_green_"+i%10+"_");
			}
		}
		$("#news_url").mouseout(function() {$(this).css("background", "black")});
	} else {
		if(selectColor == 2) $(".top_content2").css("background", "#0083ff");
		if(selectColor == 3) $(".top_content2").css("background", "#ee00ff");
		if(selectColor == 4) $(".top_content2").css("background", "#41d300");

	}
	if(selectColor == 2) $(".top_news_bar6").css("background", "#0083ff");
	if(selectColor == 3) $(".top_news_bar6").css("background", "#ee00ff");
	if(selectColor == 4) $(".top_news_bar6").css("background", "#41d300");

	$(".top_news_bar6").mouseover(function() {$(".top_news_bar6 > img").show(0);});
});
