2 "name" : "Roo.BasicDialog",
13 "desc" : "Lightweight Dialog Class. The code below shows the creation of a typical dialog using existing HTML markup:\n<pre><code>\nvar dlg = new Roo.BasicDialog(\"my-dlg\", {\n height: 200,\n width: 300,\n minHeight: 100,\n minWidth: 150,\n modal: true,\n proxyDrag: true,\n shadow: true\n});\ndlg.addKeyListener(27, dlg.hide, dlg); // ESC can also close the dialog\ndlg.addButton('OK', dlg.hide, dlg); // Could call a save function instead of hiding\ndlg.addButton('Cancel', dlg.hide, dlg);\ndlg.show();\n</code></pre>\n <b>A Dialog should always be a direct child of the body element.</b>",
14 "isSingleton" : false,
18 "isBuilderTop" : false,
19 "memberOf" : "BasicDialog",
27 "type" : "String/HTMLElement/Roo.Element",
28 "desc" : "The container element or DOM node, or its id",
34 "desc" : "Configuration options",
45 "desc" : "The default top page coordinate of the dialog (defaults to center screen)",
51 "desc" : "True to show the dialog modally, preventing user interaction with the rest of the page (defaults to false)",
57 "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>",
58 "memberOf" : "Roo.util.Observable"
61 "name" : "animateTarget",
62 "type" : "String/Element",
63 "desc" : "Id or element from which the dialog should animate while opening\n(defaults to null with no animation)",
68 "type" : "Boolean/String",
69 "desc" : "True or \"sides\" for the default effect, \"frame\" for 4-way shadow, and \"drop\" for bottom-right\nshadow (defaults to false)",
73 "name" : "autoScroll",
75 "desc" : "True to allow the dialog body contents to overflow and display scrollbars (defaults to false)",
79 "name" : "collapsible",
81 "desc" : "False to remove the built-in top-right corner collapse button (defaults to true)",
87 "desc" : "If true, all elements with class 'x-dlg-tab' will get automatically converted to tabs (defaults to false)",
91 "name" : "shadowOffset",
93 "desc" : "The number of pixels to offset the shadow if displayed (defaults to 5)",
99 "desc" : "Array of buttons",
103 "name" : "minButtonWidth",
105 "desc" : "Minimum width of all dialog buttons (defaults to 75)",
111 "desc" : "Default text to display in the title bar (defaults to null)",
117 "desc" : "The minimum allowable width for a resizable dialog (defaults to 200)",
121 "name" : "buttonAlign",
123 "desc" : "Valid values are \"left,\" \"center\" and \"right\" (defaults to \"right\")",
127 "name" : "autoCreate",
128 "type" : "Boolean/DomHelper",
129 "desc" : "True to auto create from scratch, or using a DomHelper Object (defaults to false)",
133 "name" : "minHeight",
135 "desc" : "The minimum allowable height for a resizable dialog (defaults to 80)",
139 "name" : "proxyDrag",
141 "desc" : "True to drag a lightweight proxy element rather than the dialog itself, used when\ndraggable = true (defaults to false)",
147 "desc" : "True to create an iframe shim that prevents selects from showing through (defaults to false)",
153 "desc" : "Width of the dialog in pixels (can also be set via CSS). Determined by browser if unspecified.",
157 "name" : "constraintoviewport",
159 "desc" : "True to keep the dialog constrained within the visible viewport boundaries (defaults to true)",
163 "name" : "syncHeightBeforeShow",
165 "desc" : "True to cause the dimensions to be recalculated before the dialog is shown (defaults to false)",
171 "desc" : "The tag name of tab elements, used when autoTabs = true (defaults to 'div')",
175 "name" : "resizable",
177 "desc" : "False to disable manual dialog resizing (defaults to true)",
183 "desc" : "False to remove the built-in top-right corner close button (defaults to true)",
187 "name" : "fixedcenter",
189 "desc" : "True to ensure that anytime the dialog is shown or resized it gets centered (defaults to false)",
195 "desc" : "Height of the dialog in pixels (can also be set via CSS). Determined by browser if unspecified.",
199 "name" : "resizeHandles",
201 "desc" : "Which resize handles to display - see the {@link Roo.Resizable} handles config\nproperty for valid values (defaults to 'all')",
207 "desc" : "The default left page coordinate of the dialog (defaults to center screen)",
211 "name" : "draggable",
213 "desc" : "False to disable dragging of the dialog within the viewport (defaults to true)",
221 "desc" : "Expands a collapsed dialog back to its normal state. Equivalent to the user\nclicking the expand dialog button.",
222 "sig" : "()\n{\n\n}",
226 "isConstructor" : false,
240 "desc" : "Aligns the dialog to the specified element",
241 "sig" : "(element, position, offsets)",
245 "isConstructor" : false,
256 "type" : "String/HTMLElement/Roo.Element",
257 "desc" : "The element to align to.",
263 "desc" : "The position to align to (see {@link Roo.Element#alignTo} for more details).",
269 "desc" : "(optional) Offset the positioning by [x, y]",
276 "type" : "Roo.BasicDialog",
284 "desc" : "Sets the dialog title text",
289 "isConstructor" : false,
301 "desc" : "The title text to display",
308 "type" : "Roo.BasicDialog",
314 "name" : "isVisible",
316 "desc" : "Returns true if the dialog is visible",
317 "sig" : "()\n{\n\n}",
321 "isConstructor" : false,
341 "desc" : "Resizes the dialog.",
342 "sig" : "(width, height)",
346 "isConstructor" : false,
371 "type" : "Roo.BasicDialog",
379 "desc" : "Centers this dialog in the viewport",
380 "sig" : "()\n{\n\n}",
384 "isConstructor" : false,
396 "type" : "Roo.BasicDialog",
404 "desc" : "Collapses the dialog to its minimized state (only the title bar is visible).\nEquivalent to the user clicking the collapse dialog button.",
405 "sig" : "()\n{\n\n}",
409 "isConstructor" : false,
423 "desc" : "Reinitializes the tabs component, clearing out old tabs and finding new ones.",
424 "sig" : "()\n{\n\n}",
428 "isConstructor" : false,
440 "type" : "Roo.TabPanel",
441 "desc" : "The tabs component"
448 "desc" : "Brings this dialog to the front of any other visible dialogs",
449 "sig" : "()\n{\n\n}",
453 "isConstructor" : false,
465 "type" : "Roo.BasicDialog",
473 "desc" : "Moves the dialog's top-left corner to the specified point",
478 "isConstructor" : false,
503 "type" : "Roo.BasicDialog",
511 "desc" : "Hides the dialog.",
512 "sig" : "(callback)",
516 "isConstructor" : false,
528 "desc" : "(optional) Function to call when the dialog is hidden",
535 "type" : "Roo.BasicDialog",
543 "desc" : "Destroys this dialog and all its supporting elements (including any tabs, shim,\nshadow, proxy, mask, etc.) Also removes all event listeners.",
544 "sig" : "(removeEl)",
548 "isConstructor" : false,
560 "desc" : "(optional) true to remove the element from the DOM",
569 "desc" : "Shows the dialog.",
570 "sig" : "(animateTarget)",
574 "isConstructor" : false,
584 "name" : "animateTarget",
585 "type" : "String/HTMLElement/Roo.Element",
586 "desc" : "(optional) Reset the animation target",
593 "type" : "Roo.BasicDialog",
601 "desc" : "Anchors an element to another element and realigns it when the window is resized.",
602 "sig" : "(element, position, offsets, monitorScroll)",
606 "isConstructor" : false,
617 "type" : "String/HTMLElement/Roo.Element",
618 "desc" : "The element to align to.",
624 "desc" : "The position to align to (see {@link Roo.Element#alignTo} for more details)",
630 "desc" : "(optional) Offset the positioning by [x, y]",
634 "name" : "monitorScroll",
635 "type" : "Boolean/Number",
636 "desc" : "(optional) true to monitor body scroll and reposition. If this parameter\nis a number, it is used as the buffer delay (defaults to 50ms).",
643 "type" : "Roo.BasicDialog",
649 "name" : "addButton",
651 "desc" : "Adds a button to the footer section of the dialog.",
652 "sig" : "(config, handler, scope)",
656 "isConstructor" : false,
667 "type" : "String/Object",
668 "desc" : "A string becomes the button text, an object can either be a Button config\nobject or a valid Roo.DomHelper element config",
674 "desc" : "The function called when the button is clicked",
680 "desc" : "(optional) The scope of the handler function (accepts position as a property)",
687 "type" : "Roo.Button",
688 "desc" : "The new button"
693 "name" : "addKeyListener",
695 "desc" : "Adds a key listener for when this dialog is displayed. This allows you to hook in a function that will be\nexecuted in response to a particular key being pressed while the dialog is active.",
696 "sig" : "(key, fn, scope)",
700 "isConstructor" : false,
711 "type" : "Number/Array/Object",
712 "desc" : "Either the numeric key code, array of key codes or an object with the following options:\n {key: (number or array), shift: (true/false), ctrl: (true/false), alt: (true/false)}",
718 "desc" : "The function to call",
724 "desc" : "(optional) The scope of the function",
731 "type" : "Roo.BasicDialog",
739 "desc" : "Focuses the dialog. If a defaultButton is set, it will receive focus, otherwise the\ndialog itself will receive focus.",
740 "sig" : "()\n{\n\n}",
744 "isConstructor" : false,
758 "desc" : "Returns the TabPanel component (creates it if it doesn't exist).\nNote: If you wish to simply check for the existence of tabs without creating them,\ncheck for a null 'tabs' property.",
759 "sig" : "()\n{\n\n}",
763 "isConstructor" : false,
775 "type" : "Roo.TabPanel",
776 "desc" : "The tabs component"
781 "name" : "setDefaultButton",
783 "desc" : "Sets the default button to be focused when the dialog is displayed.",
788 "isConstructor" : false,
799 "type" : "Roo.BasicDialog.Button",
800 "desc" : "The button object returned by {@link #addButton}",
807 "type" : "Roo.BasicDialog",
815 "desc" : "Sends this dialog to the back (under) of any other visible dialogs",
816 "sig" : "()\n{\n\n}",
820 "isConstructor" : false,
832 "type" : "Roo.BasicDialog",
838 "name" : "setContentSize",
840 "desc" : "Resizes the dialog to fit the specified content size.",
841 "sig" : "(width, height)",
845 "isConstructor" : false,
870 "type" : "Roo.BasicDialog",
876 "name" : "restoreState",
878 "desc" : "Restores the previous state of the dialog if Roo.state is configured.",
879 "sig" : "()\n{\n\n}",
883 "isConstructor" : false,
895 "type" : "Roo.BasicDialog",
903 "desc" : "Returns the element for this dialog",
904 "sig" : "()\n{\n\n}",
908 "isConstructor" : false,
920 "type" : "Roo.Element",
921 "desc" : "The underlying dialog Element"
926 "name" : "purgeListeners",
928 "desc" : "Removes all listeners for this object",
929 "sig" : "()\n{\n\n}",
931 "memberOf" : "Roo.util.Observable",
933 "isConstructor" : false,
947 "desc" : "Appends an event handler to this element (shorthand for addListener)",
948 "sig" : "(eventName, handler, scope, options)",
950 "memberOf" : "Roo.util.Observable",
952 "isConstructor" : false,
962 "name" : "eventName",
964 "desc" : "The type of event to listen for",
970 "desc" : "The method the event invokes",
976 "desc" : "(optional) The scope in which to execute the handler\nfunction. The handler function's \"this\" context.",
982 "desc" : "(optional)",
991 "desc" : "Removes a listener (shorthand for removeListener)",
992 "sig" : "(eventName, handler, scope)",
994 "memberOf" : "Roo.util.Observable",
996 "isConstructor" : false,
1006 "name" : "eventName",
1008 "desc" : "The type of event to listen for",
1009 "isOptional" : false
1013 "type" : "Function",
1014 "desc" : "The handler to remove",
1015 "isOptional" : false
1020 "desc" : "(optional) The scope (this object) for the handler",
1021 "isOptional" : false
1027 "name" : "addEvents",
1028 "type" : "function",
1029 "desc" : "Used to define events on this Observable",
1032 "memberOf" : "Roo.util.Observable",
1034 "isConstructor" : false,
1035 "isPrivate" : false,
1046 "desc" : "The object with the events defined",
1047 "isOptional" : false
1053 "name" : "releaseCapture",
1054 "type" : "function",
1055 "desc" : "Removes <b>all</b> added captures from the Observable.",
1058 "memberOf" : "Roo.util.Observable",
1060 "isConstructor" : false,
1061 "isPrivate" : false,
1071 "type" : "Observable",
1072 "desc" : "The Observable to release",
1073 "isOptional" : false
1079 "name" : "removeListener",
1080 "type" : "function",
1081 "desc" : "Removes a listener",
1082 "sig" : "(eventName, handler, scope)",
1084 "memberOf" : "Roo.util.Observable",
1086 "isConstructor" : false,
1087 "isPrivate" : false,
1096 "name" : "eventName",
1098 "desc" : "The type of event to listen for",
1099 "isOptional" : false
1103 "type" : "Function",
1104 "desc" : "The handler to remove",
1105 "isOptional" : false
1110 "desc" : "(optional) The scope (this object) for the handler",
1111 "isOptional" : false
1117 "name" : "fireEvent",
1118 "type" : "function",
1119 "desc" : "Fires the specified event with the passed parameters (minus the event name).",
1120 "sig" : "(eventName, args)",
1122 "memberOf" : "Roo.util.Observable",
1124 "isConstructor" : false,
1125 "isPrivate" : false,
1134 "name" : "eventName",
1137 "isOptional" : false
1141 "type" : "Object...",
1142 "desc" : "Variable number of parameters are passed to handlers",
1143 "isOptional" : false
1150 "desc" : "returns false if any of the handlers return false otherwise it returns true"
1155 "name" : "hasListener",
1156 "type" : "function",
1157 "desc" : "Checks to see if this object has any listeners for a specified event",
1158 "sig" : "(eventName)",
1160 "memberOf" : "Roo.util.Observable",
1162 "isConstructor" : false,
1163 "isPrivate" : false,
1172 "name" : "eventName",
1174 "desc" : "The name of the event to check for",
1175 "isOptional" : false
1182 "desc" : "True if the event is being listened for, else false"
1188 "type" : "function",
1189 "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.",
1190 "sig" : "(o, fn, scope)",
1192 "memberOf" : "Roo.util.Observable",
1194 "isConstructor" : false,
1195 "isPrivate" : false,
1205 "type" : "Observable",
1206 "desc" : "The Observable to capture",
1207 "isOptional" : false
1211 "type" : "Function",
1212 "desc" : "The function to call",
1213 "isOptional" : false
1218 "desc" : "(optional) The scope (this object) for the fn",
1219 "isOptional" : false
1225 "name" : "addListener",
1226 "type" : "function",
1227 "desc" : "Appends an event handler to this component",
1228 "sig" : "(eventName, handler, scope, options)",
1230 "memberOf" : "Roo.util.Observable",
1232 "isConstructor" : false,
1233 "isPrivate" : false,
1242 "name" : "eventName",
1244 "desc" : "The type of event to listen for",
1245 "isOptional" : false
1249 "type" : "Function",
1250 "desc" : "The method the event invokes",
1251 "isOptional" : false
1256 "desc" : "(optional) The scope in which to execute the handler\nfunction. The handler function's \"this\" context.",
1257 "isOptional" : false
1262 "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>",
1263 "isOptional" : false
1272 "type" : "function",
1273 "desc" : "Fires when this dialog is moved by the user.",
1274 "sig" : "function (_self, x, y)\n{\n\n}",
1283 "type" : "Roo.BasicDialog",
1285 "isOptional" : false
1290 "desc" : "The new page X",
1291 "isOptional" : false
1296 "desc" : "The new page Y",
1297 "isOptional" : false
1304 "type" : "function",
1305 "desc" : "Fires when this dialog is resized by the user.",
1306 "sig" : "function (_self, width, height)\n{\n\n}",
1315 "type" : "Roo.BasicDialog",
1317 "isOptional" : false
1322 "desc" : "The new width",
1323 "isOptional" : false
1328 "desc" : "The new height",
1329 "isOptional" : false
1335 "name" : "beforehide",
1336 "type" : "function",
1337 "desc" : "Fires before this dialog is hidden.",
1338 "sig" : "function (_self)\n{\n\n}",
1347 "type" : "Roo.BasicDialog",
1349 "isOptional" : false
1355 "name" : "beforeshow",
1356 "type" : "function",
1357 "desc" : "Fires before this dialog is shown.",
1358 "sig" : "function (_self)\n{\n\n}",
1367 "type" : "Roo.BasicDialog",
1369 "isOptional" : false
1376 "type" : "function",
1377 "desc" : "Fires when this dialog is hidden.",
1378 "sig" : "function (_self)\n{\n\n}",
1387 "type" : "Roo.BasicDialog",
1389 "isOptional" : false
1396 "type" : "function",
1397 "desc" : "Fires when this dialog is shown.",
1398 "sig" : "function (_self)\n{\n\n}",
1407 "type" : "Roo.BasicDialog",
1409 "isOptional" : false
1416 "type" : "function",
1417 "desc" : "Fires when a key is pressed",
1418 "sig" : "function (_self, e)\n{\n\n}",
1427 "type" : "Roo.BasicDialog",
1429 "isOptional" : false
1433 "type" : "Roo.EventObject",
1435 "isOptional" : false