899 lines
No EOL
49 KiB
HTML
899 lines
No EOL
49 KiB
HTML
<!doctype html public "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
|
|
<html>
|
|
<head>
|
|
<title>YAHOO.ext.BasicDialog</title>
|
|
<link rel="stylesheet" type="text/css" href="../resources/reset.css"/>
|
|
<link rel="stylesheet" type="text/css" href="../resources/style.css" media="screen"/>
|
|
<link rel="stylesheet" type="text/css" href="../resources/print.css" media="print">
|
|
</head>
|
|
<body>
|
|
<div class="body-wrap">
|
|
<div class="top-tools"><img src="../resources/print.gif" width="16" height="16" align="absmiddle"> <a href="YAHOO.ext.BasicDialog.html" target="_blank">Print Friendly</a></div>
|
|
<h1>Class YAHOO.ext.BasicDialog</h1>
|
|
<table cellspacing="0">
|
|
<tr><td class="label">Package:</td><td>YAHOO.ext</td></tr>
|
|
<tr><td class="label">Class:</td><td>BasicDialog</td></tr>
|
|
<tr><td class="label">Extends:</td><td><a href="YAHOO.ext.util.Observable.html">Observable</a></td></tr>
|
|
<tr><td class="label">Subclasses:</td><td><a href="YAHOO.ext.LayoutDialog.html">LayoutDialog</a></td></tr>
|
|
<tr><td class="label">Defined In:</td><td><a href="BasicDialog.js.html">BasicDialog.js</a></td></tr>
|
|
</table>
|
|
<div class="description">
|
|
Lightweight Dialog Class.
|
|
The code below lists all configuration options along with the default value.
|
|
If the default value is what you want you can leave it out:
|
|
<pre><code>
|
|
var dlg = new YAHOO.ext.BasicDialog('element-id', {
|
|
width: auto,
|
|
height: auto,
|
|
x: 200, //(defaults to center screen if blank)
|
|
y: 500, //(defaults to center screen if blank)
|
|
animateTarget: null,// (no animation) This is the id or element to animate from
|
|
resizable: true,
|
|
minHeight: 80,
|
|
minWidth: 200,
|
|
modal: false,
|
|
autoScroll: true,
|
|
closable: true,
|
|
constraintoviewport: true,
|
|
draggable: true,
|
|
autoTabs: false, (if true searches child nodes for elements with class ydlg-tab and converts them to tabs)
|
|
proxyDrag: false, (drag a proxy element rather than the dialog itself)
|
|
fixedcenter: false,
|
|
shadow: false,
|
|
minButtonWidth: 75,
|
|
shim: false // true to create an iframe shim to
|
|
// keep selects from showing through
|
|
});
|
|
</code></pre> </div>
|
|
<hr />
|
|
<a name="properties"></a>
|
|
<h2>Public Properties</h2>
|
|
<table cellspacing="0" class="member-table">
|
|
<tr>
|
|
<th class="sig-header" colspan="2">Property</th>
|
|
<th class="msource-header">Defined By</th>
|
|
</tr>
|
|
<tr>
|
|
<td class="micon" rowspan="2"> </td>
|
|
<td class="sig"><a class="mlink" href="#body">body</a> : YAHOO.ext.Element</td>
|
|
<td class="msource" rowspan="2">BasicDialog</td>
|
|
</tr>
|
|
<tr>
|
|
<td class="mdesc">The body element</td>
|
|
</tr>
|
|
<tr class="alt">
|
|
<td class="micon" rowspan="2"> </td>
|
|
<td class="sig"><a class="mlink" href="#footer">footer</a> : YAHOO.ext.Element</td>
|
|
<td class="msource" rowspan="2">BasicDialog</td>
|
|
</tr>
|
|
<tr class="alt">
|
|
<td class="mdesc">The footer element</td>
|
|
</tr>
|
|
<tr>
|
|
<td class="micon" rowspan="2"> </td>
|
|
<td class="sig"><a class="mlink" href="#header">header</a> : YAHOO.ext.Element</td>
|
|
<td class="msource" rowspan="2">BasicDialog</td>
|
|
</tr>
|
|
<tr>
|
|
<td class="mdesc">The header element</td>
|
|
</tr>
|
|
<tr class="alt">
|
|
<td class="micon" rowspan="2"> </td>
|
|
<td class="sig"><a class="mlink" href="#zseed">zseed</a> : Number</td>
|
|
<td class="msource" rowspan="2">BasicDialog</td>
|
|
</tr>
|
|
<tr class="alt">
|
|
<td class="mdesc">The starting z-index for BasicDialogs - defaults to 10000</td>
|
|
</tr>
|
|
</table>
|
|
<a name="methods"></a>
|
|
<h2>Public Methods</h2>
|
|
<table cellspacing="0" class="member-table">
|
|
<tr>
|
|
<th class="sig-header" colspan="2">Method</th>
|
|
<th class="msource-header">Defined By</th>
|
|
</tr>
|
|
<tr>
|
|
<td class="micon" rowspan="2"> </td>
|
|
<td class="sig"><a class="mlink" href="#BasicDialog">BasicDialog</a>(<code>String/HTMLElement/YAHOO.ext.Element el</code>, <code>Object config</code>)</td>
|
|
<td class="msource" rowspan="2">BasicDialog</td>
|
|
</tr>
|
|
<tr>
|
|
<td class="mdesc">Create a new BasicDialog.</td>
|
|
</tr>
|
|
<tr class="alt">
|
|
<td class="micon" rowspan="2"> </td>
|
|
<td class="sig"><a class="mlink" href="#addButton">addButton</a>(<code>String/Object config</code>, <code>Function handler</code>, <span class="optional" title="Optional">[<code>Object scope</code>]</span>) : YAHOO.ext.BasicDialog.Button</td>
|
|
<td class="msource" rowspan="2">BasicDialog</td>
|
|
</tr>
|
|
<tr class="alt">
|
|
<td class="mdesc">Adds a button.</td>
|
|
</tr>
|
|
<tr>
|
|
<td class="micon" rowspan="2"> </td>
|
|
<td class="sig"><a class="mlink" href="#addKeyListener">addKeyListener</a>(<code>Number/Array/Object key</code>, <code>Function fn</code>, <span class="optional" title="Optional">[<code>Object scope</code>]</span>) : YAHOO.ext.BasicDialog</td>
|
|
<td class="msource" rowspan="2">BasicDialog</td>
|
|
</tr>
|
|
<tr>
|
|
<td class="mdesc">Adds a key listener for when this dialog is displayed</td>
|
|
</tr>
|
|
<tr class="alt">
|
|
<td class="micon inherited" title="Inherited" rowspan="2"> </td>
|
|
<td class="sig"><a class="mlink" href="#addListener">addListener</a>(<code>String eventName</code>, <code>Function handler</code>, <span class="optional" title="Optional">[<code>Object scope</code>]</span>, <span class="optional" title="Optional">[<code>boolean override</code>]</span>) : void</td>
|
|
<td class="msource" rowspan="2"><a href="YAHOO.ext.util.Observable.html#addListener">Observable</a></td>
|
|
</tr>
|
|
<tr class="alt">
|
|
<td class="mdesc">Appends an event handler to this element</td>
|
|
</tr>
|
|
<tr>
|
|
<td class="micon" rowspan="2"> </td>
|
|
<td class="sig"><a class="mlink" href="#bringToFront">bringToFront</a>(<code>String/Object dlg</code>) : YAHOO.ext.BasicDialog</td>
|
|
<td class="msource" rowspan="2">BasicDialog</td>
|
|
</tr>
|
|
<tr>
|
|
<td class="mdesc">Brings the specified dialog to the front</td>
|
|
</tr>
|
|
<tr class="alt">
|
|
<td class="micon" rowspan="2"> </td>
|
|
<td class="sig"><a class="mlink" href="#center">center</a>() : YAHOO.ext.BasicDialog</td>
|
|
<td class="msource" rowspan="2">BasicDialog</td>
|
|
</tr>
|
|
<tr class="alt">
|
|
<td class="mdesc">Centers this dialog</td>
|
|
</tr>
|
|
<tr>
|
|
<td class="micon inherited" title="Inherited" rowspan="2"> </td>
|
|
<td class="sig"><a class="mlink" href="#delayedListener">delayedListener</a>(<code>String eventName</code>, <code>Function handler</code>, <span class="optional" title="Optional">[<code>Object scope</code>]</span>, <span class="optional" title="Optional">[<code>Number delay</code>]</span>) : Function</td>
|
|
<td class="msource" rowspan="2"><a href="YAHOO.ext.util.Observable.html#delayedListener">Observable</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td class="mdesc">Appends an event handler to this element that is delayed the specified number of milliseconds.</td>
|
|
</tr>
|
|
<tr class="alt">
|
|
<td class="micon" rowspan="2"> </td>
|
|
<td class="sig"><a class="mlink" href="#destroy">destroy</a>(<span class="optional" title="Optional">[<code>Boolean removeEl</code>]</span>) : void</td>
|
|
<td class="msource" rowspan="2">BasicDialog</td>
|
|
</tr>
|
|
<tr class="alt">
|
|
<td class="mdesc">Destroys this dialog</td>
|
|
</tr>
|
|
<tr>
|
|
<td class="micon inherited" title="Inherited" rowspan="2"> </td>
|
|
<td class="sig"><a class="mlink" href="#fireEvent">fireEvent</a>(<code>String eventName</code>, <code>Object... args</code>) : Boolean</td>
|
|
<td class="msource" rowspan="2"><a href="YAHOO.ext.util.Observable.html#fireEvent">Observable</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td class="mdesc">Fires the specified event with the passed parameters (minus the event name).</td>
|
|
</tr>
|
|
<tr class="alt">
|
|
<td class="micon" rowspan="2"> </td>
|
|
<td class="sig"><a class="mlink" href="#get">get</a>(<code>String/Object id</code>) : YAHOO.ext.BasicDialog</td>
|
|
<td class="msource" rowspan="2">BasicDialog</td>
|
|
</tr>
|
|
<tr class="alt">
|
|
<td class="mdesc">Gets a registered dialog by id</td>
|
|
</tr>
|
|
<tr>
|
|
<td class="micon" rowspan="2"> </td>
|
|
<td class="sig"><a class="mlink" href="#getEl">getEl</a>() : YAHOO.ext.Element</td>
|
|
<td class="msource" rowspan="2">BasicDialog</td>
|
|
</tr>
|
|
<tr>
|
|
<td class="mdesc">Returns the element for this dialog</td>
|
|
</tr>
|
|
<tr class="alt">
|
|
<td class="micon" rowspan="2"> </td>
|
|
<td class="sig"><a class="mlink" href="#getTabs">getTabs</a>() : YAHOO.ext.TabPanel</td>
|
|
<td class="msource" rowspan="2">BasicDialog</td>
|
|
</tr>
|
|
<tr class="alt">
|
|
<td class="mdesc">Returns the TabPanel component (if autoTabs)</td>
|
|
</tr>
|
|
<tr>
|
|
<td class="micon" rowspan="2"> </td>
|
|
<td class="sig"><a class="mlink" href="#hide">hide</a>(<span class="optional" title="Optional">[<code>Function callback</code>]</span>) : YAHOO.ext.BasicDialog</td>
|
|
<td class="msource" rowspan="2">BasicDialog</td>
|
|
</tr>
|
|
<tr>
|
|
<td class="mdesc">Hides the dialog.</td>
|
|
</tr>
|
|
<tr class="alt">
|
|
<td class="micon" rowspan="2"> </td>
|
|
<td class="sig"><a class="mlink" href="#isVisible">isVisible</a>() : Boolean</td>
|
|
<td class="msource" rowspan="2">BasicDialog</td>
|
|
</tr>
|
|
<tr class="alt">
|
|
<td class="mdesc">Returns true if the dialog is visible</td>
|
|
</tr>
|
|
<tr>
|
|
<td class="micon" rowspan="2"> </td>
|
|
<td class="sig"><a class="mlink" href="#moveTo">moveTo</a>(<code>Number x</code>, <code>Number y</code>) : YAHOO.ext.BasicDialog</td>
|
|
<td class="msource" rowspan="2">BasicDialog</td>
|
|
</tr>
|
|
<tr>
|
|
<td class="mdesc">Moves the dialog to the specified point</td>
|
|
</tr>
|
|
<tr class="alt">
|
|
<td class="micon inherited" title="Inherited" rowspan="2"> </td>
|
|
<td class="sig"><a class="mlink" href="#purgeListeners">purgeListeners</a>() : void</td>
|
|
<td class="msource" rowspan="2"><a href="YAHOO.ext.util.Observable.html#purgeListeners">Observable</a></td>
|
|
</tr>
|
|
<tr class="alt">
|
|
<td class="mdesc">Removes all listeners for this object</td>
|
|
</tr>
|
|
<tr>
|
|
<td class="micon inherited" title="Inherited" rowspan="2"> </td>
|
|
<td class="sig"><a class="mlink" href="#removeListener">removeListener</a>(<code>String eventName</code>, <code>Function handler</code>, <span class="optional" title="Optional">[<code>Object scope</code>]</span>) : void</td>
|
|
<td class="msource" rowspan="2"><a href="YAHOO.ext.util.Observable.html#removeListener">Observable</a></td>
|
|
</tr>
|
|
<tr>
|
|
<td class="mdesc">Removes a listener</td>
|
|
</tr>
|
|
<tr class="alt">
|
|
<td class="micon" rowspan="2"> </td>
|
|
<td class="sig"><a class="mlink" href="#resizeTo">resizeTo</a>(<code>Number width</code>, <code>Number height</code>) : YAHOO.ext.BasicDialog</td>
|
|
<td class="msource" rowspan="2">BasicDialog</td>
|
|
</tr>
|
|
<tr class="alt">
|
|
<td class="mdesc">Resizes the dialog.</td>
|
|
</tr>
|
|
<tr>
|
|
<td class="micon" rowspan="2"> </td>
|
|
<td class="sig"><a class="mlink" href="#restoreState">restoreState</a>() : YAHOO.ext.BasicDialog</td>
|
|
<td class="msource" rowspan="2">BasicDialog</td>
|
|
</tr>
|
|
<tr>
|
|
<td class="mdesc">Restores the previous state of the dialog if YAHOO.ext.state is configured</td>
|
|
</tr>
|
|
<tr class="alt">
|
|
<td class="micon" rowspan="2"> </td>
|
|
<td class="sig"><a class="mlink" href="#sendToBack">sendToBack</a>(<code>String/Object dlg</code>) : YAHOO.ext.BasicDialog</td>
|
|
<td class="msource" rowspan="2">BasicDialog</td>
|
|
</tr>
|
|
<tr class="alt">
|
|
<td class="mdesc">Sends the specified dialog to the back</td>
|
|
</tr>
|
|
<tr>
|
|
<td class="micon" rowspan="2"> </td>
|
|
<td class="sig"><a class="mlink" href="#setDefaultButton">setDefaultButton</a>(<code>YAHOO.ext.BasicDialog.Button btn</code>) : YAHOO.ext.BasicDialog</td>
|
|
<td class="msource" rowspan="2">BasicDialog</td>
|
|
</tr>
|
|
<tr>
|
|
<td class="mdesc">Sets the default button to be focused when the dialog is displayed</td>
|
|
</tr>
|
|
<tr class="alt">
|
|
<td class="micon" rowspan="2"> </td>
|
|
<td class="sig"><a class="mlink" href="#show">show</a>(<span class="optional" title="Optional">[<code>String/HTMLElement/YAHOO.ext.Element animateTarget</code>]</span>) : YAHOO.ext.BasicDialog</td>
|
|
<td class="msource" rowspan="2">BasicDialog</td>
|
|
</tr>
|
|
<tr class="alt">
|
|
<td class="mdesc">Shows the dialog.</td>
|
|
</tr>
|
|
<tr>
|
|
<td class="micon" rowspan="2"> </td>
|
|
<td class="sig"><a class="mlink" href="#toBack">toBack</a>() : YAHOO.ext.BasicDialog</td>
|
|
<td class="msource" rowspan="2">BasicDialog</td>
|
|
</tr>
|
|
<tr>
|
|
<td class="mdesc">Sends this dialog to the back (under) of any other visible dialogs</td>
|
|
</tr>
|
|
<tr class="alt">
|
|
<td class="micon" rowspan="2"> </td>
|
|
<td class="sig"><a class="mlink" href="#toFront">toFront</a>() : YAHOO.ext.BasicDialog</td>
|
|
<td class="msource" rowspan="2">BasicDialog</td>
|
|
</tr>
|
|
<tr class="alt">
|
|
<td class="mdesc">Brings this dialog to the front of any other visible dialogs</td>
|
|
</tr>
|
|
</table>
|
|
<a name="events"></a>
|
|
<h2>Public Events</h2>
|
|
<table cellspacing="0" class="member-table">
|
|
<tr>
|
|
<th class="sig-header" colspan="2">Event</th>
|
|
<th class="msource-header">Defined By</th>
|
|
</tr>
|
|
<tr>
|
|
<td class="micon" rowspan="2"> </td>
|
|
<td class="sig"><a class="mlink" href="#event-beforehide">beforehide</a> : (<code>YAHOO.ext.BasicDialog this</code>)</td>
|
|
<td class="msource" rowspan="2">BasicDialog</td>
|
|
</tr>
|
|
<tr>
|
|
<td class="mdesc">Fires before this dialog is hidden.</td>
|
|
</tr>
|
|
<tr class="alt">
|
|
<td class="micon" rowspan="2"> </td>
|
|
<td class="sig"><a class="mlink" href="#event-beforeshow">beforeshow</a> : (<code>YAHOO.ext.BasicDialog this</code>)</td>
|
|
<td class="msource" rowspan="2">BasicDialog</td>
|
|
</tr>
|
|
<tr class="alt">
|
|
<td class="mdesc">Fires before this dialog is shown.</td>
|
|
</tr>
|
|
<tr>
|
|
<td class="micon" rowspan="2"> </td>
|
|
<td class="sig"><a class="mlink" href="#event-hide">hide</a> : (<code>YAHOO.ext.BasicDialog this</code>)</td>
|
|
<td class="msource" rowspan="2">BasicDialog</td>
|
|
</tr>
|
|
<tr>
|
|
<td class="mdesc">Fires when this dialog is hidden.</td>
|
|
</tr>
|
|
<tr class="alt">
|
|
<td class="micon" rowspan="2"> </td>
|
|
<td class="sig"><a class="mlink" href="#event-keydown">keydown</a> : (<code>YAHOO.ext.BasicDialog this</code>, <code>YAHOO.ext.EventObject e</code>)</td>
|
|
<td class="msource" rowspan="2">BasicDialog</td>
|
|
</tr>
|
|
<tr class="alt">
|
|
<td class="mdesc">Fires when a key is pressed</td>
|
|
</tr>
|
|
<tr>
|
|
<td class="micon" rowspan="2"> </td>
|
|
<td class="sig"><a class="mlink" href="#event-move">move</a> : (<code>YAHOO.ext.BasicDialog this</code>, <code>Number x</code>, <code>Number y</code>)</td>
|
|
<td class="msource" rowspan="2">BasicDialog</td>
|
|
</tr>
|
|
<tr>
|
|
<td class="mdesc">Fires when this dialog is moved by the user.</td>
|
|
</tr>
|
|
<tr class="alt">
|
|
<td class="micon" rowspan="2"> </td>
|
|
<td class="sig"><a class="mlink" href="#event-resize">resize</a> : (<code>YAHOO.ext.BasicDialog this</code>, <code>Number width</code>, <code>Number height</code>)</td>
|
|
<td class="msource" rowspan="2">BasicDialog</td>
|
|
</tr>
|
|
<tr class="alt">
|
|
<td class="mdesc">Fires when this dialog is resized by the user.</td>
|
|
</tr>
|
|
<tr>
|
|
<td class="micon" rowspan="2"> </td>
|
|
<td class="sig"><a class="mlink" href="#event-show">show</a> : (<code>YAHOO.ext.BasicDialog this</code>)</td>
|
|
<td class="msource" rowspan="2">BasicDialog</td>
|
|
</tr>
|
|
<tr>
|
|
<td class="mdesc">Fires when this dialog is shown.</td>
|
|
</tr>
|
|
</table>
|
|
|
|
<h2 class="mdetail-head">Property Details</h2>
|
|
<div class="detail-wrap">
|
|
<a name="body"></a>
|
|
<div class="mdetail">
|
|
<h3>body</i></h3>
|
|
<code>public YAHOO.ext.Element body</code>
|
|
<div class="mdetail-desc">
|
|
The body element </div>
|
|
<div class="mdetail-def">This property is defined by BasicDialog.</div>
|
|
</div>
|
|
<a name="footer"></a>
|
|
<div class="mdetail alt">
|
|
<h3>footer</i></h3>
|
|
<code>public YAHOO.ext.Element footer</code>
|
|
<div class="mdetail-desc">
|
|
The footer element </div>
|
|
<div class="mdetail-def">This property is defined by BasicDialog.</div>
|
|
</div>
|
|
<a name="header"></a>
|
|
<div class="mdetail">
|
|
<h3>header</i></h3>
|
|
<code>public YAHOO.ext.Element header</code>
|
|
<div class="mdetail-desc">
|
|
The header element </div>
|
|
<div class="mdetail-def">This property is defined by BasicDialog.</div>
|
|
</div>
|
|
<a name="zseed"></a>
|
|
<div class="mdetail alt">
|
|
<h3>zseed</i></h3>
|
|
<code>public Number zseed</code>
|
|
<div class="mdetail-desc">
|
|
The starting z-index for BasicDialogs - defaults to 10000 </div>
|
|
<div class="mdetail-def">This property is defined by BasicDialog.</div>
|
|
</div>
|
|
</div>
|
|
|
|
<a name="BasicDialog"></a>
|
|
<h2 class="mdetail-head">Constructor Details</h2>
|
|
<div class="detail-wrap">
|
|
<div class="mdetail">
|
|
<h3>BasicDialog</i></h3>
|
|
<code>public function BasicDialog(<code>String/HTMLElement/YAHOO.ext.Element el</code>, <code>Object config</code>)</code>
|
|
<div class="mdetail-desc">
|
|
Create a new BasicDialog. <div class="mdetail-params">
|
|
<strong>Parameters:</strong>
|
|
<ul><li><code>el</code> : String/HTMLElement/YAHOO.ext.Element<div class="sub-desc">The id of or container element</div></li><li><code>config</code> : Object<div class="sub-desc">configuration options</div></li> </ul>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<h2 class="mdetail-head">Method Details</h2>
|
|
<div class="detail-wrap">
|
|
<a name="addButton"></a>
|
|
<div class="mdetail">
|
|
<h3>addButton</i></h3>
|
|
<code>public function addButton(<code>String/Object config</code>, <code>Function handler</code>, <span class="optional" title="Optional">[<code>Object scope</code>]</span>)</code>
|
|
<div class="mdetail-desc">
|
|
Adds a button.
|
|
<div class="mdetail-params">
|
|
<strong>Parameters:</strong>
|
|
<ul><li><code>config</code> : String/Object<div class="sub-desc">A string becomes the button text, an object is expected to be a valid YAHOO.ext.DomHelper element config</div></li><li><code>handler</code> : Function<div class="sub-desc">The function called when the button is clicked</div></li><li><code>scope</code> : Object<div class="sub-desc">(optional) The scope of the handler function</div></li> </ul>
|
|
<strong>Returns:</strong>
|
|
<ul>
|
|
<li><code>YAHOO.ext.BasicDialog.Button</code></li>
|
|
</ul>
|
|
</div>
|
|
</div>
|
|
<div class="mdetail-def">This method is defined by BasicDialog.</div>
|
|
</div>
|
|
<a name="addKeyListener"></a>
|
|
<div class="mdetail alt">
|
|
<h3>addKeyListener</i></h3>
|
|
<code>public function addKeyListener(<code>Number/Array/Object key</code>, <code>Function fn</code>, <span class="optional" title="Optional">[<code>Object scope</code>]</span>)</code>
|
|
<div class="mdetail-desc">
|
|
Adds a key listener for when this dialog is displayed
|
|
<div class="mdetail-params">
|
|
<strong>Parameters:</strong>
|
|
<ul><li><code>key</code> : Number/Array/Object<div class="sub-desc">Either the numeric key code, array of key codes or an object with the following options: {key: (number or array), shift: (true/false), ctrl: (true/false), alt: (true/false)}</div></li><li><code>fn</code> : Function<div class="sub-desc">The function to call</div></li><li><code>scope</code> : Object<div class="sub-desc">(optional) The scope of the function</div></li> </ul>
|
|
<strong>Returns:</strong>
|
|
<ul>
|
|
<li><code>YAHOO.ext.BasicDialog</code><div class="sub-desc">this</div></li>
|
|
</ul>
|
|
</div>
|
|
</div>
|
|
<div class="mdetail-def">This method is defined by BasicDialog.</div>
|
|
</div>
|
|
<a name="addListener"></a>
|
|
<div class="mdetail">
|
|
<h3>addListener</i></h3>
|
|
<code>public function addListener(<code>String eventName</code>, <code>Function handler</code>, <span class="optional" title="Optional">[<code>Object scope</code>]</span>, <span class="optional" title="Optional">[<code>boolean override</code>]</span>)</code>
|
|
<div class="mdetail-desc">
|
|
Appends an event handler to this element
|
|
<div class="mdetail-params">
|
|
<strong>Parameters:</strong>
|
|
<ul><li><code>eventName</code> : String<div class="sub-desc">The type of event to listen for</div></li><li><code>handler</code> : Function<div class="sub-desc">The method the event invokes</div></li><li><code>scope</code> : Object<div class="sub-desc">(optional) The scope (this object) for the handler</div></li><li><code>override</code> : boolean<div class="sub-desc">(optional) If true, scope becomes the scope</div></li> </ul>
|
|
<strong>Returns:</strong>
|
|
<ul>
|
|
<li><code>void</code></li>
|
|
</ul>
|
|
</div>
|
|
</div>
|
|
<div class="mdetail-def">This method is defined by <a href="YAHOO.ext.util.Observable.html#addListener">Observable</a>.</div>
|
|
</div>
|
|
<a name="bringToFront"></a>
|
|
<div class="mdetail alt">
|
|
<h3>bringToFront</i></h3>
|
|
<code>public function bringToFront(<code>String/Object dlg</code>)</code>
|
|
<div class="mdetail-desc">
|
|
Brings the specified dialog to the front
|
|
<div class="mdetail-params">
|
|
<strong>Parameters:</strong>
|
|
<ul><li><code>dlg</code> : String/Object<div class="sub-desc">The id of the dialog or a dialog</div></li> </ul>
|
|
<strong>Returns:</strong>
|
|
<ul>
|
|
<li><code>YAHOO.ext.BasicDialog</code></li>
|
|
</ul>
|
|
</div>
|
|
</div>
|
|
<div class="mdetail-def">This method is defined by BasicDialog.</div>
|
|
</div>
|
|
<a name="center"></a>
|
|
<div class="mdetail">
|
|
<h3>center</i></h3>
|
|
<code>public function center()</code>
|
|
<div class="mdetail-desc">
|
|
Centers this dialog
|
|
<div class="mdetail-params">
|
|
<strong>Parameters:</strong>
|
|
<ul><li>None.</li> </ul>
|
|
<strong>Returns:</strong>
|
|
<ul>
|
|
<li><code>YAHOO.ext.BasicDialog</code><div class="sub-desc">this</div></li>
|
|
</ul>
|
|
</div>
|
|
</div>
|
|
<div class="mdetail-def">This method is defined by BasicDialog.</div>
|
|
</div>
|
|
<a name="delayedListener"></a>
|
|
<div class="mdetail alt">
|
|
<h3>delayedListener</i></h3>
|
|
<code>public function delayedListener(<code>String eventName</code>, <code>Function handler</code>, <span class="optional" title="Optional">[<code>Object scope</code>]</span>, <span class="optional" title="Optional">[<code>Number delay</code>]</span>)</code>
|
|
<div class="mdetail-desc">
|
|
Appends an event handler to this element that is delayed the specified number of milliseconds.
|
|
<div class="mdetail-params">
|
|
<strong>Parameters:</strong>
|
|
<ul><li><code>eventName</code> : String<div class="sub-desc">The type of event to listen for</div></li><li><code>handler</code> : Function<div class="sub-desc">The method the event invokes</div></li><li><code>scope</code> : Object<div class="sub-desc">(optional) The scope (this object) for the handler</div></li><li><code>delay</code> : Number<div class="sub-desc">(optional) The number of milliseconds to delay</div></li> </ul>
|
|
<strong>Returns:</strong>
|
|
<ul>
|
|
<li><code>Function</code><div class="sub-desc">The wrapped function that was created (can be used to remove the listener)</div></li>
|
|
</ul>
|
|
</div>
|
|
</div>
|
|
<div class="mdetail-def">This method is defined by <a href="YAHOO.ext.util.Observable.html#delayedListener">Observable</a>.</div>
|
|
</div>
|
|
<a name="destroy"></a>
|
|
<div class="mdetail">
|
|
<h3>destroy</i></h3>
|
|
<code>public function destroy(<span class="optional" title="Optional">[<code>Boolean removeEl</code>]</span>)</code>
|
|
<div class="mdetail-desc">
|
|
Destroys this dialog
|
|
<div class="mdetail-params">
|
|
<strong>Parameters:</strong>
|
|
<ul><li><code>removeEl</code> : Boolean<div class="sub-desc">(optional) true to remove the element from the DOM</div></li> </ul>
|
|
<strong>Returns:</strong>
|
|
<ul>
|
|
<li><code>void</code></li>
|
|
</ul>
|
|
</div>
|
|
</div>
|
|
<div class="mdetail-def">This method is defined by BasicDialog.</div>
|
|
</div>
|
|
<a name="fireEvent"></a>
|
|
<div class="mdetail alt">
|
|
<h3>fireEvent</i></h3>
|
|
<code>public function fireEvent(<code>String eventName</code>, <code>Object... args</code>)</code>
|
|
<div class="mdetail-desc">
|
|
Fires the specified event with the passed parameters (minus the event name).
|
|
<div class="mdetail-params">
|
|
<strong>Parameters:</strong>
|
|
<ul><li><code>eventName</code> : String<div class="sub-desc"></div></li><li><code>args</code> : Object...<div class="sub-desc">Variable number of parameters are passed to handlers</div></li> </ul>
|
|
<strong>Returns:</strong>
|
|
<ul>
|
|
<li><code>Boolean</code><div class="sub-desc">returns false if any of the handlers return false otherwise it returns true</div></li>
|
|
</ul>
|
|
</div>
|
|
</div>
|
|
<div class="mdetail-def">This method is defined by <a href="YAHOO.ext.util.Observable.html#fireEvent">Observable</a>.</div>
|
|
</div>
|
|
<a name="get"></a>
|
|
<div class="mdetail">
|
|
<h3>get</i></h3>
|
|
<code>public function get(<code>String/Object id</code>)</code>
|
|
<div class="mdetail-desc">
|
|
Gets a registered dialog by id
|
|
<div class="mdetail-params">
|
|
<strong>Parameters:</strong>
|
|
<ul><li><code>id</code> : String/Object<div class="sub-desc">The id of the dialog or a dialog</div></li> </ul>
|
|
<strong>Returns:</strong>
|
|
<ul>
|
|
<li><code>YAHOO.ext.BasicDialog</code></li>
|
|
</ul>
|
|
</div>
|
|
</div>
|
|
<div class="mdetail-def">This method is defined by BasicDialog.</div>
|
|
</div>
|
|
<a name="getEl"></a>
|
|
<div class="mdetail alt">
|
|
<h3>getEl</i></h3>
|
|
<code>public function getEl()</code>
|
|
<div class="mdetail-desc">
|
|
Returns the element for this dialog
|
|
<div class="mdetail-params">
|
|
<strong>Parameters:</strong>
|
|
<ul><li>None.</li> </ul>
|
|
<strong>Returns:</strong>
|
|
<ul>
|
|
<li><code>YAHOO.ext.Element</code></li>
|
|
</ul>
|
|
</div>
|
|
</div>
|
|
<div class="mdetail-def">This method is defined by BasicDialog.</div>
|
|
</div>
|
|
<a name="getTabs"></a>
|
|
<div class="mdetail">
|
|
<h3>getTabs</i></h3>
|
|
<code>public function getTabs()</code>
|
|
<div class="mdetail-desc">
|
|
Returns the TabPanel component (if autoTabs)
|
|
<div class="mdetail-params">
|
|
<strong>Parameters:</strong>
|
|
<ul><li>None.</li> </ul>
|
|
<strong>Returns:</strong>
|
|
<ul>
|
|
<li><code>YAHOO.ext.TabPanel</code></li>
|
|
</ul>
|
|
</div>
|
|
</div>
|
|
<div class="mdetail-def">This method is defined by BasicDialog.</div>
|
|
</div>
|
|
<a name="hide"></a>
|
|
<div class="mdetail alt">
|
|
<h3>hide</i></h3>
|
|
<code>public function hide(<span class="optional" title="Optional">[<code>Function callback</code>]</span>)</code>
|
|
<div class="mdetail-desc">
|
|
Hides the dialog.
|
|
<div class="mdetail-params">
|
|
<strong>Parameters:</strong>
|
|
<ul><li><code>callback</code> : Function<div class="sub-desc">(optional) Function to call when the dialog is hidden</div></li> </ul>
|
|
<strong>Returns:</strong>
|
|
<ul>
|
|
<li><code>YAHOO.ext.BasicDialog</code><div class="sub-desc">this</div></li>
|
|
</ul>
|
|
</div>
|
|
</div>
|
|
<div class="mdetail-def">This method is defined by BasicDialog.</div>
|
|
</div>
|
|
<a name="isVisible"></a>
|
|
<div class="mdetail">
|
|
<h3>isVisible</i></h3>
|
|
<code>public function isVisible()</code>
|
|
<div class="mdetail-desc">
|
|
Returns true if the dialog is visible
|
|
<div class="mdetail-params">
|
|
<strong>Parameters:</strong>
|
|
<ul><li>None.</li> </ul>
|
|
<strong>Returns:</strong>
|
|
<ul>
|
|
<li><code>Boolean</code></li>
|
|
</ul>
|
|
</div>
|
|
</div>
|
|
<div class="mdetail-def">This method is defined by BasicDialog.</div>
|
|
</div>
|
|
<a name="moveTo"></a>
|
|
<div class="mdetail alt">
|
|
<h3>moveTo</i></h3>
|
|
<code>public function moveTo(<code>Number x</code>, <code>Number y</code>)</code>
|
|
<div class="mdetail-desc">
|
|
Moves the dialog to the specified point
|
|
<div class="mdetail-params">
|
|
<strong>Parameters:</strong>
|
|
<ul><li><code>x</code> : Number<div class="sub-desc"></div></li><li><code>y</code> : Number<div class="sub-desc"></div></li> </ul>
|
|
<strong>Returns:</strong>
|
|
<ul>
|
|
<li><code>YAHOO.ext.BasicDialog</code><div class="sub-desc">this</div></li>
|
|
</ul>
|
|
</div>
|
|
</div>
|
|
<div class="mdetail-def">This method is defined by BasicDialog.</div>
|
|
</div>
|
|
<a name="purgeListeners"></a>
|
|
<div class="mdetail">
|
|
<h3>purgeListeners</i></h3>
|
|
<code>public function purgeListeners()</code>
|
|
<div class="mdetail-desc">
|
|
Removes all listeners for this object
|
|
<div class="mdetail-params">
|
|
<strong>Parameters:</strong>
|
|
<ul><li>None.</li> </ul>
|
|
<strong>Returns:</strong>
|
|
<ul>
|
|
<li><code>void</code></li>
|
|
</ul>
|
|
</div>
|
|
</div>
|
|
<div class="mdetail-def">This method is defined by <a href="YAHOO.ext.util.Observable.html#purgeListeners">Observable</a>.</div>
|
|
</div>
|
|
<a name="removeListener"></a>
|
|
<div class="mdetail alt">
|
|
<h3>removeListener</i></h3>
|
|
<code>public function removeListener(<code>String eventName</code>, <code>Function handler</code>, <span class="optional" title="Optional">[<code>Object scope</code>]</span>)</code>
|
|
<div class="mdetail-desc">
|
|
Removes a listener
|
|
<div class="mdetail-params">
|
|
<strong>Parameters:</strong>
|
|
<ul><li><code>eventName</code> : String<div class="sub-desc">The type of event to listen for</div></li><li><code>handler</code> : Function<div class="sub-desc">The handler to remove</div></li><li><code>scope</code> : Object<div class="sub-desc">(optional) The scope (this object) for the handler</div></li> </ul>
|
|
<strong>Returns:</strong>
|
|
<ul>
|
|
<li><code>void</code></li>
|
|
</ul>
|
|
</div>
|
|
</div>
|
|
<div class="mdetail-def">This method is defined by <a href="YAHOO.ext.util.Observable.html#removeListener">Observable</a>.</div>
|
|
</div>
|
|
<a name="resizeTo"></a>
|
|
<div class="mdetail">
|
|
<h3>resizeTo</i></h3>
|
|
<code>public function resizeTo(<code>Number width</code>, <code>Number height</code>)</code>
|
|
<div class="mdetail-desc">
|
|
Resizes the dialog.
|
|
<div class="mdetail-params">
|
|
<strong>Parameters:</strong>
|
|
<ul><li><code>width</code> : Number<div class="sub-desc"></div></li><li><code>height</code> : Number<div class="sub-desc"></div></li> </ul>
|
|
<strong>Returns:</strong>
|
|
<ul>
|
|
<li><code>YAHOO.ext.BasicDialog</code><div class="sub-desc">this</div></li>
|
|
</ul>
|
|
</div>
|
|
</div>
|
|
<div class="mdetail-def">This method is defined by BasicDialog.</div>
|
|
</div>
|
|
<a name="restoreState"></a>
|
|
<div class="mdetail alt">
|
|
<h3>restoreState</i></h3>
|
|
<code>public function restoreState()</code>
|
|
<div class="mdetail-desc">
|
|
Restores the previous state of the dialog if YAHOO.ext.state is configured
|
|
<div class="mdetail-params">
|
|
<strong>Parameters:</strong>
|
|
<ul><li>None.</li> </ul>
|
|
<strong>Returns:</strong>
|
|
<ul>
|
|
<li><code>YAHOO.ext.BasicDialog</code><div class="sub-desc">this</div></li>
|
|
</ul>
|
|
</div>
|
|
</div>
|
|
<div class="mdetail-def">This method is defined by BasicDialog.</div>
|
|
</div>
|
|
<a name="sendToBack"></a>
|
|
<div class="mdetail">
|
|
<h3>sendToBack</i></h3>
|
|
<code>public function sendToBack(<code>String/Object dlg</code>)</code>
|
|
<div class="mdetail-desc">
|
|
Sends the specified dialog to the back
|
|
<div class="mdetail-params">
|
|
<strong>Parameters:</strong>
|
|
<ul><li><code>dlg</code> : String/Object<div class="sub-desc">The id of the dialog or a dialog</div></li> </ul>
|
|
<strong>Returns:</strong>
|
|
<ul>
|
|
<li><code>YAHOO.ext.BasicDialog</code></li>
|
|
</ul>
|
|
</div>
|
|
</div>
|
|
<div class="mdetail-def">This method is defined by BasicDialog.</div>
|
|
</div>
|
|
<a name="setDefaultButton"></a>
|
|
<div class="mdetail alt">
|
|
<h3>setDefaultButton</i></h3>
|
|
<code>public function setDefaultButton(<code>YAHOO.ext.BasicDialog.Button btn</code>)</code>
|
|
<div class="mdetail-desc">
|
|
Sets the default button to be focused when the dialog is displayed
|
|
<div class="mdetail-params">
|
|
<strong>Parameters:</strong>
|
|
<ul><li><code>btn</code> : YAHOO.ext.BasicDialog.Button<div class="sub-desc">The button object returned by addButton</div></li> </ul>
|
|
<strong>Returns:</strong>
|
|
<ul>
|
|
<li><code>YAHOO.ext.BasicDialog</code><div class="sub-desc">this</div></li>
|
|
</ul>
|
|
</div>
|
|
</div>
|
|
<div class="mdetail-def">This method is defined by BasicDialog.</div>
|
|
</div>
|
|
<a name="show"></a>
|
|
<div class="mdetail">
|
|
<h3>show</i></h3>
|
|
<code>public function show(<span class="optional" title="Optional">[<code>String/HTMLElement/YAHOO.ext.Element animateTarget</code>]</span>)</code>
|
|
<div class="mdetail-desc">
|
|
Shows the dialog.
|
|
<div class="mdetail-params">
|
|
<strong>Parameters:</strong>
|
|
<ul><li><code>animateTarget</code> : String/HTMLElement/YAHOO.ext.Element<div class="sub-desc">(optional) Reset the animation target</div></li> </ul>
|
|
<strong>Returns:</strong>
|
|
<ul>
|
|
<li><code>YAHOO.ext.BasicDialog</code><div class="sub-desc">this</div></li>
|
|
</ul>
|
|
</div>
|
|
</div>
|
|
<div class="mdetail-def">This method is defined by BasicDialog.</div>
|
|
</div>
|
|
<a name="toBack"></a>
|
|
<div class="mdetail alt">
|
|
<h3>toBack</i></h3>
|
|
<code>public function toBack()</code>
|
|
<div class="mdetail-desc">
|
|
Sends this dialog to the back (under) of any other visible dialogs
|
|
<div class="mdetail-params">
|
|
<strong>Parameters:</strong>
|
|
<ul><li>None.</li> </ul>
|
|
<strong>Returns:</strong>
|
|
<ul>
|
|
<li><code>YAHOO.ext.BasicDialog</code><div class="sub-desc">this</div></li>
|
|
</ul>
|
|
</div>
|
|
</div>
|
|
<div class="mdetail-def">This method is defined by BasicDialog.</div>
|
|
</div>
|
|
<a name="toFront"></a>
|
|
<div class="mdetail">
|
|
<h3>toFront</i></h3>
|
|
<code>public function toFront()</code>
|
|
<div class="mdetail-desc">
|
|
Brings this dialog to the front of any other visible dialogs
|
|
<div class="mdetail-params">
|
|
<strong>Parameters:</strong>
|
|
<ul><li>None.</li> </ul>
|
|
<strong>Returns:</strong>
|
|
<ul>
|
|
<li><code>YAHOO.ext.BasicDialog</code><div class="sub-desc">this</div></li>
|
|
</ul>
|
|
</div>
|
|
</div>
|
|
<div class="mdetail-def">This method is defined by BasicDialog.</div>
|
|
</div>
|
|
</div>
|
|
|
|
<h2 class="mdetail-head">Event Details</h2>
|
|
<div class="detail-wrap">
|
|
<a name="event-beforehide"></a>
|
|
<div class="mdetail">
|
|
<h3>beforehide</i></h3>
|
|
<code>public event beforehide</code>
|
|
<div class="mdetail-desc">
|
|
Fires before this dialog is hidden.
|
|
<div class="mdetail-params">
|
|
<strong style="font-weight:normal;">Subscribers will be called with the following parameters:</strong>
|
|
<ul><li><code>this</code> : YAHOO.ext.BasicDialog<div class="sub-desc"></div></li> </ul>
|
|
</div>
|
|
</div>
|
|
<div class="mdetail-def">This event is defined by BasicDialog.</div>
|
|
</div>
|
|
<a name="event-beforeshow"></a>
|
|
<div class="mdetail alt">
|
|
<h3>beforeshow</i></h3>
|
|
<code>public event beforeshow</code>
|
|
<div class="mdetail-desc">
|
|
Fires before this dialog is shown.
|
|
<div class="mdetail-params">
|
|
<strong style="font-weight:normal;">Subscribers will be called with the following parameters:</strong>
|
|
<ul><li><code>this</code> : YAHOO.ext.BasicDialog<div class="sub-desc"></div></li> </ul>
|
|
</div>
|
|
</div>
|
|
<div class="mdetail-def">This event is defined by BasicDialog.</div>
|
|
</div>
|
|
<a name="event-hide"></a>
|
|
<div class="mdetail">
|
|
<h3>hide</i></h3>
|
|
<code>public event hide</code>
|
|
<div class="mdetail-desc">
|
|
Fires when this dialog is hidden.
|
|
<div class="mdetail-params">
|
|
<strong style="font-weight:normal;">Subscribers will be called with the following parameters:</strong>
|
|
<ul><li><code>this</code> : YAHOO.ext.BasicDialog<div class="sub-desc"></div></li> </ul>
|
|
</div>
|
|
</div>
|
|
<div class="mdetail-def">This event is defined by BasicDialog.</div>
|
|
</div>
|
|
<a name="event-keydown"></a>
|
|
<div class="mdetail alt">
|
|
<h3>keydown</i></h3>
|
|
<code>public event keydown</code>
|
|
<div class="mdetail-desc">
|
|
Fires when a key is pressed
|
|
<div class="mdetail-params">
|
|
<strong style="font-weight:normal;">Subscribers will be called with the following parameters:</strong>
|
|
<ul><li><code>this</code> : YAHOO.ext.BasicDialog<div class="sub-desc"></div></li><li><code>e</code> : YAHOO.ext.EventObject<div class="sub-desc"></div></li> </ul>
|
|
</div>
|
|
</div>
|
|
<div class="mdetail-def">This event is defined by BasicDialog.</div>
|
|
</div>
|
|
<a name="event-move"></a>
|
|
<div class="mdetail">
|
|
<h3>move</i></h3>
|
|
<code>public event move</code>
|
|
<div class="mdetail-desc">
|
|
Fires when this dialog is moved by the user.
|
|
<div class="mdetail-params">
|
|
<strong style="font-weight:normal;">Subscribers will be called with the following parameters:</strong>
|
|
<ul><li><code>this</code> : YAHOO.ext.BasicDialog<div class="sub-desc"></div></li><li><code>x</code> : Number<div class="sub-desc">The new page X</div></li><li><code>y</code> : Number<div class="sub-desc">The new page Y</div></li> </ul>
|
|
</div>
|
|
</div>
|
|
<div class="mdetail-def">This event is defined by BasicDialog.</div>
|
|
</div>
|
|
<a name="event-resize"></a>
|
|
<div class="mdetail alt">
|
|
<h3>resize</i></h3>
|
|
<code>public event resize</code>
|
|
<div class="mdetail-desc">
|
|
Fires when this dialog is resized by the user.
|
|
<div class="mdetail-params">
|
|
<strong style="font-weight:normal;">Subscribers will be called with the following parameters:</strong>
|
|
<ul><li><code>this</code> : YAHOO.ext.BasicDialog<div class="sub-desc"></div></li><li><code>width</code> : Number<div class="sub-desc">The new width</div></li><li><code>height</code> : Number<div class="sub-desc">The new height</div></li> </ul>
|
|
</div>
|
|
</div>
|
|
<div class="mdetail-def">This event is defined by BasicDialog.</div>
|
|
</div>
|
|
<a name="event-show"></a>
|
|
<div class="mdetail">
|
|
<h3>show</i></h3>
|
|
<code>public event show</code>
|
|
<div class="mdetail-desc">
|
|
Fires when this dialog is shown.
|
|
<div class="mdetail-params">
|
|
<strong style="font-weight:normal;">Subscribers will be called with the following parameters:</strong>
|
|
<ul><li><code>this</code> : YAHOO.ext.BasicDialog<div class="sub-desc"></div></li> </ul>
|
|
</div>
|
|
</div>
|
|
<div class="mdetail-def">This event is defined by BasicDialog.</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<hr>
|
|
Copyright © 2006 Jack Slocum. All rights reserved.
|
|
</body>
|
|
</html>
|
|
|