要转为数字对比,而不是直接list.style.left<=-3000+p'x'
var left=parseInt(list.style.left)+offset; list.style.left=left+'px' if(left<-3000)....