3
我的問題是,如何啓動帶有垂直按鈕的底部工具欄的面板。Sencha-touch:帶有按鈕自動高度的工具欄
這裏是我的代碼
var filterActionsButtons = [
{
ui : 'confirm',
text: 'Apply for current view',
},
{
ui : 'action',
text: 'Apply and Save in your profile',
},
{
ui: 'decline',
text: 'Cancel',
handler: function() {
filterPanel.hide();
}
}
];
var filterPanel =
new Ext.Panel({
fullscreen: true,
modal: true,
floating: true,
centered: true,
//width: Ext.is.Phone ? 260 : 400,
//height: Ext.is.Phone ? 260 : 400,
//autoWidth: true,
layout: 'fit',
scroll: 'vertical',
html: '<h2>Agencies</h2>...',
dockedItems: [
{
xtype: 'toolbar',
dock: 'top',
title:'Manage your filters',
},
{
xtype: 'toolbar',
dock: 'bottom',
layout: {
type: 'vbox',
align: 'strech',
},
height: '100',
//height: 'auto',
items: filterActionsButtons,
}
],
});
它的工作原理,因爲我指定的高度:「100」,但我想指定自動高度或無高度。當我爲高度屬性指定'auto'時,按鈕很小,左邊對齊,當我點擊一個按鈕時,他就是(按鈕)拉鍊!
那麼,如何使用高度:'自動'工具欄與相同寬度的按鈕(自動strech)?
如果垂直工具欄的高度不足以容納所有的按鈕,你的答案會縮水每個按鈕。不是我正在尋找的解決方案。 – Arvin 2014-02-28 01:47:18