Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

bump version to 0.0.11.

  • Loading branch information...
commit c90a0301dee074c2f6fb8642b8244b915916724d 1 parent 41a19da
@ngryman authored
View
3  README.md
@@ -143,6 +143,9 @@ $('#menu').on('flick', function(e) {
## Release History
```
+v0.0.11
+ - `press` event is now fired by `timeout` instead of `touchend`.
+
v0.0.10
- fixed events fired multiple times (#1).
- added `preventDefault` support.
View
2  component.json
@@ -1,6 +1,6 @@
{
"name": "jquery.finger",
- "version": "0.0.10",
+ "version": "0.0.11",
"main": "dist/jquery.finger.js",
"dependencies": {
"jquery": "~1.7.0"
View
2  dist/jquery.finger.js
@@ -1,4 +1,4 @@
-/*! jquery.finger - v0.0.10 - 2013-04-27
+/*! jquery.finger - v0.0.11 - 2013-04-27
* https://github.com/ngryman/jquery.finger
* Copyright (c) 2013 Nicolas Gryman; Licensed MIT */
View
2  dist/jquery.finger.min.js
@@ -1,4 +1,4 @@
-/*! jquery.finger - v0.0.10 - 2013-04-27
+/*! jquery.finger - v0.0.11 - 2013-04-27
* https://github.com/ngryman/jquery.finger
* Copyright (c) 2013 Nicolas Gryman; Licensed MIT */
(function(t){function e(t,e){return(r?e.originalEvent.touches[0]:e)["page"+t.toUpperCase()]}function a(a){var r={},v=t.data(this,u);i!=a.timeStamp&&(i=a.timeStamp,r.move={x:e("x",a),y:e("y",a)},r.start=t.extend({time:a.timeStamp,target:a.target},r.move),r.timeout=setTimeout(t.proxy(function(){t.event.trigger(t.Event("press",r.move),null,a.target),t.event.remove(this,s+"."+u,n),t.event.remove(this,d+"."+u,o)},this),t.Finger.pressDuration),t.event.add(this,s+"."+u,n,r),t.event.add(this,d+"."+u,o,r),v.preventDefault&&a.preventDefault())}function n(a){var n=a.data,i=n.start,r=n.move;return r.x=e("x",a),r.y=e("y",a),r.dx=r.x-i.x,r.dy=r.y-i.y,r.adx=Math.abs(r.dx),r.ady=Math.abs(r.dy),n.motion=r.adx>l.motionThreshold||r.ady>l.motionThreshold,n.motion?(clearTimeout(n.timeout),r.orientation||(r.adx>n.move.ady?(r.orientation="horizontal",r.direction=r.dx>0?1:-1):(r.orientation="vertical",r.direction=r.dy>0?1:-1)),a.target!==i.target?(a.target=i.target,o.call(this,t.Event(d+"."+u,a)),void 0):(t.event.trigger(t.Event("drag",r),null,a.target),void 0)):void 0}function o(e){var a,i=e.data,r=e.timeStamp,v=t.data(this,u),m=r-i.start.time;clearTimeout(i.timeout),e.target===i.start.target&&(i.motion?(a=l.flickDuration>m?"flick":"drag",i.move.end=!0):(a=l.pressDuration>m&&!v.prev||v.prev&&r-v.prev>l.doubleTapInterval?"tap":"doubletap",v.prev=r),t.event.trigger(t.Event(a,i.move),null,e.target),t.event.remove(this,s+"."+u,n),t.event.remove(this,d+"."+u,o))}var i,r="ontouchstart"in window,v=r?"touchstart":"mousedown",d=r?"touchend touchcancel":"mouseup mouseleave",s=r?"touchmove":"mousemove",u="finger",l=t.Finger={pressDuration:300,doubleTapInterval:300,flickDuration:150,motionThreshold:5},m={add:function(e){var n,o=e.data;t.data(this,u)||(t.event.add(this,v+"."+u,a),n=t.data(this,u,{}),(l.preventDefault||o&&o.preventDefault)&&(n.preventDefault=!0))},teardown:function(){t.data(this,u)&&(t.event.remove(this,v+"."+u,a),t.data(this,u,null))}};t.event.special.tap=m,t.event.special.press=m,t.event.special.doubletap=m,t.event.special.drag=m,t.event.special.flick=m})(jQuery);
View
2  finger.jquery.json
@@ -1,7 +1,7 @@
{
"name": "finger",
"title": "jQuery Finger",
- "version": "0.0.10",
+ "version": "0.0.11",
"description": "jQuery Finger unifies click and touch events by removing the 300ms delay on touch devices. It also provide a common set of events to handle basic gestures such as drag and pinch. Small (< 1kb gzipped), it is focused on performance, is well tested and ... also supports jQuery delegated events.",
"homepage": "https://github.com/ngryman/jquery.finger",
"bugs": "https://github.com/ngryman/jquery.finger/issues",
View
2  package.json
@@ -1,6 +1,6 @@
{
"name": "jquery.finger",
- "version": "0.0.10",
+ "version": "0.0.11",
"description": "jQuery Finger unifies click and touch events by removing the 300ms delay on touch devices. It also provide a common set of events to handle basic gestures such as drag and pinch. Small (< 1kb gzipped), it is focused on performance, is well tested and ... also supports jQuery delegated events.",
"homepage": "https://github.com/ngryman/jquery.finger",
"keywords": [
Please sign in to comment.
Something went wrong with that request. Please try again.