gesture-config.js 641B

123456789101112131415161718192021
  1. import { Injectable } from '@angular/core';
  2. import { HammerGestureConfig } from '@angular/platform-browser';
  3. /**
  4. * @hidden
  5. * This class overrides the default Angular gesture config.
  6. */
  7. export class IonicGestureConfig extends HammerGestureConfig {
  8. buildHammer(element) {
  9. const mc = new window.Hammer(element);
  10. for (let eventName in this.overrides) {
  11. mc.get(eventName).set(this.overrides[eventName]);
  12. }
  13. return mc;
  14. }
  15. }
  16. IonicGestureConfig.decorators = [
  17. { type: Injectable },
  18. ];
  19. /** @nocollapse */
  20. IonicGestureConfig.ctorParameters = () => [];
  21. //# sourceMappingURL=gesture-config.js.map