Skip to content

Commit

Permalink
fix41: Call event.preventDefault before simulating a click event, to …
Browse files Browse the repository at this point in the history
…avoid getting two clicks.
  • Loading branch information
RandScullard committed Dec 19, 2014
1 parent c04e571 commit 17f9036
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion jquery.ui.touch-punch.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/*!
/*!
* jQuery UI Touch Punch 0.2.3
*
* Copyright 2011–2014, Dave Furfero
Expand Down Expand Up @@ -134,6 +134,7 @@
if (!this._touchMoved) {

// Simulate the click event
event.preventDefault();
simulateMouseEvent(event, 'click');
}

Expand Down

0 comments on commit 17f9036

Please sign in to comment.