Success! Looks like we've fixed this one. According to our records the fix was applied for TOUCH-4130 in a recent build.
  1. #1
    Sencha User
    Join Date
    Mar 2008
    Posts
    24
    Vote Rating
    0
    michael.piecko is on a distinguished road

      0  

    Default [2.2.0 Beta] Ext.field.Select does not destroy its list panel (picker)

    [2.2.0 Beta] Ext.field.Select does not destroy its list panel (picker)


    I noticed a growing number of items inside my Ext.Viewport whenever i used a 'selectfield' with the list picker (usePicker: false). As recommended i destroy all panels that i don't use anymore in my Ext.Viewport. Here i noticed that the number is growing after calling a form with a selectfield in it, even if the form panel is destroyed.

    I solved it by adding the following lines inside the destroy() method of Ext.field.Select:

    Code:
      
            ...  
            if (this.listPanel) {
                Ext.destroy(this.listPanel);
            }
    
            if (this.picker) {
                Ext.destroy(this.picker);
            }
            ...
    Michael

    Code:
    Ext.Viewport.add({
        items : [
            {
                html : 'Open picker on select field first, then tap button. Console should show undefined.'
            },
            {
                xtype   : 'selectfield',
                label   : 'Test',
                options : [
                    { text : 'First Option',  value : 'first'  },
                    { text : 'Second Option', value : 'second' },
                    { text : 'Third Option',  value : 'third'  }
                ],
                defaultTabletPickerConfig : {
                    id : 'myselectfieldlist'
                }
            },
            {
                xtype   : 'button',
                text    : 'Destroy Select Field',
                handler : function() {
                    var field = Ext.Viewport.down('selectfield'),
                        cmp;
    
                    field.destroy();
    
                    cmp = Ext.getCmp('myselectfieldlist');
    
                    console.log(cmp); //should be undefined
                }
            }
        ]
    });
    Last edited by mitchellsimoens; 14 Mar 2013 at 9:41 AM. Reason: Added test

  2. #2
    Sencha - Senior Forum Manager mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    35,731
    Vote Rating
    754
    mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute

      0  

    Default


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

  3. #3
    Sencha User
    Join Date
    Mar 2008
    Posts
    24
    Vote Rating
    0
    michael.piecko is on a distinguished road

      0  

    Default


    Thanks for the test case. This is true for both, the tablet picker and the phone picker.

    Michael

Thread Participants: 1

film izle

hd film izle

film sitesi

takipci kazanma sitesi

takipci kazanma sitesi

güzel olan herşey

takipci alma sitesi

komik eğlenceli videolar