dojox/geo/charting/TouchInteractionSupport (version 1.10)

Summary

A class to handle touch interactions on a dojox/geo/charting/Map component.

Usage

var foo = new TouchInteractionSupport(map);
dojox/geo/charting/TouchInteractionSupport
Parameter Type Description
map dojox/geo/charting/Map

the Map widget this class provides touch navigation for.

See the dojox/geo/charting/TouchInteractionSupport reference documentation for more information.

Property Summary

Method Summary

  • _doubleTapHandler(touchEvent) action performed on the map when a double tap was triggered
  • _getFeatureFromTouchEvent(touchEvent) utility function to return the feature located at this touch event location
  • _getFingerSpacing(touchEvent) computes the distance between the first two fingers
  • _getTouchBarycenter(touchEvent) returns the midpoint of the two first fingers (or the first finger location if only one)
  • _isDoubleTap(touchEvent) checks whether the specified touchStart event is a double tap (i.e. follows closely a previous touchStart at approximately the same location)
  • _singleTapHandler(touchEvent) action performed on the map when a single tap was triggered
  • _touchEndHandler(touchEvent) action performed on the map when a touch end was triggered
  • _touchEndTapHandler(touchEvent) action performed on the map when a tap was triggered
  • _touchMoveHandler(touchEvent) action performed on the map when a touch move was triggered
  • _touchStartHandler(touchEvent) action performed on the map when a touch start was triggered
  • connect() install touch listeners
  • disconnect() disconnects any installed listeners.

Properties

_centerTouchLocation
_doubleTapPerformed
_initialFingerSpacing
_initialScale
_oneFingerTouch
_tapThreshold
_touchEndListener
_touchEndTapListener
_touchMoveListener
_touchStartListener

Methods

_doubleTapHandler(touchEvent)

action performed on the map when a double tap was triggered

Parameter Type Description
touchEvent TouchEvent

a touch event

_getFeatureFromTouchEvent(touchEvent)

utility function to return the feature located at this touch event location

Parameter Type Description
touchEvent TouchEvent

a touch event

Returns:any | undefined

the feature found if any, null otherwise.

_getFingerSpacing(touchEvent)

computes the distance between the first two fingers

Parameter Type Description
touchEvent undefined
Returns:any | undefined

a distance. -1 if less than 2 fingers

_getTouchBarycenter(touchEvent)

returns the midpoint of the two first fingers (or the first finger location if only one)

Parameter Type Description
touchEvent TouchEvent

a touch event

Returns:any | object

the midpoint

_isDoubleTap(touchEvent)

checks whether the specified touchStart event is a double tap (i.e. follows closely a previous touchStart at approximately the same location)

Parameter Type Description
touchEvent TouchEvent

a touch event

Returns:any | boolean

true if this event is considered a double tap

_singleTapHandler(touchEvent)

action performed on the map when a single tap was triggered

Parameter Type Description
touchEvent TouchEvent

a touch event

_touchEndHandler(touchEvent)

action performed on the map when a touch end was triggered

Parameter Type Description
touchEvent TouchEvent

a touch event

_touchEndTapHandler(touchEvent)

action performed on the map when a tap was triggered

Parameter Type Description
touchEvent TouchEvent

a touch event

_touchMoveHandler(touchEvent)

action performed on the map when a touch move was triggered

Parameter Type Description
touchEvent TouchEvent

a touch event

_touchStartHandler(touchEvent)

action performed on the map when a touch start was triggered

Parameter Type Description
touchEvent TouchEvent

a touch event

connect()

install touch listeners

disconnect()

disconnects any installed listeners. Must be called only when disposing of this instance

Error in the documentation? Can’t find what you are looking for? Let us know!