forked from DefinitelyTyped/DefinitelyTyped
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdojox.gesture.d.ts
101 lines (97 loc) · 3.24 KB
/
dojox.gesture.d.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
// Type definitions for Dojo v1.9
// Project: http://dojotoolkit.org
// Definitions by: Michael Van Sickle <https://github.com/vansimke>
// Definitions: https://github.com/borisyankov/DefinitelyTyped
declare module dojox {
module gesture {
/**
* Permalink: http://dojotoolkit.org/api/1.9/dojox/gesture/Base.html
*
*
* @param args
*/
class Base {
constructor(args: any);
/**
* Default event e.g. 'tap' is a default event of dojox.gesture.tap
*
*/
"defaultEvent": string;
/**
* A list of sub events e.g ['hold', 'doubletap'],
* used by being combined with defaultEvent like 'tap.hold', 'tap.doubletap' etc.
*
*/
"subEvents": any[];
/**
* Whether the gesture is touch-device only
*
*/
"touchOnly": boolean;
/**
* Process the 'cancel' phase of a gesture
*
* @param data
* @param e
*/
cancel(data: any, e: any): void;
/**
* Release all handlers and resources
*
*/
destroy(): void;
/**
* Fire a gesture event and invoke registered listeners
* a simulated GestureEvent will also be sent along
*
* @param node Target node to fire the gesture
* @param event An object containing specific gesture info e.g {type: 'tap.hold'|'swipe.left'), ...}all these properties will be put into a simulated GestureEvent when fired.Note - Default properties in a native Event won't be overwritten, see on.emit() for more details.
*/
fire(node: HTMLElement, event: Object): void;
/**
* Initialization works
*
*/
init(): void;
/**
* Check if the node is locked, isLocked(node) means
* whether it's a descendant of the currently locked node.
*
* @param node
*/
isLocked(node: any): boolean;
/**
* Lock all descendants of the node.
*
* @param node
*/
lock(node: HTMLElement): void;
/**
* Process the 'move' phase of a gesture
*
* @param data
* @param e
*/
move(data: any, e: any): void;
/**
* Process the 'press' phase of a gesture
*
* @param data
* @param e
*/
press(data: any, e: any): void;
/**
* Process the 'release' phase of a gesture
*
* @param data
* @param e
*/
release(data: any, e: any): void;
/**
* Release the lock
*
*/
unLock(): void;
}
}
}