var ListUpMove=function(){

}
ListUpMove.prototype={

  RomeDome:function(onediv,towdiv,countMin,sin){
//  	alert("Lichun 0");
	//var countMin=-30;
	var current=0;
	var sleep=80;
	var onediv_yin=$(onediv);
	var towdiv_yin=$(towdiv);
	var towdiv_yin_ul=towdiv_yin.find("ul");	
	if(sin!=0){
         var dd=$(towdiv_yin_ul.html())
	 towdiv_yin_ul.append(dd);
        }
//	alert("Lichun 1");
//	var TABLEobj=divobj.find("TABLE");
	onediv_yin.css({"position":"relative","overflow":"hidden"});
	towdiv_yin.css({"position":"relative"});
//	alert("Lichun 2");
	var move=setInterval(MoveDom,sleep);
	onediv_yin.mouseover(function(){clearInterval(move);});
	onediv_yin.mouseout(function(){move=setInterval(MoveDom,sleep);});
//	alert("Lichun 3");	
	function MoveDom(){

   if(current>countMin)	{	
      towdiv_yin.css("top",current+"px");
      current--;
   }
    else  if(current==countMin){
    	towdiv_yin.css("top",countMin+"px");
    	current--;
          
      }else if(current<countMin){      	
        var firt=towdiv_yin.find("li").get(0);
       	towdiv_yin_ul.append(firt);
       	towdiv_yin.css("top",0+"px");
       current=0;
      }
	}
//	alert("Lichun4");
  }

}
$(function() {
          var html=new ListUpMove();
          html.RomeDome("#gonggao","#gonggao1",-40,0);         
          html.RomeDome("#sfcs","#sfcs1",-23,0);
		})