Skip to content

Commit

Permalink
fixed stop event when no start event was raised.
Browse files Browse the repository at this point in the history
  • Loading branch information
ngryman committed Mar 12, 2013
1 parent 2aa8e94 commit 54cffe6
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/jquery.finger.js
Original file line number Original file line Diff line number Diff line change
Expand Up @@ -102,6 +102,9 @@
now = event.timeStamp, now = event.timeStamp,
evtName; evtName;


// no start event fired, do nothing
if (!f.start) return;

// tap-like events // tap-like events
evtName = now - f.start.time < $.Finger.pressDuration ? 'tap' : 'press'; evtName = now - f.start.time < $.Finger.pressDuration ? 'tap' : 'press';
// is it a double tap ? // is it a double tap ?
Expand Down

0 comments on commit 54cffe6

Please sign in to comment.