/*定义滚动条高宽及背景 高宽分别对应横竖滚动条的尺寸*/
::-webkit-scrollbar
{
width: 16px;
height: 16px;
background-color: #F5F5F5;
}
/*定义滚动条轨道 内阴影+圆角*/
::-webkit-scrollbar-track
{
-webkit-box-shadow: inset 0 0 6px rgba(0,0,0,0.3);
border-radius: 10px;
background-color: #F5F5F5;
}
/*定义滑块 内阴影+圆角*/
::-webkit-scrollbar-thumb
{
border-radius: 10px;
-webkit-box-shadow: inset 0 0 6px rgba(0,0,0,.3);
background-color: #666;
}
/*机泵监测窗口轮播*/
var index = 0;
function pumpanimation(){
if(index != ($('.pumpmonwindow ul li').length - 7) ){
var mainContainer = $('.pumpmonwindow ul');
var scrollToContainer = $('.pumpmonwindow ul li:eq('+index+')');
debugger;
mainContainer.animate({
scrollTop: scrollToContainer.offset().top - mainContainer.offset().top + mainContainer.scrollTop()
}, 1100);
index++;
}else{
index = 0;
var mainContainer = $('.pumpmonwindow ul');
var scrollToContainer = $('.pumpmonwindow ul li:eq('+index+')');
mainContainer.animate({
scrollTop: scrollToContainer.offset().top - mainContainer.offset().top + mainContainer.scrollTop()
}, 1000);
}
}
/*机泵监测窗口轮播*/
pumpanimation();
var pumpanimationval;
pumpanimationval = window.setInterval(function(){
pumpanimation();
},1000);
$('.pumpmonwindow ul').css('overflow-y','hidden');
$('.pumpmonwindow ul').hover(function(){
debugger;
clearInterval(pumpanimationval);
$('.pumpmonwindow ul').css('overflow-y','auto');
},function(){
$('.pumpmonwindow ul').css('overflow-y','hidden');
pumpanimationval = window.setInterval(function(){
pumpanimation();
},1000);
});