4 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
5 <title>The source code</title>
6 <link href="../prettify/prettify.css" type="text/css" rel="stylesheet" />
7 <script type="text/javascript" src="../prettify/prettify.js"></script>
8 <style type="text/css">
9 .highlight { display: block; background-color: #ddd; }
11 <script type="text/javascript">
12 function highlight() {
13 document.getElementById(location.hash.replace(/#/, "")).className = "highlight";
17 <body onload="prettyPrint(); highlight();">
18 <pre class="prettyprint lang-js"><span id='Ext-layout-container-AbstractFit'>/**
19 </span> * @class Ext.layout.container.AbstractFit
20 * @extends Ext.layout.container.Container
21 * <p>This is a base class for layouts that contain <b>a single item</b> that automatically expands to fill the layout's
22 * container. This class is intended to be extended or created via the <tt>layout:'fit'</tt> {@link Ext.container.Container#layout}
23 * config, and should generally not need to be created directly via the new keyword.</p>
24 * <p>FitLayout does not have any direct config options (other than inherited ones). To fit a panel to a container
25 * using FitLayout, simply set layout:'fit' on the container and add a single panel to it. If the container has
26 * multiple panels, only the first one will be displayed. Example usage:</p>
27 * <pre><code>
28 var p = new Ext.panel.Panel({
33 html: '&lt;p&gt;This is the inner panel content&lt;/p&gt;',
37 </code></pre>
39 Ext.define('Ext.layout.container.AbstractFit', {
41 /* Begin Definitions */
43 extend: 'Ext.layout.container.Container',
47 itemCls: Ext.baseCSSPrefix + 'fit-item',
48 targetCls: Ext.baseCSSPrefix + 'layout-fit',