如何设置treepanel的高度让其自动填充到这个的panel里,见图。
1个回答
展开全部
这个不对,反正我这里没有效果。
问题补充:还是不行,给你代码,帮我测试一下啊,谢谢。 Setting_Panel=Ext.extend(Ext.form.FormPanel,{ constructor:function(){ Setting_Panel.superclass.constructor.call(this,{ renderTo:'ShowPanel', split :true, width:500, draggable :true, height:600, collapsible :true, fitToFrame :true, closable :true, frame:true, title :"系统资源设定", layout :'accordion',// 下拉功能属性 layoutConfig : { titleCollapse :false, animate :true, activeOnTop :true }, items : [{ title :'我的系统', html :'' },{ title :'系统设置', html :'' }] }) } }); Seeting_TreeRoot = Ext.extend(Ext.tree.AsyncTreeNode, { constructor : function() { Seeting_TreeRoot.superclass.constructor.call(this, { text :'我的系统目录', draggable :false, expanded :true, id :'root', href :'#' }) } }); Seeting_Treepanel = Ext.extend(Ext.tree.TreePanel, { Root :null, constructor : function(Root) { this.Root = Root; Seeting_Treepanel.superclass.constructor.call(this, { root :this.Root, renderTo :'Mysystems', //width :250, frame :true, layout:'fit', autoWidth:true , autoHeigth:false, // loader:treeLoader, animate :true, useArrows :true, autoHeight :true, autoScroll :true, border :false }); this.addEvents("OnClick");// 添加事件 } }); 问题补充:yourgame (架构师)
问题补充: Setting_Panel=Ext.extend(Ext.form.FormPanel,{ constructor:function(){ Setting_Panel.superclass.constructor.call(this,{ renderTo:'ShowPanel', split :true, width:500, draggable :true, height:600, collapsible :true, fitToFrame :true, closable :true, frame:true, title :"系统资源设定", layout :'accordion',// 下拉功能属性 layoutConfig : { titleCollapse :false, animate :true, activeOnTop :true }, items : [{ title :'我的系统', html :'' },{ title :'系统设置', html :'' }] }) } }); Seeting_TreeRoot = Ext.extend(Ext.tree.AsyncTreeNode, { constructor : function() { Seeting_TreeRoot.superclass.constructor.call(this, { text :'我的系统目录', draggable :false, expanded :true, id :'root', href :'#' }) } }); Seeting_Treepanel = Ext.extend(Ext.tree.TreePanel, { Root :null, constructor : function(Root) { this.Root = Root; Seeting_Treepanel.superclass.constructor.call(this, { root :this.Root, renderTo :'Mysystems', frame :true, animate :true, useArrows :true, autoHeight :true, autoScroll :true, border :false }); this.addEvents("OnClick");// 添加事件 } }); Ext.onReady( function() { new Setting_Panel(); new Seeting_Treepanel(new Seeting_TreeRoot()); }); 问题补充:不过你要引入Extjs的包 2.2.1或者2.2都可以。
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询