You found a bug! We've classified it as EXTJSIV-8121 . We encourage you to continue the discussion and to find an acceptable workaround while we work on a permanent fix.
  1. #1
    Sencha User
    Join Date
    Aug 2009
    Posts
    42
    Vote Rating
    0
    fguest is on a distinguished road

      0  

    Default Ext.TabPanel: event 'activate' not fired for first added tab

    Ext.TabPanel: event 'activate' not fired for first added tab


    Press button "Add" twice. In console print info only for "Panel-2". After select "Panel-1" print info for "Panel-1".

    P.S. In 4.0.7 for "Panel-1" event 'activate' fired twice for first activate...

    Code:
    var cnt = 0;
        var b_add = Ext.create('Ext.Button', {
          renderTo: document.body,
          text: 'Add',
          handler: function() {
            cnt++;
            var p = Ext.create('Ext.panel.Panel', {
              title: 'Panel-' + cnt,
              items: [
                {html: 'Text-' + cnt}
              ],
              listeners: {
                activate: function(a) {
                  console.info("Activate", a);
                }
              }
            });
            panel.add(p);
            panel.setActiveTab(p);
          }
        });
        var panel = Ext.create('Ext.tab.Panel', {
          renderTo: document.body,
          width: 500,
          height: 300
        });
    Last edited by mitchellsimoens; 28 Dec 2012 at 9:01 AM. Reason: fix test case

  2. #2
    Sencha - Senior Forum Manager mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    St. Louis, MO
    Posts
    33,582
    Vote Rating
    434
    mitchellsimoens has much to be proud of mitchellsimoens has much to be proud of mitchellsimoens has much to be proud of mitchellsimoens has much to be proud of mitchellsimoens has much to be proud of mitchellsimoens has much to be proud of mitchellsimoens has much to be proud of mitchellsimoens has much to be proud of mitchellsimoens has much to be proud of

      0  

    Default


    Thanks for the report! I have opened a bug in our bug tracker.