PDA

View Full Version : [FIXED] Hide even fires when a Component is Shown



lylepratt
19 Nov 2011, 7:08 PM
The 'hide' event is firing when a component is shown.

Example:


detailView.on('hide', function() {
console.log('hidden');
})
Ext.ComponentQuery.query('Main')[0].setActiveItem(detailView); //hide event will be fired

Jamie Avins
21 Nov 2011, 9:16 AM
Thank you for the report.

rdougan
21 Nov 2011, 4:41 PM
I can't seem to reproduce this when manually changing the active item after instantiation.

However, when you first create a container with a card layout, all items will be hidden when it is instantiated, then the activeItem will be shown, therefor the show event will be fired. So ideally, what you should listen to is the activate or deactivate events on the cards themselves, or the `activeitemchange` on the container.