function CreatePop(ob)
{
		function isIE()
		{
			 return (document.all && window.ActiveXObject && !window.opera) ? true : false;
		}

        var s1=document.getElementById("GroundDiv");
		var s2=document.getElementById("GroundDiv2");
		var s3=document.getElementById("GroundDiv3");
		if(document.getElementById("GroundDiv"))
		{
		    s1.parentNode.removeChild(s1);
		}
		if(document.getElementById("GroundDiv2"))
		{
		    s2.parentNode.removeChild(s2);
		}
		if(document.getElementById("GroundDiv3"))
		{
		    s3.parentNode.removeChild(s3);
		}		
		
		document.getElementById("t").style.display="none";
		p=document.getElementById(ob).getBoundingClientRect();
		var top=document.documentElement.scrollTop+document.documentElement.clientHeight/2-100;;
		var left=(screen.height/2-50);

		var MainDiv=document.createElement("Div");
		MainDiv.id="MainDiv";
		MainDiv.style.position="absolute";
		MainDiv.style.zIndex="1";
		MainDiv.style.top=(p.top-90)+"px";
		MainDiv.style.left=(p.left-2)+"px";
		
		var GroundDiv=document.createElement("Div");
		GroundDiv.id="GroundDiv";
		GroundDiv.style.top=(p.top-122)+"px";
		GroundDiv.style.left=(p.left-2)+"px";
		GroundDiv.className="ct_center";
		
		if(ob=="menu5")
		{
			 GroundDiv.style.background="url(/images/index/116aaa_an_09.png) no-repeat";
			 MainDiv.style.left=(p.left-92)+"px";
		}
		else if(ob=="menu6")
		{
			 GroundDiv.style.background="url(/images/index/116aaa_an_09.png) no-repeat";
			 MainDiv.style.left=(p.left-91)+"px";
		}		
		
		var GroundDiv2=document.createElement("Div");
		GroundDiv2.id="GroundDiv2";
		GroundDiv2.style.top=top+"px";
		GroundDiv2.style.left=left+"px";
		GroundDiv2.className="top_wen";
		
		var Describe='';
		switch(ob)
		{
		     case "menu1":
			 Describe="免费无限增长的网络硬盘，永久存放你的文件。可私密，可分享！";
			 break;
		     case "menu2":
			 Describe="高清影视应有尽有，分享一切视听盛宴。";
			 break;
		     case "menu3":
			 Describe="海量软件资源免费共享，版权还可自由交易。";
			 break;
		     case "menu4":
			 Describe="自主设置播放你喜欢的音乐，同时还可以欣赏自己及好友照片。";
			 break;	
		     case "menu5":
			 Describe="这里有网友上传的美丽图片，还有精美的个性相册。";
			 break;
		     case "menu6":
			 Describe="更多抽屉有趣应用，点击查看详情。";
			 break;				 
		}
		GroundDiv2.innerHTML=Describe;
		
		isIE()?GroundDiv.style.filter="Alpha(Opacity=0)":GroundDiv.style.opacity=0.0;
		
		GroundDiv.appendChild(GroundDiv2);
		MainDiv.appendChild(GroundDiv);
		document.body.appendChild(MainDiv);
		
		var c=10;
		var ct;
		var mo=1;
		function SetH()
		{
			     isIE()?GroundDiv.style.filter="Alpha(Opacity="+c+")":GroundDiv.style.opacity=c/100;
				 if(c>=100)
				 {
					 clearInterval(ct);		
				 }
				 c=c+10;
				 mo++;
				 if(mo<=10)
				 {
				     MainDiv.style.top=(parseInt(MainDiv.style.top)-4)+"px";
				 }
		}
		ct=setInterval(SetH,50);
		
}


var i=1;
var temp1;
var temp2;
function MouseOver(ob)
{
		 i=1;
		 if(temp2!=null)
		 {
			  clearInterval(temp2);		
		 }
		 function nowOver()
		 {
				  document.getElementById(ob).className=ob+"_"+i;
				  if(i==4)
				  {
					  CreatePop(ob);
				  }
				  if(i<7)
				  {
					 i++;
				  }
				  else
				  {
					 i=7;
				  }

		 }
		 temp1=setInterval(nowOver,50);
}

function MouseOut(ob)
{
		 if(temp1!=null)
		 {
			 clearInterval(temp1);		
		 }
		 document.getElementById(ob).className=ob+"_7";
		 i=1;
}

var count=1;
function CreateSelectMenu()
{
		 if(count==2)
		 {
				 var s1=document.getElementById("SMenu");
				 if(document.getElementById("SMenu"))
				 {
					  s1.parentNode.removeChild(s1);
				 }
				 count=1;
		 }
		 else
		 {
				 p=document.getElementById("cm").getBoundingClientRect();
				 var MainDiv=document.createElement("Div");
				 MainDiv.id="SMenu";
				 MainDiv.style.position="absolute";
				 MainDiv.style.zIndex="1";
				 MainDiv.className="down_left_lib";
				 MainDiv.style.cursor="pointer";
				 MainDiv.innerHTML="<ul><li onmouseover='this.style.background=\"#ddecfb\"'  onmouseout='this.style.background=\"#fff\"' onclick='GV(\"all\")'>全部&nbsp;&nbsp;&nbsp;</li><li onmouseover='this.style.background=\"#ddecfb\"'  onmouseout='this.style.background=\"#fff\"' onclick='GV(\"movie\")'>影视&nbsp;&nbsp;&nbsp;</li><li onmouseover='this.style.background=\"#ddecfb\"'  onmouseout='this.style.background=\"#fff\"' onclick='GV(\"soft\")'>软件&nbsp;&nbsp;&nbsp;</li><li onmouseover='this.style.background=\"#ddecfb\"'  onmouseout='this.style.background=\"#fff\"' onclick='GV(\"music\")'>音乐&nbsp;&nbsp;&nbsp;</li><li onmouseover='this.style.background=\"#ddecfb\"'  onmouseout='this.style.background=\"#fff\"' onclick='GV(\"pic\")'>图片&nbsp;&nbsp;&nbsp;</li></ul>";
				 //默认值
				 MainDiv.style.top=(p.top+23)+"px";
				 MainDiv.style.left=(p.left+1)+"px";
				 if(navigator.userAgent.indexOf("MSIE 8.0")>0)
				 {
				      MainDiv.style.top=(p.top+24)+"px";
				      MainDiv.style.left=(p.left+1)+"px";
				 }
				 else if(navigator.userAgent.indexOf("MSIE 6.0")>0)
				 {
				      if(navigator.userAgent.indexOf("SV1")>0)
					  {
						  MainDiv.style.top=(p.top+24)+"px";
						  MainDiv.style.left=(p.left-1)+"px";						  
					  }
					  else
					  {
					      MainDiv.style.top=(p.top+24)+"px";
				          MainDiv.style.left=(p.left-1)+"px";
					  }
				 }				 
				 else if(navigator.userAgent.indexOf("MSIE 7.0")>0)
				 {
				      var Na=navigator.userAgent;
					  if(Na.indexOf("GreenBrowser")>0)
					  {
					       MainDiv.style.top=(p.top+25)+"px";
				           MainDiv.style.left=(p.left-1)+"px";
					  }
					  else if(Na.indexOf("Maxthon")>0)
					  {
					       MainDiv.style.top=(p.top+25)+"px";
				           MainDiv.style.left=(p.left-4)+"px";
					  }
					  else if(Na.indexOf("360SE")>0)
					  {
					       MainDiv.style.top=(p.top+25)+"px";
				           MainDiv.style.left=(p.left-2)+"px";
					  }						  
					  else if(Na=="Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1)")
					  {
					       MainDiv.style.top=(p.top+25)+"px";
				           MainDiv.style.left=(p.left-1)+"px";
					  }					  
					  else if(Na=="Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; Trident/4.0)")
					  {
					       MainDiv.style.top=(p.top+25)+"px";
				           MainDiv.style.left=(p.left-1)+"px";
					  }

				 }				 
				 else if(navigator.userAgent.indexOf("Firefox")>0)
				 {
				      MainDiv.style.top=(p.top+25)+"px";
				      MainDiv.style.left=(p.left+1)+"px";
				 }
				 else if(navigator.userAgent.indexOf("Presto")>0)
				 {
				      MainDiv.style.top=(p.top+26)+"px";
				      MainDiv.style.left=(p.left+1)+"px";
				 }
				 else if(navigator.userAgent.indexOf("Chrome")>0)
				 {
				      MainDiv.style.top=(p.top+27)+"px";
				      MainDiv.style.left=(p.left+1)+"px";
				 }
				 else if(navigator.userAgent.indexOf("Safari")>0)
				 {
				      MainDiv.style.top=(p.top+25)+"px";
				      MainDiv.style.left=(p.left+1)+"px";
				 }				 
				 document.body.appendChild(MainDiv);
				 count++;
		 }
		 
}

function GV(v)
{
		 var s1=document.getElementById("SMenu");
		 if(document.getElementById("SMenu"))
		 {
			  s1.parentNode.removeChild(s1);
		 }
		 count=1;
		 switch(v)
		 {
			 case "movie":
			 document.getElementById("sm").innerHTML="影视";
			 document.getElementById("SearchType").value="movie";
			 break;
			 case "music":
			 document.getElementById("sm").innerHTML="音乐";
			 document.getElementById("SearchType").value="music";
			 break;
			 case "soft":
			 document.getElementById("sm").innerHTML="软件";
			 document.getElementById("SearchType").value="soft";
			 break;
			 case "all":
			 document.getElementById("sm").innerHTML="全部";
			 document.getElementById("SearchType").value="all";
			 break;
			 case "pic":
			 document.getElementById("sm").innerHTML="图片";
			 document.getElementById("SearchType").value="pic";
			 break;			 
			 
		 }
}


