//>>built
define("dojox/analytics/plugins/gestureEvents","dojo/_base/lang ../_base dojo/_base/window dojo/on dojo/_base/config dojo/touch dojox/gesture/tap dojox/gesture/swipe".split(" "),function(c,f,k,l,g,p,m,n){return f.plugins.gestureEvents=new function(){this.watchSwipe=void 0===g.watchSwipe||g.watchSwipe?!0:!1;this.swipeSampleDelay=g.swipeSampleDelay||1E3;this.targetProps=g.targetProps||"id className localName href spellcheck lang textContent value".split(" ");this.textContentMaxChars=g.textContentMaxChars||
50;this.addDataSwipe=c.hitch(f,"addData","gesture.swipe");this.sampleSwipe=function(a){this._rateLimited||(this.addDataSwipe(this.trimEvent(a)),this._rateLimited=!0,setTimeout(c.hitch(this,function(){this._rateLimited&&(this.trimEvent(this._lastSwipeEvent),delete this._lastSwipeEvent,delete this._rateLimited)}),this.swipeSampleDelay));return this._lastSwipeEvent=a};this.watchSwipe&&l(k.doc,n,c.hitch(this,"sampleSwipe"));this.addData=c.hitch(f,"addData","gesture.tap");this.onGestureTap=function(a){this.addData(this.trimEvent(a))};
l(k.doc,m,c.hitch(this,"onGestureTap"));this.addDataDoubleTap=c.hitch(f,"addData","gesture.tap.doubletap");this.onGestureDoubleTap=function(a){this.addDataDoubleTap(this.trimEvent(a))};l(k.doc,m.doubletap,c.hitch(this,"onGestureDoubleTap"));this.addDataTapHold=c.hitch(f,"addData","gesture.tap.taphold");this.onGestureTapHold=function(a){this.addDataTapHold(this.trimEvent(a))};l(k.doc,m.hold,c.hitch(this,"onGestureTapHold"));this.trimEvent=function(a){var h={},b;for(b in a)switch(b){case "target":var e=
this.targetProps;h[b]={};for(var d=0;d<e.length;d++)a[b][e[d]]&&("text"==e[d]||"textContent"==e[d]?"HTML"!=a[b].localName&&"BODY"!=a[b].localName&&(h[b][e[d]]=a[b][e[d]].substr(0,this.textContentMaxChars)):h[b][e[d]]=a[b][e[d]]);break;case "clientX":case "clientY":case "screenX":case "screenY":case "dx":case "dy":case "time":h[b]=a[b]}return h}}});