您可以捕获 OnMouseWheel 事件,手动滚动窗口并防止默认处理:
<html>
<head>
<script>
var MOUSE_WHEEL_GAIN = 1;
function OnMouseWheel() {
window.scrollTo(0, document.body.scrollTop - event.wheelDelta/120 * MOUSE_WHEEL_GAIN);
var e = window.event;
e.returnValue = false;
e.cancelBubble = true;
return false;
}
</script>
<head>
<body ONMOUSEWHEEL="OnMouseWheel()">
<script>
for (i=0;i<20;i++) document.write("<p>" + i + " Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.</p>");
</script>
</body>
</html>