enable grammerly in editor
[roojs1] / docs / symbols / Roo.TabPanelItem.json
1 {
2   "name" : "Roo.TabPanelItem",
3   "augments" : [
4     "Roo.util.Observable"
5   ],
6   "desc" : "Represents an individual item (tab plus body) in a TabPanel.",
7   "isSingleton" : false,
8   "isStatic" : false,
9   "isBuiltin" : false,
10   "memberOf" : "TabPanelItem",
11   "example" : "",
12   "deprecated" : "",
13   "since" : "",
14   "see" : "",
15   "params" : [
16     {
17       "name" : "tabPanel",
18       "type" : "Roo.TabPanel",
19       "desc" : "The {@link Roo.TabPanel} this TabPanelItem belongs to",
20       "isOptional" : false
21     },
22     {
23       "name" : "id",
24       "type" : "String",
25       "desc" : "The id of this TabPanelItem",
26       "isOptional" : false
27     },
28     {
29       "name" : "text",
30       "type" : "String",
31       "desc" : "The text for the tab of this TabPanelItem",
32       "isOptional" : false
33     },
34     {
35       "name" : "closable",
36       "type" : "Boolean",
37       "desc" : "True to allow this TabPanelItem to be closable (defaults to false)",
38       "isOptional" : false
39     }
40   ],
41   "returns" : [],
42   "config" : [
43     {
44       "name" : "listeners",
45       "type" : "Object",
46       "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>",
47       "memberOf" : "Roo.util.Observable",
48       "optvals" : []
49     }
50   ],
51   "methods" : [
52     {
53       "name" : "setUrl",
54       "desc" : "Set a URL to be used to load the content for this TabPanelItem.",
55       "isStatic" : false,
56       "isConstructor" : false,
57       "isPrivate" : false,
58       "memberOf" : "Roo.TabPanelItem",
59       "example" : "",
60       "deprecated" : "",
61       "since" : "",
62       "see" : "",
63       "params" : [
64         {
65           "name" : "url",
66           "type" : "String/Function",
67           "desc" : "The URL to load the content from, or a function to call to get the URL",
68           "isOptional" : false
69         },
70         {
71           "name" : "params",
72           "type" : "String/Object",
73           "desc" : "(optional) The string params for the update call or an object of the params. See {@link Roo.UpdateManager#update} for more details. (Defaults to null)",
74           "isOptional" : false
75         },
76         {
77           "name" : "loadOnce",
78           "type" : "Boolean",
79           "desc" : "(optional) Whether to only load the content once. If this is false it makes the Ajax call every time this TabPanelItem is activated. (Defaults to false)",
80           "isOptional" : false
81         }
82       ],
83       "returns" : [
84         {
85           "name" : "",
86           "type" : "Roo.UpdateManager",
87           "desc" : "The UpdateManager"
88         }
89       ]
90     },
91     {
92       "name" : "getText",
93       "desc" : "Returns the text for this tab",
94       "isStatic" : false,
95       "isConstructor" : false,
96       "isPrivate" : false,
97       "memberOf" : "Roo.TabPanelItem",
98       "example" : "",
99       "deprecated" : "",
100       "since" : "",
101       "see" : "",
102       "params" : [],
103       "returns" : [
104         {
105           "name" : "",
106           "type" : "String",
107           "desc" : ""
108         }
109       ]
110     },
111     {
112       "name" : "isHidden",
113       "desc" : "Returns true if this tab is \"hidden\"",
114       "isStatic" : false,
115       "isConstructor" : false,
116       "isPrivate" : false,
117       "memberOf" : "Roo.TabPanelItem",
118       "example" : "",
119       "deprecated" : "",
120       "since" : "",
121       "see" : "",
122       "params" : [],
123       "returns" : [
124         {
125           "name" : "",
126           "type" : "Boolean",
127           "desc" : ""
128         }
129       ]
130     },
131     {
132       "name" : "setText",
133       "desc" : "Sets the text for the tab (Note: this also sets the tooltip text)",
134       "isStatic" : false,
135       "isConstructor" : false,
136       "isPrivate" : false,
137       "memberOf" : "Roo.TabPanelItem",
138       "example" : "",
139       "deprecated" : "",
140       "since" : "",
141       "see" : "",
142       "params" : [
143         {
144           "name" : "text",
145           "type" : "String",
146           "desc" : "The tab's text and tooltip",
147           "isOptional" : false
148         }
149       ],
150       "returns" : []
151     },
152     {
153       "name" : "activate",
154       "desc" : "Activates this TabPanelItem -- this <b>does</b> deactivate the currently active TabPanelItem.",
155       "isStatic" : false,
156       "isConstructor" : false,
157       "isPrivate" : false,
158       "memberOf" : "Roo.TabPanelItem",
159       "example" : "",
160       "deprecated" : "",
161       "since" : "",
162       "see" : "",
163       "params" : [],
164       "returns" : []
165     },
166     {
167       "name" : "isActive",
168       "desc" : "Returns true if this tab is the active tab.",
169       "isStatic" : false,
170       "isConstructor" : false,
171       "isPrivate" : false,
172       "memberOf" : "Roo.TabPanelItem",
173       "example" : "",
174       "deprecated" : "",
175       "since" : "",
176       "see" : "",
177       "params" : [],
178       "returns" : [
179         {
180           "name" : "",
181           "type" : "Boolean",
182           "desc" : ""
183         }
184       ]
185     },
186     {
187       "name" : "setContent",
188       "desc" : "Sets the content for this TabPanelItem.",
189       "isStatic" : false,
190       "isConstructor" : false,
191       "isPrivate" : false,
192       "memberOf" : "Roo.TabPanelItem",
193       "example" : "",
194       "deprecated" : "",
195       "since" : "",
196       "see" : "",
197       "params" : [
198         {
199           "name" : "content",
200           "type" : "String",
201           "desc" : "The content",
202           "isOptional" : false
203         },
204         {
205           "name" : "loadScripts",
206           "type" : "Boolean",
207           "desc" : "true to look for and load scripts",
208           "isOptional" : false
209         }
210       ],
211       "returns" : []
212     },
213     {
214       "name" : "refresh",
215       "desc" : "Forces a content refresh from the URL specified in the {@link #setUrl} method.\n  Will fail silently if the setUrl method has not been called.\n  This does not activate the panel, just updates its content.",
216       "isStatic" : false,
217       "isConstructor" : false,
218       "isPrivate" : false,
219       "memberOf" : "Roo.TabPanelItem",
220       "example" : "",
221       "deprecated" : "",
222       "since" : "",
223       "see" : "",
224       "params" : [],
225       "returns" : []
226     },
227     {
228       "name" : "setHidden",
229       "desc" : "Show or hide the tab",
230       "isStatic" : false,
231       "isConstructor" : false,
232       "isPrivate" : false,
233       "memberOf" : "Roo.TabPanelItem",
234       "example" : "",
235       "deprecated" : "",
236       "since" : "",
237       "see" : "",
238       "params" : [
239         {
240           "name" : "hidden",
241           "type" : "Boolean",
242           "desc" : "True to hide or false to show.",
243           "isOptional" : false
244         }
245       ],
246       "returns" : []
247     },
248     {
249       "name" : "setTooltip",
250       "desc" : "Set the tooltip for the tab.",
251       "isStatic" : false,
252       "isConstructor" : false,
253       "isPrivate" : false,
254       "memberOf" : "Roo.TabPanelItem",
255       "example" : "",
256       "deprecated" : "",
257       "since" : "",
258       "see" : "",
259       "params" : [
260         {
261           "name" : "tooltip",
262           "type" : "String",
263           "desc" : "The tab's tooltip",
264           "isOptional" : false
265         }
266       ],
267       "returns" : []
268     },
269     {
270       "name" : "enable",
271       "desc" : "Enables this TabPanelItem if it was previously disabled.",
272       "isStatic" : false,
273       "isConstructor" : false,
274       "isPrivate" : false,
275       "memberOf" : "Roo.TabPanelItem",
276       "example" : "",
277       "deprecated" : "",
278       "since" : "",
279       "see" : "",
280       "params" : [],
281       "returns" : []
282     },
283     {
284       "name" : "getUpdateManager",
285       "desc" : "Gets the {@link Roo.UpdateManager} for the body of this TabPanelItem. Enables you to perform Ajax updates.",
286       "isStatic" : false,
287       "isConstructor" : false,
288       "isPrivate" : false,
289       "memberOf" : "Roo.TabPanelItem",
290       "example" : "",
291       "deprecated" : "",
292       "since" : "",
293       "see" : "",
294       "params" : [],
295       "returns" : [
296         {
297           "name" : "",
298           "type" : "Roo.UpdateManager",
299           "desc" : "The UpdateManager"
300         }
301       ]
302     },
303     {
304       "name" : "disable",
305       "desc" : "Disables this TabPanelItem -- this does nothing if this is the active TabPanelItem.",
306       "isStatic" : false,
307       "isConstructor" : false,
308       "isPrivate" : false,
309       "memberOf" : "Roo.TabPanelItem",
310       "example" : "",
311       "deprecated" : "",
312       "since" : "",
313       "see" : "",
314       "params" : [],
315       "returns" : []
316     },
317     {
318       "name" : "hide",
319       "desc" : "Hides this TabPanelItem -- if you don't activate another TabPanelItem this could look odd.",
320       "isStatic" : false,
321       "isConstructor" : false,
322       "isPrivate" : false,
323       "memberOf" : "Roo.TabPanelItem",
324       "example" : "",
325       "deprecated" : "",
326       "since" : "",
327       "see" : "",
328       "params" : [],
329       "returns" : []
330     },
331     {
332       "name" : "show",
333       "desc" : "Shows this TabPanelItem -- this <b>does not</b> deactivate the currently active TabPanelItem.",
334       "isStatic" : false,
335       "isConstructor" : false,
336       "isPrivate" : false,
337       "memberOf" : "Roo.TabPanelItem",
338       "example" : "",
339       "deprecated" : "",
340       "since" : "",
341       "see" : "",
342       "params" : [],
343       "returns" : []
344     },
345     {
346       "name" : "purgeListeners",
347       "desc" : "Removes all listeners for this object",
348       "isStatic" : false,
349       "isConstructor" : false,
350       "isPrivate" : false,
351       "memberOf" : "Roo.util.Observable",
352       "example" : "",
353       "deprecated" : "",
354       "since" : "",
355       "see" : "",
356       "params" : [],
357       "returns" : []
358     },
359     {
360       "name" : "on",
361       "desc" : "Appends an event handler to this element (shorthand for addListener)",
362       "isStatic" : false,
363       "isConstructor" : false,
364       "isPrivate" : false,
365       "memberOf" : "Roo.util.Observable",
366       "example" : "",
367       "deprecated" : "",
368       "since" : "",
369       "see" : "",
370       "params" : [
371         {
372           "name" : "eventName",
373           "type" : "String",
374           "desc" : "The type of event to listen for",
375           "isOptional" : false
376         },
377         {
378           "name" : "handler",
379           "type" : "Function",
380           "desc" : "The method the event invokes",
381           "isOptional" : false
382         },
383         {
384           "name" : "scope",
385           "type" : "Object",
386           "desc" : "(optional) The scope in which to execute the handler\nfunction. The handler function's \"this\" context.",
387           "isOptional" : false
388         },
389         {
390           "name" : "options",
391           "type" : "Object",
392           "desc" : "(optional)",
393           "isOptional" : false
394         }
395       ],
396       "returns" : []
397     },
398     {
399       "name" : "un",
400       "desc" : "Removes a listener (shorthand for removeListener)",
401       "isStatic" : false,
402       "isConstructor" : false,
403       "isPrivate" : false,
404       "memberOf" : "Roo.util.Observable",
405       "example" : "",
406       "deprecated" : "",
407       "since" : "",
408       "see" : "",
409       "params" : [
410         {
411           "name" : "eventName",
412           "type" : "String",
413           "desc" : "The type of event to listen for",
414           "isOptional" : false
415         },
416         {
417           "name" : "handler",
418           "type" : "Function",
419           "desc" : "The handler to remove",
420           "isOptional" : false
421         },
422         {
423           "name" : "scope",
424           "type" : "Object",
425           "desc" : "(optional) The scope (this object) for the handler",
426           "isOptional" : false
427         }
428       ],
429       "returns" : []
430     },
431     {
432       "name" : "addEvents",
433       "desc" : "Used to define events on this Observable",
434       "isStatic" : false,
435       "isConstructor" : false,
436       "isPrivate" : false,
437       "memberOf" : "Roo.util.Observable",
438       "example" : "",
439       "deprecated" : "",
440       "since" : "",
441       "see" : "",
442       "params" : [
443         {
444           "name" : "object",
445           "type" : "Object",
446           "desc" : "The object with the events defined",
447           "isOptional" : false
448         }
449       ],
450       "returns" : []
451     },
452     {
453       "name" : "releaseCapture",
454       "desc" : "Removes <b>all</b> added captures from the Observable.",
455       "isStatic" : true,
456       "isConstructor" : false,
457       "isPrivate" : false,
458       "memberOf" : "Roo.util.Observable",
459       "example" : "",
460       "deprecated" : "",
461       "since" : "",
462       "see" : "",
463       "params" : [
464         {
465           "name" : "o",
466           "type" : "Observable",
467           "desc" : "The Observable to release",
468           "isOptional" : false
469         }
470       ],
471       "returns" : []
472     },
473     {
474       "name" : "removeListener",
475       "desc" : "Removes a listener",
476       "isStatic" : false,
477       "isConstructor" : false,
478       "isPrivate" : false,
479       "memberOf" : "Roo.util.Observable",
480       "example" : "",
481       "deprecated" : "",
482       "since" : "",
483       "see" : "",
484       "params" : [
485         {
486           "name" : "eventName",
487           "type" : "String",
488           "desc" : "The type of event to listen for",
489           "isOptional" : false
490         },
491         {
492           "name" : "handler",
493           "type" : "Function",
494           "desc" : "The handler to remove",
495           "isOptional" : false
496         },
497         {
498           "name" : "scope",
499           "type" : "Object",
500           "desc" : "(optional) The scope (this object) for the handler",
501           "isOptional" : false
502         }
503       ],
504       "returns" : []
505     },
506     {
507       "name" : "fireEvent",
508       "desc" : "Fires the specified event with the passed parameters (minus the event name).",
509       "isStatic" : false,
510       "isConstructor" : false,
511       "isPrivate" : false,
512       "memberOf" : "Roo.util.Observable",
513       "example" : "",
514       "deprecated" : "",
515       "since" : "",
516       "see" : "",
517       "params" : [
518         {
519           "name" : "eventName",
520           "type" : "String",
521           "desc" : "",
522           "isOptional" : false
523         },
524         {
525           "name" : "args",
526           "type" : "Object...",
527           "desc" : "Variable number of parameters are passed to handlers",
528           "isOptional" : false
529         }
530       ],
531       "returns" : [
532         {
533           "name" : "",
534           "type" : "Boolean",
535           "desc" : "returns false if any of the handlers return false otherwise it returns true"
536         }
537       ]
538     },
539     {
540       "name" : "hasListener",
541       "desc" : "Checks to see if this object has any listeners for a specified event",
542       "isStatic" : false,
543       "isConstructor" : false,
544       "isPrivate" : false,
545       "memberOf" : "Roo.util.Observable",
546       "example" : "",
547       "deprecated" : "",
548       "since" : "",
549       "see" : "",
550       "params" : [
551         {
552           "name" : "eventName",
553           "type" : "String",
554           "desc" : "The name of the event to check for",
555           "isOptional" : false
556         }
557       ],
558       "returns" : [
559         {
560           "name" : "",
561           "type" : "Boolean",
562           "desc" : "True if the event is being listened for, else false"
563         }
564       ]
565     },
566     {
567       "name" : "capture",
568       "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.",
569       "isStatic" : true,
570       "isConstructor" : false,
571       "isPrivate" : false,
572       "memberOf" : "Roo.util.Observable",
573       "example" : "",
574       "deprecated" : "",
575       "since" : "",
576       "see" : "",
577       "params" : [
578         {
579           "name" : "o",
580           "type" : "Observable",
581           "desc" : "The Observable to capture",
582           "isOptional" : false
583         },
584         {
585           "name" : "fn",
586           "type" : "Function",
587           "desc" : "The function to call",
588           "isOptional" : false
589         },
590         {
591           "name" : "scope",
592           "type" : "Object",
593           "desc" : "(optional) The scope (this object) for the fn",
594           "isOptional" : false
595         }
596       ],
597       "returns" : []
598     },
599     {
600       "name" : "addListener",
601       "desc" : "Appends an event handler to this component",
602       "isStatic" : false,
603       "isConstructor" : false,
604       "isPrivate" : false,
605       "memberOf" : "Roo.util.Observable",
606       "example" : "",
607       "deprecated" : "",
608       "since" : "",
609       "see" : "",
610       "params" : [
611         {
612           "name" : "eventName",
613           "type" : "String",
614           "desc" : "The type of event to listen for",
615           "isOptional" : false
616         },
617         {
618           "name" : "handler",
619           "type" : "Function",
620           "desc" : "The method the event invokes",
621           "isOptional" : false
622         },
623         {
624           "name" : "scope",
625           "type" : "Object",
626           "desc" : "(optional) The scope in which to execute the handler\nfunction. The handler function's \"this\" context.",
627           "isOptional" : false
628         },
629         {
630           "name" : "options",
631           "type" : "Object",
632           "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>",
633           "isOptional" : false
634         }
635       ],
636       "returns" : []
637     }
638   ],
639   "events" : [
640     {
641       "name" : "beforeclose",
642       "desc" : "Fires before this tab is closed. To cancel the close, set cancel to true on e (e.cancel = true).",
643       "memberOf" : "Roo.TabPanelItem",
644       "example" : "",
645       "deprecated" : "",
646       "since" : "",
647       "see" : "",
648       "params" : [
649         {
650           "name" : "this",
651           "type" : "Roo.TabPanelItem",
652           "desc" : "",
653           "isOptional" : false
654         },
655         {
656           "name" : "e",
657           "type" : "Object",
658           "desc" : "Set cancel to true on this object to cancel the close.",
659           "isOptional" : false
660         }
661       ],
662       "returns" : []
663     },
664     {
665       "name" : "close",
666       "desc" : "Fires when this tab is closed.",
667       "memberOf" : "Roo.TabPanelItem",
668       "example" : "",
669       "deprecated" : "",
670       "since" : "",
671       "see" : "",
672       "params" : [
673         {
674           "name" : "this",
675           "type" : "Roo.TabPanelItem",
676           "desc" : "",
677           "isOptional" : false
678         }
679       ],
680       "returns" : []
681     },
682     {
683       "name" : "activate",
684       "desc" : "Fires when this tab becomes the active tab.",
685       "memberOf" : "Roo.TabPanelItem",
686       "example" : "",
687       "deprecated" : "",
688       "since" : "",
689       "see" : "",
690       "params" : [
691         {
692           "name" : "tabPanel",
693           "type" : "Roo.TabPanel",
694           "desc" : "The parent TabPanel",
695           "isOptional" : false
696         },
697         {
698           "name" : "this",
699           "type" : "Roo.TabPanelItem",
700           "desc" : "",
701           "isOptional" : false
702         }
703       ],
704       "returns" : []
705     },
706     {
707       "name" : "deactivate",
708       "desc" : "Fires when this tab is no longer the active tab.",
709       "memberOf" : "Roo.TabPanelItem",
710       "example" : "",
711       "deprecated" : "",
712       "since" : "",
713       "see" : "",
714       "params" : [
715         {
716           "name" : "tabPanel",
717           "type" : "Roo.TabPanel",
718           "desc" : "The parent TabPanel",
719           "isOptional" : false
720         },
721         {
722           "name" : "this",
723           "type" : "Roo.TabPanelItem",
724           "desc" : "",
725           "isOptional" : false
726         }
727       ],
728       "returns" : []
729     }
730   ]
731 }