PDA

View Full Version : [2.0b1][SOLVED] Toolbar.Item destroy blows up



harley.333
10 Oct 2007, 7:46 PM
I've got a TabPanel, using 'border' layout, which gets created dynamically. In the east panel, I've got a TabPanel with three tabs. Each tab has a GridPanel with top and bottom toolbar. Everything creates and functions properly. However, when I close the first TabPanel, the toolbar items on the GridPanels barf. Here's the fix I did until the next release:

old code:


Ext.Toolbar.Item.prototype.destroy = function(){
this.td.parentNode.removeChild(this.td);
};


new code:


Ext.Toolbar.Item.prototype.destroy = function(){
if (this.td.parentNode) {
this.td.parentNode.removeChild(this.td);
}
};

jack.slocum
10 Oct 2007, 8:45 PM
Thanks. I have made a change in SVN that should fix the issue.