在ExtJS 4.2.2中。我有一个这样的hbox容器:
Ext.create('Ext.Panel', {
width: 500,
height: 300,
title: "HBoxLayout Panel",
layout: {
type: 'hbox',
align: 'stretch'
},
renderTo: document.body,
items: [{
xtype: 'panel',
title: 'Inner Panel One',
flex: 2
},{
xtype: 'panel',
title: 'Inner Panel Two',
flex: 1
},{
xtype: 'panel',
title: 'Inner Panel Three',
flex: 1
}]
});
这只是文档中的示例。但是我希望三个不同面板之间的垂直线是可拖动的,以便用户能够调整每个面板的大小。
谢谢您的帮助!
最佳答案
您正在寻找Splitter。在面板之间,添加:
{xtype: 'splitter'}
示例:https://fiddle.sencha.com/#fiddle/r4h