Skip to content
This repository was archived by the owner on Apr 12, 2024. It is now read-only.

Commit bea74c0

Browse files
alfonso-presaNarretz
authored andcommitted
docs(ngTouch): Document event parameter for $swipe handlers
Document that the event handlers provided by $swipe do receive the raw event as their last parameter. Closes #11983 Closes #12149
1 parent bacc3b7 commit bea74c0

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/ngTouch/swipe.js

+2-1
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,8 @@ ngTouch.factory('$swipe', [function() {
7474
* `$swipe` will listen for `mouse` and `touch` events.
7575
*
7676
* The four events are `start`, `move`, `end`, and `cancel`. `start`, `move`, and `end`
77-
* receive as a parameter a coordinates object of the form `{ x: 150, y: 310 }`.
77+
* receive as a parameter a coordinates object of the form `{ x: 150, y: 310 }` and the raw
78+
* `event`. `cancel` receives the raw `event` as its single parameter.
7879
*
7980
* `start` is called on either `mousedown` or `touchstart`. After this event, `$swipe` is
8081
* watching for `touchmove` or `mousemove` events. These events are ignored until the total

0 commit comments

Comments
 (0)