/**
* @class Roo.bootstrap.layout.Border
* @extends Roo.bootstrap.layout.Manager
+ * @builder-top
* This class represents a common layout manager used in desktop applications. For screenshots and more details,
* please see: examples/bootstrap/nested.html<br><br>
*/
Roo.bootstrap.layout.Border = function(config){
config = config || {};
-
Roo.bootstrap.layout.Border.superclass.constructor.call(this, config);
+
+
Roo.each(Roo.bootstrap.layout.Border.regions, function(region) {
if(config[region]){
config[region].region = region;
};
-Roo.bootstrap.layout.Border.regions = ["north","south","east","west","center"];
+Roo.bootstrap.layout.Border.regions = ["center", "north","south","east","west"];
Roo.extend(Roo.bootstrap.layout.Border, Roo.bootstrap.layout.Manager, {
+
+ parent : false, // this might point to a 'nest' or a ???
+
/**
* Creates and adds a new region if it doesn't already exist.
* @param {String} target The target region key (north, south, east, west or center).
},
// private (kinda)
- bindRegion : function(r)
- {
+ bindRegion : function(r){
this.regions[r.config.region] = r;
r.on("visibilitychange", this.layout, this);
*/
layout : function()
{
- Roo.log('calling layout!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!');
- Roo.log(this);
if(this.updating) {
return;
}
delete cfg.items;
}
var nb = false;
+
+ if ( region == 'center') {
+ Roo.log("Center: " + cfg.title);
+ }
+
switch(cfg.xtype)
{
case 'Content': // ContentPanel (el, cfg)
case 'Scroll': // ContentPanel (el, cfg)
case 'View':
- cfg.autoCreate = true;
+ cfg.autoCreate = cfg.autoCreate || true;
ret = new cfg.xns[cfg.xtype](cfg); // new panel!!!!!
//} else {
// var el = this.el.createChild();
},
+
// private
factory : function(cfg)
{
cfg.mgr = this;
var r = Roo.bootstrap.layout;
-
+ Roo.log(target);
switch(target){
case "north":
return new r.North(cfg);