Results 1 to 3 of 3

Thread: disabled selectfield acts as if enabled when navigated to using tab

Threaded View

Previous Post Previous Post   Next Post Next Post
    Success! Looks like we've fixed this one. According to our records the fix was applied for TOUCH-3889 in a recent build.
  1. #1
    Sencha User
    Join Date
    Oct 2012
    Posts
    3
    Vote Rating
    0
      0  

    Default disabled selectfield acts as if enabled when navigated to using tab

    // bug / feature deficiency
    // disabled selectfield acts as if enabled when navigated to using tab key in chrome Version 23.0.1271.97 m

    // 'Ext.field.Select' file: Select.js


    onMaskTap: function() {

    //-----------------------------------------
    //if (this.getDisabled()) { move this to onFocus(e)
    // return false;
    //}
    //----------------------------------------------------
    this.onFocus();
    return false;
    }
    onFocus: function (e) {
    //- will handle tab navigation focus when selectfield is disabled
    if(this.getDisabled())
    {
    return false;
    }
    //--------- continue with original code
    var component =this.getComponent();
    this.fireEvent('focus',this, e);

    if
    (Ext.os.is.Android4){
    component.input.dom.focus();
    }
    component.input.dom.blur();
    this.isFocused =true;
    this.showPicker();
    }

    Test case:

    Code:
    Ext.Viewport.add({
        xtype : 'formpanel',
        items : [
            {
                xtype : 'textfield',
                label : 'Foo'
            },
            {
                xtype    : 'selectfield',
                label    : 'Choose one',
                disabled : true,
                options  : [
                    { text : 'First Option',  value : 'first'  },
                    { text : 'Second Option', value : 'second' },
                    { text : 'Third Option',  value : 'third'  }
                ]
            }
        ]
    });
    Last edited by mitchellsimoens; 8 Jan 2013 at 7:23 AM. Reason: Added testcase to post

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •