tap polyfill only when from touch event

This commit is contained in:
Adam Bradley
2013-09-26 13:00:09 -05:00
parent 0b7c6ada06
commit e39f224fb9
4 changed files with 14 additions and 28 deletions

View File

@ -90,16 +90,9 @@
ionic.Gestures.event.determineEventTypes();
// Register all gestures inside ionic.Gestures.gestures
if(this === this.window) {
// this is a window, only add these
ionic.Gestures.detection.register(ionic.Gestures.gestures.Tap);
} else {
// everything else but the window
for(var name in ionic.Gestures.gestures) {
if(ionic.Gestures.gestures.hasOwnProperty(name)) {
ionic.Gestures.detection.register(ionic.Gestures.gestures[name]);
}
for(var name in ionic.Gestures.gestures) {
if(ionic.Gestures.gestures.hasOwnProperty(name)) {
ionic.Gestures.detection.register(ionic.Gestures.gestures[name]);
}
}