function getCoordinates(event) {
    var originalEvent = event.originalEvent || event;
    var touches = originalEvent.touches && originalEvent.touches.length ? originalEvent.touches : [originalEvent];
    var e = (originalEvent.changedTouches && originalEvent.changedTouches[0]) || touches[0];

    return {
      x: e.clientX,
      y: e.clientY
    };
  }
@ngdoc service
@name $swipe

@deprecated
sinceVersion="1.7.0"

See the {@link ngTouch module} documentation for more information.

@description
The `$swipe` service is a service that abstracts the messier details of hold-and-drag swipe
behavior, to make implementing swipe-related directives more convenient.

Requires the {@link ngTouch `ngTouch`} module to be installed.

`$swipe` is used by the `ngSwipeLeft` and `ngSwipeRight` directives in `ngTouch`.

# Usage
The `$swipe` service is an object with a single method: `bind`. `bind` takes an element
which is to be watched for swipes, and an object with four handler functions. See the
documentation for `bind` below.