[webkit-dev] Mouse wheel event precision

Nathan Vander Wilt nate-lists at calftrail.com
Tue Jun 8 19:09:32 PDT 2010

In Safari 4, the following event handler would log nice smooth values when scrolling:
// logs: -3, -9, -6, -48, ...
document.addEventListener("mousewheel", function(e) { console.log(e.wheelDeltaY); });

In Safari 5, the mousewheel events have lost all precision, and are now big ugly integral multiples of 120:
// logs: -120, -240, -120, -480, ... (no correspondence with above values, of course)
document.addEventListener("mousewheel", function(e) { console.log(e.wheelDeltaY); });

This is a serious loss of precision, and brings us back to the primitive days when a mouse a had 1-axis clicky scroll wheel if it had one at all, and Firefox was the top browser. Compare the smooth, precise scroll zooming of http://calftrail.com/Share/multitouch/ in Safari 4 to the jerky, way-too-fast zooming in Safari 5.

Is this a regression introduced directly in recent WebKit builds, or is it Safari-specific? If the former, was it really necessary and can it please be rolled back?


More information about the webkit-dev mailing list