日期:2014-05-16 浏览次数:20413 次
MouseWheel.js的代码如下:
var MouseWheel_Count=0;
|
function MouseWheel$handle(delta){
|
???? MouseWheel_Count++;
|
???? if (MouseWheel_Count>1)?? return ;
|
???? if (delta < 0) //小于0向下滚动,大于0向上滚动
|
??????? //??????? alert("向下滚动");
|
???? else ? |
??????? //??????? alert("向上滚动");
|
???? setTimeout( "MouseWheel$CountMinus();" ,500);
|
} |
? ? |
function MouseWheel$CountMinus()
|
{ |
???? MouseWheel_Count=0;
|
} |
? ? |
/** 事件句柄 |
? */
|
|