On a whim today, I wanted to hide the corresponding toolbar when switching the tabpanel, but the result was blank, so let’s bear with the blank first!
No nonsense, here’s the code, the code is as follows:
//Hide
Ext.getCmp('Tab2').tbar.hide();
Ext.getCmp('Tab2').tbar.dom.style.height = '0px';
// Show
Ext.getCmp('Tab2').tbar.show();
Ext.getCmp('Tab2').tbar.dom.style.height = '27px';//The height can be defined by yourself
Done, so easy!