I would like to disable or hide the toolbar items. With the code above, only the event beforerender is executed and the items count is 0. How i can check all the items?
Code:
new Ext.Toolbar({
items:[{
id: "titem-add",
text:'Add Button',
handler: Ext.emptyFn
}, "-", {
id: "titem-other",
text: 'Other Button',
handler: Ext.emptyFn
}],
listeners:{
beforeshow: function(toolbar){
console.log("beforeshow", toolbar.items.getCount());
},
beforerender: function(toolbar){
console.log("beforerender", toolbar.items.getCount());
}
}
})
Thank's in advance.