带复选框且支持搜索功能的下拉列表6
// private onLoad : function() { if (!this.hasFocus) { return; } if (this.store.getCount() > 0) { this.expand(); this.restrictHeight(); if (this.lastQuery == this.allQuery) { if (this.editable) { this.el.dom.select(); } if (!this.selectByValue(this.value, true)) { this.select(0, true); } } else { this.selectNext(); if (this.typeAhead && this.lastKey != Ext.EventObject.BACKSPACE && this.lastKey != Ext.EventObject .DELETE) { this.taTask.delay(this.typeAheadDelay); } } } else { this.onEmptyResults(); } }, // private onTypeAhead : function() { if (this.store.getCount() > 0) { var r = this.store.getAt(0); var newValue = r.data[this.displayField]; var len = newValue.length; var selStart = this.getRawValue().length; if (selStart != len) { this.setRawValue(newValue); this.selectText(selStart, newValue.length); } } },