-All adapter related files below are located in \r
-/adapters/<lib name>/ of this zip file.\r
-\r
-Your include order should be:\r
-\r
-Ext Stand-alone\r
--------------------------------------------------------------------\r
-ext-base.js\r
-ext-all.js (or your choice of files)\r
-\r
-\r
-Yahoo! UI (.12+)\r
--------------------------------------------------------------------\r
-yui-utilities.js\r
-ext-yui-adapter.js\r
-ext-all.js (or your choice of files)\r
-\r
-\r
-jQuery (1.1+)\r
--------------------------------------------------------------------\r
-jquery.js\r
-ext-jquery-adapter.js\r
-ext-all.js (or your choice of files)\r
-\r
-\r
-Prototype (1.5+) / Scriptaculous (1.7+)\r
--------------------------------------------------------------------\r
-prototype.js\r
-scriptaculous.js?load=effects (or whatever you want to load)\r
-ext-prototype-adapter.js\r
-ext-all.js (or your choice of files)\r
-\r
-\r
-\r
+All adapter related files below are located in
+/adapters/<lib name>/ of this zip file.
+
+Your include order should be:
+
+Ext Stand-alone
+-------------------------------------------------------------------
+ext-base.js
+ext-all.js (or your choice of files)
+
+
+Yahoo! UI (.12+)
+-------------------------------------------------------------------
+yui-utilities.js
+ext-yui-adapter.js
+ext-all.js (or your choice of files)
+
+
+jQuery (1.1+)
+-------------------------------------------------------------------
+jquery.js
+ext-jquery-adapter.js
+ext-all.js (or your choice of files)
+
+
+Prototype (1.5+) / Scriptaculous (1.7+)
+-------------------------------------------------------------------
+prototype.js
+scriptaculous.js?load=effects (or whatever you want to load)
+ext-prototype-adapter.js
+ext-all.js (or your choice of files)
+
+
+
See the examples folders for more examples.
/*!
- * Ext JS Library 3.1.1
- * Copyright(c) 2006-2010 Ext JS, LLC
+ * Ext JS Library 3.2.0
+ * Copyright(c) 2006-2010 Ext JS, Inc.
* licensing@extjs.com
* http://www.extjs.com/license
*/
* The version of the framework
* @type String
*/
- version : '3.1.1'
+ version : '3.2.0'
};
/**
* @return {Boolean}
*/
isElement : function(v) {
- return !!v && v.tagName;
+ return v ? !!v.tagName : false;
},
/**
}
});
* </code></pre>
- * @param {Object} The destination object.
- * @param {Object} The source object.
- * @param {Array/String} Either an Array of property names, or a comma-delimited list
+ * @param {Object} dest The destination object.
+ * @param {Object} source The source object.
+ * @param {Array/String} names Either an Array of property names, or a comma-delimited list
* of property names to copy.
* @return {Object} The modified object.
*/
* </code></pre>
* @param {Array|NodeList} arr The Array of items to invoke the method on.
* @param {String} methodName The method name to invoke.
- * @param {Anything} ... Arguments to send into the method invocation.
+ * @param {...*} args Arguments to send into the method invocation.
* @return {Array} The results of invoking the method on each item in the array.
*/
invoke : function(arr, methodName){
});
* </code></pre>
+ * <p>See the {@link #start} method for details about how to configure a task object.</p>
* Also see {@link Ext.util.DelayedTask}.
*
* @constructor
/**
* Starts a new task.
* @method start
- * @param {Object} task A config object that supports the following properties:<ul>
- * <li><code>run</code> : Function<div class="sub-desc">The function to execute each time the task is run. The
- * function will be called at each interval and passed the <code>args</code> argument if specified. If a
- * particular scope is required, be sure to specify it using the <code>scope</code> argument.</div></li>
+ * @param {Object} task <p>A config object that supports the following properties:<ul>
+ * <li><code>run</code> : Function<div class="sub-desc"><p>The function to execute each time the task is invoked. The
+ * function will be called at each interval and passed the <code>args</code> argument if specified, and the
+ * current invocation count if not.</p>
+ * <p>If a particular scope (<code>this</code> reference) is required, be sure to specify it using the <code>scope</code> argument.</p>
+ * <p>Return <code>false</code> from this function to terminate the task.</p></div></li>
* <li><code>interval</code> : Number<div class="sub-desc">The frequency in milliseconds with which the task
- * should be executed.</div></li>
+ * should be invoked.</div></li>
* <li><code>args</code> : Array<div class="sub-desc">(optional) An array of arguments to be passed to the function
- * specified by <code>run</code>.</div></li>
+ * specified by <code>run</code>. If not specified, the current invocation count is passed.</div></li>
* <li><code>scope</code> : Object<div class="sub-desc">(optional) The scope (<tt>this</tt> reference) in which to execute the
* <code>run</code> function. Defaults to the task config object.</div></li>
- * <li><code>duration</code> : Number<div class="sub-desc">(optional) The length of time in milliseconds to execute
+ * <li><code>duration</code> : Number<div class="sub-desc">(optional) The length of time in milliseconds to invoke
* the task before stopping automatically (defaults to indefinite).</div></li>
- * <li><code>repeat</code> : Number<div class="sub-desc">(optional) The number of times to execute the task before
+ * <li><code>repeat</code> : Number<div class="sub-desc">(optional) The number of times to invoke the task before
* stopping automatically (defaults to indefinite).</div></li>
- * </ul>
+ * </ul></p>
+ * <p>Before each invocation, Ext injects the property <code>taskRunCount</code> into the task object so
+ * that calculations based on the repeat count can be performed.</p>
* @return {Object} The task
*/
this.start = function(task){
}
Ext.TaskMgr.start(task);
</code></pre>
+ * <p>See the {@link #start} method for details about how to configure a task object.</p>
* @singleton
*/
-Ext.TaskMgr = new Ext.util.TaskRunner();(function(){\r
- var libFlyweight;\r
- \r
- function fly(el) {\r
- if (!libFlyweight) {\r
- libFlyweight = new Ext.Element.Flyweight();\r
- }\r
- libFlyweight.dom = el;\r
- return libFlyweight;\r
- }\r
- \r
- (function(){\r
- var doc = document,\r
- isCSS1 = doc.compatMode == "CSS1Compat",\r
- MAX = Math.max, \r
- ROUND = Math.round,\r
- PARSEINT = parseInt;\r
- \r
- Ext.lib.Dom = {\r
- isAncestor : function(p, c) {\r
- var ret = false;\r
- \r
- p = Ext.getDom(p);\r
- c = Ext.getDom(c);\r
- if (p && c) {\r
- if (p.contains) {\r
- return p.contains(c);\r
- } else if (p.compareDocumentPosition) {\r
- return !!(p.compareDocumentPosition(c) & 16);\r
- } else {\r
- while (c = c.parentNode) {\r
- ret = c == p || ret; \r
- }\r
- } \r
- } \r
- return ret;\r
- },\r
- \r
- getViewWidth : function(full) {\r
- return full ? this.getDocumentWidth() : this.getViewportWidth();\r
- },\r
-\r
- getViewHeight : function(full) {\r
- return full ? this.getDocumentHeight() : this.getViewportHeight();\r
- },\r
-\r
- getDocumentHeight: function() { \r
- return MAX(!isCSS1 ? doc.body.scrollHeight : doc.documentElement.scrollHeight, this.getViewportHeight());\r
- },\r
-\r
- getDocumentWidth: function() { \r
- return MAX(!isCSS1 ? doc.body.scrollWidth : doc.documentElement.scrollWidth, this.getViewportWidth());\r
- },\r
-\r
- getViewportHeight: function(){\r
- return Ext.isIE ? \r
- (Ext.isStrict ? doc.documentElement.clientHeight : doc.body.clientHeight) :\r
- self.innerHeight;\r
- },\r
-\r
- getViewportWidth : function() {\r
- return !Ext.isStrict && !Ext.isOpera ? doc.body.clientWidth :\r
- Ext.isIE ? doc.documentElement.clientWidth : self.innerWidth;\r
- },\r
- \r
- getY : function(el) {\r
- return this.getXY(el)[1];\r
- },\r
-\r
- getX : function(el) {\r
- return this.getXY(el)[0];\r
- },\r
-\r
- getXY : function(el) {\r
- var p, \r
- pe, \r
- b,\r
- bt, \r
- bl, \r
- dbd, \r
- x = 0,\r
- y = 0, \r
- scroll,\r
- hasAbsolute, \r
- bd = (doc.body || doc.documentElement),\r
- ret = [0,0];\r
- \r
- el = Ext.getDom(el);\r
-\r
- if(el != bd){\r
- if (el.getBoundingClientRect) {\r
- b = el.getBoundingClientRect();\r
- scroll = fly(document).getScroll();\r
- ret = [ROUND(b.left + scroll.left), ROUND(b.top + scroll.top)];\r
- } else { \r
- p = el; \r
- hasAbsolute = fly(el).isStyle("position", "absolute");\r
- \r
- while (p) {\r
- pe = fly(p); \r
- x += p.offsetLeft;\r
- y += p.offsetTop;\r
- \r
- hasAbsolute = hasAbsolute || pe.isStyle("position", "absolute");\r
- \r
- if (Ext.isGecko) { \r
- y += bt = PARSEINT(pe.getStyle("borderTopWidth"), 10) || 0;\r
- x += bl = PARSEINT(pe.getStyle("borderLeftWidth"), 10) || 0; \r
- \r
- if (p != el && !pe.isStyle('overflow','visible')) {\r
- x += bl;\r
- y += bt;\r
- }\r
- }\r
- p = p.offsetParent;\r
- }\r
- \r
- if (Ext.isSafari && hasAbsolute) {\r
- x -= bd.offsetLeft;\r
- y -= bd.offsetTop;\r
- }\r
- \r
- if (Ext.isGecko && !hasAbsolute) {\r
- dbd = fly(bd);\r
- x += PARSEINT(dbd.getStyle("borderLeftWidth"), 10) || 0;\r
- y += PARSEINT(dbd.getStyle("borderTopWidth"), 10) || 0;\r
- }\r
- \r
- p = el.parentNode;\r
- while (p && p != bd) {\r
- if (!Ext.isOpera || (p.tagName != 'TR' && !fly(p).isStyle("display", "inline"))) {\r
- x -= p.scrollLeft;\r
- y -= p.scrollTop;\r
- }\r
- p = p.parentNode;\r
- }\r
- ret = [x,y];\r
- }\r
- }\r
- return ret\r
- },\r
-\r
- setXY : function(el, xy) {\r
- (el = Ext.fly(el, '_setXY')).position();\r
- \r
- var pts = el.translatePoints(xy),\r
- style = el.dom.style,\r
- pos; \r
- \r
- for (pos in pts) { \r
- if(!isNaN(pts[pos])) style[pos] = pts[pos] + "px"\r
- }\r
- },\r
-\r
- setX : function(el, x) {\r
- this.setXY(el, [x, false]);\r
- },\r
-\r
- setY : function(el, y) {\r
- this.setXY(el, [false, y]);\r
- }\r
- };\r
-})();Ext.lib.Dom.getRegion = function(el) {\r
- return Ext.lib.Region.getRegion(el);\r
+Ext.TaskMgr = new Ext.util.TaskRunner();(function(){
+ var libFlyweight;
+
+ function fly(el) {
+ if (!libFlyweight) {
+ libFlyweight = new Ext.Element.Flyweight();
+ }
+ libFlyweight.dom = el;
+ return libFlyweight;
+ }
+
+ (function(){
+ var doc = document,
+ isCSS1 = doc.compatMode == "CSS1Compat",
+ MAX = Math.max,
+ ROUND = Math.round,
+ PARSEINT = parseInt;
+
+ Ext.lib.Dom = {
+ isAncestor : function(p, c) {
+ var ret = false;
+
+ p = Ext.getDom(p);
+ c = Ext.getDom(c);
+ if (p && c) {
+ if (p.contains) {
+ return p.contains(c);
+ } else if (p.compareDocumentPosition) {
+ return !!(p.compareDocumentPosition(c) & 16);
+ } else {
+ while (c = c.parentNode) {
+ ret = c == p || ret;
+ }
+ }
+ }
+ return ret;
+ },
+
+ getViewWidth : function(full) {
+ return full ? this.getDocumentWidth() : this.getViewportWidth();
+ },
+
+ getViewHeight : function(full) {
+ return full ? this.getDocumentHeight() : this.getViewportHeight();
+ },
+
+ getDocumentHeight: function() {
+ return MAX(!isCSS1 ? doc.body.scrollHeight : doc.documentElement.scrollHeight, this.getViewportHeight());
+ },
+
+ getDocumentWidth: function() {
+ return MAX(!isCSS1 ? doc.body.scrollWidth : doc.documentElement.scrollWidth, this.getViewportWidth());
+ },
+
+ getViewportHeight: function(){
+ return Ext.isIE ?
+ (Ext.isStrict ? doc.documentElement.clientHeight : doc.body.clientHeight) :
+ self.innerHeight;
+ },
+
+ getViewportWidth : function() {
+ return !Ext.isStrict && !Ext.isOpera ? doc.body.clientWidth :
+ Ext.isIE ? doc.documentElement.clientWidth : self.innerWidth;
+ },
+
+ getY : function(el) {
+ return this.getXY(el)[1];
+ },
+
+ getX : function(el) {
+ return this.getXY(el)[0];
+ },
+
+ getXY : function(el) {
+ var p,
+ pe,
+ b,
+ bt,
+ bl,
+ dbd,
+ x = 0,
+ y = 0,
+ scroll,
+ hasAbsolute,
+ bd = (doc.body || doc.documentElement),
+ ret = [0,0];
+
+ el = Ext.getDom(el);
+
+ if(el != bd){
+ if (el.getBoundingClientRect) {
+ b = el.getBoundingClientRect();
+ scroll = fly(document).getScroll();
+ ret = [ROUND(b.left + scroll.left), ROUND(b.top + scroll.top)];
+ } else {
+ p = el;
+ hasAbsolute = fly(el).isStyle("position", "absolute");
+
+ while (p) {
+ pe = fly(p);
+ x += p.offsetLeft;
+ y += p.offsetTop;
+
+ hasAbsolute = hasAbsolute || pe.isStyle("position", "absolute");
+
+ if (Ext.isGecko) {
+ y += bt = PARSEINT(pe.getStyle("borderTopWidth"), 10) || 0;
+ x += bl = PARSEINT(pe.getStyle("borderLeftWidth"), 10) || 0;
+
+ if (p != el && !pe.isStyle('overflow','visible')) {
+ x += bl;
+ y += bt;
+ }
+ }
+ p = p.offsetParent;
+ }
+
+ if (Ext.isSafari && hasAbsolute) {
+ x -= bd.offsetLeft;
+ y -= bd.offsetTop;
+