Skip to content

Commit

Permalink
Improve 'auto' preventDefault with manualStart
Browse files Browse the repository at this point in the history
If manuanStart is `true`, default prevention will happen only while
interacting.

See #138
  • Loading branch information
taye committed Feb 16, 2015
1 parent b653307 commit 8df9cd6
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions interact.js
Original file line number Diff line number Diff line change
Expand Up @@ -2939,6 +2939,12 @@
return;
}

// with manualStart, only preventDefault while interacting
if (options[this.prepared.name] && options[this.prepared.name].manualStart
&& !this.interacting()) {
return;
}

event.preventDefault();
return;
}
Expand Down

0 comments on commit 8df9cd6

Please sign in to comment.