Skip to content

Commit

Permalink
fixes #17716, sporadic gesture/tap error
Browse files Browse the repository at this point in the history
  • Loading branch information
jason0x43 authored and dylans committed Feb 24, 2017
1 parent cc13d35 commit 2c8df0f
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion gesture/tap.js
Original file line number Diff line number Diff line change
Expand Up @@ -129,6 +129,9 @@ var clz = declare(/*===== "dojox.gesture.tap", =====*/Base, {
_isTap: function(/*Object*/data, /*Event*/e){
// summary:
// Check whether it's an valid tap
if (!data.context) {
return false;
}
var dx = Math.abs(data.context.x - e.screenX);
var dy = Math.abs(data.context.y - e.screenY);
return dx <= this.tapRadius && dy <= this.tapRadius;
Expand All @@ -142,4 +145,4 @@ dojox.gesture.tap.Tap = clz;

return dojox.gesture.tap;

});
});

0 comments on commit 2c8df0f

Please sign in to comment.