1 <!DOCTYPE html><html><head><title>Sencha Documentation Project</title><link rel="stylesheet" href="../reset.css" type="text/css"><link rel="stylesheet" href="../prettify.css" type="text/css"><link rel="stylesheet" href="../prettify_sa.css" type="text/css"><script type="text/javascript" src="../prettify.js"></script></head><body onload="prettyPrint()"><pre class="prettyprint"><pre><span id='Ext-layout.container.AbstractContainer'>/**
2 </span> * @class Ext.layout.container.AbstractContainer
3 * @extends Ext.layout.Layout
4 * Please refer to sub classes documentation
7 Ext.define('Ext.layout.container.AbstractContainer', {
9 /* Begin Definitions */
11 extend: 'Ext.layout.Layout',
24 <span id='Ext-layout.container.AbstractContainer-cfg-bindToOwnerCtComponent'> /**
25 </span> * @cfg {Boolean} bindToOwnerCtComponent
26 * Flag to notify the ownerCt Component on afterLayout of a change
28 bindToOwnerCtComponent: false,
30 <span id='Ext-layout.container.AbstractContainer-cfg-bindToOwnerCtContainer'> /**
31 </span> * @cfg {Boolean} bindToOwnerCtContainer
32 * Flag to notify the ownerCt Container on afterLayout of a change
34 bindToOwnerCtContainer: false,
36 <span id='Ext-layout.container.AbstractContainer-cfg-itemCls'> /**
37 </span> * @cfg {String} itemCls
38 * <p>An optional extra CSS class that will be added to the container. This can be useful for adding
39 * customized styles to the container or any of its children using standard CSS rules. See
40 * {@link Ext.Component}.{@link Ext.Component#ctCls ctCls} also.</p>
44 isManaged: function(dimension) {
45 dimension = Ext.String.capitalize(dimension);
48 managed = me['managed' + dimension],
49 ancestor = me.owner.ownerCt;
51 if (ancestor && ancestor.layout) {
52 while (ancestor && ancestor.layout) {
53 if (managed === false || ancestor.layout['managed' + dimension] === false) {
57 ancestor = ancestor.ownerCt;
66 if (Ext.isNumber(owner.height) || owner.isViewport) {
67 me.managedHeight = false;
69 if (Ext.isNumber(owner.width) || owner.isViewport) {
70 me.managedWidth = false;
72 me.callParent(arguments);
75 <span id='Ext-layout.container.AbstractContainer-method-setItemSize'> /**
76 </span> * Set the size of an item within the Container. We should always use setCalculatedSize.
79 setItemSize: function(item, width, height) {
80 if (Ext.isObject(width)) {
81 height = width.height;
84 item.setCalculatedSize(width, height, this.owner);
87 <span id='Ext-layout.container.AbstractContainer-method-getLayoutItems'> /**
88 </span> * <p>Returns an array of child components either for a render phase (Performed in the beforeLayout method of the layout's
89 * base class), or the layout phase (onLayout).</p>
90 * @return {Array} of child components
92 getLayoutItems: function() {
93 return this.owner && this.owner.items && this.owner.items.items || [];
96 afterLayout: function() {
97 this.owner.afterLayout(this);
99 <span id='Ext-layout.container.AbstractContainer-method-getTarget'> /**
100 </span> * Returns the owner component's resize element.
101 * @return {Ext.core.Element}
103 getTarget: function() {
104 return this.owner.getTargetEl();
106 <span id='Ext-layout.container.AbstractContainer-method-getRenderTarget'> /**
107 </span> * <p>Returns the element into which rendering must take place. Defaults to the owner Container's {@link Ext.AbstractComponent#targetEl}.</p>
108 * May be overridden in layout managers which implement an inner element.
109 * @return {Ext.core.Element}
111 getRenderTarget: function() {
112 return this.owner.getTargetEl();
115 </pre></pre></body></html>