Upgrade to ExtJS 4.0.7 - Released 10/19/2011
[extjs.git] / docs / source / CompositeElement.html
1 <!DOCTYPE html>
2 <html>
3 <head>
4   <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
5   <title>The source code</title>
6   <link href="../resources/prettify/prettify.css" type="text/css" rel="stylesheet" />
7   <script type="text/javascript" src="../resources/prettify/prettify.js"></script>
8   <style type="text/css">
9     .highlight { display: block; background-color: #ddd; }
10   </style>
11   <script type="text/javascript">
12     function highlight() {
13       document.getElementById(location.hash.replace(/#/, "")).className = "highlight";
14     }
15   </script>
16 </head>
17 <body onload="prettyPrint(); highlight();">
18   <pre class="prettyprint lang-js"><span id='Ext-fx-target-CompositeElement'>/**
19 </span> * @class Ext.fx.target.CompositeElement
20  * @extends Ext.fx.target.Element
21  * 
22  * This class represents a animation target for a {@link Ext.CompositeElement}. It allows
23  * each {@link Ext.Element} in the group to be animated as a whole. In general this class will not be
24  * created directly, the {@link Ext.CompositeElement} will be passed to the animation and
25  * and the appropriate target will be created.
26  */
27 Ext.define('Ext.fx.target.CompositeElement', {
28
29     /* Begin Definitions */
30
31     extend: 'Ext.fx.target.Element',
32
33     /* End Definitions */
34
35     isComposite: true,
36     
37     constructor: function(target) {
38         target.id = target.id || Ext.id(null, 'ext-composite-');
39         this.callParent([target]);
40     },
41
42     getAttr: function(attr, val) {
43         var out = [],
44             target = this.target;
45         target.each(function(el) {
46             out.push([el, this.getElVal(el, attr, val)]);
47         }, this);
48         return out;
49     }
50 });
51 </pre>
52 </body>
53 </html>