[619] | 1 | <div class="body-wrap"> |
---|
| 2 | <div class="top-tools"> |
---|
| 3 | <a class="inner-link" href="#Ext.util.DelayedTask-props"><img src="../resources/images/default/s.gif" class="item-icon icon-prop">Properties</a> |
---|
| 4 | <a class="inner-link" href="#Ext.util.DelayedTask-methods"><img src="../resources/images/default/s.gif" class="item-icon icon-method">Methods</a> |
---|
| 5 | <a class="inner-link" href="#Ext.util.DelayedTask-events"><img src="../resources/images/default/s.gif" class="item-icon icon-event">Events</a> |
---|
| 6 | <a class="bookmark" href="../docs/?class=Ext.util.DelayedTask"><img src="../resources/images/default/s.gif" class="item-icon icon-fav">Direct Link</a> |
---|
| 7 | </div> |
---|
| 8 | <h1>Class Ext.util.DelayedTask</h1> |
---|
| 9 | <table cellspacing="0"> |
---|
| 10 | <tr><td class="label">Package:</td><td class="hd-info">Ext.util</td></tr> |
---|
| 11 | <tr><td class="label">Defined In:</td><td class="hd-info"><a href="../src/DelayedTask.js" target="_blank">DelayedTask.js</a></td></tr> |
---|
| 12 | <tr><td class="label">Class:</td><td class="hd-info">DelayedTask</td></tr> |
---|
| 13 | <tr><td class="label">Extends:</td><td class="hd-info">Object</td></tr> |
---|
| 14 | </table> |
---|
| 15 | <div class="description"> |
---|
| 16 | * |
---|
| 17 | Provides a convenient method of performing setTimeout where a new |
---|
| 18 | timeout cancels the old timeout. An example would be performing validation on a keypress. |
---|
| 19 | You can use this class to buffer |
---|
| 20 | the keypress events for a certain number of milliseconds, and perform only if they stop |
---|
| 21 | for that amount of time. </div> |
---|
| 22 | |
---|
| 23 | <div class="hr"></div> |
---|
| 24 | <a id="Ext.util.DelayedTask-props"></a> |
---|
| 25 | <h2>Public Properties</h2> |
---|
| 26 | <div class="no-members">This class has no public properties.</div> <a id="Ext.util.DelayedTask-methods"></a> |
---|
| 27 | <h2>Public Methods</h2> |
---|
| 28 | <table cellspacing="0" class="member-table"> |
---|
| 29 | <tr> |
---|
| 30 | <th class="sig-header" colspan="2">Method</th> |
---|
| 31 | <th class="msource-header">Defined By</th> |
---|
| 32 | </tr> |
---|
| 33 | <tr class="method-row expandable"> |
---|
| 34 | <td class="micon"><a class="exi" href="#expand"> </a></td> |
---|
| 35 | <td class="sig"> |
---|
| 36 | <a id="Ext.util.DelayedTask-DelayedTask"></a> |
---|
| 37 | <b>DelayedTask</b>( <span class="optional" title="Optional">[<code>Function fn</code>]</span>, <span class="optional" title="Optional">[<code>Object scope</code>]</span>, <span class="optional" title="Optional">[<code>Array args</code>]</span> ) <div class="mdesc"> |
---|
| 38 | <div class="short">The parameters to this constructor serve as defaults and are not required.</div> |
---|
| 39 | <div class="long"> |
---|
| 40 | The parameters to this constructor serve as defaults and are not required. <div class="mdetail-params"> |
---|
| 41 | <strong>Parameters:</strong> |
---|
| 42 | <ul><li><code>fn</code> : Function<div class="sub-desc">(optional) The default function to timeout</div></li><li><code>scope</code> : Object<div class="sub-desc">(optional) The default scope of that timeout</div></li><li><code>args</code> : Array<div class="sub-desc">(optional) The default Array of arguments</div></li> </ul> |
---|
| 43 | <strong>Returns:</strong> |
---|
| 44 | <ul> |
---|
| 45 | <li><code></code></li> |
---|
| 46 | </ul> |
---|
| 47 | </div> |
---|
| 48 | </div> |
---|
| 49 | </div> |
---|
| 50 | </td> |
---|
| 51 | <td class="msource">DelayedTask</td> |
---|
| 52 | </tr> |
---|
| 53 | <tr class="method-row alt expandable"> |
---|
| 54 | <td class="micon"><a class="exi" href="#expand"> </a></td> |
---|
| 55 | <td class="sig"> |
---|
| 56 | <a id="Ext.util.DelayedTask-cancel"></a> |
---|
| 57 | <b>cancel</b>() : void <div class="mdesc"> |
---|
| 58 | <div class="short">Cancel the last queued timeout</div> |
---|
| 59 | <div class="long"> |
---|
| 60 | Cancel the last queued timeout <div class="mdetail-params"> |
---|
| 61 | <strong>Parameters:</strong> |
---|
| 62 | <ul><li>None.</li> </ul> |
---|
| 63 | <strong>Returns:</strong> |
---|
| 64 | <ul> |
---|
| 65 | <li><code>void</code></li> |
---|
| 66 | </ul> |
---|
| 67 | </div> |
---|
| 68 | </div> |
---|
| 69 | </div> |
---|
| 70 | </td> |
---|
| 71 | <td class="msource">DelayedTask</td> |
---|
| 72 | </tr> |
---|
| 73 | <tr class="method-row expandable"> |
---|
| 74 | <td class="micon"><a class="exi" href="#expand"> </a></td> |
---|
| 75 | <td class="sig"> |
---|
| 76 | <a id="Ext.util.DelayedTask-delay"></a> |
---|
| 77 | <b>delay</b>( <code>Number delay</code>, <span class="optional" title="Optional">[<code>Function newFn</code>]</span>, <span class="optional" title="Optional">[<code>Object newScope</code>]</span>, <span class="optional" title="Optional">[<code>Array newArgs</code>]</span> ) : void <div class="mdesc"> |
---|
| 78 | <div class="short">Cancels any pending timeout and queues a new one</div> |
---|
| 79 | <div class="long"> |
---|
| 80 | Cancels any pending timeout and queues a new one <div class="mdetail-params"> |
---|
| 81 | <strong>Parameters:</strong> |
---|
| 82 | <ul><li><code>delay</code> : Number<div class="sub-desc">The milliseconds to delay</div></li><li><code>newFn</code> : Function<div class="sub-desc">(optional) Overrides function passed to constructor</div></li><li><code>newScope</code> : Object<div class="sub-desc">(optional) Overrides scope passed to constructor</div></li><li><code>newArgs</code> : Array<div class="sub-desc">(optional) Overrides args passed to constructor</div></li> </ul> |
---|
| 83 | <strong>Returns:</strong> |
---|
| 84 | <ul> |
---|
| 85 | <li><code>void</code></li> |
---|
| 86 | </ul> |
---|
| 87 | </div> |
---|
| 88 | </div> |
---|
| 89 | </div> |
---|
| 90 | </td> |
---|
| 91 | <td class="msource">DelayedTask</td> |
---|
| 92 | </tr> |
---|
| 93 | </table> |
---|
| 94 | <a id="Ext.util.DelayedTask-events"></a> |
---|
| 95 | <h2>Public Events</h2> |
---|
| 96 | <div class="no-members">This class has no public events.</div> |
---|
| 97 | </div> |
---|