Skip to content

Commit

Permalink
Added x and y coordinates for doubleTap and singleTap events
Browse files Browse the repository at this point in the history
  • Loading branch information
joschi127 committed Aug 12, 2015
1 parent 3f45a65 commit 697f2a5
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions touch.js
Original file line number Diff line number Diff line change
Expand Up @@ -105,11 +105,17 @@
return _cleanGesture();
} else {
if (GESTURE.isDoubleTap) {
_trigger("doubleTap");
_trigger("doubleTap", {
x: FIRST_TOUCH[0].x,
y: FIRST_TOUCH[0].y
});
return _cleanGesture();
} else {
TOUCH_TIMEOUT = setTimeout(function () {
_trigger("singleTap");
_trigger("singleTap", {
x: FIRST_TOUCH[0].x,
y: FIRST_TOUCH[0].y
});
_cleanGesture();
}, 250);
return TOUCH_TIMEOUT;
Expand Down

0 comments on commit 697f2a5

Please sign in to comment.