UNPKG

1.22 kBTypeScriptView Raw
1// Type definitions for ag-grid v18.1.2
2// Project: http://www.ag-grid.com/
3// Definitions by: Niall Crosby <https://github.com/ag-grid/>
4import { IEventEmitter } from "../interfaces/iEventEmitter";
5import { AgEvent } from "../events";
6export interface TapEvent extends AgEvent {
7 touchStart: Touch;
8}
9export interface LongTapEvent extends AgEvent {
10 touchStart: Touch;
11 touchEvent: TouchEvent;
12}
13export declare class TouchListener implements IEventEmitter {
14 static EVENT_TAP: string;
15 static EVENT_DOUBLE_TAP: string;
16 static EVENT_LONG_TAP: string;
17 private static DOUBLE_TAP_MILLIS;
18 private eElement;
19 private destroyFuncs;
20 private moved;
21 private touching;
22 private touchStart;
23 private lastTapTime;
24 private eventService;
25 private preventMouseClick;
26 constructor(eElement: HTMLElement, preventMouseClick?: boolean);
27 private getActiveTouch(touchList);
28 addEventListener(eventType: string, listener: Function): void;
29 removeEventListener(eventType: string, listener: Function): void;
30 private onTouchStart(touchEvent);
31 private onTouchMove(touchEvent);
32 private onTouchEnd(touchEvent);
33 private checkForDoubleTap();
34 destroy(): void;
35}