Fix #6893 - fix roo docs
[roojs1] / docs / symbols / Roo.util.ClickRepeater.json
1 {
2   "name" : "Roo.util.ClickRepeater",
3   "augments" : [
4     "Roo.util.Observable"
5   ],
6   "desc" : "A wrapper class which can be applied to any element. Fires a \"click\" event while the\nmouse is pressed. The interval between firings may be specified in the config but\ndefaults to 10 milliseconds.\n\nOptionally, a CSS class may be applied to the element during the time it is pressed.",
7   "isSingleton" : false,
8   "isStatic" : false,
9   "isBuiltin" : false,
10   "memberOf" : "ClickRepeater",
11   "example" : "",
12   "deprecated" : "",
13   "since" : "",
14   "see" : "",
15   "params" : [
16     {
17       "name" : "el",
18       "type" : "String/HTMLElement/Element",
19       "desc" : "The element to listen on",
20       "isOptional" : false
21     },
22     {
23       "name" : "config",
24       "type" : "Object",
25       "desc" : "",
26       "isOptional" : false
27     }
28   ],
29   "returns" : [],
30   "config" : [
31     {
32       "name" : "stopDefault",
33       "type" : "Boolean",
34       "desc" : "True to stop the default click event",
35       "memberOf" : "Roo.util.ClickRepeater",
36       "optvals" : []
37     },
38     {
39       "name" : "listeners",
40       "type" : "Object",
41       "desc" : "list of events and functions to call for this object, \nFor example :\n<pre><code>\n    listeners :  { \n       'click' : function(e) {\n           ..... \n        } ,\n        .... \n    } \n  </code></pre>",
42       "memberOf" : "Roo.util.Observable",
43       "optvals" : []
44     },
45     {
46       "name" : "delay",
47       "type" : "Number",
48       "desc" : "The initial delay before the repeating event begins firing.\nSimilar to an autorepeat key delay.",
49       "memberOf" : "Roo.util.ClickRepeater",
50       "optvals" : []
51     },
52     {
53       "name" : "accelerate",
54       "type" : "Boolean",
55       "desc" : "True if autorepeating should start slowly and accelerate.\n          \"interval\" and \"delay\" are ignored. \"immediate\" is honored.",
56       "memberOf" : "Roo.util.ClickRepeater",
57       "optvals" : []
58     },
59     {
60       "name" : "preventDefault",
61       "type" : "Boolean",
62       "desc" : "True to prevent the default click event",
63       "memberOf" : "Roo.util.ClickRepeater",
64       "optvals" : []
65     },
66     {
67       "name" : "interval",
68       "type" : "Number",
69       "desc" : "The interval between firings of the \"click\" event. Default 10 ms.",
70       "memberOf" : "Roo.util.ClickRepeater",
71       "optvals" : []
72     },
73     {
74       "name" : "el",
75       "type" : "String/HTMLElement/Element",
76       "desc" : "The element to act as a button.",
77       "memberOf" : "Roo.util.ClickRepeater",
78       "optvals" : []
79     },
80     {
81       "name" : "pressClass",
82       "type" : "String",
83       "desc" : "A CSS class name to be applied to the element while pressed.",
84       "memberOf" : "Roo.util.ClickRepeater",
85       "optvals" : []
86     }
87   ],
88   "methods" : [
89     {
90       "name" : "purgeListeners",
91       "desc" : "Removes all listeners for this object",
92       "isStatic" : false,
93       "isConstructor" : false,
94       "isPrivate" : false,
95       "memberOf" : "Roo.util.Observable",
96       "example" : "",
97       "deprecated" : "",
98       "since" : "",
99       "see" : "",
100       "params" : [],
101       "returns" : []
102     },
103     {
104       "name" : "on",
105       "desc" : "Appends an event handler to this element (shorthand for addListener)",
106       "isStatic" : false,
107       "isConstructor" : false,
108       "isPrivate" : false,
109       "memberOf" : "Roo.util.Observable",
110       "example" : "",
111       "deprecated" : "",
112       "since" : "",
113       "see" : "",
114       "params" : [
115         {
116           "name" : "eventName",
117           "type" : "String",
118           "desc" : "The type of event to listen for",
119           "isOptional" : false
120         },
121         {
122           "name" : "handler",
123           "type" : "Function",
124           "desc" : "The method the event invokes",
125           "isOptional" : false
126         },
127         {
128           "name" : "scope",
129           "type" : "Object",
130           "desc" : "(optional) The scope in which to execute the handler\nfunction. The handler function's \"this\" context.",
131           "isOptional" : false
132         },
133         {
134           "name" : "options",
135           "type" : "Object",
136           "desc" : "(optional)",
137           "isOptional" : false
138         }
139       ],
140       "returns" : []
141     },
142     {
143       "name" : "un",
144       "desc" : "Removes a listener (shorthand for removeListener)",
145       "isStatic" : false,
146       "isConstructor" : false,
147       "isPrivate" : false,
148       "memberOf" : "Roo.util.Observable",
149       "example" : "",
150       "deprecated" : "",
151       "since" : "",
152       "see" : "",
153       "params" : [
154         {
155           "name" : "eventName",
156           "type" : "String",
157           "desc" : "The type of event to listen for",
158           "isOptional" : false
159         },
160         {
161           "name" : "handler",
162           "type" : "Function",
163           "desc" : "The handler to remove",
164           "isOptional" : false
165         },
166         {
167           "name" : "scope",
168           "type" : "Object",
169           "desc" : "(optional) The scope (this object) for the handler",
170           "isOptional" : false
171         }
172       ],
173       "returns" : []
174     },
175     {
176       "name" : "addEvents",
177       "desc" : "Used to define events on this Observable",
178       "isStatic" : false,
179       "isConstructor" : false,
180       "isPrivate" : false,
181       "memberOf" : "Roo.util.Observable",
182       "example" : "",
183       "deprecated" : "",
184       "since" : "",
185       "see" : "",
186       "params" : [
187         {
188           "name" : "object",
189           "type" : "Object",
190           "desc" : "The object with the events defined",
191           "isOptional" : false
192         }
193       ],
194       "returns" : []
195     },
196     {
197       "name" : "releaseCapture",
198       "desc" : "Removes <b>all</b> added captures from the Observable.",
199       "isStatic" : true,
200       "isConstructor" : false,
201       "isPrivate" : false,
202       "memberOf" : "Roo.util.Observable",
203       "example" : "",
204       "deprecated" : "",
205       "since" : "",
206       "see" : "",
207       "params" : [
208         {
209           "name" : "o",
210           "type" : "Observable",
211           "desc" : "The Observable to release",
212           "isOptional" : false
213         }
214       ],
215       "returns" : []
216     },
217     {
218       "name" : "removeListener",
219       "desc" : "Removes a listener",
220       "isStatic" : false,
221       "isConstructor" : false,
222       "isPrivate" : false,
223       "memberOf" : "Roo.util.Observable",
224       "example" : "",
225       "deprecated" : "",
226       "since" : "",
227       "see" : "",
228       "params" : [
229         {
230           "name" : "eventName",
231           "type" : "String",
232           "desc" : "The type of event to listen for",
233           "isOptional" : false
234         },
235         {
236           "name" : "handler",
237           "type" : "Function",
238           "desc" : "The handler to remove",
239           "isOptional" : false
240         },
241         {
242           "name" : "scope",
243           "type" : "Object",
244           "desc" : "(optional) The scope (this object) for the handler",
245           "isOptional" : false
246         }
247       ],
248       "returns" : []
249     },
250     {
251       "name" : "fireEvent",
252       "desc" : "Fires the specified event with the passed parameters (minus the event name).",
253       "isStatic" : false,
254       "isConstructor" : false,
255       "isPrivate" : false,
256       "memberOf" : "Roo.util.Observable",
257       "example" : "",
258       "deprecated" : "",
259       "since" : "",
260       "see" : "",
261       "params" : [
262         {
263           "name" : "eventName",
264           "type" : "String",
265           "desc" : "",
266           "isOptional" : false
267         },
268         {
269           "name" : "args",
270           "type" : "Object...",
271           "desc" : "Variable number of parameters are passed to handlers",
272           "isOptional" : false
273         }
274       ],
275       "returns" : [
276         {
277           "name" : "",
278           "type" : "Boolean",
279           "desc" : "returns false if any of the handlers return false otherwise it returns true"
280         }
281       ]
282     },
283     {
284       "name" : "hasListener",
285       "desc" : "Checks to see if this object has any listeners for a specified event",
286       "isStatic" : false,
287       "isConstructor" : false,
288       "isPrivate" : false,
289       "memberOf" : "Roo.util.Observable",
290       "example" : "",
291       "deprecated" : "",
292       "since" : "",
293       "see" : "",
294       "params" : [
295         {
296           "name" : "eventName",
297           "type" : "String",
298           "desc" : "The name of the event to check for",
299           "isOptional" : false
300         }
301       ],
302       "returns" : [
303         {
304           "name" : "",
305           "type" : "Boolean",
306           "desc" : "True if the event is being listened for, else false"
307         }
308       ]
309     },
310     {
311       "name" : "capture",
312       "desc" : "Starts capture on the specified Observable. All events will be passed\nto the supplied function with the event name + standard signature of the event\n<b>before</b> the event is fired. If the supplied function returns false,\nthe event will not fire.",
313       "isStatic" : true,
314       "isConstructor" : false,
315       "isPrivate" : false,
316       "memberOf" : "Roo.util.Observable",
317       "example" : "",
318       "deprecated" : "",
319       "since" : "",
320       "see" : "",
321       "params" : [
322         {
323           "name" : "o",
324           "type" : "Observable",
325           "desc" : "The Observable to capture",
326           "isOptional" : false
327         },
328         {
329           "name" : "fn",
330           "type" : "Function",
331           "desc" : "The function to call",
332           "isOptional" : false
333         },
334         {
335           "name" : "scope",
336           "type" : "Object",
337           "desc" : "(optional) The scope (this object) for the fn",
338           "isOptional" : false
339         }
340       ],
341       "returns" : []
342     },
343     {
344       "name" : "addListener",
345       "desc" : "Appends an event handler to this component",
346       "isStatic" : false,
347       "isConstructor" : false,
348       "isPrivate" : false,
349       "memberOf" : "Roo.util.Observable",
350       "example" : "",
351       "deprecated" : "",
352       "since" : "",
353       "see" : "",
354       "params" : [
355         {
356           "name" : "eventName",
357           "type" : "String",
358           "desc" : "The type of event to listen for",
359           "isOptional" : false
360         },
361         {
362           "name" : "handler",
363           "type" : "Function",
364           "desc" : "The method the event invokes",
365           "isOptional" : false
366         },
367         {
368           "name" : "scope",
369           "type" : "Object",
370           "desc" : "(optional) The scope in which to execute the handler\nfunction. The handler function's \"this\" context.",
371           "isOptional" : false
372         },
373         {
374           "name" : "options",
375           "type" : "Object",
376           "desc" : "(optional) An object containing handler configuration\nproperties. This may contain any of the following properties:<ul>\n<li>scope {Object} The scope in which to execute the handler function. The handler function's \"this\" context.</li>\n<li>delay {Number} The number of milliseconds to delay the invocation of the handler after te event fires.</li>\n<li>single {Boolean} True to add a handler to handle just the next firing of the event, and then remove itself.</li>\n<li>buffer {Number} Causes the handler to be scheduled to run in an {@link Roo.util.DelayedTask} delayed\nby the specified number of milliseconds. If the event fires again within that time, the original\nhandler is <em>not</em> invoked, but the new handler is scheduled in its place.</li>\n</ul><br>\n<p>\n<b>Combining Options</b><br>\nUsing the options argument, it is possible to combine different types of listeners:<br>\n<br>\nA normalized, delayed, one-time listener that auto stops the event and passes a custom argument (forumId)\n\t\t<pre><code>\n\t\tel.on('click', this.onClick, this, {\n \t\t\tsingle: true,\n    \t\tdelay: 100,\n    \t\tforumId: 4\n\t\t});\n\t\t</code></pre>\n<p>\n<b>Attaching multiple handlers in 1 call</b><br>\nThe method also allows for a single argument to be passed which is a config object containing properties\nwhich specify multiple handlers.\n<pre><code>\n\t\tel.on({\n\t\t\t'click': {\n        \t\tfn: this.onClick,\n        \t\tscope: this,\n        \t\tdelay: 100\n    \t\t}, \n    \t\t'mouseover': {\n        \t\tfn: this.onMouseOver,\n        \t\tscope: this\n    \t\t},\n    \t\t'mouseout': {\n        \t\tfn: this.onMouseOut,\n        \t\tscope: this\n    \t\t}\n\t\t});\n\t\t</code></pre>\n<p>\nOr a shorthand syntax which passes the same scope object to all handlers:\n     \t<pre><code>\n\t\tel.on({\n\t\t\t'click': this.onClick,\n    \t\t'mouseover': this.onMouseOver,\n    \t\t'mouseout': this.onMouseOut,\n    \t\tscope: this\n\t\t});\n\t\t</code></pre>",
377           "isOptional" : false
378         }
379       ],
380       "returns" : []
381     }
382   ],
383   "events" : [
384     {
385       "name" : "mousedown",
386       "desc" : "Fires when the mouse button is depressed.",
387       "memberOf" : "Roo.util.ClickRepeater",
388       "example" : "",
389       "deprecated" : "",
390       "since" : "",
391       "see" : "",
392       "params" : [
393         {
394           "name" : "this",
395           "type" : "Roo.util.ClickRepeater",
396           "desc" : "",
397           "isOptional" : false
398         }
399       ],
400       "returns" : []
401     },
402     {
403       "name" : "click",
404       "desc" : "Fires on a specified interval during the time the element is pressed.",
405       "memberOf" : "Roo.util.ClickRepeater",
406       "example" : "",
407       "deprecated" : "",
408       "since" : "",
409       "see" : "",
410       "params" : [
411         {
412           "name" : "this",
413           "type" : "Roo.util.ClickRepeater",
414           "desc" : "",
415           "isOptional" : false
416         }
417       ],
418       "returns" : []
419     },
420     {
421       "name" : "mouseup",
422       "desc" : "Fires when the mouse key is released.",
423       "memberOf" : "Roo.util.ClickRepeater",
424       "example" : "",
425       "deprecated" : "",
426       "since" : "",
427       "see" : "",
428       "params" : [
429         {
430           "name" : "this",
431           "type" : "Roo.util.ClickRepeater",
432           "desc" : "",
433           "isOptional" : false
434         }
435       ],
436       "returns" : []
437     }
438   ]
439 }