Skip to content

Commit

Permalink
do not prevent defaults for pan-x pan-y case
Browse files Browse the repository at this point in the history
`pan-x pan-y` means browser handles all scrolling/panning, do not
prevent these
  • Loading branch information
patrickhlauke committed Oct 7, 2015
1 parent bafc807 commit 95eaafa
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/touchaction.js
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,11 @@ TouchAction.prototype = {
}
}

if (hasPanX && hasPanY) {
// `pan-x pan-y` means browser handles all scrolling/panning, do not prevent
return;
}

if (hasNone ||
(hasPanY && direction & DIRECTION_HORIZONTAL) ||
(hasPanX && direction & DIRECTION_VERTICAL)) {
Expand Down

0 comments on commit 95eaafa

Please sign in to comment.