1

I would like to add a button in the fieldset title. Maybe something like this:

var btn = Ext.create('Ext.Button', {
    text: 'my button'
});

...

xtype: 'fieldset',
title: 'my title' + btn

Is something like this possible. I really don't want to use a delegate to reference html for the tap event. Any ideas?

squistbe
  • 305
  • 1
  • 3
  • 18

1 Answers1

4

Behind the scene fieldset's title is a Ext.Title component. So do not use the

{xtype: 'fieldset', title: 'title'... }

but

{xtype: 'fieldset', items: [{xtype: 'titlebar', title: 'Title', items: [{xtype: 'button'...}], ...}],... }

Cheers, Oleg

Titouan de Bailleul
  • 12,920
  • 11
  • 66
  • 121
olegtaranenko
  • 3,722
  • 3
  • 26
  • 33