*/
/**
- * @class Roo.GridPanel
- * @extends Roo.ContentPanel
+ * @class Roo.ViewPanel
+ * @extends Roo.panel.Content
* @constructor
- * Create a new GridPanel.
+ * Create a new ViewPanel.
* @param {Roo.grid.Grid} grid The grid for this panel
* @param {String/Object} config A string to set only the panel's title, or a config object
*/
Roo.ViewPanel = function(el, config){
-
-
+
this.wrapper = Roo.DomHelper.append(document.body, // wrapper for IE7 strict & safari scroll issue
{tag: "div", cls: "x-layout-grid-wrapper x-layout-inactive-content"}, true);
- this.wrapper.dom.appendChild(view.el.dom);
+ this.wrapper.dom.appendChild(el.dom);
Roo.ViewPanel.superclass.constructor.call(this, this.wrapper, config);
this.footer = Roo.factory(this.footer, Roo);
}
+ //??? create teh view???
//grid.monitorWindowResize = false; // turn off autosizing
//grid.autoHeight = false;
//this.grid.getGridEl().replaceClass("x-layout-inactive-content", "x-layout-component-panel");
};
-Roo.extend(Roo.ViewPanel, Roo.ContentPanel, {
+Roo.extend(Roo.ViewPanel, Roo.panel.Content, {
+
+ autoCreate : true,
getId : function(){
return this.view.id;
},
destroy : function(){
this.grid.destroy();
delete this.grid;
- Roo.GridPanel.superclass.destroy.call(this);
+ Roo.panel.Grid.superclass.destroy.call(this);
}
});
\ No newline at end of file