質問

Getting an exception like this while trying to have a single column vertical buttongroup:

Uncaught Error: INDEX_SIZE_ERR: DOM Exception 1 [ext-all-dev.js:88026]

var btn1 = Ext.create('Ext.button.Button', {
    text: 'BTN 1',
    iconCls: 'icon-database-go-32'
});

var btn2 = Ext.create('Ext.button.Button', {
    text: 'BTN 2',
    iconCls: 'icon-data-table-32'
});

var actions = Ext.create('Ext.container.ButtonGroup', {
    columns: 1,
    defaults: {
        scale: 'large',
        iconAlign: 'top',
        rowspan: 3
    },
    title: 'Actions',
    items: [btn1, btn2]
});

this.dockedItems = [{
    xtype: 'toolbar',
    dock: 'left',
    items: [actions]    
}];
役に立ちましたか?

解決

Well, the rowspan kills it. Here is a tested example that works

var actions = Ext.create('Ext.container.ButtonGroup', {
    columns: 1,
    title: 'Actions',
    items: [
    {
        text: 'BTN 2',
        iconCls: 'icon-data-table-32',
        scale: 'large',
        iconAlign: 'top'
    }, {
        text: 'BTN 1',
        iconCls: 'icon-database-go-32',
        scale: 'large',
        iconAlign: 'top'
    }]
});

Here is the JSFiddle

ライセンス: CC-BY-SA帰属
所属していません StackOverflow
scroll top