Use clientX and clientY instead of x,y for mouse event test page.
--- a/mouse-event-test.html Tue Oct 22 16:49:23 2013 -0700
+++ b/mouse-event-test.html Wed Oct 23 13:40:53 2013 -0700
@@ -216,7 +216,7 @@
var this_mousemove = e.type + "_" + e.currentTarget.id;
if (this_mousemove == last_mousemove) {
count_mousemove++;
- updateCount(calcPosition(e.x, e.y));
+ updateCount(calcPosition(e.clientX, e.clientY));
return;
}
last_mousemove = this_mousemove;
@@ -229,7 +229,7 @@
eventinfo["etype"] = e.type;
eventinfo["data"] = calcString(e.data);
eventinfo["id"] = e.currentTarget.id;
- eventinfo["xy"] = calcPosition(e.x, e.y);
+ eventinfo["xy"] = calcPosition(e.clientX, e.clientY);
addEvent(eventinfo);
}