체크 상자가 있고 검색 기능을 지원하는 드롭다운 목록 5

2128 단어 ext

// private
    fireKey : function(e)
    {
        if (e.isNavKeyPress() && !this.list.isVisible())
        {
            this.fireEvent("specialkey", this, e);
        }
    },

    // private
    onResize: function(w, h)
    {
        Ext.form.ComboBox.superclass.onResize.apply(this, arguments);
        if (this.list && this.listWidth === undefined)
        {
            var lw = Math.max(w, this.minListWidth);
            this.list.setWidth(lw);
            this.innerList.setWidth(lw - this.list.getFrameWidth('lr'));
        }
    },

    // private
    onDisable: function()
    {
        Ext.form.ComboBox.superclass.onDisable.apply(this, arguments);
        if (this.hiddenField)
        {
            this.hiddenField.disabled = this.disabled;
        }
    },
    setEditable : function(value)
    {
        if (value == this.editable)
        {
            return;
        }
        this.editable = value;
        if (!value)
        {
            this.el.dom.setAttribute('readOnly', true);
            this.el.on('mousedown', this.onTriggerClick, this);
            this.el.addClass('x-combo-noedit');
        }
        else
        {
            this.el.dom.setAttribute('readOnly', false);
            this.el.un('mousedown', this.onTriggerClick, this);
            this.el.removeClass('x-combo-noedit');
        }
    },

    // private
    onBeforeLoad : function()
    {
        if (!this.hasFocus)
        {
            return;
        }
        this.innerList.update(this.loadingText ? '<div class="loading-indicator">' + this.loadingText + '</div>' : '');
        this.restrictHeight();
        this.selectedIndex = -1;
    },

좋은 웹페이지 즐겨찾기