/*!
- * Ext JS Library 3.0.3
+ * Ext JS Library 3.1.0
* Copyright(c) 2006-2009 Ext JS, LLC
* licensing@extjs.com
* http://www.extjs.com/license
\r
constructor: function(config){\r
Ext.layout.CardLayout.superclass.constructor.call(this, config);\r
- this.forceLayout = (this.deferredRender === false);\r
+ // this.forceLayout = (this.deferredRender === false);\r
},\r
\r
/**\r
* @param {String/Number} item The string component id or numeric index of the item to activate\r
*/\r
setActiveItem : function(item){\r
+ var ai = this.activeItem;\r
item = this.container.getComponent(item);\r
- if(this.activeItem != item){\r
- if(this.activeItem){\r
- this.activeItem.hide();\r
+ if(ai != item){\r
+ if(ai){\r
+ ai.hide();\r
+ ai.fireEvent('deactivate', ai);\r
}\r
var layout = item.doLayout && (this.layoutOnCardChange || !item.rendered);\r
this.activeItem = item;\r
- item.show();\r
+ if(item){\r
+ item.show();\r
+ }\r
this.layout();\r
- if(layout){\r
+ if(item && layout){\r
item.doLayout();\r
}\r
+ item.fireEvent('activate', item);\r
}\r
},\r
\r